Repository navigation
Make the provider bridges speak the APIs the providers actually run - #7
Merged
Merged
Conversation
…tually run Four defects in the Deepgram and Cartesia bridges, none of which raised an exception. Each was an error message the provider sent us, which reached an if/elif chain with no else, was parsed, and dropped. - Deepgram Flux `Configure` used the Listen-v1 schema: `UNPARSABLE_CLIENT_MESSAGE: unknown field 'processors', expected 'thresholds'` STT accepted audio and returned nothing — 25s of silence on a live call while every health check reported green. - Flux turn state was read from `type` instead of `event`. A `TurnInfo` message carries its state in `event`, so barge-in and LLM pre-warm never fired: dead code that looked live. - Flux needs the `/v2/listen` endpoint. The bridge routed everything to v1. - Cartesia `encoding: "mulaw"` -> `400 unsupported encoding for raw: mulaw`. The correct value is `pcm_mulaw`. Behind it, a second 400: `sonic-english` had been sunsetted. TTS never synthesised a byte; only a cached greeting was ever audible. `finally: is_connected = False` in `receive_audio_events()` is removed. The turn loop breaks out of that async generator every turn, and `break` runs `finally`, so the bridge declared its own healthy socket dead after turn one. Connection lifetime belongs to close(), not to whoever stopped iterating. Cartesia `error` events are now logged and reported instead of ignored, which is how three of the four above stayed invisible for a week. conftest.py blanks SENTRY_DSN so the test suite stops reporting its own deliberate exceptions to the live Sentry project.
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This branch was successfully deployed
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
Four defects in the Deepgram and Cartesia bridges, none of which raised an
exception. Each was an error message the provider sent us, which reached an
if/elif chain with no else, was parsed, and dropped.
Configureused the Listen-v1 schema:UNPARSABLE_CLIENT_MESSAGE: unknown field 'processors', expected 'thresholds'STT accepted audio and returned nothing — 25s of silence on a live call
while every health check reported green.
typeinstead ofevent. ATurnInfomessage carries its state in
event, so barge-in and LLM pre-warm neverfired: dead code that looked live.
/v2/listenendpoint. The bridge routed everything to v1.encoding: "mulaw"->400 unsupported encoding for raw: mulaw.The correct value is
pcm_mulaw. Behind it, a second 400:sonic-englishhad been sunsetted. TTS never synthesised a byte; only a cached greeting
was ever audible.
finally: is_connected = Falseinreceive_audio_events()is removed. Theturn loop breaks out of that async generator every turn, and
breakrunsfinally, so the bridge declared its own healthy socket dead after turn one.Connection lifetime belongs to close(), not to whoever stopped iterating.
Cartesia
errorevents are now logged and reported instead of ignored, whichis how three of the four above stayed invisible for a week.
conftest.py blanks SENTRY_DSN so the test suite stops reporting its own
deliberate exceptions to the live Sentry project.
Verified on a live PSTN call. Three tests in this repo were green while certifying two of these bugs, because they mocked the provider boundary.