Surface + document the loopback Local API for on-device agents (Settings toggle + docs) - #715
Surface + document the loopback Local API for on-device agents (Settings toggle + docs)#715PaulBlackSwan wants to merge 27 commits into
Conversation
The loopback-only Local API (POST /v1/transcribe, /v1/postprocess) already exists but was enable-only via a hidden "LocalAPIEnabled" default and was undocumented. This surfaces and documents it: - SettingsStore.localAPIEnabled (reuses the existing "LocalAPIEnabled" key) - LocalAPIServer.refresh() to start/stop the server live when toggled - a "Local API (on-device agents)" toggle in Settings (loopback-only, off by default) - README section + docs/local-api.md documenting endpoints & security Lets other apps/agents on the same Mac reuse FluidVoice's transcription instead of loading their own ASR model. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
The PR Policy check is blocking this PR because required template information is missing. Please update the PR description with:
Visual files detected:
Screenshots or video are required for UI, UX, settings, onboarding, overlay, menu bar, or visual behavior changes. If this PR has no visual changes, check the no-visual-change box in the template. If this remains incomplete for 48 hours after opening, the PR may be closed. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 66dbd621be
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
Greptile SummaryThis PR exposes the existing loopback Local API and expands its supported audio contract.
|
…o-cap docs) - LocalAPIServer: ignore state callbacks from a superseded listener (guard self.listener === listener, weak capture) so a rapid off->on toggle can no longer orphan/cancel the newly-installed listener (Codex P2 / Greptile P1). - Qualify the privacy claim: only the HTTP listener and /v1/transcribe are on-device; /v1/postprocess follows the configured provider (may be remote) (toggle text, README, docs). - Describe the accept-time loopback filtering accurately instead of claiming it binds 127.0.0.1. - Document the 300s (5 min) audio-duration cap alongside the 25 MB body cap. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
7d418cb to
0e68a5d
Compare
|
Thanks for the thorough review — all four points addressed in
Rebuilt clean ( |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 0e68a5d532
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
…ed section The toggle sat next to 'Copy to Clipboard', which lives inside the `if accessibilityEnabled` block, so it was hidden until the user granted Accessibility — unrelated to a loopback HTTP API. Moved it to the always-visible 'App Settings' section, and split the long description into description + footnote so it no longer truncates on one line. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
Follow-up in |
settingsToggleRow renders description and footnote on single truncating lines; the previous footnote overflowed. Trimmed it to the essentials — the full contract (non-loopback filtering, limits, post-processing locality) lives in README + docs/local-api.md. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: e88f57419b
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
- LocalAPIServer: the deferred @mainactor task now also checks the server is still running (listener != nil) before creating a handler, so a connection accepted just before stop()/toggle-off is dropped instead of handled. - docs: note that enabling via `defaults` needs an app relaunch (the Settings toggle applies live via refresh()); clarify the 300s audio cap rejects file-path input but truncates inline audioBase64 input. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
34c108d to
cec22e7
Compare
|
Latest round (
Also filled the PR template + added the toggle screenshot to the description. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: cec22e7eb0
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
|
Hi, any ETA on when this might be merged, desperately need access to the local API 🙏 |
|
This pull request has been marked stale because it has had no activity for 5 days. It will be closed in 2 days if there is no further activity. Add the |
|
Is there anything we can do to help you merge this ?
Le mar. 4 août 2026 à 02:29, github-actions[bot] ***@***.***>
a écrit :
… *github-actions[bot]* left a comment (altic-dev/FluidVoice#715)
<#715 (comment)>
This pull request has been marked stale because it has had no activity for
5 days. It will be closed in 2 days if there is no further activity. Add
the keep-open or pinned label to prevent automatic closure.
—
Reply to this email directly, view it on GitHub
<#715?email_source=notifications&email_token=AL63CVP6ERH4GYRKQYILA735IEVABA5CNFSNUABFM5UWIORPF5TWS5BNNB2WEL2JONZXKZKDN5WW2ZLOOQXTKMJXGMYTSMRYGE2KM4TFMFZW63VGMF2XI2DPOKSWK5TFNZ2KYZTPN52GK4S7MNWGSY3L#issuecomment-5173192814>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AL63CVOUXDDA4CKUSZUJ6LL5IEVABAVCNFSNUABGKJSXA33TNF2G64TZHMYTANRRGMZDOMZRGE5US43TOVSTWNBZHAYTKOBSGA3DPILWAI>
.
Triage notifications, keep track of coding agent tasks and review pull
requests on the go with GitHub Mobile for iOS
<https://github.com/notifications/mobile/ios/AL63CVPA7OBTZJAMDI5NHCL5IEVABA5CNFSNUABFM5UWIORPF5TWS5BNNB2WEL2JONZXKZKDN5WW2ZLOOQXTKMJXGMYTSMRYGE2KM4TFMFZW63VGMF2XI2DPOKSWK5TFNZ2KUZTPN52GK4S7NFXXG>
and Android
<https://github.com/notifications/mobile/android/AL63CVOC3ODMXJSGLYHGYOT5IEVABA5CNFSNUABFM5UWIORPF5TWS5BNNB2WEL2JONZXKZKDN5WW2ZLOOQXTKMJXGMYTSMRYGE2KM4TFMFZW63VGMF2XI2DPOKSWK5TFNZ2K4ZTPN52GK4S7MFXGI4TPNFSA>.
Download it today!
You are receiving this because you authored the thread.Message ID:
***@***.***>
|
|
This pull request has been marked stale because it has had no activity for 5 days. It will be closed in 2 days if there is no further activity. Add the |
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 1d1ce5934a
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
|
@codex review |
|
@codex review |
1 similar comment
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 2ebca65d88
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 166ca005bb
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 6285201dbe
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
|
@codex review |
|
I think we should stop rn Paul. Codex will run out before the month ends
unfortunately. I’d advise you to take this offline ahd make the changes and
push once you figure it all out.
Thanks.
…On Thu, Aug 13, 2026 at 1:24 PM Paul BlackSwan ***@***.***> wrote:
***@***.**** commented on this pull request.
------------------------------
In docs/local-api.md
<#715 (comment)>:
> +r = requests.post("http://127.0.0.1:47733/v1/transcribe",
+ json={"path": "/tmp/memo.ogg"}, timeout=90)
Traité : l’exemple Python lit maintenant le token per-user avec defaults
et envoie le header Authorization: Bearer ….
—
Reply to this email directly, view it on GitHub
<#715?email_source=notifications&email_token=BVSOW2QYKF6BN3CTFRN4S435JYPYTA5CNFSNUABKM5UWIORPF5TWS5BNNB2WEL2QOVWGYUTFOF2WK43UKJSXM2LFO4XTIOJTGEZDQNJWGY22M4TFMFZW63VHNVSW45DJN5XKKZLWMVXHJLDGN5XXIZLSL5RWY2LDNM#discussion_r3778834623>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/BVSOW2SK7ZMWJQXIBYH5PNL5JYPYTAVCNFSNUABGKJSXA33TNF2G64TZHMYTANRRGMZDOMZRGE5US43TOVSTWNBZHAYTKOBSGA3DPILWAI>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 2f6788f75f
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 687e040390
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
|
@codex review |
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 06ad4b9279
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
|
@codex review |
|
Codex Review: Didn't find any major issues. Delightful! Reviewed commit: ℹ️ About Codex in GitHubCodex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback". |

Description
FluidVoice already ships a loopback-only Local API (
LocalAPIServer:POST /v1/transcribe,POST /v1/postprocess,GET /v1/health, plus history/dictionary), but it can only be enabled through the hiddenLocalAPIEnableddefault and is undocumented. This PR surfaces and documents it so other apps and AI agents running on the same Mac can reuse FluidVoice's transcription instead of bundling and loading their own ASR model.SettingsStore.localAPIEnabled— reuses the existing"LocalAPIEnabled"key (no change to how the server reads config).LocalAPIServer.refresh()— starts/stops the listener live when the setting changes (no app restart).docs/local-api.md(endpoints, request/response, security, limits, examples).Type of Change
Related Issue or Discussion
Related to #529 (Companion CLI for Local API — adoption discussion) and #414 (Extend the LocalAPI to read/set the speech model…). This PR surfaces the existing Local API via a Settings toggle and documents it (endpoints, security, limits), which directly supports the external/agent adoption those threads discuss. No dedicated issue was opened for the toggle+docs itself — happy to file one if you'd prefer.
Testing
swiftlint --strict --config .swiftlint.yml Sourcesswiftformat --config .swiftformat Sourcesxcodebuild -scheme Fluid -configuration Debug build→ BUILD SUCCEEDED. Manual checks: toggle on →GET /v1/health200 on127.0.0.1:47733;POST /v1/transcribe {"path": …}returns the transcript reusing the already-warm model; toggle off → listener stops; rapid off→on handled cleanly; non-loopback peer refused.Screenshots / Video
Notes
Addressed the automated review feedback:
stateUpdateHandlernow guardsself.listener === listener(weak capture) so a rapid off→on toggle can't orphan or cancel the freshly-installed listener; and connections accepted just beforestop()are now dropped instead of handled after disable./v1/transcribeare on-device;/v1/postprocessfollows the configured provider (may be remote). Documented the 300 s audio cap (file-pathinput rejected; inlineaudioBase64truncated) and that enabling viadefaultsneeds a relaunch, whereas the Settings toggle applies live.