BaseFakeCallbackHandler Class — langchain Architecture
Architecture documentation for the BaseFakeCallbackHandler class in callbacks.py from the langchain codebase.
Entity Profile
Dependency Diagram
graph TD eff3f7b6_5c03_0199_00ef_6908753431c6["BaseFakeCallbackHandler"] c9ec0e10_1116_ed48_cb65_a2d7d41b2ec0["callbacks.py"] eff3f7b6_5c03_0199_00ef_6908753431c6 -->|defined in| c9ec0e10_1116_ed48_cb65_a2d7d41b2ec0
Relationship Graph
Source Code
libs/partners/groq/tests/unit_tests/fake/callbacks.py lines 14–45
class BaseFakeCallbackHandler(BaseModel):
"""Base fake callback handler for testing."""
starts: int = 0
ends: int = 0
errors: int = 0
errors_args: list[Any] = []
text: int = 0
ignore_llm_: bool = False
ignore_chain_: bool = False
ignore_agent_: bool = False
ignore_retriever_: bool = False
ignore_chat_model_: bool = False
# to allow for similar callback handlers that are not technically equal
fake_id: str | None = None
# add finer-grained counters for easier debugging of failing tests
chain_starts: int = 0
chain_ends: int = 0
llm_starts: int = 0
llm_ends: int = 0
llm_streams: int = 0
tool_starts: int = 0
tool_ends: int = 0
agent_actions: int = 0
agent_ends: int = 0
chat_model_starts: int = 0
retriever_starts: int = 0
retriever_ends: int = 0
retriever_errors: int = 0
retries: int = 0
Source
Frequently Asked Questions
What is the BaseFakeCallbackHandler class?
BaseFakeCallbackHandler is a class in the langchain codebase, defined in libs/partners/groq/tests/unit_tests/fake/callbacks.py.
Where is BaseFakeCallbackHandler defined?
BaseFakeCallbackHandler is defined in libs/partners/groq/tests/unit_tests/fake/callbacks.py at line 14.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free