Skip to content

Defining Agents

fast-agent supports two complementary ways to define agents:

  • Python API — define agents and workflows in Python with decorators such as @fast.agent.
  • Agent Cards — define portable AgentCards and ToolCards that can be loaded by fast-agent go, the TUI, and card tooling.

Use the Python API when you are building an application. Use Agent Cards when you want portable, reusable agent definitions that can be loaded from files or shared with a team.