Skip to main content
Glama

generate_workflow

Break a high-level goal into ordered stages and launch agents that execute each stage only after the previous stage completes.

Instructions

Auto-decompose a high-level goal into an ordered sequence of stages, then spawn all jobs with stage-based dependency enforcement. Returns immediately with workflow_id, job_ids, and the stage breakdown. Use get_workflow_status to poll progress. Each stage only starts after ALL jobs in the prior stage complete — guaranteeing ordered execution even across 100s of agents.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
goalYesHigh-level natural language goal to decompose into workflow stages (e.g. 'build, test, and deploy X')
repo_urlYesGit repository URL for all spawned agents (https://github.com/owner/repo)
max_stagesNoMaximum number of sequential stages (default 8, hard cap 20)
agent_modelNoModel override for spawned agents (optional)
agent_driverNoDriver override for spawned agents (optional, e.g. 'claude', 'aider')
max_agents_per_stageNoMaximum number of parallel agents per stage (default 3)
max_budget_per_agentNoMaximum USD budget per spawned agent (default 5)
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations, the description fully covers behavioral aspects: it is asynchronous (returns immediately), enforces ordered execution ('Each stage only starts after ALL jobs in the prior stage complete'), and scales to '100s of agents'. No contradictions.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Two sentences with no fluff. First sentence states action and return values, second provides polling guidance and execution behavior. All information is front-loaded.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given no output schema, the description explains return values (workflow_id, job_ids, stage breakdown) and covers how to handle the async result. All 7 parameters are described with additional context on defaults and caps.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so baseline is 3. The description adds value by specifying default values for max_stages (8), max_agents_per_stage (3), max_budget_per_agent (5), and a hard cap of 20 for max_stages, which are not in the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool's purpose: 'Auto-decompose a high-level goal into an ordered sequence of stages, then spawn all jobs with stage-based dependency enforcement.' It uses specific verbs and resources, and the unique decomposition and ordering differentiates it from siblings like spawn_agent.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Provides explicit usage guidance: 'Returns immediately... Use get_workflow_status to poll progress.' and explains stage execution ordering. However, it does not explicitly state when to use this tool vs alternatives like spawn_agent or swarm_task.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Gonzih/cc-agent'

If you have feedback or need assistance with the MCP directory API, please join our Discord server