_is_tool_call() — langchain Function Reference
Architecture documentation for the _is_tool_call() function in base.py from the langchain codebase.
Entity Profile
Dependency Diagram
graph TD c8875a66_eb8e_d434_b86b_f2a5e4543dc8["_is_tool_call()"] 6508e071_ac7c_8516_5d11_f42f8a45558c["base.py"] c8875a66_eb8e_d434_b86b_f2a5e4543dc8 -->|defined in| 6508e071_ac7c_8516_5d11_f42f8a45558c a3b618af_7f94_a18d_4bad_838dee2ae5d1["_prep_run_args()"] a3b618af_7f94_a18d_4bad_838dee2ae5d1 -->|calls| c8875a66_eb8e_d434_b86b_f2a5e4543dc8 style c8875a66_eb8e_d434_b86b_f2a5e4543dc8 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
libs/core/langchain_core/tools/base.py lines 1137–1146
def _is_tool_call(x: Any) -> bool:
"""Check if the input is a tool call dictionary.
Args:
x: The input to check.
Returns:
`True` if the input is a tool call, `False` otherwise.
"""
return isinstance(x, dict) and x.get("type") == "tool_call"
Domain
Subdomains
Defined In
Called By
Source
Frequently Asked Questions
What does _is_tool_call() do?
_is_tool_call() is a function in the langchain codebase, defined in libs/core/langchain_core/tools/base.py.
Where is _is_tool_call() defined?
_is_tool_call() is defined in libs/core/langchain_core/tools/base.py at line 1137.
What calls _is_tool_call()?
_is_tool_call() is called by 1 function(s): _prep_run_args.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free