test_convert_dict_to_message_with_reasoning_content() — langchain Function Reference
Architecture documentation for the test_convert_dict_to_message_with_reasoning_content() function in test_chat_models.py from the langchain codebase.
Entity Profile
Dependency Diagram
graph TD 4f5a2823_0a2a_d93e_1053_6d52e31c3d51["test_convert_dict_to_message_with_reasoning_content()"] f28fd121_9d98_6d1d_bc45_cccbf6b9fad5["test_chat_models.py"] 4f5a2823_0a2a_d93e_1053_6d52e31c3d51 -->|defined in| f28fd121_9d98_6d1d_bc45_cccbf6b9fad5 style 4f5a2823_0a2a_d93e_1053_6d52e31c3d51 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
libs/partners/fireworks/tests/unit_tests/test_chat_models.py lines 10–24
def test_convert_dict_to_message_with_reasoning_content() -> None:
"""Test that reasoning_content is correctly extracted from API response."""
response_dict = {
"role": "assistant",
"content": "The answer is 42.",
"reasoning_content": "Let me think about this step by step...",
}
message = _convert_dict_to_message(response_dict)
assert isinstance(message, AIMessage)
assert message.content == "The answer is 42."
assert "reasoning_content" in message.additional_kwargs
expected_reasoning = "Let me think about this step by step..."
assert message.additional_kwargs["reasoning_content"] == expected_reasoning
Domain
Subdomains
Source
Frequently Asked Questions
What does test_convert_dict_to_message_with_reasoning_content() do?
test_convert_dict_to_message_with_reasoning_content() is a function in the langchain codebase, defined in libs/partners/fireworks/tests/unit_tests/test_chat_models.py.
Where is test_convert_dict_to_message_with_reasoning_content() defined?
test_convert_dict_to_message_with_reasoning_content() is defined in libs/partners/fireworks/tests/unit_tests/test_chat_models.py at line 10.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free