Home / Function/ _xml_to_tool_calls() — langchain Function Reference

_xml_to_tool_calls() — langchain Function Reference

Architecture documentation for the _xml_to_tool_calls() function in experimental.py from the langchain codebase.

Entity Profile

Dependency Diagram

graph TD
  a9a83498_6055_e600_f7dc_4634dfd82ff8["_xml_to_tool_calls()"]
  ce9a5118_b2cf_f25f_fad5_ea15575e8265["experimental.py"]
  a9a83498_6055_e600_f7dc_4634dfd82ff8 -->|defined in| ce9a5118_b2cf_f25f_fad5_ea15575e8265
  2f365234_b69d_08fc_8892_b7529ec51dbf["_xml_to_function_call()"]
  a9a83498_6055_e600_f7dc_4634dfd82ff8 -->|calls| 2f365234_b69d_08fc_8892_b7529ec51dbf
  style a9a83498_6055_e600_f7dc_4634dfd82ff8 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

libs/partners/anthropic/langchain_anthropic/experimental.py lines 136–140

def _xml_to_tool_calls(elem: Any, tools: list[dict]) -> list[dict[str, Any]]:
    """Convert an XML element and its children into a dictionary of dictionaries."""
    invokes = elem.findall("invoke")

    return [_xml_to_function_call(invoke, tools) for invoke in invokes]

Domain

Subdomains

Frequently Asked Questions

What does _xml_to_tool_calls() do?
_xml_to_tool_calls() is a function in the langchain codebase, defined in libs/partners/anthropic/langchain_anthropic/experimental.py.
Where is _xml_to_tool_calls() defined?
_xml_to_tool_calls() is defined in libs/partners/anthropic/langchain_anthropic/experimental.py at line 136.
What does _xml_to_tool_calls() call?
_xml_to_tool_calls() calls 1 function(s): _xml_to_function_call.

Analyze Your Own Codebase

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

Try Supermodel Free