@pennixrv/trellis 0.7.1 → 0.7.2-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/README.md +10 -7
- package/dist/cli/index.d.ts.map +1 -1
- package/dist/cli/index.js +6 -4
- package/dist/cli/index.js.map +1 -1
- package/dist/commands/ablate.d.ts.map +1 -1
- package/dist/commands/ablate.js +2 -0
- package/dist/commands/ablate.js.map +1 -1
- package/dist/commands/backup.d.ts +4 -0
- package/dist/commands/backup.d.ts.map +1 -0
- package/dist/commands/backup.js +75 -0
- package/dist/commands/backup.js.map +1 -0
- package/dist/commands/init.d.ts.map +1 -1
- package/dist/commands/init.js +705 -681
- package/dist/commands/init.js.map +1 -1
- package/dist/commands/mem.d.ts.map +1 -1
- package/dist/commands/mem.js +49 -7
- package/dist/commands/mem.js.map +1 -1
- package/dist/commands/task-progress.d.ts +1 -0
- package/dist/commands/task-progress.d.ts.map +1 -1
- package/dist/commands/task-progress.js +67 -25
- package/dist/commands/task-progress.js.map +1 -1
- package/dist/commands/teamwork/adapters/acp.d.ts +20 -0
- package/dist/commands/teamwork/adapters/acp.d.ts.map +1 -0
- package/dist/commands/teamwork/adapters/acp.js +268 -0
- package/dist/commands/teamwork/adapters/acp.js.map +1 -0
- package/dist/commands/teamwork/adapters/claude.d.ts +1 -0
- package/dist/commands/teamwork/adapters/claude.d.ts.map +1 -1
- package/dist/commands/teamwork/adapters/claude.js +5 -0
- package/dist/commands/teamwork/adapters/claude.js.map +1 -1
- package/dist/commands/teamwork/adapters/codex.d.ts +3 -2
- package/dist/commands/teamwork/adapters/codex.d.ts.map +1 -1
- package/dist/commands/teamwork/adapters/codex.js +14 -15
- package/dist/commands/teamwork/adapters/codex.js.map +1 -1
- package/dist/commands/teamwork/adapters/index.d.ts +23 -1
- package/dist/commands/teamwork/adapters/index.d.ts.map +1 -1
- package/dist/commands/teamwork/adapters/index.js +163 -24
- package/dist/commands/teamwork/adapters/index.js.map +1 -1
- package/dist/commands/teamwork/agent-loader.d.ts +2 -1
- package/dist/commands/teamwork/agent-loader.d.ts.map +1 -1
- package/dist/commands/teamwork/agent-loader.js +2 -1
- package/dist/commands/teamwork/agent-loader.js.map +1 -1
- package/dist/commands/teamwork/artifact.d.ts +42 -14
- package/dist/commands/teamwork/artifact.d.ts.map +1 -1
- package/dist/commands/teamwork/artifact.js +188 -85
- package/dist/commands/teamwork/artifact.js.map +1 -1
- package/dist/commands/teamwork/batch-reservation.d.ts +16 -0
- package/dist/commands/teamwork/batch-reservation.d.ts.map +1 -0
- package/dist/commands/teamwork/batch-reservation.js +43 -0
- package/dist/commands/teamwork/batch-reservation.js.map +1 -0
- package/dist/commands/teamwork/batch.d.ts +23 -0
- package/dist/commands/teamwork/batch.d.ts.map +1 -0
- package/dist/commands/teamwork/batch.js +415 -0
- package/dist/commands/teamwork/batch.js.map +1 -0
- package/dist/commands/teamwork/context-loader.d.ts +1 -1
- package/dist/commands/teamwork/context-loader.d.ts.map +1 -1
- package/dist/commands/teamwork/context-loader.js +19 -6
- package/dist/commands/teamwork/context-loader.js.map +1 -1
- package/dist/commands/teamwork/coordination.d.ts +88 -0
- package/dist/commands/teamwork/coordination.d.ts.map +1 -0
- package/dist/commands/teamwork/coordination.js +153 -0
- package/dist/commands/teamwork/coordination.js.map +1 -0
- package/dist/commands/teamwork/coordinator.d.ts +33 -6
- package/dist/commands/teamwork/coordinator.d.ts.map +1 -1
- package/dist/commands/teamwork/coordinator.js +948 -342
- package/dist/commands/teamwork/coordinator.js.map +1 -1
- package/dist/commands/teamwork/create.d.ts +1 -0
- package/dist/commands/teamwork/create.d.ts.map +1 -1
- package/dist/commands/teamwork/create.js +2 -1
- package/dist/commands/teamwork/create.js.map +1 -1
- package/dist/commands/teamwork/dev-parse-trace.d.ts +2 -1
- package/dist/commands/teamwork/dev-parse-trace.d.ts.map +1 -1
- package/dist/commands/teamwork/dev-parse-trace.js +2 -0
- package/dist/commands/teamwork/dev-parse-trace.js.map +1 -1
- package/dist/commands/teamwork/foreground-wait.d.ts +6 -0
- package/dist/commands/teamwork/foreground-wait.d.ts.map +1 -0
- package/dist/commands/teamwork/foreground-wait.js +65 -0
- package/dist/commands/teamwork/foreground-wait.js.map +1 -0
- package/dist/commands/teamwork/guard.d.ts +2 -2
- package/dist/commands/teamwork/guard.d.ts.map +1 -1
- package/dist/commands/teamwork/guard.js +25 -7
- package/dist/commands/teamwork/guard.js.map +1 -1
- package/dist/commands/teamwork/index.d.ts.map +1 -1
- package/dist/commands/teamwork/index.js +163 -10
- package/dist/commands/teamwork/index.js.map +1 -1
- package/dist/commands/teamwork/kill.d.ts +2 -0
- package/dist/commands/teamwork/kill.d.ts.map +1 -1
- package/dist/commands/teamwork/kill.js +79 -38
- package/dist/commands/teamwork/kill.js.map +1 -1
- package/dist/commands/teamwork/messages.d.ts.map +1 -1
- package/dist/commands/teamwork/messages.js +3 -0
- package/dist/commands/teamwork/messages.js.map +1 -1
- package/dist/commands/teamwork/plan.d.ts +22 -0
- package/dist/commands/teamwork/plan.d.ts.map +1 -0
- package/dist/commands/teamwork/plan.js +288 -0
- package/dist/commands/teamwork/plan.js.map +1 -0
- package/dist/commands/teamwork/process-identity.d.ts +3 -0
- package/dist/commands/teamwork/process-identity.d.ts.map +1 -0
- package/dist/commands/teamwork/process-identity.js +24 -0
- package/dist/commands/teamwork/process-identity.js.map +1 -0
- package/dist/commands/teamwork/profiles.d.ts +43 -6
- package/dist/commands/teamwork/profiles.d.ts.map +1 -1
- package/dist/commands/teamwork/profiles.js +138 -110
- package/dist/commands/teamwork/profiles.js.map +1 -1
- package/dist/commands/teamwork/prompt.d.ts +4 -0
- package/dist/commands/teamwork/prompt.d.ts.map +1 -0
- package/dist/commands/teamwork/prompt.js +33 -0
- package/dist/commands/teamwork/prompt.js.map +1 -0
- package/dist/commands/teamwork/result.d.ts +55 -0
- package/dist/commands/teamwork/result.d.ts.map +1 -0
- package/dist/commands/teamwork/result.js +94 -0
- package/dist/commands/teamwork/result.js.map +1 -0
- package/dist/commands/teamwork/rm.d.ts.map +1 -1
- package/dist/commands/teamwork/rm.js +64 -64
- package/dist/commands/teamwork/rm.js.map +1 -1
- package/dist/commands/teamwork/run.d.ts +5 -0
- package/dist/commands/teamwork/run.d.ts.map +1 -1
- package/dist/commands/teamwork/run.js +120 -24
- package/dist/commands/teamwork/run.js.map +1 -1
- package/dist/commands/teamwork/runtime.d.ts +9 -0
- package/dist/commands/teamwork/runtime.d.ts.map +1 -0
- package/dist/commands/teamwork/runtime.js +401 -0
- package/dist/commands/teamwork/runtime.js.map +1 -0
- package/dist/commands/teamwork/send.d.ts +1 -0
- package/dist/commands/teamwork/send.d.ts.map +1 -1
- package/dist/commands/teamwork/send.js +2 -1
- package/dist/commands/teamwork/send.js.map +1 -1
- package/dist/commands/teamwork/spawn.d.ts +10 -3
- package/dist/commands/teamwork/spawn.d.ts.map +1 -1
- package/dist/commands/teamwork/spawn.js +42 -27
- package/dist/commands/teamwork/spawn.js.map +1 -1
- package/dist/commands/teamwork/store/lock.js +28 -4
- package/dist/commands/teamwork/store/lock.js.map +1 -1
- package/dist/commands/teamwork/supervisor/inbox.d.ts +1 -0
- package/dist/commands/teamwork/supervisor/inbox.d.ts.map +1 -1
- package/dist/commands/teamwork/supervisor/inbox.js +28 -9
- package/dist/commands/teamwork/supervisor/inbox.js.map +1 -1
- package/dist/commands/teamwork/supervisor/stdout.d.ts.map +1 -1
- package/dist/commands/teamwork/supervisor/stdout.js +2 -3
- package/dist/commands/teamwork/supervisor/stdout.js.map +1 -1
- package/dist/commands/teamwork/supervisor/warning.d.ts.map +1 -1
- package/dist/commands/teamwork/supervisor/warning.js +2 -3
- package/dist/commands/teamwork/supervisor/warning.js.map +1 -1
- package/dist/commands/teamwork/supervisor.d.ts +5 -0
- package/dist/commands/teamwork/supervisor.d.ts.map +1 -1
- package/dist/commands/teamwork/supervisor.js +21 -12
- package/dist/commands/teamwork/supervisor.js.map +1 -1
- package/dist/commands/teamwork/teammate-adapters.d.ts +0 -5
- package/dist/commands/teamwork/teammate-adapters.d.ts.map +1 -1
- package/dist/commands/teamwork/teammate-adapters.js +9 -56
- package/dist/commands/teamwork/teammate-adapters.js.map +1 -1
- package/dist/commands/teamwork/teammate-config.d.ts +5 -1
- package/dist/commands/teamwork/teammate-config.d.ts.map +1 -1
- package/dist/commands/teamwork/teammate-config.js +62 -19
- package/dist/commands/teamwork/teammate-config.js.map +1 -1
- package/dist/commands/teamwork/teammate-launch.d.ts +15 -6
- package/dist/commands/teamwork/teammate-launch.d.ts.map +1 -1
- package/dist/commands/teamwork/teammate-launch.js +129 -22
- package/dist/commands/teamwork/teammate-launch.js.map +1 -1
- package/dist/commands/teamwork/wait.d.ts +2 -0
- package/dist/commands/teamwork/wait.d.ts.map +1 -1
- package/dist/commands/teamwork/wait.js +44 -3
- package/dist/commands/teamwork/wait.js.map +1 -1
- package/dist/commands/uninstall.d.ts.map +1 -1
- package/dist/commands/uninstall.js +92 -84
- package/dist/commands/uninstall.js.map +1 -1
- package/dist/commands/update.d.ts.map +1 -1
- package/dist/commands/update.js +635 -592
- package/dist/commands/update.js.map +1 -1
- package/dist/commands/workflow.d.ts.map +1 -1
- package/dist/commands/workflow.js +94 -89
- package/dist/commands/workflow.js.map +1 -1
- package/dist/configurators/shared.js +2 -2
- package/dist/configurators/shared.js.map +1 -1
- package/dist/configurators/workflow.d.ts.map +1 -1
- package/dist/configurators/workflow.js +14 -32
- package/dist/configurators/workflow.js.map +1 -1
- package/dist/constants/paths.d.ts +3 -10
- package/dist/constants/paths.d.ts.map +1 -1
- package/dist/constants/paths.js +4 -13
- package/dist/constants/paths.js.map +1 -1
- package/dist/migrations/manifests/0.7.1-beta.0.json +9 -0
- package/dist/migrations/manifests/0.7.1-beta.1.json +186 -0
- package/dist/migrations/manifests/0.7.1-beta.10.json +9 -0
- package/dist/migrations/manifests/0.7.1-beta.11.json +9 -0
- package/dist/migrations/manifests/0.7.1-beta.12.json +9 -0
- package/dist/migrations/manifests/0.7.1-beta.13.json +9 -0
- package/dist/migrations/manifests/0.7.1-beta.14.json +11 -0
- package/dist/migrations/manifests/0.7.1-beta.15.json +9 -0
- package/dist/migrations/manifests/0.7.1-beta.16.json +9 -0
- package/dist/migrations/manifests/0.7.1-beta.17.json +9 -0
- package/dist/migrations/manifests/0.7.1-beta.18.json +9 -0
- package/dist/migrations/manifests/0.7.1-beta.19.json +9 -0
- package/dist/migrations/manifests/0.7.1-beta.2.json +522 -0
- package/dist/migrations/manifests/0.7.1-beta.3.json +9 -0
- package/dist/migrations/manifests/0.7.1-beta.4.json +9 -0
- package/dist/migrations/manifests/0.7.1-beta.5.json +9 -0
- package/dist/migrations/manifests/0.7.1-beta.6.json +10 -0
- package/dist/migrations/manifests/0.7.1-beta.7.json +8 -0
- package/dist/migrations/manifests/0.7.1-beta.8.json +481 -0
- package/dist/migrations/manifests/0.7.1-beta.9.json +191 -0
- package/dist/migrations/manifests/0.7.2-beta.0.json +11 -0
- package/dist/migrations/manifests/0.7.2-beta.1.json +11 -0
- package/dist/migrations/manifests/0.7.2-beta.2.json +11 -0
- package/dist/templates/claude/hooks/statusline.py +9 -4
- package/dist/templates/codex/hooks/session-start.py +14 -11
- package/dist/templates/codex/hooks.json +10 -0
- package/dist/templates/common/bundled-skills/trellis-decision-space-construction-and-merging/workflow.md +2 -0
- package/dist/templates/common/bundled-skills/trellis-goal-exploration-and-requirements/workflow.md +2 -0
- package/dist/templates/common/bundled-skills/trellis-meta/SKILL.md +1 -1
- package/dist/templates/common/bundled-skills/trellis-meta/references/customize-local/add-project-local-conventions.md +1 -1
- package/dist/templates/common/bundled-skills/trellis-meta/references/customize-local/change-context-loading.md +5 -5
- package/dist/templates/common/bundled-skills/trellis-meta/references/customize-local/change-task-lifecycle.md +3 -2
- package/dist/templates/common/bundled-skills/trellis-meta/references/customize-local/overview.md +1 -1
- package/dist/templates/common/bundled-skills/trellis-meta/references/local-architecture/context-injection.md +1 -1
- package/dist/templates/common/bundled-skills/trellis-meta/references/local-architecture/multi-agent-teamwork.md +14 -2
- package/dist/templates/common/bundled-skills/trellis-meta/references/local-architecture/task-system.md +8 -2
- package/dist/templates/common/bundled-skills/trellis-session-insight/references/cli-quick-reference.md +2 -1
- package/dist/templates/common/bundled-skills/trellis-session-insight/references/triggering-patterns.md +2 -2
- package/dist/templates/common/bundled-skills/trellis-solution-design-and-convergence/workflow.md +8 -0
- package/dist/templates/common/bundled-skills/trellis-spec-bootstrap/references/mcp-setup.md +4 -2
- package/dist/templates/common/bundled-skills/trellis-spec-bootstrap/references/spec-task-planning.md +2 -2
- package/dist/templates/common/bundled-skills/trellis-task-implementation/workflow.md +6 -0
- package/dist/templates/common/bundled-skills/trellis-teamwork/SKILL.md +18 -3
- package/dist/templates/common/bundled-skills/trellis-teamwork/references/coordination-modes.md +34 -3
- package/dist/templates/common/bundled-skills/trellis-teamwork/references/teammate-configuration-matrix.md +37 -26
- package/dist/templates/common/bundled-skills/trellis-teamwork/references/teammate-processes.md +128 -14
- package/dist/templates/common/bundled-skills/trellis-teamwork/references/teamwork-plan-construction.md +152 -20
- package/dist/templates/common/commands/start.md +2 -2
- package/dist/templates/common/skills/before-dev.md +1 -4
- package/dist/templates/common/skills/break-loop.md +7 -18
- package/dist/templates/common/skills/check.md +7 -11
- package/dist/templates/common/skills/{brainstorm.md → request-intake.md} +5 -3
- package/dist/templates/common/skills/update-spec.md +5 -7
- package/dist/templates/copilot/hooks/session-start.py +14 -11
- package/dist/templates/copilot/index.d.ts +1 -6
- package/dist/templates/copilot/index.d.ts.map +1 -1
- package/dist/templates/copilot/index.js +1 -14
- package/dist/templates/copilot/index.js.map +1 -1
- package/dist/templates/extract.js +4 -0
- package/dist/templates/extract.js.map +1 -1
- package/dist/templates/markdown/spec/backend/index.md.txt +4 -35
- package/dist/templates/markdown/spec/frontend/index.md.txt +4 -36
- package/dist/templates/omp/extensions/trellis/index.ts.txt +2 -2
- package/dist/templates/opencode/lib/session-utils.js +301 -209
- package/dist/templates/pi/extensions/trellis/index.ts.txt +17 -1
- package/dist/templates/shared-hooks/guard-teamwork-wait.py +58 -0
- package/dist/templates/shared-hooks/index.d.ts +1 -1
- package/dist/templates/shared-hooks/index.d.ts.map +1 -1
- package/dist/templates/shared-hooks/index.js +1 -0
- package/dist/templates/shared-hooks/index.js.map +1 -1
- package/dist/templates/shared-hooks/inject-workflow-state.py +8 -3
- package/dist/templates/shared-hooks/session-start.py +16 -12
- package/dist/templates/snow/SNOW.md +1 -1
- package/dist/templates/trellis/agents/delegated-worktree-primary-agent.md +9 -0
- package/dist/templates/trellis/agents/profiles/architecture.md +9 -0
- package/dist/templates/trellis/agents/profiles/diagnosis.md +9 -0
- package/dist/templates/trellis/agents/profiles/exploration.md +9 -0
- package/dist/templates/trellis/agents/profiles/research.md +9 -0
- package/dist/templates/trellis/agents/profiles/review.md +9 -0
- package/dist/templates/trellis/agents/profiles/verification.md +9 -0
- package/dist/templates/trellis/agents/teammate-profiles.json +56 -4
- package/dist/templates/trellis/agents/teammate.md +4 -52
- package/dist/templates/trellis/config.yaml +2 -5
- package/dist/templates/trellis/index.d.ts +4 -0
- package/dist/templates/trellis/index.d.ts.map +1 -1
- package/dist/templates/trellis/index.js +22 -4
- package/dist/templates/trellis/index.js.map +1 -1
- package/dist/templates/trellis/scripts/add_session.py +1 -1
- package/dist/templates/trellis/scripts/common/active_task.py +3 -47
- package/dist/templates/trellis/scripts/common/config.py +5 -0
- package/dist/templates/trellis/scripts/common/paths.py +9 -25
- package/dist/templates/trellis/scripts/common/safe_commit.py +8 -8
- package/dist/templates/trellis/scripts/common/task_context.py +11 -51
- package/dist/templates/trellis/scripts/common/task_continuity.py +191 -60
- package/dist/templates/trellis/scripts/common/task_layout.py +80 -0
- package/dist/templates/trellis/scripts/common/task_move.py +345 -0
- package/dist/templates/trellis/scripts/common/task_store.py +51 -57
- package/dist/templates/trellis/scripts/common/task_utils.py +23 -19
- package/dist/templates/trellis/scripts/common/task_workflow.py +395 -49
- package/dist/templates/trellis/scripts/common/tasks.py +6 -5
- package/dist/templates/trellis/scripts/hooks/linear_sync.py +13 -3
- package/dist/templates/trellis/scripts/task.py +76 -24
- package/dist/templates/trellis/teamwork.json +10 -0
- package/dist/templates/trellis/workflow.md +11 -2
- package/dist/utils/ablation-store.d.ts +1 -1
- package/dist/utils/ablation-store.d.ts.map +1 -1
- package/dist/utils/ablation-store.js +58 -24
- package/dist/utils/ablation-store.js.map +1 -1
- package/dist/utils/asset-backup.d.ts +138 -0
- package/dist/utils/asset-backup.d.ts.map +1 -0
- package/dist/utils/asset-backup.js +525 -0
- package/dist/utils/asset-backup.js.map +1 -0
- package/dist/utils/atomic-write.d.ts +1 -1
- package/dist/utils/atomic-write.d.ts.map +1 -1
- package/dist/utils/atomic-write.js +6 -3
- package/dist/utils/atomic-write.js.map +1 -1
- package/dist/utils/manifest-prune.d.ts +4 -1
- package/dist/utils/manifest-prune.d.ts.map +1 -1
- package/dist/utils/manifest-prune.js +17 -6
- package/dist/utils/manifest-prune.js.map +1 -1
- package/dist/utils/template-fetcher.d.ts +4 -19
- package/dist/utils/template-fetcher.d.ts.map +1 -1
- package/dist/utils/template-fetcher.js +9 -45
- package/dist/utils/template-fetcher.js.map +1 -1
- package/dist/utils/template-hash.d.ts +5 -4
- package/dist/utils/template-hash.d.ts.map +1 -1
- package/dist/utils/template-hash.js +24 -17
- package/dist/utils/template-hash.js.map +1 -1
- package/package.json +3 -2
- package/dist/templates/copilot/prompts/before-dev.prompt.md +0 -39
- package/dist/templates/copilot/prompts/brainstorm.prompt.md +0 -13
- package/dist/templates/copilot/prompts/break-loop.prompt.md +0 -129
- package/dist/templates/copilot/prompts/check-cross-layer.prompt.md +0 -170
- package/dist/templates/copilot/prompts/check.prompt.md +0 -110
- package/dist/templates/copilot/prompts/create-command.prompt.md +0 -116
- package/dist/templates/copilot/prompts/finish-work.prompt.md +0 -22
- package/dist/templates/copilot/prompts/integrate-skill.prompt.md +0 -223
- package/dist/templates/copilot/prompts/onboard.prompt.md +0 -362
- package/dist/templates/copilot/prompts/record-session.prompt.md +0 -58
- package/dist/templates/copilot/prompts/start.prompt.md +0 -65
- package/dist/templates/copilot/prompts/update-spec.prompt.md +0 -358
|
@@ -1,65 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
description: "Trellis Copilot prompt: Start Session"
|
|
3
|
-
---
|
|
4
|
-
|
|
5
|
-
# Start Session
|
|
6
|
-
|
|
7
|
-
Use this prompt to inspect or refresh Trellis context. Copilot also supplies SessionStart context and a per-turn workflow-state breadcrumb through its hooks.
|
|
8
|
-
|
|
9
|
-
---
|
|
10
|
-
|
|
11
|
-
## Step 1: Current state
|
|
12
|
-
Identity, git status, current task, active tasks, journal location.
|
|
13
|
-
|
|
14
|
-
```bash
|
|
15
|
-
{{PYTHON_CMD}} ./.trellis/scripts/get_context.py
|
|
16
|
-
```
|
|
17
|
-
|
|
18
|
-
If this output includes a line beginning `Trellis update available:`, copy the full line verbatim when summarizing session context. Do not shorten operational command hints.
|
|
19
|
-
|
|
20
|
-
## Step 2: Workflow overview
|
|
21
|
-
Phase Index + skill routing table + DO-NOT-skip rules.
|
|
22
|
-
|
|
23
|
-
```bash
|
|
24
|
-
{{PYTHON_CMD}} ./.trellis/scripts/get_context.py --mode phase
|
|
25
|
-
```
|
|
26
|
-
|
|
27
|
-
Full guide in `.trellis/workflow.md` (read on demand).
|
|
28
|
-
|
|
29
|
-
## Step 3: Guideline indexes
|
|
30
|
-
Discover packages + spec layers, then read each relevant index file.
|
|
31
|
-
|
|
32
|
-
```bash
|
|
33
|
-
{{PYTHON_CMD}} ./.trellis/scripts/get_context.py --mode packages
|
|
34
|
-
cat .trellis/spec/guides/index.md
|
|
35
|
-
cat .trellis/spec/<package>/<layer>/index.md # for each relevant layer
|
|
36
|
-
```
|
|
37
|
-
|
|
38
|
-
Index files list the specific guideline docs to read when you actually start coding.
|
|
39
|
-
|
|
40
|
-
## Step 4: Decide next action
|
|
41
|
-
Use the current `<workflow-state>` breadcrumb to identify the business phase; task lifecycle status (`planning` or `in_progress`) and artifact presence do not identify that phase. If the breadcrumb is missing or stale, inspect the task with `task.py phase show <task>` and follow the matching phase Skill in `.trellis/workflow.md`.
|
|
42
|
-
|
|
43
|
-
- **An active phase is recorded** → continue that phase and load its matching Skill.
|
|
44
|
-
- **The task has no initialized phase route** → load `trellis-goal-exploration-and-requirements`, align and obtain the user's confirmation of the current requirements baseline, then initialize the applicable ordered route with `task.py phase init`.
|
|
45
|
-
- **No active task** → classify first. Handle a clear, low-risk, reversible, authorized, immediately verifiable request directly; otherwise ask for task-creation consent and begin with `trellis-goal-exploration-and-requirements`.
|
|
46
|
-
|
|
47
|
-
`task.py start` enters implementation only after an accepted implementation contract from Solution Design and Convergence Phase and separate implementation authorization.
|
|
48
|
-
|
|
49
|
-
---
|
|
50
|
-
|
|
51
|
-
## Skill routing (quick reference)
|
|
52
|
-
|
|
53
|
-
| User intent | Skill |
|
|
54
|
-
|---|---|
|
|
55
|
-
| Goal and requirements | `trellis-goal-exploration-and-requirements` |
|
|
56
|
-
| Decision alternatives | `trellis-decision-space-construction-and-merging` |
|
|
57
|
-
| Solution design | `trellis-solution-design-and-convergence` |
|
|
58
|
-
| Implementation | `trellis-task-implementation` |
|
|
59
|
-
| Delivery review | `trellis-delivery-review-and-closeout` |
|
|
60
|
-
| About to write code | `trellis-before-dev` |
|
|
61
|
-
| Done coding / quality check | `trellis-check` |
|
|
62
|
-
| Stuck / fixed same bug multiple times | `trellis-break-loop` |
|
|
63
|
-
| Learned something worth capturing | `trellis-update-spec` |
|
|
64
|
-
|
|
65
|
-
Full rules + anti-rationalization table in `.trellis/workflow.md`.
|
|
@@ -1,358 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
description: "Trellis Copilot prompt: Update Code-Spec - Capture Executable Contracts"
|
|
3
|
-
---
|
|
4
|
-
|
|
5
|
-
# Update Code-Spec - Capture Executable Contracts
|
|
6
|
-
|
|
7
|
-
When you learn something valuable (from debugging, implementing, or discussion), use this command to update the relevant code-spec documents.
|
|
8
|
-
|
|
9
|
-
**Timing**: After completing a task, fixing a bug, or discovering a new pattern
|
|
10
|
-
|
|
11
|
-
---
|
|
12
|
-
|
|
13
|
-
## Code-Spec First Rule (CRITICAL)
|
|
14
|
-
|
|
15
|
-
In this project, "spec" for implementation work means **code-spec**:
|
|
16
|
-
- Executable contracts (not principle-only text)
|
|
17
|
-
- Concrete signatures, payload fields, env keys, and boundary behavior
|
|
18
|
-
- Testable validation/error behavior
|
|
19
|
-
|
|
20
|
-
If the change touches infra or cross-layer contracts, code-spec depth is mandatory.
|
|
21
|
-
|
|
22
|
-
### Mandatory Triggers
|
|
23
|
-
|
|
24
|
-
Apply code-spec depth when the change includes any of:
|
|
25
|
-
- New/changed command or API signature
|
|
26
|
-
- Cross-layer request/response contract change
|
|
27
|
-
- Database schema/migration change
|
|
28
|
-
- Infra integration (storage, queue, cache, secrets, env wiring)
|
|
29
|
-
|
|
30
|
-
### Mandatory Output (7 Sections)
|
|
31
|
-
|
|
32
|
-
For triggered tasks, include all sections below:
|
|
33
|
-
1. Scope / Trigger
|
|
34
|
-
2. Signatures (command/API/DB)
|
|
35
|
-
3. Contracts (request/response/env)
|
|
36
|
-
4. Validation & Error Matrix
|
|
37
|
-
5. Good/Base/Bad Cases
|
|
38
|
-
6. Tests Required (with assertion points)
|
|
39
|
-
7. Wrong vs Correct (at least one pair)
|
|
40
|
-
|
|
41
|
-
---
|
|
42
|
-
|
|
43
|
-
## When to Update Code-Specs
|
|
44
|
-
|
|
45
|
-
| Trigger | Example | Target Spec |
|
|
46
|
-
|---------|---------|-------------|
|
|
47
|
-
| **Implemented a feature** | Added template download with giget | Relevant `backend/` or `frontend/` file |
|
|
48
|
-
| **Made a design decision** | Used type field + mapping table for extensibility | Relevant code-spec + "Design Decisions" section |
|
|
49
|
-
| **Fixed a bug** | Found a subtle issue with error handling | `backend/error-handling.md` |
|
|
50
|
-
| **Discovered a pattern** | Found a better way to structure code | Relevant `backend/` or `frontend/` file |
|
|
51
|
-
| **Hit a gotcha** | Learned that X must be done before Y | Relevant code-spec + "Common Mistakes" section |
|
|
52
|
-
| **Established a convention** | Team agreed on naming pattern | `quality-guidelines.md` |
|
|
53
|
-
| **New thinking trigger** | "Don't forget to check X before doing Y" | `guides/*.md` (as a checklist item, not detailed rules) |
|
|
54
|
-
|
|
55
|
-
**Key Insight**: Code-spec updates are NOT just for problems. Every feature implementation contains design decisions and contracts that future AI/developers need to execute safely.
|
|
56
|
-
|
|
57
|
-
---
|
|
58
|
-
|
|
59
|
-
## Spec Structure Overview
|
|
60
|
-
|
|
61
|
-
```
|
|
62
|
-
.trellis/spec/
|
|
63
|
-
├── backend/ # Backend coding standards
|
|
64
|
-
�? ├── index.md # Overview and links
|
|
65
|
-
�? └── *.md # Topic-specific guidelines
|
|
66
|
-
├── frontend/ # Frontend coding standards
|
|
67
|
-
�? ├── index.md # Overview and links
|
|
68
|
-
�? └── *.md # Topic-specific guidelines
|
|
69
|
-
└── guides/ # Thinking checklists (NOT coding specs!)
|
|
70
|
-
├── index.md # Guide index
|
|
71
|
-
└── *.md # Topic-specific guides
|
|
72
|
-
```
|
|
73
|
-
|
|
74
|
-
### CRITICAL: Code-Spec vs Guide - Know the Difference
|
|
75
|
-
|
|
76
|
-
| Type | Location | Purpose | Content Style |
|
|
77
|
-
|------|----------|---------|---------------|
|
|
78
|
-
| **Code-Spec** | `backend/*.md`, `frontend/*.md` | Tell AI "how to implement safely" | Signatures, contracts, matrices, cases, test points |
|
|
79
|
-
| **Guide** | `guides/*.md` | Help AI "what to think about" | Checklists, questions, pointers to specs |
|
|
80
|
-
|
|
81
|
-
**Decision Rule**: Ask yourself:
|
|
82
|
-
|
|
83
|
-
- "This is **how to write** the code" �?Put in `backend/` or `frontend/`
|
|
84
|
-
- "This is **what to consider** before writing" �?Put in `guides/`
|
|
85
|
-
|
|
86
|
-
**Example**:
|
|
87
|
-
|
|
88
|
-
| Learning | Wrong Location | Correct Location |
|
|
89
|
-
|----------|----------------|------------------|
|
|
90
|
-
| "Use `reconfigure()` not `TextIOWrapper` for Windows stdout" | �?`guides/cross-platform-thinking-guide.md` | �?`backend/script-conventions.md` |
|
|
91
|
-
| "Remember to check encoding when writing cross-platform code" | �?`backend/script-conventions.md` | �?`guides/cross-platform-thinking-guide.md` |
|
|
92
|
-
|
|
93
|
-
**Guides should be short checklists that point to specs**, not duplicate the detailed rules.
|
|
94
|
-
|
|
95
|
-
---
|
|
96
|
-
|
|
97
|
-
## Update Process
|
|
98
|
-
|
|
99
|
-
### Step 1: Identify What You Learned
|
|
100
|
-
|
|
101
|
-
Answer these questions:
|
|
102
|
-
|
|
103
|
-
1. **What did you learn?** (Be specific)
|
|
104
|
-
2. **Why is it important?** (What problem does it prevent?)
|
|
105
|
-
3. **Where does it belong?** (Which spec file?)
|
|
106
|
-
|
|
107
|
-
### Step 2: Classify the Update Type
|
|
108
|
-
|
|
109
|
-
| Type | Description | Action |
|
|
110
|
-
|------|-------------|--------|
|
|
111
|
-
| **Design Decision** | Why we chose approach X over Y | Add to "Design Decisions" section |
|
|
112
|
-
| **Project Convention** | How we do X in this project | Add to relevant section with examples |
|
|
113
|
-
| **New Pattern** | A reusable approach discovered | Add to "Patterns" section |
|
|
114
|
-
| **Forbidden Pattern** | Something that causes problems | Add to "Anti-patterns" or "Don't" section |
|
|
115
|
-
| **Common Mistake** | Easy-to-make error | Add to "Common Mistakes" section |
|
|
116
|
-
| **Convention** | Agreed-upon standard | Add to relevant section |
|
|
117
|
-
| **Gotcha** | Non-obvious behavior | Add warning callout |
|
|
118
|
-
|
|
119
|
-
### Step 3: Read the Target Code-Spec
|
|
120
|
-
|
|
121
|
-
Before editing, read the current code-spec to:
|
|
122
|
-
- Understand existing structure
|
|
123
|
-
- Avoid duplicating content
|
|
124
|
-
- Find the right section for your update
|
|
125
|
-
|
|
126
|
-
```bash
|
|
127
|
-
cat .trellis/spec/<category>/<file>.md
|
|
128
|
-
```
|
|
129
|
-
|
|
130
|
-
### Step 4: Make the Update
|
|
131
|
-
|
|
132
|
-
Follow these principles:
|
|
133
|
-
|
|
134
|
-
1. **Be Specific**: Include concrete examples, not just abstract rules
|
|
135
|
-
2. **Explain Why**: State the problem this prevents
|
|
136
|
-
3. **Show Contracts**: Add signatures, payload fields, and error behavior
|
|
137
|
-
4. **Show Code**: Add code snippets for key patterns
|
|
138
|
-
5. **Keep it Short**: One concept per section
|
|
139
|
-
|
|
140
|
-
### Step 5: Update the Index (if needed)
|
|
141
|
-
|
|
142
|
-
If you added a new section or the code-spec status changed, update the category's `index.md`.
|
|
143
|
-
|
|
144
|
-
---
|
|
145
|
-
|
|
146
|
-
## Update Templates
|
|
147
|
-
|
|
148
|
-
### Mandatory Template for Infra/Cross-Layer Work
|
|
149
|
-
|
|
150
|
-
```markdown
|
|
151
|
-
## Scenario: <name>
|
|
152
|
-
|
|
153
|
-
### 1. Scope / Trigger
|
|
154
|
-
- Trigger: <why this requires code-spec depth>
|
|
155
|
-
|
|
156
|
-
### 2. Signatures
|
|
157
|
-
- Backend command/API/DB signature(s)
|
|
158
|
-
|
|
159
|
-
### 3. Contracts
|
|
160
|
-
- Request fields (name, type, constraints)
|
|
161
|
-
- Response fields (name, type, constraints)
|
|
162
|
-
- Environment keys (required/optional)
|
|
163
|
-
|
|
164
|
-
### 4. Validation & Error Matrix
|
|
165
|
-
- <condition> -> <error>
|
|
166
|
-
|
|
167
|
-
### 5. Good/Base/Bad Cases
|
|
168
|
-
- Good: ...
|
|
169
|
-
- Base: ...
|
|
170
|
-
- Bad: ...
|
|
171
|
-
|
|
172
|
-
### 6. Tests Required
|
|
173
|
-
- Unit/Integration/E2E with assertion points
|
|
174
|
-
|
|
175
|
-
### 7. Wrong vs Correct
|
|
176
|
-
#### Wrong
|
|
177
|
-
...
|
|
178
|
-
#### Correct
|
|
179
|
-
...
|
|
180
|
-
```
|
|
181
|
-
|
|
182
|
-
### Adding a Design Decision
|
|
183
|
-
|
|
184
|
-
```markdown
|
|
185
|
-
### Design Decision: [Decision Name]
|
|
186
|
-
|
|
187
|
-
**Context**: What problem were we solving?
|
|
188
|
-
|
|
189
|
-
**Options Considered**:
|
|
190
|
-
1. Option A - brief description
|
|
191
|
-
2. Option B - brief description
|
|
192
|
-
|
|
193
|
-
**Decision**: We chose Option X because...
|
|
194
|
-
|
|
195
|
-
**Example**:
|
|
196
|
-
\`\`\`typescript
|
|
197
|
-
// How it's implemented
|
|
198
|
-
code example
|
|
199
|
-
\`\`\`
|
|
200
|
-
|
|
201
|
-
**Extensibility**: How to extend this in the future...
|
|
202
|
-
```
|
|
203
|
-
|
|
204
|
-
### Adding a Project Convention
|
|
205
|
-
|
|
206
|
-
```markdown
|
|
207
|
-
### Convention: [Convention Name]
|
|
208
|
-
|
|
209
|
-
**What**: Brief description of the convention.
|
|
210
|
-
|
|
211
|
-
**Why**: Why we do it this way in this project.
|
|
212
|
-
|
|
213
|
-
**Example**:
|
|
214
|
-
\`\`\`typescript
|
|
215
|
-
// How to follow this convention
|
|
216
|
-
code example
|
|
217
|
-
\`\`\`
|
|
218
|
-
|
|
219
|
-
**Related**: Links to related conventions or specs.
|
|
220
|
-
```
|
|
221
|
-
|
|
222
|
-
### Adding a New Pattern
|
|
223
|
-
|
|
224
|
-
```markdown
|
|
225
|
-
### Pattern Name
|
|
226
|
-
|
|
227
|
-
**Problem**: What problem does this solve?
|
|
228
|
-
|
|
229
|
-
**Solution**: Brief description of the approach.
|
|
230
|
-
|
|
231
|
-
**Example**:
|
|
232
|
-
\`\`\`
|
|
233
|
-
// Good
|
|
234
|
-
code example
|
|
235
|
-
|
|
236
|
-
// Bad
|
|
237
|
-
code example
|
|
238
|
-
\`\`\`
|
|
239
|
-
|
|
240
|
-
**Why**: Explanation of why this works better.
|
|
241
|
-
```
|
|
242
|
-
|
|
243
|
-
### Adding a Forbidden Pattern
|
|
244
|
-
|
|
245
|
-
```markdown
|
|
246
|
-
### Don't: Pattern Name
|
|
247
|
-
|
|
248
|
-
**Problem**:
|
|
249
|
-
\`\`\`
|
|
250
|
-
// Don't do this
|
|
251
|
-
bad code example
|
|
252
|
-
\`\`\`
|
|
253
|
-
|
|
254
|
-
**Why it's bad**: Explanation of the issue.
|
|
255
|
-
|
|
256
|
-
**Instead**:
|
|
257
|
-
\`\`\`
|
|
258
|
-
// Do this instead
|
|
259
|
-
good code example
|
|
260
|
-
\`\`\`
|
|
261
|
-
```
|
|
262
|
-
|
|
263
|
-
### Adding a Common Mistake
|
|
264
|
-
|
|
265
|
-
```markdown
|
|
266
|
-
### Common Mistake: Description
|
|
267
|
-
|
|
268
|
-
**Symptom**: What goes wrong
|
|
269
|
-
|
|
270
|
-
**Cause**: Why this happens
|
|
271
|
-
|
|
272
|
-
**Fix**: How to correct it
|
|
273
|
-
|
|
274
|
-
**Prevention**: How to avoid it in the future
|
|
275
|
-
```
|
|
276
|
-
|
|
277
|
-
### Adding a Gotcha
|
|
278
|
-
|
|
279
|
-
```markdown
|
|
280
|
-
> **Warning**: Brief description of the non-obvious behavior.
|
|
281
|
-
>
|
|
282
|
-
> Details about when this happens and how to handle it.
|
|
283
|
-
```
|
|
284
|
-
|
|
285
|
-
---
|
|
286
|
-
|
|
287
|
-
## Interactive Mode
|
|
288
|
-
|
|
289
|
-
If you're unsure what to update, answer these prompts:
|
|
290
|
-
|
|
291
|
-
1. **What did you just finish?**
|
|
292
|
-
- [ ] Fixed a bug
|
|
293
|
-
- [ ] Implemented a feature
|
|
294
|
-
- [ ] Refactored code
|
|
295
|
-
- [ ] Had a discussion about approach
|
|
296
|
-
|
|
297
|
-
2. **What did you learn or decide?**
|
|
298
|
-
- Design decision (why X over Y)
|
|
299
|
-
- Project convention (how we do X)
|
|
300
|
-
- Non-obvious behavior (gotcha)
|
|
301
|
-
- Better approach (pattern)
|
|
302
|
-
|
|
303
|
-
3. **Would future AI/developers need to know this?**
|
|
304
|
-
- To understand how the code works �?Yes, update spec
|
|
305
|
-
- To maintain or extend the feature �?Yes, update spec
|
|
306
|
-
- To avoid repeating mistakes �?Yes, update spec
|
|
307
|
-
- Purely one-off implementation detail �?Maybe skip
|
|
308
|
-
|
|
309
|
-
4. **Which area does it relate to?**
|
|
310
|
-
- [ ] Backend code
|
|
311
|
-
- [ ] Frontend code
|
|
312
|
-
- [ ] Cross-layer data flow
|
|
313
|
-
- [ ] Code organization/reuse
|
|
314
|
-
- [ ] Quality/testing
|
|
315
|
-
|
|
316
|
-
---
|
|
317
|
-
|
|
318
|
-
## Quality Checklist
|
|
319
|
-
|
|
320
|
-
Before finishing your code-spec update:
|
|
321
|
-
|
|
322
|
-
- [ ] Is the content specific and actionable?
|
|
323
|
-
- [ ] Did you include a code example?
|
|
324
|
-
- [ ] Did you explain WHY, not just WHAT?
|
|
325
|
-
- [ ] Did you include executable signatures/contracts?
|
|
326
|
-
- [ ] Did you include validation and error matrix?
|
|
327
|
-
- [ ] Did you include Good/Base/Bad cases?
|
|
328
|
-
- [ ] Did you include required tests with assertion points?
|
|
329
|
-
- [ ] Is it in the right code-spec file?
|
|
330
|
-
- [ ] Does it duplicate existing content?
|
|
331
|
-
- [ ] Would a new team member understand it?
|
|
332
|
-
|
|
333
|
-
---
|
|
334
|
-
|
|
335
|
-
## Relationship to Other Commands
|
|
336
|
-
|
|
337
|
-
```
|
|
338
|
-
Development Flow:
|
|
339
|
-
Learn something �?/ �?Knowledge captured
|
|
340
|
-
�? �?
|
|
341
|
-
/ ←──────────────────── Future sessions benefit
|
|
342
|
-
(deep bug analysis)
|
|
343
|
-
```
|
|
344
|
-
|
|
345
|
-
- `/` - Analyzes bugs deeply, often reveals spec updates needed
|
|
346
|
-
- `/` - Actually makes the updates (this command)
|
|
347
|
-
- `/` - Reminds you to check if specs need updates
|
|
348
|
-
|
|
349
|
-
---
|
|
350
|
-
|
|
351
|
-
## Core Philosophy
|
|
352
|
-
|
|
353
|
-
> **Code-specs are living documents. Every debugging session, every "aha moment" is an opportunity to make the implementation contract clearer.**
|
|
354
|
-
|
|
355
|
-
The goal is **institutional memory**:
|
|
356
|
-
- What one person learns, everyone benefits from
|
|
357
|
-
- What AI learns in one session, persists to future sessions
|
|
358
|
-
- Mistakes become documented guardrails
|