mirror of
https://github.com/pchuan98/codex.git
synced 2026-07-01 00:31:56 +08:00
fix: dont compact standalone websearch schema (#24660)
add new `parse_tool_input_schema_without_compaction` to bypass the existing compaction/trimming of client-provided tool schemas that are over 4k bytes. we want this for standalone web search to keep field guidance/metadata on certain fields; this keeps us closer to parity with existing hosted tool schema (which didnt go through this 4k byte filter).
This commit is contained in:
@@ -112,9 +112,12 @@ async fn standalone_web_search_round_trips_encrypted_output() -> Result<()> {
|
||||
assert_eq!(requests.len(), 2);
|
||||
|
||||
let first_response = requests[0].body_json();
|
||||
assert!(
|
||||
requests[0].tool_by_name("web", "run").is_some(),
|
||||
"web.run should be sent to the model"
|
||||
let web_run = requests[0]
|
||||
.tool_by_name("web", "run")
|
||||
.context("web.run should be sent to the model")?;
|
||||
assert_eq!(
|
||||
web_run.pointer("/parameters/properties/time/description"),
|
||||
Some(&json!("Get time for the given UTC offsets."))
|
||||
);
|
||||
assert!(
|
||||
!has_hosted_web_search(&first_response),
|
||||
|
||||
Reference in New Issue
Block a user