collectToolCallMetadata
expect open suspend override fun collectToolCallMetadata(eventId: String, executionInfo: AgentExecutionInfo, runId: String, toolCallId: String?, toolName: String, toolDescription: String?, toolArgs: JSONObject, context: AIAgentContext): ToolCallMetadata(source)
Collects metadata contributions from every feature that registered a handler via provideToolCallMetadata and returns the combined map.
Contributions are merged in feature installation order; later contributions overwrite earlier ones on key collision. Called by ai.koog.agents.core.environment.ContextualAgentEnvironment before it delegates to the wrapped environment.
Parameters
eventId
The unique identifier for the current event;
executionInfo
The execution information for the tool call event;
runId
The unique identifier for the current run;
toolCallId
The unique identifier for the current tool call;
toolName
The tool name that is being called;
toolDescription
The description of the tool that is being called;
toolArgs
The arguments provided to the tool;
context
The agent context associated with the tool call.