mirror of
https://github.com/invariantlabs-ai/invariant-gateway.git
synced 2026-08-15 21:40:20 +02:00
Add tool_result type in the coverter test for Anthropic.
This commit is contained in:
@@ -60,6 +60,16 @@ def test_convert_messages_with_tool_call():
|
||||
},
|
||||
],
|
||||
},
|
||||
{
|
||||
"role": "user",
|
||||
"content": [
|
||||
{
|
||||
"type": "tool_result",
|
||||
"content": "Paris is the capital of France.",
|
||||
"tool_use_id": "toolu_013btUg7dbaEq7NbPGzw4K9u",
|
||||
}
|
||||
],
|
||||
},
|
||||
]
|
||||
|
||||
converted_messages = convert_anthropic_to_invariant_message_format(messages)
|
||||
@@ -84,4 +94,9 @@ def test_convert_messages_with_tool_call():
|
||||
}
|
||||
],
|
||||
},
|
||||
{
|
||||
"role": "tool",
|
||||
"content": "Paris is the capital of France.",
|
||||
"tool_call_id": "toolu_013btUg7dbaEq7NbPGzw4K9u",
|
||||
},
|
||||
]
|
||||
|
||||
Reference in New Issue
Block a user