Repository navigation
feat(frontend): advance on the server's boundary signal - #89
Merged
Merged
Conversation
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
FE-05 of
tavus-single-session-interview: the client advances on the server'sboundary_duesignal. Two commits.chore: syncopenapi.jsonand the generated types with the merged api contract (the/utterance202 body only; generated withbun run codegen).feat:sendUtteranceparses the 202 body and reportstrueonly for a literalboundary_due: true; a missing,null, string,{}or non-boolean body is ignored without throwing. The transcript handler then callsassertBoundary('completed')when the handle is still the active one. It is the THIRD input beside the closing phrase and the 300 s timer;assertBoundaryalready gates onisSteerable(Tavus with a named conversation) and is idempotent, so a paraphrased closing line still advances, phrase plusboundary_duein one tick cause one/endand one steering call, and non-Tavus handles ignore the flag.Decisions
assertBoundary(no new flag).callEnddrains the tracked set, so chaining there would make the boundary wait on itself.boundary_due: truealso triggers the boundary when it arrives on an avatar-speaker utterance: the server returns the flag for every row and "due" is treated as due regardless of speaker.develop.Verification
RED first (1 failed, 41 passed: only the "advances without a phrase" test fails before; the others guard "does nothing"/idempotency by design); 42/42 green. Mutations (drop the
isSteerablegate, stop parsing the body) each fail tests and were reverted. Full Vitest 119 files / 3008 tests, typecheck and lint pass. Not run:codegen:checkand the wrapper parity script (FE-08).