Commit Graph
17 Commits
Author SHA1 Message Date
inference-admin e8da85f730 chat: fix and complete voice chat (STT/TTS) wiring — full endpoint URLs, live gateway key, engine defaults
The speech section shipped 6 Nov was doubly broken: LibreChat POSTs to
speech.*.openai.url VERBATIM in 0.8.8, so the base '/v1' URL 404'd, and the
STT_API_KEY/TTS_API_KEY env values held a key that no longer exists on the
gateway (401 token_not_found). Also:
- STT: tinfoil/voxtral-small-24b (token-priced; gateway bills ~$0.00008/request,
  125x under the flat $0.01/request whisper; same TEE provider, verified equal
  quality on dictation clips). Whisper remains allowed on the key as fallback.
- TTS voices: full provider speaker list (an unknown voice 400s at the gateway).
- speechTab: object form seeds Settings->Speech defaults (engineSTT/engineTTS
  external, voice casual_female) for members who never saved their own.
- new gateway key: alias librechat-speech, $5/30d, audio models only, injected
  as STT_API_KEY/TTS_API_KEY app env.

Verified on a throwaway librechat-test install then live (chat.inference.coop):
config/get serves the defaults; /api/files/speech/stt returns a correct
transcript; /api/files/speech/tts/manual returns audio. Known gap (gateway-side,
NOT this repo): aspeech rows log $0 spend — voxtral-tts is unmetered on the
gateway's aspeech path while the co-op pays ~$0.002/request.
2026-11-07 18:56:45 +00:00
inference-admin 80db1d235f chat: make the member's web-search toggle authoritative — drop modelSpec webSearch defaults
A modelSpec webSearch:true forces web_search into the ephemeral agent on every
new conversation and re-applies it on context re-keys (the client's spec effect
does not consult per-conversation toggle state for new convos), so the model
could call web_search (SearXNG) with the member's toggle OFF. The toggle state
and the ephemeral agent are the same store, but the spec default kept winning.
Remove the spec-level default so the toggle alone decides; interface.webSearch
permission, defaultPinnedTools badge and the searxng webSearch block stay.
Server-side needs no change: @librechat/api never injects search from specs.
2026-11-06 04:24:59 +00:00
inference-admin 981ef5aac2 chat: shorten the welcome line — 'Your co-op, your choice.' (the long no-API-key explanation outlived its purpose) 2026-11-02 06:57:09 +00:00
inference-admin fb1b6fd86e Pin manifest to 20261027-d099d31 2026-10-27 22:02:11 +00:00
inference-admin aca430cea6 release.sh: retry served-HTML checks during the post-deploy container swap
A fetch seconds after 'App is updated' can come back empty while the container
recreates, which false-negatived the x-coop-build check on the 1.4.5 deploy
(2026-10-26). http_body retries 3x before declaring failure.
2026-10-26 03:31:38 +00:00
inference-admin 91b274969b Pin manifest to 20261026-60ee597 2026-10-26 03:27:57 +00:00
inference-admin f195f4509b Pin manifest to 20261026-13f2b3a 2026-10-26 03:24:17 +00:00
inference-admin bcc85709f6 release.sh: fix the builder-login detection (info output is multiline) 2026-10-26 02:13:48 +00:00
inference-admin cb7661dde6 release.sh: also accept a registry app password from the env
REGISTRY_BUILD_TOKEN (+ optional REGISTRY_BUILD_USERNAME) lets a build run from
any host with the token in its environment, no ~/.cloudron.json builder config
required. The narrow credential (app password scoped to the registry app) is the
least-privileged way to hand a host build rights; with no token and no builder
config the script prints both bootstrap routes and exits instead of guessing.
2026-10-26 02:13:28 +00:00
inference-admin b657030d24 release.sh: correct the build prerequisites (builds are remote, not docker-local)
I had it wrong: `cloudron builder build` uploads the build context and the
registry app's BuildKit builds it — the caller needs no docker, only a registry
login. The guard now checks for that login and prints both bootstrap routes
(narrow app password scoped to the registry app, or the CLI device flow) instead
of blaming a missing docker binary.
2026-10-26 01:39:38 +00:00
inference-admin 2357d5d55a release.sh: refuse to pin from a non-master branch (the pin commit lands on master) 2026-10-26 01:39:15 +00:00
inference-admin 8f9d6a1e20 Stage: bump the appstore pin to 1.4.5 (uv 0.13.5, LibreChat unchanged at 0.8.8)
Not deployed. Diffed against the official 1.4.5 manifest: version, changelog and
the base-image tag were the only differences, so this copy now matches official
field-for-field except dockerImage (+ our scheduler block).

The risk is the overlay, not the bump: every build-time patch runs against a new
base layer, and they are all non-fatal by design, so a silent no-op is the failure
mode. Verify on the rendered DOM. Rollback = repoint dockerImage to
20261023-65a38bb.
2026-10-26 01:36:11 +00:00
inference-admin 0102c1790f Stage: run the per-member key seed from the image, not the volume
Ready to build, not yet deployed — deploying the repointed scheduler command
without the new image would break the seed on schedule, which is why this sits on
a branch with the ordering written down.

- Dockerfile: COPY sync-keys.js /app/code/sync-keys.js; rule 3 in the header now
  states the one exception (operational scripts that must not depend on a volume).
- CloudronManifest.json: scheduler command repointed to /app/code/sync-keys.js.
- README: ordering (build -> deploy -> verify -> delete the volume copy), and the
  table row moved from the volume layer to the image layer.

After deploy: delete /app/data/sync-keys.js, but keep it until you are past the
rollback window — the previous image tag still runs the volume copy.
2026-10-26 01:35:06 +00:00
inference-admin bb2503bb47 Add release.sh; make the verify block honest; print the seed script's own revision
Three drifts between this repo and reality, found while moving the per-member key
seed into the app:

- The 'verify after every image deploy' block asserted the CREAM palette
  (rgb(250,248,245)). The deployed palette has been the green wash
  (rgb(234,243,234) with white text areas) for some time, so a correct deploy
  would have read as a failure — and invited someone to 'fix' the CSS back.
- The block still verified against librechat-test.inference.coop; the swap to
  chat.inference.coop happened 2026-10-21 and that alias is not provisioned.
- Nothing checked that the scheduler task's script exists in the running image,
  which is exactly the failure mode a manifest repoint can introduce.

release.sh encodes the documented release flow (dirty-tree guard, always
--no-cache, pin-before-deploy) and its verify subcommand runs checks 1-5 plus the
seed task's log lines. sync-keys.js now prints its own md5 prefix on every run,
so a stale volume copy can never hide again — the repo copy's md5 is the
authority.

Verified: ./release.sh verify passes all six checks against the live app;
./release.sh volume sync-keys.js confirms md5 parity.
2026-10-26 01:34:22 +00:00
inference-admin 2d66ea212d README: document the in-app key-sync scheduling, the creds file, and the fail-closed guards 2026-10-25 22:44:34 +00:00
inference-admin e544dc4a11 key sync: read CREDS_KEY/CREDS_IV from the volume, add a failure diagnostic
The first scheduled run failed closed (good) — Cloudron's scheduler addon runs
each task in its OWN container, so the app's process env is absent there and
/proc/1/environ belongs to the task launcher, not to LibreChat. CREDS_KEY/CREDS_IV
now come from /app/data/.librechat-creds (root:cloudron 0640), written from the
live app env; a stale key makes the decrypt-against-existing-rows guard refuse to
write rather than corrupt member keys. Credential failure now also writes
/app/data/key-sync-diag.txt so a future failure explains itself.

Verified: the 22:40 scheduled fire logged 'creds check: decrypt-ok (25 existing
row(s))' / 'done: 50 seeded, 15 skipped'.
2026-10-25 22:42:13 +00:00
inference-admin 4e28b7a612 Key sync runs inside the app: scheduler addon task every 10 min, plus write guards
The per-member key seed ran from a steward cron on the co-op agent VM, shelling
into this app over the Cloudron API. That made a member-facing function depend on
a separate machine's uptime and paths (it went silently stale once, exiting 127
on schedule while the job looked healthy).

- CloudronManifest.json: addons.scheduler gains librechat_key_sync
  (cd /app/code/librechat/api && node /app/data/sync-keys.js, */10 * * * *).
  Official addon set (postgresql, mongodb, localstorage, oidc, sendmail) and the
  dockerImage pin are untouched.
- sync-keys.js: refuse to write unless CREDS_KEY can first decrypt an existing
  key row, and unless each fresh ciphertext round-trips back to the plaintext.
  Scheduled runs get a different environment than an interactive exec, so a wrong
  or absent CREDS_KEY must fail loudly instead of overwriting working member keys.
2026-10-25 22:25:10 +00:00