Home / Function/ on_tool_error() — langchain Function Reference

on_tool_error() — langchain Function Reference

Architecture documentation for the on_tool_error() function in streaming_stdout.py from the langchain codebase.

Entity Profile

Dependency Diagram

graph TD
  3231d3f3_27a2_2852_8c88_685f98bb84c7["on_tool_error()"]
  6b65bf57_0fa9_b411_5886_294d6dbe5842["StreamingStdOutCallbackHandler"]
  3231d3f3_27a2_2852_8c88_685f98bb84c7 -->|defined in| 6b65bf57_0fa9_b411_5886_294d6dbe5842
  style 3231d3f3_27a2_2852_8c88_685f98bb84c7 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

libs/core/langchain_core/callbacks/streaming_stdout.py lines 130–136

    def on_tool_error(self, error: BaseException, **kwargs: Any) -> None:
        """Run when tool errors.

        Args:
            error: The error that occurred.
            **kwargs: Additional keyword arguments.
        """

Domain

Subdomains

Frequently Asked Questions

What does on_tool_error() do?
on_tool_error() is a function in the langchain codebase, defined in libs/core/langchain_core/callbacks/streaming_stdout.py.
Where is on_tool_error() defined?
on_tool_error() is defined in libs/core/langchain_core/callbacks/streaming_stdout.py at line 130.

Analyze Your Own Codebase

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

Try Supermodel Free