Update the frameless realtime default model (#40321)

## What changed

- Use `gpt-live-1-codex` as the default model for frameless realtime sessions.
- Preserve an explicitly supplied per-session model override.

## Testing

- Cover both default and explicit model selection in the WebRTC frameless conversation test.
- Update the app-server live session request expectation for the new default.

GitOrigin-RevId: ce5dc978911ff0289d677b60fae2dd8cb1058d22
This commit is contained in:
Eric Traut
2026-08-24 03:34:15 +00:00
committed by copyberry
parent 76d98a771e
commit 068c49f075
3 changed files with 12 additions and 5 deletions
@@ -1907,7 +1907,7 @@ async fn webrtc_v3_start_posts_live_session_and_joins_without_session_update() -
assert_call_create_multipart(
harness.call_capture.single_request(),
"v=offer\r\n",
r#"{"audio":{"output":{"voice":"cove"}},"delegation":{"ack_filler":false,"type":"client"},"instructions":"backend prompt\n\nstartup context","model":"gpt-live-1-boulder-alpha"}"#,
r#"{"audio":{"output":{"voice":"cove"}},"delegation":{"ack_filler":false,"type":"client"},"instructions":"backend prompt\n\nstartup context","model":"gpt-live-1-codex"}"#,
"/v1/live",
)?;
assert!(
+1 -1
View File
@@ -102,7 +102,7 @@ const HANDOFF_STREAM_TRUNCATION_MARKER: &str = "\n…output truncated…\n";
const AGENT_FINAL_MESSAGE_PREFIX: &str = "\"Agent Final Message\":\n\n";
const STANDALONE_HANDOFF_ID: &str = "codex";
const DEFAULT_REALTIME_MODEL: &str = "gpt-realtime-1.5";
const DEFAULT_FRAMELESS_REALTIME_MODEL: &str = "gpt-live-1-boulder-alpha";
const DEFAULT_FRAMELESS_REALTIME_MODEL: &str = "gpt-live-1-codex";
pub(crate) const REALTIME_USER_TEXT_PREFIX: &str = "[USER] ";
pub(crate) const REALTIME_BACKEND_TEXT_PREFIX: &str = "[BACKEND] ";
const REALTIME_V2_HANDOFF_COMPLETE_ACKNOWLEDGEMENT: &str =
@@ -588,8 +588,13 @@ async fn conversation_existing_call_attaches_without_creating_another_call() ->
Ok(())
}
#[test_case(None, "gpt-live-1-codex"; "default model")]
#[test_case(Some("session-override-model"), "session-override-model"; "explicit model")]
#[tokio::test(flavor = "multi_thread", worker_threads = 2)]
async fn conversation_webrtc_frameless_chatgpt_sends_codex_headers_to_backend() -> Result<()> {
async fn conversation_webrtc_frameless_chatgpt_sends_codex_headers_to_backend(
model: Option<&str>,
expected_model: &str,
) -> Result<()> {
skip_if_no_network!(Ok(()));
let server = start_mock_server().await;
@@ -619,7 +624,7 @@ async fn conversation_webrtc_frameless_chatgpt_sends_codex_headers_to_backend()
config.experimental_realtime_ws_backend_prompt = Some("backend prompt".to_string());
config.experimental_realtime_ws_base_url = Some(realtime_ws_base_url);
});
let test = builder.build(&server).await?;
let test = builder.build_with_auto_env(&server).await?;
test.codex
.submit(Op::RealtimeConversationStart(ConversationStartParams {
@@ -631,7 +636,7 @@ async fn conversation_webrtc_frameless_chatgpt_sends_codex_headers_to_backend()
codex_response_handoff_mode:
codex_protocol::protocol::CodexResponseHandoffMode::Thinking,
codex_response_handoff_channel_prefixes: None,
model: Some("session-override-model".to_string()),
model: model.map(str::to_string),
output_modality: RealtimeOutputModality::Audio,
include_startup_context: false,
initial_items: Vec::new(),
@@ -690,10 +695,12 @@ async fn conversation_webrtc_frameless_chatgpt_sends_codex_headers_to_backend()
json!({
"sdp": body["sdp"],
"delegation": body["session"]["delegation"]["type"],
"model": body["session"]["model"],
}),
json!({
"sdp": "v=offer\r\n",
"delegation": "client",
"model": expected_model,
})
);