Before Tool Definitions Input • AI Agent SDK
BeforeToolDefinitionsInput: Input for BeforeToolDefinitions hooks.
BeforeToolDefinitionsInput
Defined in the events module.
AI Agent
Input for BeforeToolDefinitions hooks.
Fired right after the advertised tool definitions are assembled for a request and before they reach the LLM. Hooks should modify or filter the `tool_definitions list in place (e.g. data.tool_definitions[:] = ...`) to redact parameters, append usage guidance to descriptions, or constrain the advertised schema per request. This mirrors how BEFORE_LLM mutates its payload in place; only in-place mutations are adopted by the runtime.
Properties
ResponseField
ListNo description available.
ResponseField
strNo description available.
Internal & Generic Methods
- to_dict: Generic utility method.
Source
View on GitHubpraisonaiagents/hooks/events.py at line 51