fix(voice): accept verified Marin cancellation completion race
This commit is contained in:
@@ -198,7 +198,11 @@ class RealtimeAdapter:
|
||||
# Selected-profile probe: docs/guides/live-context-sync-repair.md.
|
||||
# The runtime separately requires the cancellation intent event_id,
|
||||
# terminal response confirmation, and heard-position truncation.
|
||||
return (self.model in ("gpt-realtime-mini", "gpt-realtime-2.1") and self.voice == "shimmer"
|
||||
return ((self.model, self.voice) in {
|
||||
("gpt-realtime-mini", "shimmer"),
|
||||
("gpt-realtime-2.1", "shimmer"),
|
||||
("gpt-realtime-2.1", "marin"),
|
||||
}
|
||||
and isinstance(error, dict)
|
||||
and error.get("type") == "invalid_request_error"
|
||||
and error.get("code") == "response_cancel_not_active"
|
||||
|
||||
Reference in New Issue
Block a user