fix(responses): add reasoning summary

Fixes #41262
This commit is contained in:
Humaira Ambreen 2026-09-27 12:17:06 +05:30
parent 8e6d99d74a
commit cb92541698
2 changed files with 19 additions and 0 deletions

View file

@ -2605,6 +2605,7 @@ class LiteLLMCompletionResponsesConfig:
for text in (reasoning_content,)
if text
],
summary=[],
encrypted_content=encrypted_content,
)
]

View file

@ -4939,6 +4939,24 @@ class TestBridgedOutputItemIdPrefixes:
choices=[choice],
)
def test_reasoning_item_includes_empty_summary(self):
item: Final = self._reasoning_items()[0]
assert item.model_dump(exclude_none=True) == {
"type": "reasoning",
"id": item.id,
"status": "completed",
"role": "assistant",
"content": [
{
"type": "output_text",
"text": "thinking about fruit",
"annotations": [],
}
],
"summary": [],
}
def test_reasoning_item_id_uses_rs_prefix(self):
items = self._reasoning_items()