Home / Function/ test_convert_dict_to_message() — langchain Function Reference

test_convert_dict_to_message() — langchain Function Reference

Architecture documentation for the test_convert_dict_to_message() function in test_chat_models.py from the langchain codebase.

Entity Profile

Dependency Diagram

graph TD
  957201ef_e0e5_8caa_1e97_e2e1bf91a842["test_convert_dict_to_message()"]
  ab3fd66d_3ad7_be56_7427_66f2c1a9d0a8["test_chat_models.py"]
  957201ef_e0e5_8caa_1e97_e2e1bf91a842 -->|defined in| ab3fd66d_3ad7_be56_7427_66f2c1a9d0a8
  style 957201ef_e0e5_8caa_1e97_e2e1bf91a842 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

libs/partners/huggingface/tests/unit_tests/test_chat_models.py lines 162–167

def test_convert_dict_to_message(
    msg_dict: dict[str, Any], expected_type: type, expected_content: str
) -> None:
    result = _convert_dict_to_message(msg_dict)
    assert isinstance(result, expected_type)
    assert result.content == expected_content

Domain

Subdomains

Frequently Asked Questions

What does test_convert_dict_to_message() do?
test_convert_dict_to_message() is a function in the langchain codebase, defined in libs/partners/huggingface/tests/unit_tests/test_chat_models.py.
Where is test_convert_dict_to_message() defined?
test_convert_dict_to_message() is defined in libs/partners/huggingface/tests/unit_tests/test_chat_models.py at line 162.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free