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 7dace065_c10f_ac11_5111_706921ba74e4["pretty_repr()"] 9ad47010_a7a4_8c98_a464_6b696766c212["ChatPromptTemplate"] 7dace065_c10f_ac11_5111_706921ba74e4 -->|defined in| 9ad47010_a7a4_8c98_a464_6b696766c212 d1ef9274_0232_5e95_287a_fdd9676ef549["pretty_print()"] d1ef9274_0232_5e95_287a_fdd9676ef549 -->|calls| 7dace065_c10f_ac11_5111_706921ba74e4 373cbf7b_1694_c787_e42e_8c54bab0f669["pretty_repr()"] 7dace065_c10f_ac11_5111_706921ba74e4 -->|calls| 373cbf7b_1694_c787_e42e_8c54bab0f669 style 7dace065_c10f_ac11_5111_706921ba74e4 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
libs/core/langchain_core/prompts/chat.py lines 1317–1327
def pretty_repr(self, html: bool = False) -> str:
"""Human-readable representation.
Args:
html: Whether to format as HTML.
Returns:
Human-readable representation.
"""
# TODO: handle partials
return "\n\n".join(msg.pretty_repr(html=html) for msg in self.messages)
Domain
Subdomains
Defined In
Calls
Called By
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 1317.
What does pretty_repr() call?
pretty_repr() calls 1 function(s): pretty_repr.
What calls pretty_repr()?
pretty_repr() is called by 1 function(s): pretty_print.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free