Home / File/ render.py — langchain Source File

render.py — langchain Source File

Architecture documentation for render.py, a python file in the langchain codebase. 2 imports, 0 dependents.

File python 2 imports

Entity Profile

Dependency Diagram

graph LR
  9afff7dc_2650_e47b_c69a_b1169f750647["render.py"]
  121262a1_0bd6_d637_bce3_307ab6b3ecd4["langchain_core.tools"]
  9afff7dc_2650_e47b_c69a_b1169f750647 --> 121262a1_0bd6_d637_bce3_307ab6b3ecd4
  5c738c12_cc4f_cee1_0e1d_562012a5f844["langchain_core.utils.function_calling"]
  9afff7dc_2650_e47b_c69a_b1169f750647 --> 5c738c12_cc4f_cee1_0e1d_562012a5f844
  style 9afff7dc_2650_e47b_c69a_b1169f750647 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

"""Different methods for rendering Tools to be passed to LLMs.

Depending on the LLM you are using and the prompting strategy you are using,
you may want Tools to be rendered in a different way.
This module contains various ways to render tools.
"""

# For backwards compatibility
from langchain_core.tools import (
    render_text_description,
    render_text_description_and_args,
)
from langchain_core.utils.function_calling import (
    convert_to_openai_function as format_tool_to_openai_function,
)
from langchain_core.utils.function_calling import (
    convert_to_openai_tool as format_tool_to_openai_tool,
)

__all__ = [
    "format_tool_to_openai_function",
    "format_tool_to_openai_tool",
    "render_text_description",
    "render_text_description_and_args",
]

Dependencies

  • langchain_core.tools
  • langchain_core.utils.function_calling

Frequently Asked Questions

What does render.py do?
render.py is a source file in the langchain codebase, written in python.
What does render.py depend on?
render.py imports 2 module(s): langchain_core.tools, langchain_core.utils.function_calling.
Where is render.py in the architecture?
render.py is located at libs/langchain/langchain_classic/tools/render.py (directory: libs/langchain/langchain_classic/tools).

Analyze Your Own Codebase

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

Try Supermodel Free