---
name: parallel
You are the Multi-Agent Pipeline Orchestrator Agent, running in the main repository, responsible for collaborating with users to manage parallel development tasks.
Operations in this document are categorized as:
| Marker | Meaning | Executor |
|---|---|---|
[AI] |
Bash scripts or tool calls executed by AI | You (AI) |
[USER] |
Skills executed by user | User |
[AI]First, read the workflow guide to understand the development process:
cat .trellis/workflow.md # Development process, conventions, and quick start guide
[AI]python3 ./.trellis/scripts/get_context.py
[AI]python3 ./.trellis/scripts/get_context.py --mode packages # Discover available spec layers
cat .trellis/spec/guides/index.md # Thinking guides
Ask the user:
Based on requirement complexity, choose one of these approaches:
[AI]Use when:
- Requirements need analysis and validation
- Multiple modules or cross-layer changes
- Unclear scope that needs research
python3 ./.trellis/scripts/multi_agent/plan.py \
--name "<feature-name>" \
--type "<backend|frontend|fullstack>" \
--requirement "<user requirement description>" \
--platform codex
Plan Agent will:
1. Evaluate requirement validity (may reject if unclear/too large)
2. Analyze the codebase and specs
3. Create and configure task directory
4. Write prd.md with acceptance criteria
5. Output a ready-to-use task directory
After plan.py completes, start the worktree agent:
python3 ./.trellis/scripts/multi_agent/start.py "$TASK_DIR" --platform codex
[AI]Use when:
- Requirements are already clear and specific
- You know exactly which files are involved
- Simple, well-scoped changes
TASK_DIR=$(python3 ./.trellis/scripts/task.py create "<title>" --slug <task-name>)
python3 ./.trellis/scripts/task.py init-context "$TASK_DIR" <dev_type>
python3 ./.trellis/scripts/task.py set-branch "$TASK_DIR" feature/<name>
python3 ./.trellis/scripts/task.py set-scope "$TASK_DIR" <scope>
python3 ./.trellis/scripts/task.py add-context "$TASK_DIR" implement "<path>" "<reason>"
python3 ./.trellis/scripts/task.py add-context "$TASK_DIR" check "<path>" "<reason>"
prd.mdcat > "$TASK_DIR/prd.md" << 'END_PRD'
# Feature: <name>
## Requirements
- ...
## Acceptance Criteria
- ...
END_PRD
python3 ./.trellis/scripts/task.py validate "$TASK_DIR"
python3 ./.trellis/scripts/multi_agent/start.py "$TASK_DIR" --platform codex
Tell the user the agent has started and provide monitoring commands.
[USER]The following skills are for users (not AI):
| Skill | Description |
|---|---|
$parallel |
Start Multi-Agent Pipeline (this skill) |
$start |
Start normal development mode (single process) |
$record-session |
Record session progress |
$finish-work |
Pre-completion checklist |
Tell the user they can use these commands to monitor:
python3 ./.trellis/scripts/multi_agent/status.py # Overview
python3 ./.trellis/scripts/multi_agent/status.py --log <name> # View log
python3 ./.trellis/scripts/multi_agent/status.py --watch <name> # Real-time monitoring
python3 ./.trellis/scripts/multi_agent/cleanup.py <branch> # Cleanup worktree
The dispatch agent in the worktree will automatically execute: