pretty_repr() — langchain Function Reference
Architecture documentation for the pretty_repr() function in chat.py from the langchain codebase.
Entity Profile
Dependency Diagram
graph TD 4a22eaf2_c4cb_6f2f_6204_f7dbd1279a87["pretty_repr()"] c5f45b6e_9126_7fa3_ba5a_e6a86d45b6d5["MessagesPlaceholder"] 4a22eaf2_c4cb_6f2f_6204_f7dbd1279a87 -->|defined in| c5f45b6e_9126_7fa3_ba5a_e6a86d45b6d5 47fe42aa_c8e0_87b2_ad04_4343c7ef26cb["pretty_repr()"] 4a22eaf2_c4cb_6f2f_6204_f7dbd1279a87 -->|calls| 47fe42aa_c8e0_87b2_ad04_4343c7ef26cb style 4a22eaf2_c4cb_6f2f_6204_f7dbd1279a87 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
libs/core/langchain_core/prompts/chat.py lines 201–216
def pretty_repr(self, html: bool = False) -> str:
"""Human-readable representation.
Args:
html: Whether to format as HTML.
Returns:
Human-readable representation.
"""
var = "{" + self.variable_name + "}"
if html:
title = get_msg_title_repr("Messages Placeholder", bold=True)
var = get_colored_text(var, "yellow")
else:
title = get_msg_title_repr("Messages Placeholder")
return f"{title}\n\n{var}"
Domain
Subdomains
Defined In
Calls
Source
Frequently Asked Questions
What does pretty_repr() do?
pretty_repr() is a function in the langchain codebase, defined in libs/core/langchain_core/prompts/chat.py.
Where is pretty_repr() defined?
pretty_repr() is defined in libs/core/langchain_core/prompts/chat.py at line 201.
What does pretty_repr() call?
pretty_repr() calls 1 function(s): pretty_repr.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free