test_normal_message_not_escaped() — langchain Function Reference
Architecture documentation for the test_normal_message_not_escaped() function in test_serializable.py from the langchain codebase.
Entity Profile
Dependency Diagram
graph TD f8760286_bbd6_0190_80b5_ac62272f5287["test_normal_message_not_escaped()"] c4a8d7fe_9c7d_27a9_b1d5_4a21a8860b2e["TestDumpdEscapesLcKeyInPlainDicts"] f8760286_bbd6_0190_80b5_ac62272f5287 -->|defined in| c4a8d7fe_9c7d_27a9_b1d5_4a21a8860b2e style f8760286_bbd6_0190_80b5_ac62272f5287 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
libs/core/tests/unit_tests/load/test_serializable.py lines 533–543
def test_normal_message_not_escaped(self) -> None:
"""Test that normal `AIMessage` without `'lc'` key is not escaped."""
msg = AIMessage(
content="Hello",
additional_kwargs={"tool_calls": []},
response_metadata={"model": "gpt-4"},
)
serialized = dumpd(msg)
assert serialized["kwargs"]["content"] == "Hello"
# No escape wrappers for normal data
assert "__lc_escaped__" not in str(serialized)
Domain
Subdomains
Source
Frequently Asked Questions
What does test_normal_message_not_escaped() do?
test_normal_message_not_escaped() is a function in the langchain codebase, defined in libs/core/tests/unit_tests/load/test_serializable.py.
Where is test_normal_message_not_escaped() defined?
test_normal_message_not_escaped() is defined in libs/core/tests/unit_tests/load/test_serializable.py at line 533.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free