Skip to content

The fastest, litest AI Gateway. Rust core with Python SDK. Call 100+ LLM APIs in OpenAI (or native) format with cost tracking, guardrails, load balancing, and logging [Bedrock, Azure, OpenAI, Anthropic, OpenAI, VertexAI, vLLM, Nvidia NIM]

Use correct key name

Joe Chengb7be609d6e3d
diff --git a/litellm/main.py b/litellm/main.py
index 36267aec1d6..f6a43023a3e 100644
--- a/litellm/main.py
+++ b/litellm/main.py
@@ -5151,8 +5151,8 @@ def stream_chunk_builder(
function_call_chunks = [
chunk
for chunk in chunks
- if "function_calls" in chunk["choices"][0]["delta"]
- and chunk["choices"][0]["delta"]["function_calls"] is not None
+ if "function_call" in chunk["choices"][0]["delta"]
+ and chunk["choices"][0]["delta"]["function_call"] is not None
]
if len(function_call_chunks) > 0: