Skip to content

tinker_cookbook.tool_use

Class Description
ToolInput Input to a tool invocation.
ToolResult Result from a tool invocation.
types.Tool Protocol for tools that can be used by LLM agents.
FunctionTool A tool created from a decorated function or method.
AgentToolMessageEnv Generic tool-use MessageEnv for agents.
Function Description
simple_tool_result() Helper function to create a ToolResult from content.
error_tool_result() Helper function to create an error ToolResult.
tools.tool() Decorator to create a tool from a function or method.
handle_tool_call() Handle a single tool call, returning a ToolResult.
build_agent_tool_env() Convenience method to build an EnvFromMessageEnv for tool-using agents.