Skip to content

fix(gateway): report stt-tts readiness and transports in talk.catalog - #165481

Open
holny wants to merge 8 commits into
openclaw:mainfrom
holny:fix/165363-talk-catalog-stt-tts
Open

holny wants to merge 8 commits into
openclaw:mainfrom
holny:fix/165363-talk-catalog-stt-tts

Conversation

@holny

@holny holny commented Oct 5, 2026 •

Copy link
Copy Markdown
Contributor

Related: #165363

What Problem This Solves

Android can reject a working native Talk setup because setup readiness is taken from an unrelated realtime provider, while talk.catalog does not expose selected-speech readiness and transport metadata.

User Impact

Configured native Talk can use device speech recognition and the selected speech provider without requiring a realtime provider. Existing device-TTS fallback is preserved for missing or unsupported speech providers; a selected, known provider without credentials still requires setup. Realtime Talk continues to use realtime readiness.

No configuration migration, schema change, or new dependency is introduced. Physical-device/live-provider and fresh-install/latest-stable upgrade validation remain outstanding; the evidence below does not claim those flows have been tested.

Why This Change Was Made

  • Derive speech.ready from the active speech row's asynchronous configured result and expose managed-room transport metadata.
  • Reuse Android's existing Talk route parser to select native-speech or realtime readiness. Native recognition does not depend on Gateway transcription readiness.
  • Invalidate setup readiness after configuration changes and reject stale refresh results. Label the shared setup row “Talk,” not “Realtime Talk.”
  • Regenerate the source-owned native localization inventory for the changed labels and configuration-error text. Translated catalogs and locale metadata remain owned by the localization workflow.

Original implementation by @holny; Android route-readiness follow-up and CI correction contributed with @IWhatsskill.

Work sessions

Evidence

Current localization follow-up

Commit 7784d02a30ab425bfb75aef40a155ba778c3245a changes only apps/.i18n/native-source.json (4 additions, 2 deletions), generated by pnpm native:i18n:baseline.

  • Reproduced the exact native app i18n inventory drift detected failure on 63959e26026939388010d16ca2b133d0b7a4891b using pnpm native:i18n:verify.
  • After regeneration, pnpm native:i18n:verify passes, including Android and Apple source-localization checks; 4,483 inventory entries.
  • Repeated generation is byte-identical. Verification passes again after the commit; git diff --check passes. Local runtime: Node 26.8.2, repository-pinned pnpm 12.9.0, frozen-lockfile dependencies.

Android behavior and review — retained evidence for 63959e2

The localization-only follow-up does not change these runtime/test sources. These are prior-commit results, not a new execution of the whole suite:

  • The new Android admission regression failed on unchanged pre-fix Android source, then passed with the route-aware fix.
  • 43 focused Android tests passed: readiness 13; NodeRuntime admission/stale-result/publication 3; Settings 1; composer 8; config parsing 10; mode manager 3; speech client 5. The selected Gradle tests and Kotlin lint completed in 48 seconds. The new 11-case admission regression took 2.137 seconds; the stale-result regression took 0.058 seconds. These are measured local times, not estimated CI seconds.
  • Kotlin lint, scoped formatting, documentation-content checks, and whitespace checks passed.
  • Two independent Codex autoreview passes over the complete implementation candidate and relevant route/fallback/lifecycle context found no actionable P0–P2 issues. ClawSweeper's October 14 review of the same head also reports no code findings, with behavior proof still outstanding.
  • The earlier exact-parent Gateway handler CI job passed 107 tests. This is parent-head evidence, not a current-head Gateway rerun.

Settings screenshots

Actual production Compose Settings rendering in a test harness, using French, a narrow viewport, and large text. These images demonstrate the shared label change only; they do not demonstrate successful Talk startup or audio. “Non vérifié” means “Unverified”: the fixture is deliberately disconnected. “Parler” is the translated “Talk” label.

BeforeAfter
Before: Realtime Talk label After: generic Talk label

Live talk.catalog runtime proof

Both scenarios run against an isolated loopback Gateway (gateway.mode=local, bind=loopback, port 18899) on the candidate build, invoked as openclaw gateway call talk.catalog --params '{}'.

Scenario A - active provider present, no credentials (talk.provider=elevenlabs, talk.providers.elevenlabs={}):

{
  "speech.ready": false,
  "speech.activeProvider": "elevenlabs",
  "elevenlabs.configured": false,
  "elevenlabs.transports": ["managed-room"],
  "elevenlabs.modes": ["stt-tts"]
}

Scenario B - same active provider after adding credentials:

{
  "speech.ready": true,
  "speech.activeProvider": "elevenlabs",
  "elevenlabs.configured": true,
  "elevenlabs.transports": ["managed-room"],
  "elevenlabs.modes": ["stt-tts"]
}

This is the readiness the fix derives from the active speech row: the selected, known provider reports ready:false (configured:false) without credentials, and ready:true once configured. A synthetic key was used and does not appear in the catalog output.

CI failure disposition and remaining proof

The CI attempt for 63959e260269393 failed in two independent jobs:

  • native-i18n: missing source-inventory regeneration, corrected by the localization follow-up above.
  • android-test-third-party: downloading gradle-9.7.1-bin.zip returned HTTP 500 before tests started. This is not a passing test result or evidence of a code failure. Its downstream openclaw/ci-gate also failed.

New-head hosted CI remains separate from the local passing check; no manual CI rerun or merge is claimed here. The live openclaw gateway call talk.catalog evidence above closes the earlier runtime-proof gap; physical-device native Talk startup/audio, device fallback and unchanged realtime admission, and fresh-install/latest-stable upgrade runs with settings preserved remain outstanding. No full repository suite was run locally.

Implementation history
  • The initial test-only commit ca0f5eeaa0e did not contain the production change; 2404bf77d27 supplied it.
  • 33df65b6c59a preserved main's asynchronous provider-catalog structure and corrected selected-provider readiness for missing credentials.
  • 63959e260269393 added Android route-aware admission, fallback preservation, configuration-refresh protection, focused regressions, and the shared Talk label. The Android admission blocker is therefore no longer excluded from this PR's scope; live proof remains open as stated above.

talk.catalog advertised the stt-tts mode but gave clients no way to
discover it: the speech section had no ready flag and speech provider
entries carried no transports, while the session-create path only
accepts transport=managed-room for stt-tts. Local-only installs could
never tell Talk was usable (openclaw#165363). Add speech.ready (the active
speech provider builds a usable tts config) and transports on speech
entries, mirroring how transcription reports readiness and its
gateway-relay transport.
@clawsweeper

clawsweeper Bot commented Oct 5, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

ClawSweeper review complete

ClawSweeper finished reviewing this revision. The review result is being finalized.

View the workflow run.

@openclaw-barnacle openclaw-barnacle Bot added gateway Gateway runtime size: XS labels Oct 5, 2026
@clawsweeper clawsweeper Bot added P2 Normal backlog priority with limited blast radius. rating: 🧂 unranked krab Not merge-ready due to missing proof or serious correctness/safety concerns. status: 📣 needs proof The PR needs real behavior proof before ClawSweeper can clear the contributor ask. labels Oct 5, 2026
@clawsweeper

clawsweeper Bot commented Oct 5, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs real behavior proof before merge.

What this changes

Expose selected-speech readiness and transport metadata, and make Android Talk admission follow its configured native or realtime route.

Example: Android uses talk.realtime.mode="stt-tts" with a configured speech provider and no realtime provider.

  • Before: The Talk button requires realtime-provider setup before native recognition starts.
  • After: The button uses speech readiness and permits the existing native recognition, chat, and playback flow.

Review scores

Measure Result What it means
Overall readiness 🦪 silver shellfish (2/6) The focused patch has no actionable code findings and passing exact-head CI, but supplied runtime evidence covers only part of the changed behavior.
Proof confidence 🦪 silver shellfish (2/6) Real behavior proof is necessary before merge. See Before merge.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Product

Kind: Bug fix · Worth it: Yes · Fix scope: Complete
User problem: Android rejects configured native Talk because it checks an unrelated realtime provider before starting recognition.
Reason: The change restores documented native Talk behavior, preserves existing fallbacks, and adds no configuration or dependency.

Merge readiness

⛔ Blocked before merge - 1 item remains

This PR addresses a current Talk readiness bug and retains useful unique work; the previous syntax finding is fixed, with no new actionable code findings.

Priority: P2
Reviewed head: 7e285f117b8c2ca7959dd2655cb6727bae10ce64

Before merge

  • Add real behavior proof - The supplied CLI output exercises selected-speech catalog readiness, and inspected screenshots cover the Settings label. Supply Android recordings or redacted logs showing native startup and a spoken reply without a realtime provider, device-TTS fallback, unchanged realtime admission, and readiness refresh after configuration changes, plus fresh-install and v2026.10.5 upgrade runs with settings intact. Redact IPs, API keys, phone numbers, and non-public endpoints. After adding proof, update the PR body, then request a new review with @clawsweeper re-review. The PR author or someone with repository write access can request it.

Findings

None.

Tests

  • Missing end-to-end proof: Android startup/audio, fallback, realtime admission, configuration-refresh behavior, and fresh-install/latest-stable upgrade proof remain outstanding; the reported admission regression does show a pre-fix failure and post-fix pass.
Agent review details

How this fits together

The Gateway projects provider configuration into talk.catalog; Android combines that catalog with talk.config to decide whether Talk needs setup before starting its existing voice runtime.

flowchart LR
  Config[Gateway configuration] --> Catalog[Talk catalog]
  Config --> Route[Existing Android route parser]
  Catalog --> Readiness[Android readiness]
  Route --> Readiness
  Readiness --> Launcher[Talk launcher]
  Launcher --> Runtime[Native or realtime runtime]
Loading

Technical review

Best possible solution:

Keep the existing Gateway readiness and Android route owners, with admission based on the selected route and existing device-TTS fallback preserved.

Do we have a high-confidence way to reproduce the issue?

Current-main source shows native stt-tts routing behind a realtime-only readiness gate; the linked report supplies an affected Android setup, but no device reproduction was run during this review.

Is this the best way to solve the issue?

The patch fixes the owning catalog and admission decisions using existing provider checks, route parsing, and refresh guards; the simplification pass found no unnecessary production machinery.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against 57d0e8e57ade.

Provenance checked

  • Android Gateway-derived readiness keeps the original intent (7cfc66a: Use authoritative Gateway readiness for mixed provider states while keeping unknown catalogs nonblocking.)
  • Native stt-tts route keeps the original intent (fix(android): Talk keeps beeping without replying and ignores the stt-tts voice mode #150175: Explicit stt-tts uses device recognition, chat.send, and talk.speak because gateway-relay carries realtime sessions.)
  • Asynchronous catalog snapshots keeps the original intent (4b0eb92: Serve catalog snapshots without repeating provider waits; readiness remains advisory and execution retains current checks.)
  • Native localization inventory keeps the original intent (f02d16e: Keep the generated source inventory deterministic while reducing conflicts between independent native changes.)

Testing

Proof path: shipped entry point.

Security

None.

Evidence

What I checked:

Likely related people:

  • Peter Steinberger: Raw commit 4b0eb92 adds src/gateway/talk/handlers/index.ts:429 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: 4b0eb922b893; files: src/gateway/talk/handlers/index.ts)

PR surface

Source +69, Tests +180, Docs +2. Total +251 across 12 files. Added test files: 0.

View PR surface stats
Area Files Added Removed Net
Source 6 84 15 +69
Tests 5 200 20 +180
Docs 1 4 2 +2
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 12 288 37 +251

Root-cause cluster

Relationship: fixed_by_candidate
Canonical: #165363
Summary: This PR is the open repair candidate for the canonical local-only Android Talk readiness report.

Members:

Proposal only: this assessment does not dispatch repair, suppress jobs, mutate sibling items, close, or merge anything.

Labels

Label changes:

  • add rating: 🦪 silver shellfish: Overall readiness is 🦪 silver shellfish; proof is 🦪 silver shellfish and patch quality is 🐚 platinum hermit.
  • remove rating: 🧂 unranked krab: Current PR rating is rating: 🦪 silver shellfish, so this older rating label is no longer current.

Label justifications:

  • P2: A focused repair restores native Talk admission for explicitly configured setups without changing defaults or adding configuration.
  • rating: 🦪 silver shellfish: Overall readiness is 🦪 silver shellfish; proof is 🦪 silver shellfish and patch quality is 🐚 platinum hermit.
  • status: 📣 needs proof: The PR needs real behavior proof before ClawSweeper can clear the contributor ask.

Rank-up moves

Optional improvements that raise the rating; they are not merge blockers.

  • Provide the Android behavior and install/upgrade evidence identified in the proof assessment.

Rating scale

6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior.

Workflow

ClawSweeper edits this one comment on every review. Comment @clawsweeper re-review for a fresh review only. Repair and merge execution lanes are retired.

History

Review history (9 earlier review cycles; latest 8 shown)
  • reviewed 2026-10-05T11:11:49.449Z sha 2404bf7 :: needs real behavior proof before merge. :: [P2] Check the selected provider’s configured state before reporting ready | [P2] Extract the catalog responsibility before growing oversized handlers
  • reviewed 2026-10-12T10:43:49.775Z sha 2404bf7 :: needs real behavior proof before merge. :: [P2] Check the selected provider’s configured state before reporting ready
  • reviewed 2026-10-14T12:15:36.897Z sha 33df65b :: needs real behavior proof before merge. :: none
  • reviewed 2026-10-14T13:28:32.745Z sha 63959e2 :: needs real behavior proof before merge. :: none
  • reviewed 2026-10-14T14:10:52.434Z sha 7784d02 :: needs real behavior proof before merge. :: none
  • reviewed 2026-10-14T14:39:30.083Z sha 7784d02 :: needs real behavior proof before merge. :: none
  • reviewed 2026-10-18T11:32:07.637Z sha 232b8a3 :: needs real behavior proof before merge. :: [P1] Remove the extra closing parenthesis from the catalog task array
  • reviewed 2026-10-20T01:35:17.146Z sha 232b8a3 :: needs real behavior proof before merge. :: [P1] Remove the extra closing parenthesis from the catalog task array

Reviewed October 21, 2026, 9:10 AM ET / 13:10 UTC (Revision 10).

talk.catalog advertised the stt-tts mode but gave clients no way to
discover it: the speech section had no ready flag and speech provider
entries carried no transports, while the session-create path only
accepts transport=managed-room for stt-tts. Local-only installs could
never tell Talk was usable (openclaw#165363). Add speech.ready (the active
speech provider builds a usable tts config) and transports on speech
entries, mirroring how transcription reports readiness and its
gateway-relay transport.
@clawsweeper clawsweeper Bot added rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. and removed rating: 🧂 unranked krab Not merge-ready due to missing proof or serious correctness/safety concerns. labels Oct 5, 2026

@chessing234 chessing234 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed commit 2404bf77d27e0c2cbbdbe1f2828c73768f270ef5.

One correctness issue needs correction; see the inline finding.

Validation: source and contract inspection only; runtime tests were not run.

Comment thread src/gateway/talk/handlers/index.ts Outdated
speechAvailable &&
configuredOrFalse(() => {
const setup = buildTalkTtsConfig(config);
return !("error" in setup);

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[P2] Check provider configuration before reporting speech readiness

buildTalkTtsConfig() validates/resolves the selected provider but does not check speechProvider.isConfigured(). With talk: { provider: "elevenlabs", providers: { elevenlabs: {} } }, no API key in config/environment, and an available speech secret owner, this branch reports speech.ready: true while the same catalog reports that provider as configured: false. Clients using the new readiness flag can offer speech that cannot synthesize audio. Compute readiness with the existing effective-TTS/provider configuration check used below, and cover the missing-credentials case.

@clawsweeper clawsweeper Bot added rating: 🧂 unranked krab Not merge-ready due to missing proof or serious correctness/safety concerns. and removed rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. labels Oct 12, 2026
holny added 2 commits October 14, 2026 11:13
… state

buildTalkTtsConfig assembles a TTS config even when the selected
provider has no API key, so speech.ready could be true while the
provider row reported configured=false and synthesis could not
produce audio. Reuse the selected provider row's isConfigured check
so the ready flag matches the row's effective configuration state
(openclaw#165363 Rev 2).
…og-stt-tts

Resolve the catalog-handler conflict in favor of main's async
provider-catalog structure and re-express speech.ready against the
active provider row's configured flag, so a missing-credentials
provider no longer reports stt-tts as ready (openclaw#165363 Rev 2).
Use the existing Talk route parser to select native speech or realtime readiness. Preserve device-TTS fallback, reject stale readiness after configuration changes, and label both paths as Talk. Include the Gateway handler formatting repair.

Co-authored-by: IWhatsskill <[email protected]>
@openclaw-barnacle openclaw-barnacle Bot added docs Improvements or additions to documentation app: android App: android size: M and removed size: S labels Oct 14, 2026
Regenerate the source-owned native localization inventory for the route-aware Talk labels and configuration error. No runtime or translated catalog changes.

Co-authored-by: IWhatsskill <[email protected]>
@clawsweeper clawsweeper Bot added the proof: 📸 screenshot Contributor real behavior proof includes screenshot evidence. label Oct 14, 2026
@holny

holny commented Oct 14, 2026

Copy link
Copy Markdown
Contributor Author

Added live talk.catalog runtime proof to the PR body — the last outstanding behavior-proof item from the earlier review.

Ran openclaw gateway call talk.catalog --params '{}' against an isolated loopback Gateway on this head:

  • Selected provider without credentials (talk.provider=elevenlabs, talk.providers.elevenlabs={}): speech.ready=false, active elevenlabs.configured=false, transports=["managed-room"].
  • Same provider after adding credentials: speech.ready=true, active elevenlabs.configured=true, transports=["managed-room"].

A synthetic key was used and does not appear in the catalog output.

@clawsweeper clawsweeper Bot added the rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. label Oct 14, 2026
@clawsweeper clawsweeper Bot removed clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. labels Oct 18, 2026
@holny

holny commented Oct 20, 2026

Copy link
Copy Markdown
Contributor Author

@clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Oct 20, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
Exact review queued.

Re-review progress:

@clawsweeper clawsweeper Bot added clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. and removed clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. labels Oct 20, 2026
@holny

holny commented Oct 21, 2026

Copy link
Copy Markdown
Contributor Author

@clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Oct 21, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
Exact review queued.

Re-review progress:

@clawsweeper clawsweeper Bot added clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. and removed rating: 🧂 unranked krab Not merge-ready due to missing proof or serious correctness/safety concerns. clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. labels Oct 21, 2026
@roboclaw-bot roboclaw-bot added the clawtributors PR from a clawtributor label Oct 28, 2026

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

app: android App: android clawtributors PR from a clawtributor docs Improvements or additions to documentation gateway Gateway runtime P2 Normal backlog priority with limited blast radius. rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. size: M status: 📣 needs proof The PR needs real behavior proof before ClawSweeper can clear the contributor ask.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants