Skip to content

Commit 550f532

Browse files
committed
fix the message parsing when there is no content only tool call
1 parent 11330f5 commit 550f532

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

eval_protocol/mcp/execution/base_policy.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@ async def _generate_live_tool_calls(
182182
# This is crucial for proper tool call ID management in add_tool_response
183183
assistant_message_for_history = {
184184
"role": "assistant",
185-
"content": response["choices"][0]["message"]["content"],
185+
"content": response["choices"][0]["message"].get("content", ""),
186186
}
187187
usage_stats = CompletionUsage(
188188
prompt_tokens=response["usage"]["prompt_tokens"],

0 commit comments

Comments
 (0)