diff --git a/litellm/responses/litellm_completion_transformation/transformation.py b/litellm/responses/litellm_completion_transformation/transformation.py index ce8841c9190..f31afa38585 100644 --- a/litellm/responses/litellm_completion_transformation/transformation.py +++ b/litellm/responses/litellm_completion_transformation/transformation.py @@ -3452,7 +3452,7 @@ class LiteLLMCompletionResponsesConfig: if text ], encrypted_content=encrypted_content, - ) + ).model_copy(update={"summary": []}) ] return [] diff --git a/tests/unit/responses/litellm_completion_transformation/test_litellm_completion_responses.py b/tests/unit/responses/litellm_completion_transformation/test_litellm_completion_responses.py index 4250c78c669..bad7e9c7282 100644 --- a/tests/unit/responses/litellm_completion_transformation/test_litellm_completion_responses.py +++ b/tests/unit/responses/litellm_completion_transformation/test_litellm_completion_responses.py @@ -5418,6 +5418,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()