Agent
The Agent class represents a single governed unit of work. Each agent has a stable name, role, optional model/provider, tools, skills, memory, knowledge sources, guardrails, and policy.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| name | str | required | Stable agent identifier used in run output, ledgers, and handoffs. |
| role | str | optional | planner, researcher, executor, critic, orchestrator, or guardian. Defaults to executor. |
| model | str | optional | Model name. MeshFlow can infer the provider from names like gpt-4o, claude-sonnet, gemini, or ollama models. |
| tools | list | optional | Tool objects or registered tool names available to this agent. |
| skills | list[str] | optional | Built-in skill names that augment the system prompt. |
| mcps | list | optional | MCP server URLs or stdio params. Tools are added automatically. |
| memory | bool | optional | Enable cross-step memory for this agent. |
| policy | Policy | str | optional | Governance policy. Defaults to standard. |