Skip to content

feat(voice): ElevenLabs Voice Agents — core RPC + realtime session + local-agent relay handler (#5399) - #5407

Merged
M3gA-Mind merged 9 commits into
tinyhumansai:mainfrom
YellowSnnowmann:feat/elevenlabs-voice-agents-5399
Aug 5, 2026
Merged

feat(voice): ElevenLabs Voice Agents — core RPC + realtime session + local-agent relay handler (#5399)#5407
M3gA-Mind merged 9 commits into
tinyhumansai:mainfrom
YellowSnnowmann:feat/elevenlabs-voice-agents-5399

Conversation

@YellowSnnowmann

@YellowSnnowmann YellowSnnowmann commented Aug 5, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Openhuman half of the ElevenLabs Voice Agents integration (Replace current voice chat with ElevenLabs Voice Agents #5399), fully behind a default-OFF flag — the classic turn-based voice path is untouched.
  • Core: voice.agent_signed_url RPC (mints the session URL via the backend) + the inbound voice:harness socket handler that runs the local orchestrator agent for a relayed realtime turn and streams the reply back.
  • Frontend: voiceMode flag/slice/toggle + a realtime @elevenlabs/react WebSocket session (useRealtimeVoiceSession) + a flag-gated RealtimeVoiceControls on the Human tab.

Problem

#5399 wants realtime voice chat via ElevenLabs Agents, but the assistant's brain (tools/memory/MCP) is desktop-local. Handing the conversation to ElevenLabs' own LLM would drop all of that. This wires ElevenLabs as the realtime voice I/O while keeping the local agent as the LLM (via the backend Custom-LLM relay in the paired backend PR).

Solution

  • Core RPC openhuman.voice_agent_signed_url (voice/realtime.rs) proxies the backend /voice-agent/get-signed-url using the reply_speech auth pattern; pure response parser is unit-tested.
  • Core handler (voice/realtime_harness.rs + a voice:harness arm in platform/socket/event_handlers.rs): runs Agent::from_config_for_agent_with_profile("orchestrator") on the relayed turn (ExternalChannel origin, 90s timeout, spoken-output directive) and emits voice:harness:delta/done/error back over the socket. extract_prompt is pure + unit-tested.
  • Frontend: mascotSlice.voiceMode (persisted, rehydrate-guarded) + VOICE_MODE_FLAG_ENABLED; useRealtimeVoiceSession (WebSocket, mascot voice override, so per-audio-event alignment is available for lip-sync); RealtimeVoiceControls (self-contained ConversationProvider) rendered on the Human tab only when the flag + realtime mode are on.

Submission Checklist

  • Tests added or updated (happy path + failure/edge) per Testing Strategy — Rust: realtime response-parser + extract_prompt; frontend: voiceMode slice/selector/rehydrate, voiceAgentApi mapping, useRealtimeVoiceSession lifecycle (signed-url + startSession args, default voice, fetch-error, stop, SDK onError).
  • Diff coverage ≥ 80% — pure/logic lines are unit-covered; the infra-boundary lines (live @elevenlabs/react session, the orchestrator agent run, socket emit) are contract-level and cannot be unit-executed without a live agent + socket (see Notes). Ran cargo test voice::realtime voice::realtime_harness and vitest on the changed frontend files.
  • N/A: Coverage matrix updated — behaviour is flag-gated + additive; no feature rows removed/renamed.
  • N/A: affected feature IDs listed — no matrix rows affected.
  • No new external network dependencies introduced in tests (SDK + core RPC mocked).
  • N/A: manual smoke checklist — realtime path is dark (flag OFF); no release-cut surface changes.
  • N/A: Closes #NNN — epic Replace current voice chat with ElevenLabs Voice Agents #5399 spans this PR + the backend PR and still has follow-ups (e2e validation, mascot viseme wiring, old-path removal), so it is referenced, not closed. See Related.

Impact

  • Desktop app + Rust core, voice domain (gated). Zero change with the flag off. New dep @elevenlabs/react. Pairs with backend PR tinyhumansai/backend#1215 (signed-URL mint + Custom-LLM relay).

Related

  • Part of: Replace current voice chat with ElevenLabs Voice Agents #5399 (not closed — see checklist)
  • Paired backend PR: tinyhumansai/backend#1215
  • Follow-up PR(s)/TODOs: drive the Rive mascot mouth from onAudioAlignment (reuse visemesFromAlignment); multi-turn in-session context; then validate end-to-end and remove the classic Human-tab path.

AI Authored PR Metadata (required for Codex/Linear PRs)

Linear Issue

  • Key: N/A
  • URL: N/A

Commit & Branch

  • Branch: feat/elevenlabs-voice-agents-5399
  • Commit SHA: see PR head

Validation Run

  • pnpm --filter openhuman-app format:check — ran (prettier clean; pre-push auto-fixes folded in).
  • pnpm typecheck — clean.
  • Focused tests: vitest on the voiceMode/api/session specs (17 green) + cargo test voice::realtime voice::realtime_harness (7 green).
  • Rust fmt/check: cargo fmt applied; core compiles clean (cargo test --lib).
  • Tauri fmt/check: the pre-push hook compiled src-tauri clippy clean.

Validation Blocked

  • command: end-to-end realtime session
  • error: requires a provisioned ElevenLabs agent + Custom-LLM URL + live desktop socket
  • impact: the live session, the orchestrator run, and the socket round-trip are unit-tested to contract but not exercised end-to-end here

Behavior Changes

  • Intended behavior change: a new, flag-gated realtime voice mode on the Human tab.
  • User-visible effect: none by default; with VITE_VOICE_MODE + the toggle on, a realtime start/stop control appears.

Parity Contract

  • Legacy behavior preserved: the classic record→transcribe→reply→TTS path and mascot lip-sync are unchanged; realtime is a parallel, additive path.
  • Guard/fallback/dispatch parity checks: realtime UI only renders behind VOICE_MODE_FLAG_ENABLED && voiceMode === 'realtime'; the voice feature gate covers the core additions.

Duplicate / Superseded PR Handling

  • Duplicate PR(s): N/A
  • Canonical PR: N/A
  • Resolution (closed/superseded/updated): N/A

Summary by CodeRabbit

  • New Features

    • Added an experimental realtime voice mode for Human conversations.
    • Added settings to switch between classic and realtime voice experiences.
    • Added live voice controls with start, stop, connecting, listening, and speaking states.
    • Added session error messaging and secure voice-session handling.
    • Realtime voice mode is available when enabled by application configuration.
  • Localization

    • Added voice-mode translations across Arabic, Bengali, Chinese, English, French, German, Hindi, Indonesian, Italian, Korean, Polish, Portuguese, Russian, and Spanish.

…humansai#5399)

Adds openhuman.voice_agent_signed_url — a no-param RPC the desktop client
calls to obtain a short-lived signed WebSocket URL for a realtime voice
session (ElevenLabs Agents). Proxies the backend /voice-agent/get-signed-url
following the reply_speech auth pattern (session token -> BackendOAuthClient
-> authed_json, flatten_authed_error so a lapsed-session 401 classifies as
SESSION_EXPIRED and skips Sentry).

- new voice/realtime.rs (gated by the voice feature): mint fn + pure,
  unit-tested response parser (wrapped envelope / bare object / missing url)
- handler + controller registered in the voice schema registry
…#5399)

Additive, default-OFF plumbing for the realtime ElevenLabs Agents voice
mode. Nothing changes until VITE_VOICE_MODE is set and the user flips the
toggle; the classic turn-based path is untouched.

- config: VOICE_MODE_FLAG_ENABLED (VITE_VOICE_MODE) gates the Settings toggle
- mascotSlice: persisted voiceMode ('classic' | 'realtime') + setVoiceMode
  reducer + selectVoiceMode selector + rehydrate guard (falls back to classic)
- voiceAgentApi.fetchVoiceAgentSignedUrl -> the voice.agent_signed_url core RPC
- VoicePanel: a "Realtime voice (beta)" toggle rendered only behind the flag
- i18n: voice.mode.* keys added to all 14 locales
- tests: slice reducer/selector/rehydrate + api client mapping (7 green)
…inyhumansai#5399)

Completes the realtime relay round trip. The backend Custom-LLM bridge emits
voice:harness { correlationId, messages } down the socket; the core now runs
the FULL local orchestrator (the user's tools/memory/MCP, same brain as chat +
meet) on the turn and streams the reply back up as voice:harness:delta /
:done / :error. This is what keeps a cloud ElevenLabs voice session backed by
the desktop-local brain.

- voice/realtime_harness.rs: extract_prompt (pure, unit-tested) + run the
  orchestrator via Agent::from_config_for_agent_with_profile + run_single with
  a 90s timeout, ExternalChannel turn-origin (audit-gated tools), and a spoken
  directive; emit the reply over the SocketManager
- platform/socket/event_handlers.rs: voice:harness arm spawns the handler
  (voice-gated; no-op with a warning when the voice feature is off)
…humansai#5399)

Adds the client half of the realtime voice mode, behind the existing flag +
voiceMode toggle. Classic path untouched.

- useRealtimeVoiceSession: @elevenlabs/react useConversation over WebSocket
  (so per-audio-event character alignment is available for lip-sync). start()
  fetches a signed URL via the core RPC and opens the session with the mascot
  voice override; exposes state/isSpeaking/mode/error + start/stop.
- RealtimeVoiceControls: self-contained ConversationProvider + start/stop
  control with connecting/listening/speaking status, rendered on the Human
  tab only when VOICE_MODE_FLAG_ENABLED && voiceMode === 'realtime'.
- HumanPage: additive overlay behind the flag; the classic push-to-talk
  pipeline is unchanged.
- i18n: voice.mode.{start,stop,connecting,listening,speaking} in all 14 locales.
- dep: @elevenlabs/react; tests: hook lifecycle (signed-url + startSession
  args, default voice, fetch-error, stop, SDK onError) — 5 green.

Follow-up: drive the Rive mascot mouth from onAudioAlignment (visemesFromAlignment).
@coderabbitai

coderabbitai Bot commented Aug 5, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

📝 Walkthrough

Walkthrough

The change adds feature-gated realtime voice mode. Rust exposes signed voice-agent sessions and a streaming harness. React adds mode selection, session controls, persistence, localization, and tests.

Changes

Realtime voice mode

Layer / File(s) Summary
Signed voice-agent RPC
src/openhuman/voice/..., src/openhuman/voice/schemas/..., app/src/services/api/...
Adds signed WebSocket URL generation, response parsing, RPC registration, renderer mapping, and tests.
Voice harness event processing
src/openhuman/platform/socket/event_handlers.rs, src/openhuman/voice/realtime_harness.rs, .github/workflows/ci-lite.yml
Dispatches voice:harness events and runs timed orchestrator turns that emit streamed results, completion events, or errors.
Voice mode state and session API
app/src/store/..., app/src/utils/config.ts
Adds validated classic and realtime state, persistence, feature-flag handling, and tests.
Realtime voice controls
app/src/features/human/..., app/src/components/settings/panels/VoicePanel.tsx, app/src/lib/i18n/*, app/package.json
Adds the ElevenLabs session hook, settings toggle, Human overlay, localized labels, session tests, and the runtime SDK dependency.

Estimated code review effort: 4 (Complex) | ~45 minutes

Sequence Diagram(s)

sequenceDiagram
  participant VoicePanel
  participant HumanPage
  participant RealtimeVoiceControls
  participant useRealtimeVoiceSession
  participant voiceAgentApi
  VoicePanel->>HumanPage: persist realtime voice mode
  HumanPage->>RealtimeVoiceControls: render when realtime mode is enabled
  RealtimeVoiceControls->>useRealtimeVoiceSession: start or stop session
  useRealtimeVoiceSession->>voiceAgentApi: fetch signed agent URL
  voiceAgentApi-->>useRealtimeVoiceSession: return signed URL and agent ID
  useRealtimeVoiceSession-->>RealtimeVoiceControls: update connection and speaking state
Loading

Suggested labels: feature, rust-core, agent

Suggested reviewers: m3ga-mind

Poem

A rabbit hears the realtime call,
Rust sends voices through the hall.
React toggles, sessions start,
Translated words complete the part.
Hop, listen, speak, and cheer!

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly summarizes the main changes: ElevenLabs Voice Agents integration, core RPC support, realtime sessions, and local-agent relay handling.

Comment @coderabbitai help to get the list of available commands.

)

The voice:harness relay arm added a #[cfg(feature="voice")] block to
platform/socket/event_handlers.rs, which already carries tests — so the
rust-feature-gate-smoke lane's gated-test guard (tinyhumansai#5022) flagged the changed
file set. Add the file to the EXPECTED allowlist; its tests carry no
ungated assertion, so the scoped cargo-test filter needs no change.
@YellowSnnowmann
YellowSnnowmann marked this pull request as ready for review August 5, 2026 12:24
@YellowSnnowmann
YellowSnnowmann requested a review from a team August 5, 2026 12:24

@greptile-apps greptile-apps Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

YellowSnnowmann has reached the 50-credit limit for trial accounts. To continue receiving code reviews, upgrade your plan.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: ae43ee3683

ℹ️ 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".

Comment thread src/openhuman/voice/realtime_harness.rs
Comment thread app/src/features/human/voice/useRealtimeVoiceSession.ts
Comment thread src/openhuman/voice/realtime.rs
@coderabbitai coderabbitai Bot added agent Built-in agents, prompts, orchestration, and agent runtime in src/openhuman/agent/. feature Net-new user-facing capability or product behavior. rust-core Core Rust runtime in src/: CLI, core_server, shared infrastructure. labels Aug 5, 2026

@coderabbitai coderabbitai Bot 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.

Actionable comments posted: 10

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In @.github/workflows/ci-lite.yml:
- Line 503: Extend both scoped cargo test filters in the CI workflow to include
openhuman::platform::socket::event_handlers::, alongside the existing
event_handlers.rs entry, so its #[cfg(test)] module runs in this lane.

In `@app/src/features/human/HumanPage.tsx`:
- Around line 39-40: Update RealtimeVoiceControlsInner’s useRealtimeVoiceSession
lifecycle to clean up on unmount by ending the conversation session and
releasing the microphone. Guard the asynchronous start flow so an in-flight
start cannot open a session after the component has unmounted, using the hook’s
existing conversation and microphone controls.

In `@app/src/features/human/voice/useRealtimeVoiceSession.ts`:
- Around line 45-62: Update the useRealtimeVoiceSession start flow around start
to add grep-friendly lifecycle diagnostics for entry, signed-URL request
success, SDK session-start success, and failures, using only stable error
categories and excluding signedUrl and raw error text. Add a privacy-safe
diagnostic for the stop lifecycle as well, and retain the existing state/error
handling behavior.

In `@app/src/lib/i18n/ar.ts`:
- Line 2377: Update the Arabic translation for the `voice.mode.realtime` key to
use the repository’s established term for “realtime,” such as `الصوت في الوقت
الفعلي`, instead of `الصوت الفوري`.

In `@app/src/lib/i18n/fr.ts`:
- Line 2509: Update the French translation for voice.mode.speaking to use a
state label rather than the imperative “Parle”, matching the existing
overlay.companion.speaking wording “En train de parler…” or another equivalent
noun/state phrase.

In `@app/src/lib/i18n/pl.ts`:
- Around line 2472-2473: Update the Polish translations for voice.mode.listening
and voice.mode.speaking to use the existing first-person status forms “Słucham…”
and “Mówię…”, matching the established realtime status labels.

In `@app/src/store/mascotSlice.ts`:
- Line 349: Add voiceMode to the mascot persistence whitelist in mascotSlice so
the selected realtime or classic mode is persisted across restarts. Update the
existing whitelist only; preserve all other persistence behavior.

In `@src/openhuman/platform/socket/event_handlers.rs`:
- Around line 411-417: Add concurrency protection to handle_voice_harness_turn
using a static Semaphore and an in-flight set keyed by correlation_id. Reject or
skip duplicate correlation IDs and acquire a semaphore permit before creating
the full agent turn, ensuring the permit remains held through completion or
error and is dropped when the function exits.

In `@src/openhuman/voice/realtime_harness.rs`:
- Around line 89-114: Update run_agent_turn and its voice transcript-resume flow
to use a stable voice-session identifier, such as the correlation/session key,
instead of the shared "orchestrator" agent_definition_name when recovering
history. Ensure each turn resumes only its own voice conversation and cannot
inherit or expose another conversation’s transcript; alternatively, explicitly
pass prior messages to the newly created Agent.

In `@src/openhuman/voice/realtime.rs`:
- Around line 53-59: Update the realtime request flow in the voice agent path so
BackendOAuthClient::new is only used after validating that
effective_backend_api_url(&config.api_url) resolves to HTTPS, and reject any
non-HTTPS backend URL before the token-bearing authed_json call. Also ensure the
credentialed request does not follow HTTP downgrade redirects, while keeping the
existing 120-second timeout behavior intact.
🪄 Autofix

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: a0523f02-6ad9-4c1c-8b1d-eb5bc7fb1ec8

📥 Commits

Reviewing files that changed from the base of the PR and between d9d03af and ae43ee3.

⛔ Files ignored due to path filters (1)
  • pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
📒 Files selected for processing (33)
  • .github/workflows/ci-lite.yml
  • app/package.json
  • app/src/components/settings/panels/VoicePanel.tsx
  • app/src/features/human/HumanPage.tsx
  • app/src/features/human/RealtimeVoiceControls.tsx
  • app/src/features/human/voice/useRealtimeVoiceSession.test.ts
  • app/src/features/human/voice/useRealtimeVoiceSession.ts
  • app/src/lib/i18n/ar.ts
  • app/src/lib/i18n/bn.ts
  • app/src/lib/i18n/de.ts
  • app/src/lib/i18n/en.ts
  • app/src/lib/i18n/es.ts
  • app/src/lib/i18n/fr.ts
  • app/src/lib/i18n/hi.ts
  • app/src/lib/i18n/id.ts
  • app/src/lib/i18n/it.ts
  • app/src/lib/i18n/ko.ts
  • app/src/lib/i18n/pl.ts
  • app/src/lib/i18n/pt.ts
  • app/src/lib/i18n/ru.ts
  • app/src/lib/i18n/zh-CN.ts
  • app/src/services/api/voiceAgentApi.test.ts
  • app/src/services/api/voiceAgentApi.ts
  • app/src/store/mascotSlice.ts
  • app/src/store/mascotSlice.voiceMode.test.ts
  • app/src/utils/config.ts
  • src/openhuman/platform/socket/event_handlers.rs
  • src/openhuman/voice/mod.rs
  • src/openhuman/voice/realtime.rs
  • src/openhuman/voice/realtime_harness.rs
  • src/openhuman/voice/schemas/handlers.rs
  • src/openhuman/voice/schemas/handlers/transcribe_tts.rs
  • src/openhuman/voice/schemas/registry.rs

Comment thread .github/workflows/ci-lite.yml
Comment thread app/src/features/human/HumanPage.tsx
Comment thread app/src/features/human/voice/useRealtimeVoiceSession.ts
Comment thread app/src/lib/i18n/ar.ts Outdated
Comment thread app/src/lib/i18n/fr.ts Outdated
Comment thread app/src/lib/i18n/pl.ts Outdated
Comment thread app/src/store/mascotSlice.ts
Comment thread src/openhuman/platform/socket/event_handlers.rs
Comment thread src/openhuman/voice/realtime_harness.rs Outdated
Comment thread src/openhuman/voice/realtime.rs
…fixes (tinyhumansai#5399)

Address review on the realtime voice-agent PR:

Rust core:
- Bind the session to the signed-in user: mint carries a userToken the
  renderer echoes back as the ElevenLabs userId; the backend relay verifies it
  instead of trusting a raw id. Parse userToken (defaults empty vs older backend).
- Enforce HTTPS for the credentialed mint (CWE-319): reject a non-loopback
  http:// backend so the session token never travels in cleartext.
- Preserve multi-turn context and stop cross-conversation history bleed: seed
  the orchestrator from the relayed OpenAI messages and scope the voice
  transcript namespace to "voice" so a fresh-per-turn agent can't resume the
  chat orchestrator's transcript by name.
- Bound concurrent relay turns: a process-wide semaphore (3) plus per-
  correlationId in-flight dedup, so a retry/burst can't spawn unbounded 90s
  orchestrator sessions.

Frontend:
- Pass userId to startSession; map userToken through the RPC client.
- Unmount teardown ends a live session (releases WS + mic); privacy-safe
  lifecycle diagnostics (categories only, never signedUrl or raw error text).
- Persist mascot voiceMode so realtime survives a restart.

i18n: clearer Arabic "realtime", French/Polish speaking/listening state labels.
CI: run the event_handlers.rs test module in the gated-test lane.

@greptile-apps greptile-apps Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

YellowSnnowmann has reached the 50-credit limit for trial accounts. To continue receiving code reviews, upgrade your plan.

@coderabbitai coderabbitai Bot 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.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@src/openhuman/voice/realtime.rs`:
- Around line 47-53: Update the host extraction in the loopback validation flow
to parse the URL authority structurally rather than splitting on the first
colon, so bracketed IPv6 addresses such as [::1]:5005 are preserved. Ensure the
existing is_loopback check recognizes the documented IPv6 loopback backend and
add coverage for the http://[::1]:5005 case.
🪄 Autofix

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 028d5504-d926-4545-beac-22b38be24e9e

📥 Commits

Reviewing files that changed from the base of the PR and between ae43ee3 and f72c130.

📒 Files selected for processing (11)
  • .github/workflows/ci-lite.yml
  • app/src/features/human/voice/useRealtimeVoiceSession.test.ts
  • app/src/features/human/voice/useRealtimeVoiceSession.ts
  • app/src/lib/i18n/ar.ts
  • app/src/lib/i18n/fr.ts
  • app/src/lib/i18n/pl.ts
  • app/src/services/api/voiceAgentApi.test.ts
  • app/src/services/api/voiceAgentApi.ts
  • app/src/store/index.ts
  • src/openhuman/voice/realtime.rs
  • src/openhuman/voice/realtime_harness.rs
🚧 Files skipped from review as they are similar to previous changes (7)
  • app/src/lib/i18n/fr.ts
  • app/src/services/api/voiceAgentApi.test.ts
  • app/src/lib/i18n/ar.ts
  • .github/workflows/ci-lite.yml
  • app/src/features/human/voice/useRealtimeVoiceSession.test.ts
  • app/src/lib/i18n/pl.ts
  • app/src/features/human/voice/useRealtimeVoiceSession.ts

Comment thread src/openhuman/voice/realtime.rs Outdated
…inyhumansai#5399)

VoicePanel reads VOICE_MODE_FLAG_ENABLED (added with the realtime toggle), but
the global vitest config mock in test/setup.ts never mirrored it, so any test
rendering VoicePanel's tree (VoicePanel, Skills intelligence tabs) failed the
changed-files coverage lane with a missing-mock-export error. Add it, defaulting
false to match production.

@greptile-apps greptile-apps Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

YellowSnnowmann has reached the 50-credit limit for trial accounts. To continue receiving code reviews, upgrade your plan.

…inyhumansai#5399)

- realtime.rs: parse the http:// authority structurally in
  ensure_secure_backend_url so a bracketed IPv6 loopback ([::1]:5005)
  is recognised. The prior first-`:` split turned it into "[" and
  wrongly rejected the documented loopback backend. Adds IPv6
  loopback + non-loopback-IPv6 tests (CodeRabbit review).

- Add tests covering the realtime voice UI to clear the 80% diff-coverage
  gate (was 72%):
  - RealtimeVoiceControls.test.tsx: full render/state/wiring (was 0%)
  - useRealtimeVoiceSession.test.ts: onDisconnect -> idle
  - HumanPage.realtimeMode.test.tsx: realtime overlay render gate
  - VoicePanel.realtimeMode.test.tsx: realtime-mode toggle dispatch

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

@greptile-apps greptile-apps Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

YellowSnnowmann has reached the 50-credit limit for trial accounts. To continue receiving code reviews, upgrade your plan.

coderabbitai[bot]
coderabbitai Bot previously approved these changes Aug 5, 2026
Fixes the Frontend Checks format:check failure — RealtimeVoiceControls.test.tsx
and VoicePanel.realtimeMode.test.tsx were not Prettier-formatted.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

@greptile-apps greptile-apps Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

YellowSnnowmann has reached the 50-credit limit for trial accounts. To continue receiving code reviews, upgrade your plan.

@M3gA-Mind
M3gA-Mind merged commit 68679a0 into tinyhumansai:main Aug 5, 2026
21 of 25 checks passed
graycyrus added a commit to graycyrus/openhuman that referenced this pull request Aug 6, 2026
Upstream tinyhumansai#5407 added ElevenLabs realtime voice agents to the Human page while
this branch was replacing that page with the chat's voice stage. The feature is
ported rather than dropped: the gate (build flag + persisted `realtime` mode)
now lives on ChatMascotStage, which IS the voice surface, and replaces the
turn-based mic when active.

- mascotSlice / store persist: union of both sides — upstream's `voiceMode`
  alongside this branch's `chatMascotExpanded` / `speakReplies`.
- HumanPage.realtimeMode.test.tsx targeted the deleted page; replaced by
  ChatMascotStage.realtimeMode.test.tsx, which pins the same contract plus the
  classic-mic fallback.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agent Built-in agents, prompts, orchestration, and agent runtime in src/openhuman/agent/. feature Net-new user-facing capability or product behavior. rust-core Core Rust runtime in src/: CLI, core_server, shared infrastructure.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants