feat(relay): gate caller audio until recipient answers (pre-greeting)#68
Merged
Conversation
수신자가 전화를 받고 첫 발화를 하기 전에 발신자 마이크로 들어온 소음/발화가 Session A에서 번역·환각되어, 공식 인사말보다 먼저 가짜 안내문으로 재생되는 문제를 차단한다 (prod 콜 9739b661에서 "연결해드리겠습니다, 잠시만 기다려주세요" 환각 재생 확인). - handle_user_audio / handle_user_audio_commit에 인사말 게이트 추가: first_message_sent(수신자 첫 발화 감지 = 인사말 발사 시점) 전의 caller 오디오는 전부 드랍 - ring buffer 앞에서 드랍하므로 recovery 재전송으로도 되살아나지 않음 - 첫 드랍 시 1회 로깅으로 prod 진단 가능성 유지 - 게이트 테스트 2건 추가, 기존 user-audio 테스트는 게이트 오픈 상태로 갱신 Quality Score: 93/100 Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Contributor
Author
|
추가 커밋: in-progress(수신 확정) 후 5초 내 수신자 발화 미감지 시 인사말 강제 발사 fallback ( |
Contributor
Author
|
추가 커밋 2건:
리뷰 89/100 PASS(Major 2건 반영 완료), 전체 469 테스트 통과. |
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.
Summary
수신자 첫 발화(= 공식 인사말 발사 시점) 전에 발신자 마이크로 들어온 오디오를 Session A에 넣지 않고 드랍합니다. 연결 직전 소음이 안내문으로 환각 생성되어 공식 인사말보다 먼저 재생되던 문제(#67 배포 후 콜
9739b661에서 재확인)를 차단합니다.Changes
src/realtime/pipeline/voice_to_voice.py—handle_user_audio/handle_user_audio_commit에 인사말 게이트(guard clause) 추가. 기존call.first_message_sent플래그 재사용 — 수신자 첫 발화 감지 시 인사말 발사와 동시에 게이트가 열림. ring buffer 앞에서 드랍하므로 recovery 재전송 경로도 차단. 첫 드랍 시 1회 로깅([Gate] Dropping pre-greeting user audio)으로 prod 진단 흔적 유지tests/test_voice_to_voice_pipeline.py— 게이트 닫힘/커밋 차단 테스트 2건 추가, 기존 user-audio 테스트 9건은 게이트 오픈 전제로 갱신tests/component/test_loopback_call.py— 동일 갱신 1건Blast Radius
FullAgentPipeline/TextToVoicePipeline은 해당 메서드가 원래 no-op이라 무영향AudioRouter,routes/stream.py호출부 그대로)Quality Gate
Test Plan
[Gate] Dropping pre-greeting user audio확인🤖 Generated with Claude Code