fix: patch bug in Anthropic code path (#1395)
This commit is contained in:
@@ -743,6 +743,8 @@ def anthropic_chat_completions_request(
|
||||
anthropic_client = anthropic.Anthropic(api_key=anthropic_override_key)
|
||||
elif model_settings.anthropic_api_key:
|
||||
anthropic_client = anthropic.Anthropic()
|
||||
else:
|
||||
raise ValueError("No available Anthropic API key")
|
||||
data = _prepare_anthropic_request(
|
||||
data=data,
|
||||
inner_thoughts_xml_tag=inner_thoughts_xml_tag,
|
||||
|
||||
@@ -351,9 +351,9 @@ def test_append_copy_suffix_simple(local_client, server, serialize_test_agent, d
|
||||
"""Test deserializing JSON into an Agent instance."""
|
||||
result = server.agent_manager.serialize(agent_id=serialize_test_agent.id, actor=default_user)
|
||||
|
||||
# write file
|
||||
# write file
|
||||
with open("test_agent_serialization.json", "w") as f:
|
||||
# write json
|
||||
# write json
|
||||
f.write(json.dumps(result.model_dump(), indent=4))
|
||||
|
||||
# Deserialize the agent
|
||||
|
||||
Reference in New Issue
Block a user