@mindfoldhq/trellis 0.4.0 → 0.5.0-beta.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cli/index.js +0 -1
- package/dist/cli/index.js.map +1 -1
- package/dist/commands/init.d.ts +0 -1
- package/dist/commands/init.d.ts.map +1 -1
- package/dist/commands/init.js +2 -4
- package/dist/commands/init.js.map +1 -1
- package/dist/commands/update.d.ts +5 -0
- package/dist/commands/update.d.ts.map +1 -1
- package/dist/commands/update.js +100 -24
- package/dist/commands/update.js.map +1 -1
- package/dist/configurators/antigravity.d.ts +3 -4
- package/dist/configurators/antigravity.d.ts.map +1 -1
- package/dist/configurators/antigravity.js +17 -10
- package/dist/configurators/antigravity.js.map +1 -1
- package/dist/configurators/claude.d.ts +5 -28
- package/dist/configurators/claude.d.ts.map +1 -1
- package/dist/configurators/claude.js +30 -51
- package/dist/configurators/claude.js.map +1 -1
- package/dist/configurators/codebuddy.d.ts +6 -7
- package/dist/configurators/codebuddy.d.ts.map +1 -1
- package/dist/configurators/codebuddy.js +23 -51
- package/dist/configurators/codebuddy.js.map +1 -1
- package/dist/configurators/codex.d.ts +3 -6
- package/dist/configurators/codex.d.ts.map +1 -1
- package/dist/configurators/codex.js +29 -12
- package/dist/configurators/codex.js.map +1 -1
- package/dist/configurators/copilot.d.ts +6 -5
- package/dist/configurators/copilot.d.ts.map +1 -1
- package/dist/configurators/copilot.js +42 -13
- package/dist/configurators/copilot.js.map +1 -1
- package/dist/configurators/cursor.d.ts +6 -1
- package/dist/configurators/cursor.d.ts.map +1 -1
- package/dist/configurators/cursor.js +22 -45
- package/dist/configurators/cursor.js.map +1 -1
- package/dist/configurators/droid.d.ts +6 -1
- package/dist/configurators/droid.d.ts.map +1 -1
- package/dist/configurators/droid.js +23 -41
- package/dist/configurators/droid.js.map +1 -1
- package/dist/configurators/gemini.d.ts +8 -4
- package/dist/configurators/gemini.d.ts.map +1 -1
- package/dist/configurators/gemini.js +28 -47
- package/dist/configurators/gemini.js.map +1 -1
- package/dist/configurators/index.d.ts +1 -1
- package/dist/configurators/index.d.ts.map +1 -1
- package/dist/configurators/index.js +142 -98
- package/dist/configurators/index.js.map +1 -1
- package/dist/configurators/kilo.d.ts +3 -4
- package/dist/configurators/kilo.d.ts.map +1 -1
- package/dist/configurators/kilo.js +19 -46
- package/dist/configurators/kilo.js.map +1 -1
- package/dist/configurators/kiro.d.ts +4 -4
- package/dist/configurators/kiro.d.ts.map +1 -1
- package/dist/configurators/kiro.js +18 -14
- package/dist/configurators/kiro.js.map +1 -1
- package/dist/configurators/opencode.d.ts +3 -28
- package/dist/configurators/opencode.d.ts.map +1 -1
- package/dist/configurators/opencode.js +23 -48
- package/dist/configurators/opencode.js.map +1 -1
- package/dist/configurators/qoder.d.ts +6 -4
- package/dist/configurators/qoder.d.ts.map +1 -1
- package/dist/configurators/qoder.js +20 -47
- package/dist/configurators/qoder.js.map +1 -1
- package/dist/configurators/shared.d.ts +66 -3
- package/dist/configurators/shared.d.ts.map +1 -1
- package/dist/configurators/shared.js +251 -3
- package/dist/configurators/shared.js.map +1 -1
- package/dist/configurators/windsurf.d.ts +3 -4
- package/dist/configurators/windsurf.d.ts.map +1 -1
- package/dist/configurators/windsurf.js +17 -10
- package/dist/configurators/windsurf.js.map +1 -1
- package/dist/configurators/workflow.d.ts +0 -3
- package/dist/configurators/workflow.d.ts.map +1 -1
- package/dist/configurators/workflow.js +1 -7
- package/dist/configurators/workflow.js.map +1 -1
- package/dist/migrations/manifests/0.4.0.json +1 -1
- package/dist/migrations/manifests/0.5.0-beta.0.json +1644 -0
- package/dist/templates/claude/agents/check.md +2 -29
- package/dist/templates/claude/agents/research.md +70 -52
- package/dist/templates/claude/index.d.ts +5 -37
- package/dist/templates/claude/index.d.ts.map +1 -1
- package/dist/templates/claude/index.js +3 -42
- package/dist/templates/claude/index.js.map +1 -1
- package/dist/templates/claude/settings.json +3 -4
- package/dist/templates/{iflow → codebuddy}/agents/check.md +3 -30
- package/dist/templates/{iflow → codebuddy}/agents/implement.md +1 -1
- package/dist/templates/codebuddy/agents/research.md +138 -0
- package/dist/templates/codebuddy/index.d.ts +6 -16
- package/dist/templates/codebuddy/index.d.ts.map +1 -1
- package/dist/templates/codebuddy/index.js +6 -36
- package/dist/templates/codebuddy/index.js.map +1 -1
- package/dist/templates/codebuddy/settings.json +59 -0
- package/dist/templates/codex/agents/research.toml +50 -16
- package/dist/templates/codex/config.toml +10 -0
- package/dist/templates/codex/hooks/session-start.py +65 -29
- package/dist/templates/codex/hooks.json +11 -0
- package/dist/templates/codex/index.d.ts +0 -1
- package/dist/templates/codex/index.d.ts.map +1 -1
- package/dist/templates/codex/index.js +1 -8
- package/dist/templates/codex/index.js.map +1 -1
- package/dist/templates/common/commands/continue.md +51 -0
- package/dist/templates/common/commands/finish-work.md +32 -0
- package/dist/templates/common/commands/start.md +56 -0
- package/dist/templates/common/index.d.ts +28 -0
- package/dist/templates/common/index.d.ts.map +1 -0
- package/dist/templates/common/index.js +55 -0
- package/dist/templates/common/index.js.map +1 -0
- package/dist/templates/{codebuddy/commands/trellis → common/skills}/brainstorm.md +4 -4
- package/dist/templates/{opencode/commands/trellis → common/skills}/break-loop.md +4 -4
- package/dist/templates/common/skills/check.md +87 -0
- package/dist/templates/{codebuddy/commands/trellis → common/skills}/update-spec.md +18 -21
- package/dist/templates/copilot/hooks/session-start.py +65 -29
- package/dist/templates/copilot/hooks.json +8 -0
- package/dist/templates/cursor/agents/check.md +95 -0
- package/dist/templates/cursor/agents/implement.md +95 -0
- package/dist/templates/cursor/agents/research.md +138 -0
- package/dist/templates/cursor/hooks.json +24 -0
- package/dist/templates/cursor/index.d.ts +6 -17
- package/dist/templates/cursor/index.d.ts.map +1 -1
- package/dist/templates/cursor/index.js +6 -37
- package/dist/templates/cursor/index.js.map +1 -1
- package/dist/templates/droid/droids/check.md +95 -0
- package/dist/templates/droid/droids/implement.md +95 -0
- package/dist/templates/droid/droids/research.md +138 -0
- package/dist/templates/droid/index.d.ts +7 -19
- package/dist/templates/droid/index.d.ts.map +1 -1
- package/dist/templates/droid/index.js +7 -39
- package/dist/templates/droid/index.js.map +1 -1
- package/dist/templates/droid/settings.json +59 -0
- package/dist/templates/extract.d.ts +7 -193
- package/dist/templates/extract.d.ts.map +1 -1
- package/dist/templates/extract.js +7 -310
- package/dist/templates/extract.js.map +1 -1
- package/dist/templates/gemini/agents/check.md +95 -0
- package/dist/templates/gemini/agents/implement.md +95 -0
- package/dist/templates/gemini/agents/research.md +138 -0
- package/dist/templates/gemini/index.d.ts +6 -14
- package/dist/templates/gemini/index.d.ts.map +1 -1
- package/dist/templates/gemini/index.js +6 -37
- package/dist/templates/gemini/index.js.map +1 -1
- package/dist/templates/gemini/settings.json +28 -0
- package/dist/templates/kiro/agents/check.json +13 -0
- package/dist/templates/kiro/agents/implement.json +13 -0
- package/dist/templates/kiro/agents/research.json +21 -0
- package/dist/templates/kiro/index.d.ts +11 -11
- package/dist/templates/kiro/index.d.ts.map +1 -1
- package/dist/templates/kiro/index.js +11 -33
- package/dist/templates/kiro/index.js.map +1 -1
- package/dist/templates/opencode/agents/check.md +3 -30
- package/dist/templates/opencode/agents/implement.md +1 -1
- package/dist/templates/opencode/agents/research.md +1 -2
- package/dist/templates/opencode/plugins/inject-subagent-context.js +9 -183
- package/dist/templates/opencode/plugins/inject-workflow-state.js +160 -0
- package/dist/templates/opencode/plugins/session-start.js +71 -32
- package/dist/templates/qoder/agents/check.md +95 -0
- package/dist/templates/qoder/agents/implement.md +95 -0
- package/dist/templates/qoder/agents/research.md +138 -0
- package/dist/templates/qoder/index.d.ts +7 -10
- package/dist/templates/qoder/index.d.ts.map +1 -1
- package/dist/templates/qoder/index.js +7 -32
- package/dist/templates/qoder/index.js.map +1 -1
- package/dist/templates/qoder/settings.json +47 -0
- package/dist/templates/shared-hooks/index.d.ts +19 -0
- package/dist/templates/shared-hooks/index.d.ts.map +1 -0
- package/dist/templates/shared-hooks/index.js +30 -0
- package/dist/templates/shared-hooks/index.js.map +1 -0
- package/dist/templates/{iflow/hooks → shared-hooks}/inject-subagent-context.py +74 -263
- package/dist/templates/shared-hooks/inject-workflow-state.py +231 -0
- package/dist/templates/{claude/hooks → shared-hooks}/session-start.py +162 -55
- package/dist/templates/template-utils.d.ts +26 -0
- package/dist/templates/template-utils.d.ts.map +1 -0
- package/dist/templates/template-utils.js +60 -0
- package/dist/templates/template-utils.js.map +1 -0
- package/dist/templates/trellis/index.d.ts +1 -14
- package/dist/templates/trellis/index.d.ts.map +1 -1
- package/dist/templates/trellis/index.js +2 -27
- package/dist/templates/trellis/index.js.map +1 -1
- package/dist/templates/trellis/scripts/common/cli_adapter.py +2 -2
- package/dist/templates/trellis/scripts/common/config.py +126 -1
- package/dist/templates/trellis/scripts/common/git_context.py +25 -2
- package/dist/templates/trellis/scripts/common/task_context.py +3 -23
- package/dist/templates/trellis/scripts/common/task_store.py +0 -12
- package/dist/templates/trellis/scripts/common/workflow_phase.py +176 -0
- package/dist/templates/trellis/scripts/task.py +6 -35
- package/dist/templates/trellis/workflow.md +274 -297
- package/dist/types/ai-tools.d.ts +21 -3
- package/dist/types/ai-tools.d.ts.map +1 -1
- package/dist/types/ai-tools.js +106 -15
- package/dist/types/ai-tools.js.map +1 -1
- package/dist/types/migration.d.ts +8 -1
- package/dist/types/migration.d.ts.map +1 -1
- package/package.json +3 -2
- package/dist/configurators/iflow.d.ts +0 -33
- package/dist/configurators/iflow.d.ts.map +0 -1
- package/dist/configurators/iflow.js +0 -99
- package/dist/configurators/iflow.js.map +0 -1
- package/dist/templates/antigravity/index.d.ts +0 -12
- package/dist/templates/antigravity/index.d.ts.map +0 -1
- package/dist/templates/antigravity/index.js +0 -29
- package/dist/templates/antigravity/index.js.map +0 -1
- package/dist/templates/claude/agents/debug.md +0 -106
- package/dist/templates/claude/agents/dispatch.md +0 -213
- package/dist/templates/claude/agents/plan.md +0 -396
- package/dist/templates/claude/commands/trellis/brainstorm.md +0 -487
- package/dist/templates/claude/commands/trellis/break-loop.md +0 -125
- package/dist/templates/claude/commands/trellis/check-cross-layer.md +0 -153
- package/dist/templates/claude/commands/trellis/check.md +0 -25
- package/dist/templates/claude/commands/trellis/create-command.md +0 -154
- package/dist/templates/claude/commands/trellis/finish-work.md +0 -153
- package/dist/templates/claude/commands/trellis/integrate-skill.md +0 -219
- package/dist/templates/claude/commands/trellis/onboard.md +0 -358
- package/dist/templates/claude/commands/trellis/parallel.md +0 -192
- package/dist/templates/claude/commands/trellis/record-session.md +0 -62
- package/dist/templates/claude/commands/trellis/start.md +0 -393
- package/dist/templates/claude/commands/trellis/update-spec.md +0 -354
- package/dist/templates/claude/hooks/inject-subagent-context.py +0 -803
- package/dist/templates/claude/hooks/ralph-loop.py +0 -396
- package/dist/templates/codebuddy/commands/trellis/before-dev.md +0 -29
- package/dist/templates/codebuddy/commands/trellis/break-loop.md +0 -107
- package/dist/templates/codebuddy/commands/trellis/check-cross-layer.md +0 -153
- package/dist/templates/codebuddy/commands/trellis/check.md +0 -25
- package/dist/templates/codebuddy/commands/trellis/create-command.md +0 -154
- package/dist/templates/codebuddy/commands/trellis/finish-work.md +0 -143
- package/dist/templates/codebuddy/commands/trellis/integrate-skill.md +0 -219
- package/dist/templates/codebuddy/commands/trellis/onboard.md +0 -358
- package/dist/templates/codebuddy/commands/trellis/record-session.md +0 -61
- package/dist/templates/codebuddy/commands/trellis/start.md +0 -373
- package/dist/templates/codex/codex-skills/parallel/SKILL.md +0 -194
- package/dist/templates/cursor/commands/trellis-before-dev.md +0 -29
- package/dist/templates/cursor/commands/trellis-brainstorm.md +0 -487
- package/dist/templates/cursor/commands/trellis-break-loop.md +0 -107
- package/dist/templates/cursor/commands/trellis-check-cross-layer.md +0 -153
- package/dist/templates/cursor/commands/trellis-check.md +0 -25
- package/dist/templates/cursor/commands/trellis-create-command.md +0 -154
- package/dist/templates/cursor/commands/trellis-finish-work.md +0 -143
- package/dist/templates/cursor/commands/trellis-integrate-skill.md +0 -219
- package/dist/templates/cursor/commands/trellis-onboard.md +0 -358
- package/dist/templates/cursor/commands/trellis-record-session.md +0 -62
- package/dist/templates/cursor/commands/trellis-start.md +0 -373
- package/dist/templates/cursor/commands/trellis-update-spec.md +0 -354
- package/dist/templates/droid/commands/trellis/before-dev.md +0 -33
- package/dist/templates/droid/commands/trellis/brainstorm.md +0 -491
- package/dist/templates/droid/commands/trellis/break-loop.md +0 -111
- package/dist/templates/droid/commands/trellis/check-cross-layer.md +0 -157
- package/dist/templates/droid/commands/trellis/check.md +0 -29
- package/dist/templates/droid/commands/trellis/create-command.md +0 -158
- package/dist/templates/droid/commands/trellis/finish-work.md +0 -147
- package/dist/templates/droid/commands/trellis/integrate-skill.md +0 -223
- package/dist/templates/droid/commands/trellis/onboard.md +0 -362
- package/dist/templates/droid/commands/trellis/record-session.md +0 -66
- package/dist/templates/droid/commands/trellis/start.md +0 -377
- package/dist/templates/droid/commands/trellis/update-spec.md +0 -358
- package/dist/templates/gemini/commands/trellis/before-dev.toml +0 -33
- package/dist/templates/gemini/commands/trellis/brainstorm.toml +0 -435
- package/dist/templates/gemini/commands/trellis/break-loop.toml +0 -129
- package/dist/templates/gemini/commands/trellis/check-cross-layer.toml +0 -147
- package/dist/templates/gemini/commands/trellis/check.toml +0 -29
- package/dist/templates/gemini/commands/trellis/create-command.toml +0 -119
- package/dist/templates/gemini/commands/trellis/finish-work.toml +0 -133
- package/dist/templates/gemini/commands/trellis/integrate-skill.toml +0 -104
- package/dist/templates/gemini/commands/trellis/onboard.toml +0 -111
- package/dist/templates/gemini/commands/trellis/record-session.toml +0 -66
- package/dist/templates/gemini/commands/trellis/start.toml +0 -354
- package/dist/templates/gemini/commands/trellis/update-spec.toml +0 -132
- package/dist/templates/iflow/agents/debug.md +0 -106
- package/dist/templates/iflow/agents/dispatch.md +0 -213
- package/dist/templates/iflow/agents/plan.md +0 -396
- package/dist/templates/iflow/agents/research.md +0 -120
- package/dist/templates/iflow/commands/trellis/before-dev.md +0 -29
- package/dist/templates/iflow/commands/trellis/brainstorm.md +0 -487
- package/dist/templates/iflow/commands/trellis/break-loop.md +0 -125
- package/dist/templates/iflow/commands/trellis/check-cross-layer.md +0 -153
- package/dist/templates/iflow/commands/trellis/check.md +0 -25
- package/dist/templates/iflow/commands/trellis/create-command.md +0 -152
- package/dist/templates/iflow/commands/trellis/finish-work.md +0 -153
- package/dist/templates/iflow/commands/trellis/integrate-skill.md +0 -219
- package/dist/templates/iflow/commands/trellis/onboard.md +0 -358
- package/dist/templates/iflow/commands/trellis/parallel.md +0 -192
- package/dist/templates/iflow/commands/trellis/record-session.md +0 -62
- package/dist/templates/iflow/commands/trellis/start.md +0 -393
- package/dist/templates/iflow/commands/trellis/update-spec.md +0 -354
- package/dist/templates/iflow/hooks/ralph-loop.py +0 -395
- package/dist/templates/iflow/hooks/session-start.py +0 -403
- package/dist/templates/iflow/index.d.ts +0 -54
- package/dist/templates/iflow/index.d.ts.map +0 -1
- package/dist/templates/iflow/index.js +0 -85
- package/dist/templates/iflow/index.js.map +0 -1
- package/dist/templates/iflow/settings.json +0 -60
- package/dist/templates/kilo/index.d.ts +0 -16
- package/dist/templates/kilo/index.d.ts.map +0 -1
- package/dist/templates/kilo/index.js +0 -39
- package/dist/templates/kilo/index.js.map +0 -1
- package/dist/templates/kilo/workflows/before-dev.md +0 -29
- package/dist/templates/kilo/workflows/brainstorm.md +0 -487
- package/dist/templates/kilo/workflows/break-loop.md +0 -125
- package/dist/templates/kilo/workflows/check-cross-layer.md +0 -153
- package/dist/templates/kilo/workflows/check.md +0 -25
- package/dist/templates/kilo/workflows/create-command.md +0 -152
- package/dist/templates/kilo/workflows/finish-work.md +0 -129
- package/dist/templates/kilo/workflows/integrate-skill.md +0 -219
- package/dist/templates/kilo/workflows/onboard.md +0 -358
- package/dist/templates/kilo/workflows/parallel.md +0 -193
- package/dist/templates/kilo/workflows/record-session.md +0 -62
- package/dist/templates/kilo/workflows/start.md +0 -387
- package/dist/templates/kilo/workflows/update-spec.md +0 -285
- package/dist/templates/kiro/skills/before-dev/SKILL.md +0 -34
- package/dist/templates/kiro/skills/brainstorm/SKILL.md +0 -492
- package/dist/templates/kiro/skills/break-loop/SKILL.md +0 -130
- package/dist/templates/kiro/skills/check/SKILL.md +0 -30
- package/dist/templates/kiro/skills/check-cross-layer/SKILL.md +0 -158
- package/dist/templates/kiro/skills/create-command/SKILL.md +0 -101
- package/dist/templates/kiro/skills/finish-work/SKILL.md +0 -148
- package/dist/templates/kiro/skills/integrate-skill/SKILL.md +0 -221
- package/dist/templates/kiro/skills/onboard/SKILL.md +0 -363
- package/dist/templates/kiro/skills/record-session/SKILL.md +0 -67
- package/dist/templates/kiro/skills/start/SKILL.md +0 -351
- package/dist/templates/kiro/skills/update-spec/SKILL.md +0 -335
- package/dist/templates/opencode/agents/debug.md +0 -129
- package/dist/templates/opencode/agents/dispatch.md +0 -223
- package/dist/templates/opencode/agents/trellis-plan.md +0 -427
- package/dist/templates/opencode/commands/trellis/before-dev.md +0 -29
- package/dist/templates/opencode/commands/trellis/brainstorm.md +0 -487
- package/dist/templates/opencode/commands/trellis/check-cross-layer.md +0 -153
- package/dist/templates/opencode/commands/trellis/check.md +0 -25
- package/dist/templates/opencode/commands/trellis/create-command.md +0 -154
- package/dist/templates/opencode/commands/trellis/finish-work.md +0 -144
- package/dist/templates/opencode/commands/trellis/integrate-skill.md +0 -219
- package/dist/templates/opencode/commands/trellis/migrate-specs.md +0 -0
- package/dist/templates/opencode/commands/trellis/onboard.md +0 -358
- package/dist/templates/opencode/commands/trellis/parallel.md +0 -193
- package/dist/templates/opencode/commands/trellis/record-session.md +0 -62
- package/dist/templates/opencode/commands/trellis/start.md +0 -351
- package/dist/templates/opencode/commands/trellis/update-spec.md +0 -354
- package/dist/templates/qoder/skills/before-dev/SKILL.md +0 -34
- package/dist/templates/qoder/skills/brainstorm/SKILL.md +0 -492
- package/dist/templates/qoder/skills/break-loop/SKILL.md +0 -130
- package/dist/templates/qoder/skills/check/SKILL.md +0 -30
- package/dist/templates/qoder/skills/check-cross-layer/SKILL.md +0 -158
- package/dist/templates/qoder/skills/create-command/SKILL.md +0 -101
- package/dist/templates/qoder/skills/finish-work/SKILL.md +0 -134
- package/dist/templates/qoder/skills/integrate-skill/SKILL.md +0 -221
- package/dist/templates/qoder/skills/onboard/SKILL.md +0 -363
- package/dist/templates/qoder/skills/record-session/SKILL.md +0 -67
- package/dist/templates/qoder/skills/start/SKILL.md +0 -388
- package/dist/templates/qoder/skills/update-spec/SKILL.md +0 -290
- package/dist/templates/trellis/scripts/common/phase.py +0 -254
- package/dist/templates/trellis/scripts/common/registry.py +0 -335
- package/dist/templates/trellis/scripts/common/worktree.py +0 -305
- package/dist/templates/trellis/scripts/multi_agent/__init__.py +0 -5
- package/dist/templates/trellis/scripts/multi_agent/_bootstrap.py +0 -17
- package/dist/templates/trellis/scripts/multi_agent/cleanup.py +0 -398
- package/dist/templates/trellis/scripts/multi_agent/create_pr.py +0 -620
- package/dist/templates/trellis/scripts/multi_agent/plan.py +0 -213
- package/dist/templates/trellis/scripts/multi_agent/start.py +0 -539
- package/dist/templates/trellis/scripts/multi_agent/status.py +0 -76
- package/dist/templates/trellis/scripts/multi_agent/status_display.py +0 -542
- package/dist/templates/trellis/scripts/multi_agent/status_monitor.py +0 -225
- package/dist/templates/trellis/scripts-shell-archive/add-session.sh +0 -384
- package/dist/templates/trellis/scripts-shell-archive/common/developer.sh +0 -129
- package/dist/templates/trellis/scripts-shell-archive/common/git-context.sh +0 -263
- package/dist/templates/trellis/scripts-shell-archive/common/paths.sh +0 -208
- package/dist/templates/trellis/scripts-shell-archive/common/phase.sh +0 -150
- package/dist/templates/trellis/scripts-shell-archive/common/registry.sh +0 -247
- package/dist/templates/trellis/scripts-shell-archive/common/task-queue.sh +0 -142
- package/dist/templates/trellis/scripts-shell-archive/common/task-utils.sh +0 -151
- package/dist/templates/trellis/scripts-shell-archive/common/worktree.sh +0 -128
- package/dist/templates/trellis/scripts-shell-archive/create-bootstrap.sh +0 -299
- package/dist/templates/trellis/scripts-shell-archive/get-context.sh +0 -7
- package/dist/templates/trellis/scripts-shell-archive/get-developer.sh +0 -15
- package/dist/templates/trellis/scripts-shell-archive/init-developer.sh +0 -34
- package/dist/templates/trellis/scripts-shell-archive/multi-agent/cleanup.sh +0 -396
- package/dist/templates/trellis/scripts-shell-archive/multi-agent/create-pr.sh +0 -241
- package/dist/templates/trellis/scripts-shell-archive/multi-agent/plan.sh +0 -207
- package/dist/templates/trellis/scripts-shell-archive/multi-agent/start.sh +0 -317
- package/dist/templates/trellis/scripts-shell-archive/multi-agent/status.sh +0 -828
- package/dist/templates/trellis/scripts-shell-archive/task.sh +0 -1204
- package/dist/templates/trellis/worktree.yaml +0 -47
- package/dist/templates/windsurf/index.d.ts +0 -21
- package/dist/templates/windsurf/index.d.ts.map +0 -1
- package/dist/templates/windsurf/index.js +0 -44
- package/dist/templates/windsurf/index.js.map +0 -1
- package/dist/templates/windsurf/workflows/trellis-before-dev.md +0 -31
- package/dist/templates/windsurf/workflows/trellis-brainstorm.md +0 -491
- package/dist/templates/windsurf/workflows/trellis-break-loop.md +0 -111
- package/dist/templates/windsurf/workflows/trellis-check-cross-layer.md +0 -157
- package/dist/templates/windsurf/workflows/trellis-check.md +0 -27
- package/dist/templates/windsurf/workflows/trellis-create-command.md +0 -154
- package/dist/templates/windsurf/workflows/trellis-finish-work.md +0 -147
- package/dist/templates/windsurf/workflows/trellis-integrate-skill.md +0 -220
- package/dist/templates/windsurf/workflows/trellis-onboard.md +0 -362
- package/dist/templates/windsurf/workflows/trellis-record-session.md +0 -66
- package/dist/templates/windsurf/workflows/trellis-start.md +0 -373
- package/dist/templates/windsurf/workflows/trellis-update-spec.md +0 -358
- /package/dist/templates/{claude/commands/trellis → common/skills}/before-dev.md +0 -0
- /package/dist/templates/{claude/hooks → shared-hooks}/statusline.py +0 -0
|
@@ -1,416 +1,393 @@
|
|
|
1
1
|
# Development Workflow
|
|
2
2
|
|
|
3
|
-
> Based on [Effective Harnesses for Long-Running Agents](https://www.anthropic.com/engineering/effective-harnesses-for-long-running-agents)
|
|
4
|
-
|
|
5
3
|
---
|
|
6
4
|
|
|
7
|
-
##
|
|
5
|
+
## Core Principles
|
|
8
6
|
|
|
9
|
-
1.
|
|
10
|
-
2.
|
|
11
|
-
3.
|
|
12
|
-
4.
|
|
13
|
-
5.
|
|
14
|
-
6. [File Descriptions](#file-descriptions)
|
|
15
|
-
7. [Best Practices](#best-practices)
|
|
7
|
+
1. **Plan before code** — figure out what to do before you start
|
|
8
|
+
2. **Specs injected, not remembered** — guidelines are injected via hook/skill, not recalled from memory
|
|
9
|
+
3. **Persist everything** — research, decisions, and lessons all go to files; conversations get compacted, files don't
|
|
10
|
+
4. **Incremental development** — one task at a time
|
|
11
|
+
5. **Capture learnings** — after each task, review and write new knowledge back to spec
|
|
16
12
|
|
|
17
13
|
---
|
|
18
14
|
|
|
19
|
-
##
|
|
15
|
+
## Trellis System
|
|
20
16
|
|
|
21
|
-
###
|
|
17
|
+
### Developer Identity
|
|
22
18
|
|
|
23
|
-
|
|
19
|
+
On first use, initialize your identity:
|
|
24
20
|
|
|
25
21
|
```bash
|
|
26
|
-
# Check if already initialized
|
|
27
|
-
python3 ./.trellis/scripts/get_developer.py
|
|
28
|
-
|
|
29
|
-
# If not initialized, run:
|
|
30
22
|
python3 ./.trellis/scripts/init_developer.py <your-name>
|
|
31
|
-
# Example: python3 ./.trellis/scripts/init_developer.py cursor-agent
|
|
32
23
|
```
|
|
33
24
|
|
|
34
|
-
|
|
35
|
-
- `.trellis/.developer` - Your identity file (gitignored, not committed)
|
|
36
|
-
- `.trellis/workspace/<your-name>/` - Your personal workspace directory
|
|
25
|
+
Creates `.trellis/.developer` (gitignored) + `.trellis/workspace/<your-name>/`.
|
|
37
26
|
|
|
38
|
-
|
|
39
|
-
- Human developers: Use your name, e.g., `john-doe`
|
|
40
|
-
- Cursor AI: `cursor-agent` or `cursor-<task>`
|
|
41
|
-
- Claude Code: `claude-agent` or `claude-<task>`
|
|
42
|
-
- iFlow cli: `iflow-agent` or `iflow-<task>`
|
|
27
|
+
### Spec System
|
|
43
28
|
|
|
44
|
-
|
|
29
|
+
`.trellis/spec/` holds coding guidelines organized by package and layer.
|
|
45
30
|
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
python3 ./.trellis/scripts/get_context.py
|
|
31
|
+
- `.trellis/spec/<package>/<layer>/index.md` — entry point with **Pre-Development Checklist** + **Quality Check**. Actual guidelines live in the `.md` files it points to.
|
|
32
|
+
- `.trellis/spec/guides/index.md` — cross-package thinking guides.
|
|
49
33
|
|
|
50
|
-
|
|
51
|
-
python3 ./.trellis/scripts/
|
|
52
|
-
python3 ./.trellis/scripts/task.py list # Active tasks
|
|
53
|
-
git status && git log --oneline -10 # Git state
|
|
34
|
+
```bash
|
|
35
|
+
python3 ./.trellis/scripts/get_context.py --mode packages # list packages / layers
|
|
54
36
|
```
|
|
55
37
|
|
|
56
|
-
|
|
38
|
+
**When to update spec**: new pattern/convention found · bug-fix prevention to codify · new technical decision.
|
|
39
|
+
|
|
40
|
+
### Task System
|
|
57
41
|
|
|
58
|
-
|
|
42
|
+
Every task has its own directory under `.trellis/tasks/{MM-DD-name}/` holding `prd.md`, `implement.jsonl`, `check.jsonl`, `task.json`, optional `research/`, `info.md`.
|
|
59
43
|
|
|
60
44
|
```bash
|
|
61
|
-
#
|
|
62
|
-
python3 ./.trellis/scripts/
|
|
45
|
+
# Task lifecycle
|
|
46
|
+
python3 ./.trellis/scripts/task.py create "<title>" [--slug <name>] [--parent <dir>]
|
|
47
|
+
python3 ./.trellis/scripts/task.py start <name> # set as current (writes .current-task, triggers after_start hooks)
|
|
48
|
+
python3 ./.trellis/scripts/task.py finish # clear current task (triggers after_finish hooks)
|
|
49
|
+
python3 ./.trellis/scripts/task.py archive <name> # move to archive/{year-month}/
|
|
50
|
+
python3 ./.trellis/scripts/task.py list [--mine] [--status <s>]
|
|
51
|
+
python3 ./.trellis/scripts/task.py list-archive
|
|
52
|
+
|
|
53
|
+
# Code-spec context (injected into implement/check agents via JSONL)
|
|
54
|
+
python3 ./.trellis/scripts/task.py init-context <name> <type> # type: backend|frontend|fullstack|test|docs
|
|
55
|
+
python3 ./.trellis/scripts/task.py add-context <name> <action> <file> <reason>
|
|
56
|
+
python3 ./.trellis/scripts/task.py list-context <name> [action]
|
|
57
|
+
python3 ./.trellis/scripts/task.py validate <name>
|
|
58
|
+
|
|
59
|
+
# Task metadata
|
|
60
|
+
python3 ./.trellis/scripts/task.py set-branch <name> <branch>
|
|
61
|
+
python3 ./.trellis/scripts/task.py set-base-branch <name> <branch> # PR target
|
|
62
|
+
python3 ./.trellis/scripts/task.py set-scope <name> <scope>
|
|
63
|
+
|
|
64
|
+
# Hierarchy (parent/child)
|
|
65
|
+
python3 ./.trellis/scripts/task.py add-subtask <parent> <child>
|
|
66
|
+
python3 ./.trellis/scripts/task.py remove-subtask <parent> <child>
|
|
67
|
+
|
|
68
|
+
# PR creation
|
|
69
|
+
python3 ./.trellis/scripts/task.py create-pr [name] [--dry-run]
|
|
70
|
+
```
|
|
63
71
|
|
|
64
|
-
|
|
65
|
-
cat .trellis/spec/<package>/<layer>/index.md
|
|
72
|
+
> Run `python3 ./.trellis/scripts/task.py --help` to see the authoritative, up-to-date list.
|
|
66
73
|
|
|
67
|
-
|
|
68
|
-
cat .trellis/spec/guides/index.md
|
|
69
|
-
```
|
|
74
|
+
**Current-task mechanism**: `task.py start` writes the task path into `.trellis/.current-task`. Hook-capable platforms auto-inject this at session start, so the AI knows what you're working on without being told.
|
|
70
75
|
|
|
71
|
-
|
|
72
|
-
- Understand which spec layers apply to your task
|
|
73
|
-
- Know coding standards for the packages you'll modify
|
|
74
|
-
- Learn the overall code quality requirements
|
|
76
|
+
### Workspace System
|
|
75
77
|
|
|
76
|
-
|
|
78
|
+
Records every AI session for cross-session tracking under `.trellis/workspace/<developer>/`.
|
|
77
79
|
|
|
78
|
-
|
|
80
|
+
- `journal-N.md` — session log. **Max 2000 lines per file**; a new `journal-(N+1).md` is auto-created when exceeded.
|
|
81
|
+
- `index.md` — personal index (total sessions, last active).
|
|
79
82
|
|
|
80
83
|
```bash
|
|
81
|
-
|
|
82
|
-
cat .trellis/spec/<package>/<layer>/error-handling.md
|
|
83
|
-
cat .trellis/spec/<package>/<layer>/conventions.md
|
|
84
|
-
# etc. — based on what the Pre-Development Checklist lists
|
|
84
|
+
python3 ./.trellis/scripts/add_session.py --title "Title" --commit "hash" --summary "Summary"
|
|
85
85
|
```
|
|
86
86
|
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
## Workflow Overview
|
|
87
|
+
### Context Script
|
|
90
88
|
|
|
91
|
-
|
|
89
|
+
```bash
|
|
90
|
+
python3 ./.trellis/scripts/get_context.py # full session context
|
|
91
|
+
python3 ./.trellis/scripts/get_context.py --mode packages # available packages + spec layers
|
|
92
|
+
python3 ./.trellis/scripts/get_context.py --mode phase --step <X.Y> # detailed guide for a workflow step
|
|
93
|
+
```
|
|
92
94
|
|
|
93
|
-
|
|
94
|
-
2. **Follow Standards** - [!] **MUST read `.trellis/spec/` guidelines before coding**
|
|
95
|
-
3. **Incremental Development** - Complete one task at a time
|
|
96
|
-
4. **Record Promptly** - Update tracking files immediately after completion
|
|
97
|
-
5. **Document Limits** - [!] **Max 2000 lines per journal document**
|
|
95
|
+
---
|
|
98
96
|
|
|
99
|
-
|
|
97
|
+
## Phase Index
|
|
100
98
|
|
|
101
99
|
```
|
|
102
|
-
.
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
| |-- __init__.py # Python package init
|
|
106
|
-
| |-- common/ # Shared utilities (Python)
|
|
107
|
-
| | |-- __init__.py
|
|
108
|
-
| | |-- paths.py # Path utilities
|
|
109
|
-
| | |-- developer.py # Developer management
|
|
110
|
-
| | +-- git_context.py # Git context implementation
|
|
111
|
-
| |-- multi_agent/ # Multi-agent pipeline scripts
|
|
112
|
-
| | |-- __init__.py
|
|
113
|
-
| | |-- start.py # Start worktree agent
|
|
114
|
-
| | |-- status.py # Monitor agent status
|
|
115
|
-
| | |-- create_pr.py # Create PR
|
|
116
|
-
| | +-- cleanup.py # Cleanup worktree
|
|
117
|
-
| |-- init_developer.py # Initialize developer identity
|
|
118
|
-
| |-- get_developer.py # Get current developer name
|
|
119
|
-
| |-- task.py # Manage tasks
|
|
120
|
-
| |-- get_context.py # Get session context
|
|
121
|
-
| +-- add_session.py # One-click session recording
|
|
122
|
-
|-- workspace/ # Developer workspaces
|
|
123
|
-
| |-- index.md # Workspace index + Session template
|
|
124
|
-
| +-- {developer}/ # Per-developer directories
|
|
125
|
-
| |-- index.md # Personal index (with @@@auto markers)
|
|
126
|
-
| +-- journal-N.md # Journal files (sequential numbering)
|
|
127
|
-
|-- tasks/ # Task tracking
|
|
128
|
-
| +-- {MM}-{DD}-{name}/
|
|
129
|
-
| +-- task.json
|
|
130
|
-
|-- spec/ # [!] MUST READ before coding
|
|
131
|
-
| |-- frontend/ # Frontend guidelines (if applicable)
|
|
132
|
-
| | |-- index.md # Start here - guidelines index
|
|
133
|
-
| | +-- *.md # Topic-specific docs
|
|
134
|
-
| |-- backend/ # Backend guidelines (if applicable)
|
|
135
|
-
| | |-- index.md # Start here - guidelines index
|
|
136
|
-
| | +-- *.md # Topic-specific docs
|
|
137
|
-
| +-- guides/ # Thinking guides
|
|
138
|
-
| |-- index.md # Guides index
|
|
139
|
-
| |-- cross-layer-thinking-guide.md # Pre-implementation checklist
|
|
140
|
-
| +-- *.md # Other guides
|
|
141
|
-
+-- workflow.md # This document
|
|
100
|
+
Phase 1: Plan → figure out what to do (brainstorm + research → prd.md)
|
|
101
|
+
Phase 2: Execute → write code and pass quality checks
|
|
102
|
+
Phase 3: Finish → distill lessons + wrap-up
|
|
142
103
|
```
|
|
143
104
|
|
|
144
|
-
|
|
105
|
+
### Phase 1: Plan
|
|
106
|
+
- 1.0 Create task `[required · once]`
|
|
107
|
+
- 1.1 Requirement exploration `[required · repeatable]`
|
|
108
|
+
- 1.2 Research `[optional · repeatable]`
|
|
109
|
+
- 1.3 Configure context `[required · once]` — Claude Code, Cursor, OpenCode, Codex, Kiro, Gemini, Qoder, CodeBuddy, Copilot, Droid
|
|
110
|
+
- 1.4 Completion criteria
|
|
145
111
|
|
|
146
|
-
|
|
112
|
+
### Phase 2: Execute
|
|
113
|
+
- 2.1 Implement `[required · repeatable]`
|
|
114
|
+
- 2.2 Quality check `[required · repeatable]`
|
|
115
|
+
- 2.3 Rollback `[on demand]`
|
|
147
116
|
|
|
148
|
-
###
|
|
117
|
+
### Phase 3: Finish
|
|
118
|
+
- 3.1 Quality verification `[required · repeatable]`
|
|
119
|
+
- 3.2 Debug retrospective `[on demand]`
|
|
120
|
+
- 3.3 Spec update `[required · once]`
|
|
121
|
+
- 3.4 Wrap-up reminder
|
|
149
122
|
|
|
150
|
-
|
|
123
|
+
### Rules
|
|
151
124
|
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
125
|
+
1. Identify which Phase you're in, then continue from the next step there
|
|
126
|
+
2. Run steps in order inside each Phase; `[required]` steps can't be skipped
|
|
127
|
+
3. Phases can roll back (e.g., Execute reveals a prd defect → return to Plan to fix, then re-enter Execute)
|
|
128
|
+
4. Steps tagged `[once]` are skipped if already done; don't re-run
|
|
155
129
|
|
|
156
|
-
|
|
157
|
-
python3 ./.trellis/scripts/get_context.py --json
|
|
158
|
-
```
|
|
130
|
+
### Skill Routing
|
|
159
131
|
|
|
160
|
-
|
|
132
|
+
When a user request matches one of these intents, load the corresponding skill first — do not skip skills.
|
|
161
133
|
|
|
162
|
-
|
|
134
|
+
| User intent | Skill |
|
|
135
|
+
|---|---|
|
|
136
|
+
| Wants a new feature / requirement unclear | trellis-brainstorm |
|
|
137
|
+
| About to write code / start implementing | trellis-before-dev |
|
|
138
|
+
| Finished writing / want to verify | trellis-check |
|
|
139
|
+
| Stuck / fixed same bug several times | trellis-break-loop |
|
|
140
|
+
| Spec needs update | trellis-update-spec |
|
|
163
141
|
|
|
164
|
-
|
|
142
|
+
### DO NOT skip skills
|
|
165
143
|
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
144
|
+
| What you're thinking | Why it's wrong |
|
|
145
|
+
|---|---|
|
|
146
|
+
| "This is simple, just code it" | Simple tasks often grow complex; before-dev takes under a minute |
|
|
147
|
+
| "I already thought it through in plan mode" | Plan-mode output lives in memory — sub-agents can't see it; must be persisted to prd.md |
|
|
148
|
+
| "I already know the spec" | The spec may have been updated since you last read it; read again |
|
|
149
|
+
| "Code first, check later" | `check` surfaces issues you won't notice yourself; earlier is cheaper |
|
|
150
|
+
|
|
151
|
+
### Loading Step Detail
|
|
169
152
|
|
|
170
|
-
|
|
171
|
-
cat .trellis/spec/<package>/<layer>/index.md
|
|
153
|
+
At each step, run this to fetch detailed guidance:
|
|
172
154
|
|
|
173
|
-
|
|
174
|
-
|
|
155
|
+
```bash
|
|
156
|
+
python3 ./.trellis/scripts/get_context.py --mode phase --step <step>
|
|
157
|
+
# e.g. python3 ./.trellis/scripts/get_context.py --mode phase --step 1.1
|
|
175
158
|
```
|
|
176
159
|
|
|
177
|
-
|
|
160
|
+
---
|
|
161
|
+
|
|
162
|
+
## Phase 1: Plan
|
|
178
163
|
|
|
179
|
-
|
|
164
|
+
Goal: figure out what to build, produce a clear requirements doc and the context needed to implement it.
|
|
180
165
|
|
|
181
|
-
|
|
182
|
-
# List active tasks
|
|
183
|
-
python3 ./.trellis/scripts/task.py list
|
|
166
|
+
#### 1.0 Create task `[required · once]`
|
|
184
167
|
|
|
185
|
-
|
|
186
|
-
|
|
168
|
+
Create the task directory and set it as current:
|
|
169
|
+
|
|
170
|
+
```bash
|
|
171
|
+
python3 ./.trellis/scripts/task.py create "<task title>" --slug <name>
|
|
172
|
+
python3 ./.trellis/scripts/task.py start <task-dir>
|
|
187
173
|
```
|
|
188
174
|
|
|
189
|
-
|
|
175
|
+
Skip when: `.trellis/.current-task` already points to a task.
|
|
190
176
|
|
|
191
|
-
|
|
177
|
+
#### 1.1 Requirement exploration `[required · repeatable]`
|
|
192
178
|
|
|
193
|
-
|
|
179
|
+
Load the `trellis-brainstorm` skill and explore requirements interactively with the user per the skill's guidance.
|
|
194
180
|
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
181
|
+
The brainstorm skill will guide you to:
|
|
182
|
+
- Ask one question at a time
|
|
183
|
+
- Prefer researching over asking the user
|
|
184
|
+
- Prefer offering options over open-ended questions
|
|
185
|
+
- Update `prd.md` immediately after each user answer
|
|
198
186
|
|
|
199
|
-
|
|
200
|
-
--> python3 ./.trellis/scripts/task.py start <name>
|
|
201
|
-
--> Writes .trellis/.current-task; future sessions see it in <current-state>
|
|
187
|
+
Return to this step whenever requirements change and revise `prd.md`.
|
|
202
188
|
|
|
203
|
-
|
|
204
|
-
--> Read .trellis/spec/ docs relevant to your task
|
|
205
|
-
--> For cross-layer: read .trellis/spec/guides/
|
|
189
|
+
#### 1.2 Research `[optional · repeatable]`
|
|
206
190
|
|
|
207
|
-
|
|
208
|
-
--> Run project's lint/test commands (see spec docs)
|
|
209
|
-
--> Manual feature testing
|
|
191
|
+
Research can happen at any time during requirement exploration. It isn't limited to local code — you can use any available tool (MCP servers, skills, web search, etc.) to look up external information, including third-party library docs, industry practices, API references, etc.
|
|
210
192
|
|
|
211
|
-
|
|
212
|
-
--> git add <files>
|
|
213
|
-
--> git commit -m "type(scope): description"
|
|
214
|
-
Format: feat/fix/docs/refactor/test/chore
|
|
193
|
+
[Claude Code, Cursor, OpenCode, Codex, Kiro, Gemini, Qoder, CodeBuddy, Copilot, Droid]
|
|
215
194
|
|
|
216
|
-
|
|
217
|
-
--> python3 ./.trellis/scripts/add_session.py --title "Title" --commit "hash"
|
|
195
|
+
Spawn the research sub-agent:
|
|
218
196
|
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
next session resumes where you left off
|
|
223
|
-
```
|
|
197
|
+
- **Agent type**: `research`
|
|
198
|
+
- **Task description**: Research <specific question>
|
|
199
|
+
- **Key requirement**: Research output MUST be persisted to `{TASK_DIR}/research/`
|
|
224
200
|
|
|
225
|
-
|
|
201
|
+
[/Claude Code, Cursor, OpenCode, Codex, Kiro, Gemini, Qoder, CodeBuddy, Copilot, Droid]
|
|
226
202
|
|
|
227
|
-
|
|
228
|
-
- [OK] Lint checks pass (project-specific command)
|
|
229
|
-
- [OK] Type checks pass (if applicable)
|
|
230
|
-
- [OK] Manual feature testing passes
|
|
203
|
+
[Kilo, Antigravity, Windsurf]
|
|
231
204
|
|
|
232
|
-
|
|
233
|
-
- See `.trellis/spec/<package>/<layer>/quality-guidelines.md` for package-specific checks
|
|
205
|
+
Do the research in the main session directly and write findings into `{TASK_DIR}/research/`.
|
|
234
206
|
|
|
235
|
-
|
|
207
|
+
[/Kilo, Antigravity, Windsurf]
|
|
208
|
+
|
|
209
|
+
**Research artifact conventions**:
|
|
210
|
+
- One file per research topic (e.g. `research/auth-library-comparison.md`)
|
|
211
|
+
- Record third-party library usage examples, API references, version constraints in files
|
|
212
|
+
- Note relevant spec file paths you discovered for later reference
|
|
213
|
+
|
|
214
|
+
Brainstorm and research can interleave freely — pause to research a technical question, then return to talk with the user.
|
|
236
215
|
|
|
237
|
-
|
|
216
|
+
**Key principle**: Research output must be written to files, not left only in the chat. Conversations get compacted; files don't.
|
|
238
217
|
|
|
239
|
-
|
|
218
|
+
#### 1.3 Configure context `[required · once]`
|
|
240
219
|
|
|
241
|
-
|
|
220
|
+
[Claude Code, Cursor, OpenCode, Codex, Kiro, Gemini, Qoder, CodeBuddy, Copilot, Droid]
|
|
221
|
+
|
|
222
|
+
Once research output is solid, initialize the agent context files:
|
|
242
223
|
|
|
243
224
|
```bash
|
|
244
|
-
python3 ./.trellis/scripts/
|
|
245
|
-
|
|
246
|
-
--commit "abc1234" \
|
|
247
|
-
--summary "Brief summary"
|
|
225
|
+
python3 ./.trellis/scripts/task.py init-context "$TASK_DIR" <type>
|
|
226
|
+
# type: backend | frontend | fullstack
|
|
248
227
|
```
|
|
249
228
|
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
3. Appends session content
|
|
254
|
-
4. Updates index.md (sessions count, history table)
|
|
229
|
+
Skip when: `implement.jsonl` already exists.
|
|
230
|
+
|
|
231
|
+
Append any extra spec files or code patterns you find `[optional · repeatable]`:
|
|
255
232
|
|
|
256
|
-
|
|
233
|
+
```bash
|
|
234
|
+
python3 ./.trellis/scripts/task.py add-context "$TASK_DIR" implement "<path>" "<reason>"
|
|
235
|
+
python3 ./.trellis/scripts/task.py add-context "$TASK_DIR" check "<path>" "<reason>"
|
|
236
|
+
```
|
|
257
237
|
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
238
|
+
These jsonl files are auto-injected into sub-agent prompts during Phase 2 via hook.
|
|
239
|
+
|
|
240
|
+
[/Claude Code, Cursor, OpenCode, Codex, Kiro, Gemini, Qoder, CodeBuddy, Copilot, Droid]
|
|
241
|
+
|
|
242
|
+
[Kilo, Antigravity, Windsurf]
|
|
243
|
+
|
|
244
|
+
Skip this step. Context is loaded directly by the `trellis-before-dev` skill in Phase 2.
|
|
245
|
+
|
|
246
|
+
[/Kilo, Antigravity, Windsurf]
|
|
247
|
+
|
|
248
|
+
#### 1.4 Completion criteria
|
|
249
|
+
|
|
250
|
+
| Condition | Required |
|
|
251
|
+
|------|:---:|
|
|
252
|
+
| `prd.md` exists | ✅ |
|
|
253
|
+
| User confirms requirements | ✅ |
|
|
254
|
+
| `research/` has artifacts (complex tasks) | recommended |
|
|
255
|
+
| `info.md` technical design (complex tasks) | optional |
|
|
256
|
+
|
|
257
|
+
[Claude Code, Cursor, OpenCode, Codex, Kiro, Gemini, Qoder, CodeBuddy, Copilot, Droid]
|
|
258
|
+
|
|
259
|
+
| `implement.jsonl` exists | ✅ |
|
|
260
|
+
|
|
261
|
+
[/Claude Code, Cursor, OpenCode, Codex, Kiro, Gemini, Qoder, CodeBuddy, Copilot, Droid]
|
|
264
262
|
|
|
265
263
|
---
|
|
266
264
|
|
|
267
|
-
##
|
|
265
|
+
## Phase 2: Execute
|
|
268
266
|
|
|
269
|
-
|
|
267
|
+
Goal: turn the prd into code that passes quality checks.
|
|
270
268
|
|
|
271
|
-
|
|
269
|
+
#### 2.1 Implement `[required · repeatable]`
|
|
272
270
|
|
|
273
|
-
|
|
274
|
-
```
|
|
275
|
-
workspace/
|
|
276
|
-
|-- index.md # Main index (Active Developers table)
|
|
277
|
-
+-- {developer}/ # Per-developer directory
|
|
278
|
-
|-- index.md # Personal index (with @@@auto markers)
|
|
279
|
-
+-- journal-N.md # Journal files (sequential: 1, 2, 3...)
|
|
280
|
-
```
|
|
271
|
+
[Claude Code, Cursor, OpenCode, Codex, Kiro, Gemini, Qoder, CodeBuddy, Copilot, Droid]
|
|
281
272
|
|
|
282
|
-
|
|
283
|
-
- [OK] End of each session
|
|
284
|
-
- [OK] Complete important task
|
|
285
|
-
- [OK] Fix important bug
|
|
273
|
+
Spawn the implement sub-agent:
|
|
286
274
|
|
|
287
|
-
|
|
275
|
+
- **Agent type**: `implement`
|
|
276
|
+
- **Task description**: Implement the requirements per prd.md, consulting materials under `{TASK_DIR}/research/`; finish by running project lint and type-check
|
|
288
277
|
|
|
289
|
-
|
|
278
|
+
The platform hook auto-handles:
|
|
279
|
+
- Reads `implement.jsonl` and injects the referenced spec files into the agent prompt
|
|
280
|
+
- Injects prd.md content
|
|
290
281
|
|
|
291
|
-
|
|
292
|
-
```
|
|
293
|
-
spec/
|
|
294
|
-
|-- frontend/ # Frontend docs (if applicable)
|
|
295
|
-
| |-- index.md # Start here
|
|
296
|
-
| +-- *.md # Topic-specific docs
|
|
297
|
-
|-- backend/ # Backend docs (if applicable)
|
|
298
|
-
| |-- index.md # Start here
|
|
299
|
-
| +-- *.md # Topic-specific docs
|
|
300
|
-
+-- guides/ # Thinking guides
|
|
301
|
-
|-- index.md # Start here
|
|
302
|
-
+-- *.md # Guide-specific docs
|
|
303
|
-
```
|
|
282
|
+
[/Claude Code, Cursor, OpenCode, Codex, Kiro, Gemini, Qoder, CodeBuddy, Copilot, Droid]
|
|
304
283
|
|
|
305
|
-
|
|
306
|
-
- [OK] New pattern discovered
|
|
307
|
-
- [OK] Bug fixed that reveals missing guidance
|
|
308
|
-
- [OK] New convention established
|
|
284
|
+
[Kilo, Antigravity, Windsurf]
|
|
309
285
|
|
|
310
|
-
|
|
286
|
+
1. Load the `trellis-before-dev` skill to read project guidelines
|
|
287
|
+
2. Read `{TASK_DIR}/prd.md` for requirements
|
|
288
|
+
3. Consult materials under `{TASK_DIR}/research/`
|
|
289
|
+
4. Implement the code per requirements
|
|
290
|
+
5. Run project lint and type-check
|
|
311
291
|
|
|
312
|
-
|
|
292
|
+
[/Kilo, Antigravity, Windsurf]
|
|
313
293
|
|
|
314
|
-
|
|
315
|
-
tasks/
|
|
316
|
-
|-- 01-21-my-task/
|
|
317
|
-
| +-- task.json
|
|
318
|
-
+-- archive/
|
|
319
|
-
+-- 2026-01/
|
|
320
|
-
+-- 01-15-old-task/
|
|
321
|
-
+-- task.json
|
|
322
|
-
```
|
|
294
|
+
#### 2.2 Quality check `[required · repeatable]`
|
|
323
295
|
|
|
324
|
-
|
|
325
|
-
```bash
|
|
326
|
-
python3 ./.trellis/scripts/task.py create "<title>" [--slug <name>] # Create task directory
|
|
327
|
-
python3 ./.trellis/scripts/task.py start <name> # Set as current task (writes .current-task, triggers after_start hooks)
|
|
328
|
-
python3 ./.trellis/scripts/task.py finish # Clear current task (triggers after_finish hooks)
|
|
329
|
-
python3 ./.trellis/scripts/task.py archive <name> # Archive to archive/{year-month}/
|
|
330
|
-
python3 ./.trellis/scripts/task.py list # List active tasks
|
|
331
|
-
python3 ./.trellis/scripts/task.py list-archive # List archived tasks
|
|
332
|
-
```
|
|
296
|
+
[Claude Code, Cursor, OpenCode, Codex, Kiro, Gemini, Qoder, CodeBuddy, Copilot, Droid]
|
|
333
297
|
|
|
334
|
-
|
|
298
|
+
Spawn the check sub-agent:
|
|
335
299
|
|
|
336
|
-
|
|
300
|
+
- **Agent type**: `check`
|
|
301
|
+
- **Task description**: Review all code changes against spec and prd; fix any findings directly; ensure lint and type-check pass
|
|
337
302
|
|
|
338
|
-
|
|
303
|
+
The check agent's job:
|
|
304
|
+
- Review code changes against specs
|
|
305
|
+
- Auto-fix issues it finds
|
|
306
|
+
- Run lint and typecheck to verify
|
|
339
307
|
|
|
340
|
-
|
|
308
|
+
[/Claude Code, Cursor, OpenCode, Codex, Kiro, Gemini, Qoder, CodeBuddy, Copilot, Droid]
|
|
341
309
|
|
|
342
|
-
|
|
343
|
-
- Run `python3 ./.trellis/scripts/get_context.py` for full context
|
|
344
|
-
- [!] **MUST read** relevant `.trellis/spec/` docs
|
|
310
|
+
[Kilo, Antigravity, Windsurf]
|
|
345
311
|
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
- Run lint and tests frequently
|
|
312
|
+
Load the `trellis-check` skill and verify the code per its guidance:
|
|
313
|
+
- Spec compliance
|
|
314
|
+
- lint / type-check / tests
|
|
315
|
+
- Cross-layer consistency (when changes span layers)
|
|
351
316
|
|
|
352
|
-
|
|
353
|
-
- Use `/trellis:finish-work` for completion checklist
|
|
354
|
-
- After fix bug, use `/trellis:break-loop` for deep analysis
|
|
355
|
-
- Human commits after testing passes
|
|
356
|
-
- Use `add_session.py` to record progress
|
|
317
|
+
If issues are found → fix → re-check, until green.
|
|
357
318
|
|
|
358
|
-
|
|
319
|
+
[/Kilo, Antigravity, Windsurf]
|
|
359
320
|
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
6. [!] **Don't** execute `git commit` - AI should not commit code
|
|
321
|
+
#### 2.3 Rollback `[on demand]`
|
|
322
|
+
|
|
323
|
+
- `check` reveals a prd defect → return to Phase 1, fix `prd.md`, then redo 2.1
|
|
324
|
+
- Implementation went wrong → revert code, redo 2.1
|
|
325
|
+
- Need more research → research (same as Phase 1.2), write findings into `research/`
|
|
366
326
|
|
|
367
327
|
---
|
|
368
328
|
|
|
369
|
-
##
|
|
329
|
+
## Phase 3: Finish
|
|
370
330
|
|
|
371
|
-
|
|
331
|
+
Goal: ensure code quality, capture lessons, record the work.
|
|
372
332
|
|
|
373
|
-
|
|
374
|
-
|-----------|-------------------|
|
|
375
|
-
| Frontend work | `frontend/index.md` → relevant docs |
|
|
376
|
-
| Backend work | `backend/index.md` → relevant docs |
|
|
377
|
-
| Cross-Layer Feature | `guides/cross-layer-thinking-guide.md` |
|
|
333
|
+
#### 3.1 Quality verification `[required · repeatable]`
|
|
378
334
|
|
|
379
|
-
|
|
335
|
+
Load the `trellis-check` skill and do a final verification:
|
|
336
|
+
- Spec compliance
|
|
337
|
+
- lint / type-check / tests
|
|
338
|
+
- Cross-layer consistency (when changes span layers)
|
|
380
339
|
|
|
381
|
-
|
|
382
|
-
git commit -m "type(scope): description"
|
|
383
|
-
```
|
|
340
|
+
If issues are found → fix → re-check, until green.
|
|
384
341
|
|
|
385
|
-
|
|
386
|
-
**Scope**: Module name (e.g., auth, api, ui)
|
|
342
|
+
#### 3.2 Debug retrospective `[on demand]`
|
|
387
343
|
|
|
388
|
-
|
|
344
|
+
If this task involved repeated debugging (the same issue was fixed multiple times), load the `trellis-break-loop` skill to:
|
|
345
|
+
- Classify the root cause
|
|
346
|
+
- Explain why earlier fixes failed
|
|
347
|
+
- Propose prevention
|
|
389
348
|
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
349
|
+
The goal is to capture debugging lessons so the same class of issue doesn't recur.
|
|
350
|
+
|
|
351
|
+
#### 3.3 Spec update `[required · once]`
|
|
352
|
+
|
|
353
|
+
Load the `trellis-update-spec` skill and review whether this task produced new knowledge worth recording:
|
|
354
|
+
- Newly discovered patterns or conventions
|
|
355
|
+
- Pitfalls you hit
|
|
356
|
+
- New technical decisions
|
|
357
|
+
|
|
358
|
+
Update the docs under `.trellis/spec/` accordingly. Even if the conclusion is "nothing to update", walk through the judgment.
|
|
359
|
+
|
|
360
|
+
#### 3.4 Wrap-up reminder
|
|
361
|
+
|
|
362
|
+
After the above, remind the user they can run `/finish-work` to wrap up (archive the task, record the session).
|
|
404
363
|
|
|
405
364
|
---
|
|
406
365
|
|
|
407
|
-
##
|
|
366
|
+
## Workflow State Breadcrumbs
|
|
367
|
+
|
|
368
|
+
<!-- Injected per-turn by UserPromptSubmit hook (inject-workflow-state.py).
|
|
369
|
+
Edit the text inside each [workflow-state:STATUS]...[/workflow-state:STATUS]
|
|
370
|
+
block to customize per-task-status flow reminders. Users who fork the
|
|
371
|
+
Trellis workflow only need to edit this file, not the hook script.
|
|
372
|
+
|
|
373
|
+
Tag STATUS matches task.json.status. Default statuses: planning /
|
|
374
|
+
in_progress / completed. Add custom status blocks as needed (hyphens
|
|
375
|
+
and underscores allowed). Hook falls back to built-in defaults when
|
|
376
|
+
a status has no tag block. -->
|
|
377
|
+
|
|
378
|
+
[workflow-state:no_task]
|
|
379
|
+
No active task. If the user describes multi-step work, load trellis-brainstorm skill to clarify requirements and create a task via `python3 ./.trellis/scripts/task.py create`. Simple one-off questions or trivial edits don't need a task — just answer directly.
|
|
380
|
+
[/workflow-state:no_task]
|
|
381
|
+
|
|
382
|
+
[workflow-state:planning]
|
|
383
|
+
Complete prd.md via trellis-brainstorm skill; then run task.py start.
|
|
384
|
+
[/workflow-state:planning]
|
|
408
385
|
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
-
|
|
413
|
-
- [OK] Knowledge accumulation in spec docs
|
|
414
|
-
- [OK] Transparent team collaboration
|
|
386
|
+
[workflow-state:in_progress]
|
|
387
|
+
Flow: implement → check → update-spec → finish
|
|
388
|
+
Check conversation history + git status to determine current step; do NOT skip check.
|
|
389
|
+
[/workflow-state:in_progress]
|
|
415
390
|
|
|
416
|
-
|
|
391
|
+
[workflow-state:completed]
|
|
392
|
+
User commits changes; then run task.py archive.
|
|
393
|
+
[/workflow-state:completed]
|