Code Mode Toolset¶
Wraps other toolsets to enable code-based tool invocation, allowing agents to call tools by generating code.
Basic Usage¶
agents:
coder:
model: openai:gpt-5-mini
tools:
- type: code_mode
toolsets:
- type: file_access
fs: "file:///workspace"
How It Works¶
Instead of calling tools directly, the agent generates Python code that invokes the wrapped tools. This enables more complex tool compositions and programmatic control flow.