Allow clients not to send summary as an option (#12950)

Summary is a required parameter on UserTurn. Ideally we'd like the core
to decide the appropriate summary level.

Make the summary optional and don't send it when not needed.
This commit is contained in:
pakrym-oai
2026-02-26 14:37:38 -08:00
committed by GitHub
parent c1afb8815a
commit 951a389654
38 changed files with 233 additions and 175 deletions

View File

@@ -185,7 +185,11 @@ pub enum Op {
effort: Option<ReasoningEffortConfig>,
/// Will only be honored if the model is configured to use reasoning.
summary: ReasoningSummaryConfig,
///
/// When omitted, the session keeps the current setting (which allows core to
/// fall back to the selected model's default on new sessions).
#[serde(default, skip_serializing_if = "Option::is_none")]
summary: Option<ReasoningSummaryConfig>,
// The JSON schema to use for the final assistant message
final_output_json_schema: Option<Value>,