Agents & Sub-Agents
Agents live in .wingman/agents/<agent-id>/ and can be defined as either JSON (agent.json) or Markdown (agent.md with frontmatter).
Discovery vs routing
- Discovery: agent definitions are loaded from
.wingman/agents/<agent-id>/. - Routing & metadata: defaults, display names, workspaces, and channel bindings live in
wingman.config.jsonunderagents.listandagents.bindings.
If you want the gateway to route messages to a specific agent (or show a friendly name in the UI), add entries in wingman.config.json. See the agents section in the wingman.config.json guide.
Bundled agents (starter templates)
Wingman ships with a small set of bundled agents so you can start quickly. These live in the package at:
When you run wingman init, the templates are copied into your workspace:
You can choose a subset during setup:
To re-copy bundled agents later without changing config or provider settings:
Bundled templates currently include:
main(general-purpose)coding(direct-execution coding specialist with tool-backed completion guard)coding-v2(multi-subagent coding orchestrator with planner/implementor/reviewer split)game-dev(game feature orchestrator with specialist sub-agents, browser-assisted WebGL/UI QA, and UV/geometry-aware texture generation guidance)image-generator(native prompt-to-image specialist usingxai:grok-imagine-image)researcher(source-first web research)stock-trader(market data research workflows)
Edit these in-place to customize prompts, tools, or sub-agents. Treat them as templates—clone and rename as needed for each project.
wingman init installs the bundled agents into your workspace and lets you choose which explicit agent should be the default.
Agent overview (including MCP dependency)
MCP dependency levels used below:
- None: the template does not rely on MCP to do its core job.
- Optional: the template can use MCP if configured, but works without it.
- Recommended: MCP materially improves core workflows.
- Required: core workflow assumes MCP tools are available.
browser_control is native to Wingman runtime (CDP with automatic persistent-context fallback when needed). It is not provided through MCP. The bundled game-dev template uses it for browser-backed QA, and when a default browser profile is configured those runs use Playwright persistent-context automatically.
MCP-focused config examples
1) No MCP dependency (researcher)
2) Required MCP dependency (stock-trader with global finance MCP)
3) Recommended MCP dependency (game-dev or main with FAL MCP)
The stock-trader agent is for research and education only. It does not provide financial advice or execute trades.
For readability, the stock-trader agent returns a concise Decision Packet with a direct answer first, followed by short sections that summarize the key signals and risks (no raw tool dumps). Ask it to expand any section if you need deeper detail.
Provider credentials (env vars)
Agents that talk to model providers require credentials. Use either wingman provider login <provider> or environment variables, for example:
agent.json example
agent.md example
Sub-agent model overrides
Sub-agents can override any agent field, including model, tools, voice, and command controls. This lets you mix fast/cheap models with deep/reasoning models in one squad.
Sub-agent prompt files (agent.md)
When using agent.md, sub-agents can load their prompts from separate files with promptFile. This keeps large prompts readable and makes it easier to reuse or iterate on specialist instructions.
File layout:
If a prompt file contains frontmatter, those fields override/extend the sub-agent metadata. Otherwise the file is treated as the sub-agent’s systemPrompt.
Available tools
Agents can only use the tools listed in the tools array. Available tool names:
internet_searchweb_crawlerbrowser_controlbrowser_session_startbrowser_session_actionbrowser_session_closebrowser_session_listcommand_executebackground_terminalnode_notifynode_runthinkcode_searchgit_statusui_registry_listui_registry_getui_present
Sub-agent delegation
subAgents lets you define specialist agents. The parent agent can delegate tasks when needed. Each sub-agent supports the same schema fields as a normal agent.
Prompt refinement
promptRefinement enables a per-agent instruction overlay that the agent can update over time based on explicit feedback.
- The overlay is stored under
/memories/so it persists across sessions. - Updates only happen when users give clear, durable preferences (e.g., “always do X”, “never do Y”).
- Keep the file short and stable: preferences, workflow rules, and corrections.
Browser, MCP, and voice overrides
browserProfile: named persistentbrowser_controlprofile ID (for exampletrading). Initialize one withwingman browser profile init trading.browserTransport: optional transport preference override (auto,playwright,relay) forbrowser_controlorbrowser_session_*browserExtensions: optional extension IDs loaded for this agent (mapped frombrowser.extensionsinwingman.config.json)mcp: agent-specific MCP serversmcpUseGlobal: include global MCP servers fromwingman.config.jsonvoice: overrides global voice configuration for this agentpromptRefinement: enable/disable prompt refinement and set the overlay path
Browser profile setup patterns
Prefer browser_session_* for normal browser automation. Reserve browser_control for agents that should only act when the user explicitly wants Wingman to use their existing browser or live tab.
- Shared default profile across browser-enabled agents:
- Run
wingman browser profile init trading --default - Omit
browserProfilein agents and rely onbrowser.defaultProfile
- Run
- Per-agent profile isolation:
- Run
wingman browser profile init <id>for each profile - Set
browserProfileper agent (research,trading, etc.)
- Run
- Per-agent extension set:
- Run
wingman browser extension install --defaultfor Wingman's bundled extension, orwingman browser extension install <id> --source <dir>for a custom one - Set
browserExtensionsin agent config when an agent needs non-default extensions
- Run
- Custom storage location:
- Run
wingman browser profile init trading --profiles-dir .wingman/profiles
- Run
For full examples, see Browser Automation, Playwright Setup, and Relay Setup.
Why voice is duplicated in agent config
Voice exists in both global config and agent config so you can set defaults once and override per agent. This allows one agent to speak with ElevenLabs while another uses Web Speech (or stays silent).
