litellm - 💡(How to fix) Fix [Bug]: `chatgpt/gpt-5.4` throw exception when stream is `false` [1 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
BerriAI/litellm#26309Fetched 2026-04-24 05:52:39
View on GitHub
Comments
0
Participants
1
Timeline
2
Reactions
0
Author
Participants
Timeline (top)
labeled ×2

Error Message

{ "error": { "message": "litellm.APIConnectionError: APIConnectionError: ChatgptException - Unknown items in responses API response: []. Received Model Group=gpt-5.4\nAvailable Model Group Fallbacks=None", "type": null, "param": null, "code": "500" } }

Code Example

{
  "model": "gpt-5.4",
  "stream": false,
  "messages": [
    {
      "role": "system",
      "content": "Say Hello to the user"
    },
    {
      "role": "user",
      "content": "Hello"
    }
  ]
}

---

{
  "error": {
    "message": "litellm.APIConnectionError: APIConnectionError: ChatgptException - Unknown items in responses API response: []. Received Model Group=gpt-5.4\nAvailable Model Group Fallbacks=None",
    "type": null,
    "param": null,
    "code": "500"
  }
}

---

litellm-1   |     raise e
litellm-1   |   File "/app/.venv/lib/python3.13/site-packages/litellm/utils.py", line 1892, in wrapper_async
litellm-1   |     result = await original_function(*args, **kwargs)
litellm-1   |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
litellm-1   |   File "/app/.venv/lib/python3.13/site-packages/litellm/main.py", line 639, in acompletion
litellm-1   |     raise exception_type(
litellm-1   |           ~~~~~~~~~~~~~~^
litellm-1   |         model=model,
litellm-1   |         ^^^^^^^^^^^^
litellm-1   |     ...<3 lines>...
litellm-1   |         extra_kwargs=kwargs,
litellm-1   |         ^^^^^^^^^^^^^^^^^^^^
litellm-1   |     )
litellm-1   |     ^
litellm-1   |   File "/app/.venv/lib/python3.13/site-packages/litellm/litellm_core_utils/exception_mapping_utils.py", line 2461, in exception_type
litellm-1   |     raise e  # it's already mapped
litellm-1   |     ^^^^^^^
litellm-1   |   File "/app/.venv/lib/python3.13/site-packages/litellm/litellm_core_utils/exception_mapping_utils.py", line 635, in exception_type
litellm-1   |     raise APIConnectionError(
litellm-1   |     ...<7 lines>...
litellm-1   |     )
litellm-1   | litellm.exceptions.APIConnectionError: litellm.APIConnectionError: APIConnectionError: ChatgptException - Unknown items in responses API response: []. Received Model Group=gpt-5.4
RAW_BUFFERClick to expand / collapse

Check for existing issues

  • I have searched the existing issues and checked that my issue is not a duplicate.

What happened?

The chatgpt/gpt-5.4 throw exception when stream is false. It work fine with other chatgpt/* model.

Steps to Reproduce

  1. Try send something like this.
{
  "model": "gpt-5.4",
  "stream": false,
  "messages": [
    {
      "role": "system",
      "content": "Say Hello to the user"
    },
    {
      "role": "user",
      "content": "Hello"
    }
  ]
}
  1. Then you will always get this:
{
  "error": {
    "message": "litellm.APIConnectionError: APIConnectionError: ChatgptException - Unknown items in responses API response: []. Received Model Group=gpt-5.4\nAvailable Model Group Fallbacks=None",
    "type": null,
    "param": null,
    "code": "500"
  }
}

Relevant log output

litellm-1   |     raise e
litellm-1   |   File "/app/.venv/lib/python3.13/site-packages/litellm/utils.py", line 1892, in wrapper_async
litellm-1   |     result = await original_function(*args, **kwargs)
litellm-1   |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
litellm-1   |   File "/app/.venv/lib/python3.13/site-packages/litellm/main.py", line 639, in acompletion
litellm-1   |     raise exception_type(
litellm-1   |           ~~~~~~~~~~~~~~^
litellm-1   |         model=model,
litellm-1   |         ^^^^^^^^^^^^
litellm-1   |     ...<3 lines>...
litellm-1   |         extra_kwargs=kwargs,
litellm-1   |         ^^^^^^^^^^^^^^^^^^^^
litellm-1   |     )
litellm-1   |     ^
litellm-1   |   File "/app/.venv/lib/python3.13/site-packages/litellm/litellm_core_utils/exception_mapping_utils.py", line 2461, in exception_type
litellm-1   |     raise e  # it's already mapped
litellm-1   |     ^^^^^^^
litellm-1   |   File "/app/.venv/lib/python3.13/site-packages/litellm/litellm_core_utils/exception_mapping_utils.py", line 635, in exception_type
litellm-1   |     raise APIConnectionError(
litellm-1   |     ...<7 lines>...
litellm-1   |     )
litellm-1   | litellm.exceptions.APIConnectionError: litellm.APIConnectionError: APIConnectionError: ChatgptException - Unknown items in responses API response: []. Received Model Group=gpt-5.4

What part of LiteLLM is this about?

Proxy

What LiteLLM version are you on ?

v1.83.8

Twitter / LinkedIn details

No response

extent analysis

TL;DR

The issue can be fixed by setting the stream parameter to true when using the gpt-5.4 model.

Guidance

  • Verify that the issue is specific to the gpt-5.4 model by testing other models with stream set to false.
  • Check the LiteLLM documentation to see if there are any known issues or limitations with the gpt-5.4 model and the stream parameter.
  • Try setting the stream parameter to true when using the gpt-5.4 model to see if it resolves the issue.
  • If the issue persists, check the LiteLLM version and consider upgrading to a newer version if available.

Notes

The issue seems to be specific to the gpt-5.4 model and the stream parameter set to false. The error message suggests that there is an unknown item in the API response, which may be related to the model or the parameter.

Recommendation

Apply workaround: set stream to true when using the gpt-5.4 model, as this may resolve the issue.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING