The agent manifest is a YAML file that defines your complete agent setup. The configuration is powered by Pydantic and provides excellent validation and IDE support for YAML linters by providing an extensive, detailed schema.
Top-Level Structure¶
Here's the complete manifest structure with all available top-level sections:
Manifest Overview¶
Complete agent configuration manifest defining all available agents.
This is the root configuration that: - Defines available response types (both inline and imported) - Configures all agent instances and their settings - Sets up custom role definitions and capabilities - Manages environment configurations
A single manifest can define multiple agents that can work independently or collaborate through the orchestrator.
Top-Level Sections¶
| Field | Type | Default | Description |
|---|---|---|---|
INHERIT |
str | list[str] | Inheritance references. | |
name |
str | Optional name for this manifest. | |
resources |
dict[str, one of 57 types] | (factory) | Resource configurations defining available filesystems. |
agents |
dict[str, one of 10 types] | (factory) | Mapping of agent IDs to their configurations. |
default_agent |
str | Name of the default/main agent. | |
file_agents |
dict[str, str | ClaudeFileAgentConfig | OpenCodeFileAgentConfig | NativeFileAgentConfig] | (factory) | Mapping of agent IDs to file-based agent definitions. |
teams |
dict[str, TeamConfig] | (factory) | Mapping of team IDs to their configurations. |
storage |
StorageConfig | (factory) | Storage provider configuration. |
observability |
ObservabilityConfig | (factory) | Observability provider configuration. |
conversion |
ConversionConfig | (factory) | Document conversion configuration. |
responses |
dict[str, StructuredResponseConfig] | (factory) | Mapping of response names to their definitions. |
model_variants |
dict[str, one of 16 types] | (factory) | Named model variants with pre-configured settings. |
jobs |
dict[str, Job[Any, str]] | (factory) | Pre-defined jobs, ready to be used by nodes. |
mcp_servers |
list[str | StdioMCPServerConfig | SSEMCPServerConfig | StreamableHTTPMCPServerConfig] | (factory) | List of MCP server configurations: |
pool_server |
MCPPoolServerConfig | (factory) | Pool server configuration. |
prompts |
PromptLibraryConfig | (factory) | Prompt library configuration. |
commands |
dict[str, StaticCommandConfig | FileCommandConfig | CallableCommandConfig | str] | (factory) | Global command shortcuts for prompt injection. |
compaction |
CompactionConfig | Compaction configuration for message history management. |
| Section | Documentation |
|---|---|
agents |
Node Types: native, Claude Code, Codex, ACP, AG-UI, OpenCode V2, Antigravity and T3 agents |
file_agents |
File Agents |
teams |
Teams |
default_agent |
The agent clients talk to first (else the first agent) |
model_variants |
Model Variants |
responses |
Response Types |
mcp_servers |
MCP Servers |
pool_server |
MCP Server (serve-mcp) |
resources |
Resources |
storage |
Storage |
observability |
Observability |
conversion |
Document Conversion |
prompts |
System Prompts, Prompt Hubs |
commands |
Commands |
jobs |
Tasks |
compaction |
Message History |
INHERIT |
Inheritance |
Configuration Resolution¶
AgentPool uses a layered configuration system inspired by OpenCode. Multiple config files are automatically discovered and deep-merged, allowing you to set global preferences while overriding project-specific settings.
Precedence Order¶
Configs are loaded and merged in this order (later sources override earlier ones):
| Priority | Source | Location | Description |
|---|---|---|---|
| 1 | Global | ~/.config/agentpool/agentpool.yml |
User-wide preferences |
| 2 | Custom | AGENTPOOL_CONFIG env var |
CI/deployment overrides |
| 3 | Inline | AGENTPOOL_CONFIG_CONTENT env var |
Runtime config as YAML/JSON string |
| 4 | Project | agentpool.yml in project root |
Project-specific settings |
| 5 | Explicit | CLI argument | Highest precedence |
| fallback | Built-in | Package defaults | Only if no agents defined elsewhere |
Deep Merge Behavior
Configs are deep-merged, not replaced. This means:
- Nested dictionaries are merged recursively
- Conflicting keys are overridden by higher-precedence sources
- Non-conflicting settings from all sources are preserved
- Lists are replaced entirely (not concatenated)
Project Config Discovery¶
Project config is discovered by searching for agentpool.yml (or .yaml, .json, .jsonc) starting from the current directory and traversing up to the nearest git repository root.
Fallback Behavior¶
The built-in fallback config (e.g., acp_assistant.yml) is only loaded if no agents are defined in any of the other layers. This ensures that:
- Users who define their own agents don't get polluted with default agents
- Users without any config still get a working default assistant
Example: Layered Configuration¶
The merged config contains both the global model_variants/storage and the project's agents.
Environment Variables¶
| Variable | Description |
|---|---|
AGENTPOOL_CONFIG |
Path to custom config file |
AGENTPOOL_CONFIG_CONTENT |
Inline YAML/JSON config content |
AGENTPOOL_NO_GLOBAL_CONFIG |
Set to disable global config loading |
AGENTPOOL_NO_PROJECT_CONFIG |
Set to disable project config discovery |
CLI Commands¶
Use these commands to inspect config resolution:
# Show which configs are found and loaded
agentpool config show
# Show standard config paths
agentpool config paths
# Create a starter config file
agentpool config init # In current project
agentpool config init global # In global config dir
File-Level Inheritance (INHERIT)¶
In addition to layered resolution, individual config files can use the INHERIT key to explicitly inherit from another file:
AgentPool supports UPaths (universal-pathlib) for INHERIT, allowing pointing to remote configurations (http://path/to/config.yml).
Reusing Settings with YAML Anchors¶
Top-level keys starting with x- (the Docker Compose convention) are extension fields:
AgentPool ignores them and the JSON schema allows them. Use one to hold shared settings as
YAML anchors (&name) and merge them into agents with <<: *name:
x-defaults: &defaults
model: openai:gpt-5-mini
retries: 2
description: "Shared defaults"
agents:
reviewer:
<<: *defaults
system_prompt: "Review the code you are given."
writer:
<<: *defaults
model: openai:gpt-5 # keys next to the merge override it
system_prompt: "Write documentation."
Other unknown top-level keys are still rejected, so typos like agent: keep failing validation.
Schema Validation¶
You can get IDE linter support by adding this line at the top of your YAML:
# yaml-language-server: $schema=https://raw.githubusercontent.com/phil65/agentpool/refs/heads/main/schema/config-schema.json
Note
Versioned config files will arrive soon for better stability!
Usage¶
Load a manifest in your code: