refactor(google-meet): merge host and node realtime engines behind one audio transport#109413
Merged
Conversation
…e audio transport
…r realtime-node removal
steipete
force-pushed
the
refactor/meet-realtime-engine
branch
from
July 17, 2026 00:26
f95f841 to
3bf4842
Compare
Contributor
Author
|
Merged via squash.
|
github-actions Bot
pushed a commit
to Desicool/openclaw
that referenced
this pull request
Jul 17, 2026
…e audio transport (openclaw#109413) * refactor(google-meet): merge host and node realtime engines behind one audio transport * refactor(google-meet): internalize engine helpers left test-only after realtime-node removal
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What Problem This Solves
extensions/google-meetshipped two near-duplicate realtime audio engines:src/realtime.ts(Gateway-host path, SoX subprocess audio I/O) andsrc/realtime-node.ts(paired-node path,pullAudio/pushAudiorelay overruntime.nodes.invoke). Every behavior fix (echo suppression, barge-in, TTS queueing, talk events) had to be made twice, and the copies had already drifted apart in event coverage, teardown ordering, and TTS completion semantics.Why This Change Was Made
This is phase 1 of consolidating OpenClaw's meeting/voice stack so new meeting platforms (Microsoft Teams, later Zoom) can reuse one engine. The realtime engine is now written once and parameterized by a narrow
MeetRealtimeAudioTransportcontract (start input, write/clear output, fatal signal, optional barge-in monitor + health). Two transports implement it:realtime-local-audio-transport.ts— SoX subprocesses (previousrealtime.tsbehavior), including the optional local human barge-in monitor.realtime-node-audio-transport.ts— node relay loop (previousrealtime-node.tsbehavior).realtime-node.ts(772 LOC) is deleted outright; no compat shims or re-exports.Where the two copies had drifted, the safer variant was chosen deliberately:
bridgeId/nodeId).onFatalreplays a pre-registration transport failure synchronously and the engine aborts before creating a provider session it could never close (review-found; regression test added).connect()awaits so the capture pipe never backpressures during provider setup (review-found). The agent/STT engine drops pre-ready chunks instead of delivering a stale burst; the bidi engine forwards pre-connect audio to the voice bridge, matching the previous local command-pair behavior.User Impact
No config changes and no intended behavior changes beyond the drift resolutions above. Google Meet chrome and chrome-node sessions (agent, bidi, transcribe modes) behave as before, with the node path gaining the fuller talk-event observability.
Evidence
node scripts/run-vitest.mjs extensions/google-meet: 18 files, 263 tests passed (includes new regression tests for transport-fatal-during-setup and pre-startup-fatal abort).git diff --checkclean.max-linesbaseline entry for the deleted file removed.