@pennixrv/trellis 0.7.0-beta.9 → 0.7.1-beta.1
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 +1 -1
- package/dist/cli/index.d.ts.map +1 -1
- package/dist/cli/index.js +14 -26
- package/dist/cli/index.js.map +1 -1
- package/dist/commands/ablate.js +1 -1
- package/dist/commands/ablate.js.map +1 -1
- package/dist/commands/init.d.ts.map +1 -1
- package/dist/commands/init.js +30 -56
- package/dist/commands/init.js.map +1 -1
- package/dist/commands/task-progress.d.ts +2 -0
- package/dist/commands/task-progress.d.ts.map +1 -1
- package/dist/commands/task-progress.js +37 -30
- package/dist/commands/task-progress.js.map +1 -1
- package/dist/commands/{channel → teamwork}/adapters/claude.d.ts +3 -3
- package/dist/commands/teamwork/adapters/claude.d.ts.map +1 -0
- package/dist/commands/{channel → teamwork}/adapters/claude.js +3 -3
- package/dist/commands/teamwork/adapters/claude.js.map +1 -0
- package/dist/commands/{channel → teamwork}/adapters/codex.d.ts +1 -15
- package/dist/commands/teamwork/adapters/codex.d.ts.map +1 -0
- package/dist/commands/{channel → teamwork}/adapters/codex.js +5 -42
- package/dist/commands/teamwork/adapters/codex.js.map +1 -0
- package/dist/commands/{channel → teamwork}/adapters/index.d.ts +6 -6
- package/dist/commands/teamwork/adapters/index.d.ts.map +1 -0
- package/dist/commands/{channel → teamwork}/adapters/index.js +16 -52
- package/dist/commands/teamwork/adapters/index.js.map +1 -0
- package/dist/commands/{channel → teamwork}/adapters/types.d.ts +2 -2
- package/dist/commands/teamwork/adapters/types.d.ts.map +1 -0
- package/dist/commands/teamwork/adapters/types.js.map +1 -0
- package/dist/commands/{channel → teamwork}/agent-loader.d.ts +2 -4
- package/dist/commands/teamwork/agent-loader.d.ts.map +1 -0
- package/dist/commands/{channel → teamwork}/agent-loader.js +4 -35
- package/dist/commands/teamwork/agent-loader.js.map +1 -0
- package/dist/commands/teamwork/artifact.d.ts +177 -0
- package/dist/commands/teamwork/artifact.d.ts.map +1 -0
- package/dist/commands/teamwork/artifact.js +908 -0
- package/dist/commands/teamwork/artifact.js.map +1 -0
- package/dist/commands/{channel → teamwork}/context-loader.d.ts +1 -1
- package/dist/commands/teamwork/context-loader.d.ts.map +1 -0
- package/dist/commands/{channel → teamwork}/context-loader.js +12 -12
- package/dist/commands/teamwork/context-loader.js.map +1 -0
- package/dist/commands/{channel → teamwork}/context-trust.d.ts +6 -6
- package/dist/commands/teamwork/context-trust.d.ts.map +1 -0
- package/dist/commands/{channel → teamwork}/context-trust.js +16 -16
- package/dist/commands/teamwork/context-trust.js.map +1 -0
- package/dist/commands/teamwork/context.d.ts +16 -0
- package/dist/commands/teamwork/context.d.ts.map +1 -0
- package/dist/commands/{channel → teamwork}/context.js +17 -17
- package/dist/commands/teamwork/context.js.map +1 -0
- package/dist/commands/teamwork/coordinator.d.ts +89 -0
- package/dist/commands/teamwork/coordinator.d.ts.map +1 -0
- package/dist/commands/teamwork/coordinator.js +1198 -0
- package/dist/commands/teamwork/coordinator.js.map +1 -0
- package/dist/commands/teamwork/create.d.ts +23 -0
- package/dist/commands/teamwork/create.d.ts.map +1 -0
- package/dist/commands/teamwork/create.js +39 -0
- package/dist/commands/teamwork/create.js.map +1 -0
- package/dist/commands/{channel → teamwork}/dev-parse-trace.d.ts +1 -1
- package/dist/commands/teamwork/dev-parse-trace.d.ts.map +1 -0
- package/dist/commands/{channel → teamwork}/dev-parse-trace.js +1 -1
- package/dist/commands/teamwork/dev-parse-trace.js.map +1 -0
- package/dist/commands/{channel → teamwork}/guard.d.ts +27 -46
- package/dist/commands/teamwork/guard.d.ts.map +1 -0
- package/dist/commands/{channel → teamwork}/guard.js +54 -156
- package/dist/commands/teamwork/guard.js.map +1 -0
- package/dist/commands/teamwork/index.d.ts +3 -0
- package/dist/commands/teamwork/index.d.ts.map +1 -0
- package/dist/commands/{channel → teamwork}/index.js +135 -165
- package/dist/commands/teamwork/index.js.map +1 -0
- package/dist/commands/{channel → teamwork}/interrupt.d.ts +1 -1
- package/dist/commands/teamwork/interrupt.d.ts.map +1 -0
- package/dist/commands/teamwork/interrupt.js +22 -0
- package/dist/commands/teamwork/interrupt.js.map +1 -0
- package/dist/commands/teamwork/kill.d.ts +7 -0
- package/dist/commands/teamwork/kill.d.ts.map +1 -0
- package/dist/commands/{channel → teamwork}/kill.js +21 -21
- package/dist/commands/teamwork/kill.js.map +1 -0
- package/dist/commands/teamwork/list.d.ts +17 -0
- package/dist/commands/teamwork/list.d.ts.map +1 -0
- package/dist/commands/{channel → teamwork}/list.js +18 -27
- package/dist/commands/teamwork/list.js.map +1 -0
- package/dist/commands/{channel → teamwork}/messages.d.ts +1 -1
- package/dist/commands/teamwork/messages.d.ts.map +1 -0
- package/dist/commands/{channel → teamwork}/messages.js +18 -18
- package/dist/commands/teamwork/messages.js.map +1 -0
- package/dist/commands/teamwork/profiles.d.ts +25 -0
- package/dist/commands/teamwork/profiles.d.ts.map +1 -0
- package/dist/commands/teamwork/profiles.js +125 -0
- package/dist/commands/teamwork/profiles.js.map +1 -0
- package/dist/commands/teamwork/rm.d.ts +27 -0
- package/dist/commands/teamwork/rm.d.ts.map +1 -0
- package/dist/commands/{channel → teamwork}/rm.js +21 -22
- package/dist/commands/teamwork/rm.js.map +1 -0
- package/dist/commands/teamwork/run.d.ts +29 -0
- package/dist/commands/{channel → teamwork}/run.d.ts.map +1 -1
- package/dist/commands/teamwork/run.js +129 -0
- package/dist/commands/teamwork/run.js.map +1 -0
- package/dist/commands/{channel → teamwork}/send.d.ts +1 -1
- package/dist/commands/teamwork/send.d.ts.map +1 -0
- package/dist/commands/{channel → teamwork}/send.js +7 -7
- package/dist/commands/teamwork/send.js.map +1 -0
- package/dist/commands/{channel → teamwork}/spawn.d.ts +8 -12
- package/dist/commands/teamwork/spawn.d.ts.map +1 -0
- package/dist/commands/{channel → teamwork}/spawn.js +51 -112
- package/dist/commands/teamwork/spawn.js.map +1 -0
- package/dist/commands/teamwork/store/events.d.ts +22 -0
- package/dist/commands/teamwork/store/events.d.ts.map +1 -0
- package/dist/commands/{channel → teamwork}/store/events.js +8 -8
- package/dist/commands/teamwork/store/events.js.map +1 -0
- package/dist/commands/teamwork/store/filter.d.ts +3 -0
- package/dist/commands/teamwork/store/filter.d.ts.map +1 -0
- package/dist/commands/teamwork/store/filter.js +2 -0
- package/dist/commands/teamwork/store/filter.js.map +1 -0
- package/dist/commands/{channel → teamwork}/store/lock.d.ts +1 -1
- package/dist/commands/teamwork/store/lock.d.ts.map +1 -0
- package/dist/commands/{channel → teamwork}/store/lock.js +2 -2
- package/dist/commands/teamwork/store/lock.js.map +1 -0
- package/dist/commands/{channel → teamwork}/store/paths.d.ts +18 -32
- package/dist/commands/teamwork/store/paths.d.ts.map +1 -0
- package/dist/commands/{channel → teamwork}/store/paths.js +42 -109
- package/dist/commands/teamwork/store/paths.js.map +1 -0
- package/dist/commands/teamwork/store/schema.d.ts +18 -0
- package/dist/commands/teamwork/store/schema.d.ts.map +1 -0
- package/dist/commands/teamwork/store/schema.js +23 -0
- package/dist/commands/teamwork/store/schema.js.map +1 -0
- package/dist/commands/{channel → teamwork}/store/thread-state.d.ts +3 -3
- package/dist/commands/teamwork/store/thread-state.d.ts.map +1 -0
- package/dist/commands/{channel → teamwork}/store/thread-state.js +1 -1
- package/dist/commands/teamwork/store/thread-state.js.map +1 -0
- package/dist/commands/teamwork/store/watch.d.ts +19 -0
- package/dist/commands/teamwork/store/watch.d.ts.map +1 -0
- package/dist/commands/{channel → teamwork}/store/watch.js +8 -8
- package/dist/commands/teamwork/store/watch.js.map +1 -0
- package/dist/commands/teamwork/supervisor/idle.d.ts.map +1 -0
- package/dist/commands/teamwork/supervisor/idle.js.map +1 -0
- package/dist/commands/{channel → teamwork}/supervisor/inbox.d.ts +2 -2
- package/dist/commands/teamwork/supervisor/inbox.d.ts.map +1 -0
- package/dist/commands/{channel → teamwork}/supervisor/inbox.js +14 -14
- package/dist/commands/teamwork/supervisor/inbox.js.map +1 -0
- package/dist/commands/{channel → teamwork}/supervisor/shutdown.d.ts +3 -6
- package/dist/commands/teamwork/supervisor/shutdown.d.ts.map +1 -0
- package/dist/commands/{channel → teamwork}/supervisor/shutdown.js +7 -17
- package/dist/commands/teamwork/supervisor/shutdown.js.map +1 -0
- package/dist/commands/{channel → teamwork}/supervisor/stdout.d.ts +3 -5
- package/dist/commands/teamwork/supervisor/stdout.d.ts.map +1 -0
- package/dist/commands/{channel → teamwork}/supervisor/stdout.js +12 -23
- package/dist/commands/teamwork/supervisor/stdout.js.map +1 -0
- package/dist/commands/teamwork/supervisor/turns.d.ts.map +1 -0
- package/dist/commands/teamwork/supervisor/turns.js.map +1 -0
- package/dist/commands/{channel → teamwork}/supervisor/warning.d.ts +5 -5
- package/dist/commands/teamwork/supervisor/warning.d.ts.map +1 -0
- package/dist/commands/{channel → teamwork}/supervisor/warning.js +6 -6
- package/dist/commands/teamwork/supervisor/warning.js.map +1 -0
- package/dist/commands/{channel → teamwork}/supervisor.d.ts +21 -21
- package/dist/commands/teamwork/supervisor.d.ts.map +1 -0
- package/dist/commands/{channel → teamwork}/supervisor.js +53 -63
- package/dist/commands/teamwork/supervisor.js.map +1 -0
- package/dist/commands/teamwork/teammate-adapters.d.ts +31 -0
- package/dist/commands/teamwork/teammate-adapters.d.ts.map +1 -0
- package/dist/commands/teamwork/teammate-adapters.js +96 -0
- package/dist/commands/teamwork/teammate-adapters.js.map +1 -0
- package/dist/commands/teamwork/teammate-config.d.ts +19 -0
- package/dist/commands/teamwork/teammate-config.d.ts.map +1 -0
- package/dist/commands/teamwork/teammate-config.js +97 -0
- package/dist/commands/teamwork/teammate-config.js.map +1 -0
- package/dist/commands/teamwork/teammate-launch.d.ts +58 -0
- package/dist/commands/teamwork/teammate-launch.d.ts.map +1 -0
- package/dist/commands/teamwork/teammate-launch.js +125 -0
- package/dist/commands/teamwork/teammate-launch.js.map +1 -0
- package/dist/commands/teamwork/text-body.d.ts +13 -0
- package/dist/commands/teamwork/text-body.d.ts.map +1 -0
- package/dist/commands/{channel → teamwork}/text-body.js +3 -3
- package/dist/commands/teamwork/text-body.js.map +1 -0
- package/dist/commands/teamwork/threads.d.ts +35 -0
- package/dist/commands/teamwork/threads.d.ts.map +1 -0
- package/dist/commands/{channel → teamwork}/threads.js +19 -19
- package/dist/commands/teamwork/threads.js.map +1 -0
- package/dist/commands/teamwork/title.d.ts +12 -0
- package/dist/commands/teamwork/title.d.ts.map +1 -0
- package/dist/commands/teamwork/title.js +24 -0
- package/dist/commands/teamwork/title.js.map +1 -0
- package/dist/commands/{channel → teamwork}/wait.d.ts +1 -5
- package/dist/commands/teamwork/wait.d.ts.map +1 -0
- package/dist/commands/{channel → teamwork}/wait.js +8 -21
- package/dist/commands/teamwork/wait.js.map +1 -0
- package/dist/commands/update.d.ts.map +1 -1
- package/dist/commands/update.js +93 -90
- package/dist/commands/update.js.map +1 -1
- package/dist/commands/workflow.d.ts +1 -1
- package/dist/commands/workflow.d.ts.map +1 -1
- package/dist/commands/workflow.js +9 -10
- package/dist/commands/workflow.js.map +1 -1
- package/dist/configurators/claude.d.ts +0 -17
- package/dist/configurators/claude.d.ts.map +1 -1
- package/dist/configurators/claude.js +2 -61
- package/dist/configurators/claude.js.map +1 -1
- package/dist/configurators/shared.d.ts.map +1 -1
- package/dist/configurators/shared.js +2 -2
- package/dist/configurators/shared.js.map +1 -1
- package/dist/configurators/snow.js +1 -1
- package/dist/configurators/snow.js.map +1 -1
- package/dist/configurators/workflow.d.ts +1 -1
- package/dist/configurators/workflow.js +5 -5
- package/dist/configurators/workflow.js.map +1 -1
- package/dist/constants/paths.d.ts +1 -1
- package/dist/constants/paths.d.ts.map +1 -1
- package/dist/constants/paths.js +1 -1
- package/dist/constants/paths.js.map +1 -1
- package/dist/migrations/manifests/0.7.0-beta.10.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.11.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.12.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.13.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.14.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.15.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.16.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.17.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.18.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.19.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.20.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.21.json +17 -0
- package/dist/migrations/manifests/0.7.0-beta.22.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.23.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.24.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.25.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.26.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.27.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.28.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.29.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.30.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.31.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.32.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.33.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.34.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.35.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.36.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.37.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.38.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.39.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.40.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.41.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.42.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.43.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.44.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.45.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.46.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.47.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.48.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.49.json +13 -0
- package/dist/migrations/manifests/0.7.0-beta.50.json +12 -0
- package/dist/migrations/manifests/0.7.0-beta.51.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.52.json +9 -0
- package/dist/migrations/manifests/0.7.0-beta.53.json +27 -0
- package/dist/migrations/manifests/0.7.0-beta.54.json +8 -0
- 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.json +9 -0
- package/dist/templates/claude/hooks/statusline.py +0 -7
- package/dist/templates/codex/hooks/session-start.py +31 -38
- package/dist/templates/common/bundled-skills/trellis-decision-space-construction-and-merging/SKILL.md +10 -0
- package/dist/templates/common/bundled-skills/trellis-decision-space-construction-and-merging/workflow.md +40 -0
- package/dist/templates/common/bundled-skills/trellis-delivery-review-and-closeout/SKILL.md +10 -0
- package/dist/templates/common/bundled-skills/trellis-delivery-review-and-closeout/workflow.md +55 -0
- package/dist/templates/common/bundled-skills/trellis-goal-exploration-and-requirements/SKILL.md +10 -0
- package/dist/templates/common/bundled-skills/trellis-goal-exploration-and-requirements/workflow.md +33 -0
- package/dist/templates/common/bundled-skills/trellis-meta/SKILL.md +25 -25
- package/dist/templates/common/bundled-skills/trellis-meta/references/customize-local/change-agents.md +1 -1
- package/dist/templates/common/bundled-skills/trellis-meta/references/customize-local/change-skills-or-commands.md +13 -19
- package/dist/templates/common/bundled-skills/trellis-meta/references/customize-local/change-spec-structure.md +1 -1
- package/dist/templates/common/bundled-skills/trellis-meta/references/customize-local/change-task-lifecycle.md +27 -75
- package/dist/templates/common/bundled-skills/trellis-meta/references/customize-local/change-workflow.md +17 -56
- 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/bundled-skills.md +14 -11
- package/dist/templates/common/bundled-skills/trellis-meta/references/local-architecture/generated-files.md +0 -33
- package/dist/templates/common/bundled-skills/trellis-meta/references/local-architecture/multi-agent-teamwork.md +32 -0
- package/dist/templates/common/bundled-skills/trellis-meta/references/local-architecture/spec-system.md +1 -1
- package/dist/templates/common/bundled-skills/trellis-meta/references/local-architecture/task-system.md +25 -111
- package/dist/templates/common/bundled-skills/trellis-meta/references/local-architecture/workflow.md +19 -60
- package/dist/templates/common/bundled-skills/trellis-meta/references/platform-files/skills-and-commands.md +1 -1
- package/dist/templates/common/bundled-skills/trellis-session-insight/SKILL.md +1 -1
- package/dist/templates/common/bundled-skills/trellis-session-insight/references/cli-quick-reference.md +1 -1
- package/dist/templates/common/bundled-skills/trellis-solution-design-and-convergence/SKILL.md +10 -0
- package/dist/templates/common/bundled-skills/trellis-solution-design-and-convergence/workflow.md +36 -0
- package/dist/templates/common/bundled-skills/trellis-task-implementation/SKILL.md +10 -0
- package/dist/templates/common/bundled-skills/trellis-task-implementation/workflow.md +29 -0
- package/dist/templates/common/bundled-skills/trellis-teamwork/SKILL.md +73 -0
- package/dist/templates/common/bundled-skills/trellis-teamwork/references/coordination-modes.md +29 -0
- package/dist/templates/common/bundled-skills/trellis-teamwork/references/teammate-configuration-matrix.md +31 -0
- package/dist/templates/common/bundled-skills/trellis-teamwork/references/teammate-processes.md +37 -0
- package/dist/templates/common/bundled-skills/trellis-teamwork/references/teamwork-plan-construction.md +78 -0
- package/dist/templates/common/commands/continue.md +9 -49
- package/dist/templates/common/commands/finish-work.md +10 -58
- package/dist/templates/common/commands/start.md +19 -49
- package/dist/templates/common/skills/brainstorm.md +11 -199
- package/dist/templates/copilot/hooks/session-start.py +30 -26
- package/dist/templates/copilot/prompts/brainstorm.prompt.md +7 -160
- package/dist/templates/copilot/prompts/finish-work.prompt.md +11 -88
- package/dist/templates/copilot/prompts/record-session.prompt.md +4 -12
- package/dist/templates/copilot/prompts/start.prompt.md +12 -10
- package/dist/templates/dsh/DSH.md +2 -2
- package/dist/templates/extract.js +4 -0
- package/dist/templates/extract.js.map +1 -1
- package/dist/templates/kiro/agents/trellis.json +2 -2
- package/dist/templates/markdown/agents.md +14 -3
- package/dist/templates/markdown/spec/guides/cross-layer-thinking-guide.md.txt +9 -8
- package/dist/templates/markdown/spec/guides/cross-platform-thinking-guide.md.txt +1 -1
- package/dist/templates/markdown/workspace-index.md +0 -1
- package/dist/templates/omp/extensions/trellis/index.ts.txt +28 -17
- package/dist/templates/opencode/lib/session-utils.js +20 -25
- package/dist/templates/opencode/lib/trellis-context.js +4 -76
- package/dist/templates/opencode/plugins/inject-subagent-context.js +5 -4
- package/dist/templates/opencode/plugins/inject-workflow-state.js +14 -17
- package/dist/templates/shared-hooks/inject-shell-session-context.py +3 -3
- package/dist/templates/shared-hooks/inject-subagent-context.py +445 -67
- package/dist/templates/shared-hooks/inject-workflow-state.py +44 -36
- package/dist/templates/shared-hooks/session-start.py +21 -33
- package/dist/templates/trellis/agents/delegated-worktree-primary-agent.md +18 -0
- package/dist/templates/trellis/agents/teammate-profiles.json +8 -0
- package/dist/templates/trellis/agents/teammate.md +63 -0
- package/dist/templates/trellis/config.yaml +29 -38
- package/dist/templates/trellis/gitignore.txt +1 -0
- package/dist/templates/trellis/index.d.ts +8 -12
- package/dist/templates/trellis/index.d.ts.map +1 -1
- package/dist/templates/trellis/index.js +14 -25
- 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/__init__.py +0 -1
- package/dist/templates/trellis/scripts/common/active_task.py +136 -100
- package/dist/templates/trellis/scripts/common/config.py +7 -9
- package/dist/templates/trellis/scripts/common/git_context.py +1 -1
- package/dist/templates/trellis/scripts/common/io.py +19 -0
- package/dist/templates/trellis/scripts/common/paths.py +0 -1
- package/dist/templates/trellis/scripts/common/safe_commit.py +11 -90
- package/dist/templates/trellis/scripts/common/session_context.py +1 -8
- package/dist/templates/trellis/scripts/common/spec_match.py +1 -1
- package/dist/templates/trellis/scripts/common/task_context.py +152 -59
- package/dist/templates/trellis/scripts/common/task_continuity.py +598 -0
- package/dist/templates/trellis/scripts/common/task_store.py +70 -548
- package/dist/templates/trellis/scripts/common/task_utils.py +4 -98
- package/dist/templates/trellis/scripts/common/task_workflow.py +1096 -0
- package/dist/templates/trellis/scripts/common/tasks.py +5 -8
- package/dist/templates/trellis/scripts/common/workflow_phase.py +8 -7
- package/dist/templates/trellis/scripts/hooks/linear_sync.py +3 -3
- package/dist/templates/trellis/scripts/task.py +119 -377
- package/dist/templates/trellis/workflow.md +111 -706
- package/dist/utils/agent-refs.d.ts +5 -5
- package/dist/utils/agent-refs.js +6 -6
- package/dist/utils/file-writer.d.ts +3 -2
- package/dist/utils/file-writer.d.ts.map +1 -1
- package/dist/utils/file-writer.js +3 -2
- package/dist/utils/file-writer.js.map +1 -1
- package/dist/utils/managed-paths.d.ts +0 -7
- package/dist/utils/managed-paths.d.ts.map +1 -1
- package/dist/utils/managed-paths.js +0 -40
- package/dist/utils/managed-paths.js.map +1 -1
- package/dist/utils/manifest-prune.d.ts +2 -1
- package/dist/utils/manifest-prune.d.ts.map +1 -1
- package/dist/utils/manifest-prune.js +14 -16
- package/dist/utils/manifest-prune.js.map +1 -1
- package/dist/utils/uninstall-scrubbers.d.ts.map +1 -1
- package/dist/utils/uninstall-scrubbers.js +3 -3
- package/dist/utils/uninstall-scrubbers.js.map +1 -1
- package/dist/utils/workflow-resolver.d.ts +10 -16
- package/dist/utils/workflow-resolver.d.ts.map +1 -1
- package/dist/utils/workflow-resolver.js +25 -36
- package/dist/utils/workflow-resolver.js.map +1 -1
- package/package.json +2 -2
- package/dist/commands/channel/adapters/claude.d.ts.map +0 -1
- package/dist/commands/channel/adapters/claude.js.map +0 -1
- package/dist/commands/channel/adapters/codex.d.ts.map +0 -1
- package/dist/commands/channel/adapters/codex.js.map +0 -1
- package/dist/commands/channel/adapters/index.d.ts.map +0 -1
- package/dist/commands/channel/adapters/index.js.map +0 -1
- package/dist/commands/channel/adapters/types.d.ts.map +0 -1
- package/dist/commands/channel/adapters/types.js.map +0 -1
- package/dist/commands/channel/agent-loader.d.ts.map +0 -1
- package/dist/commands/channel/agent-loader.js.map +0 -1
- package/dist/commands/channel/context-loader.d.ts.map +0 -1
- package/dist/commands/channel/context-loader.js.map +0 -1
- package/dist/commands/channel/context-trust.d.ts.map +0 -1
- package/dist/commands/channel/context-trust.js.map +0 -1
- package/dist/commands/channel/context.d.ts +0 -16
- package/dist/commands/channel/context.d.ts.map +0 -1
- package/dist/commands/channel/context.js.map +0 -1
- package/dist/commands/channel/create.d.ts +0 -29
- package/dist/commands/channel/create.d.ts.map +0 -1
- package/dist/commands/channel/create.js +0 -47
- package/dist/commands/channel/create.js.map +0 -1
- package/dist/commands/channel/dev-parse-trace.d.ts.map +0 -1
- package/dist/commands/channel/dev-parse-trace.js.map +0 -1
- package/dist/commands/channel/guard.d.ts.map +0 -1
- package/dist/commands/channel/guard.js.map +0 -1
- package/dist/commands/channel/index.d.ts +0 -3
- package/dist/commands/channel/index.d.ts.map +0 -1
- package/dist/commands/channel/index.js.map +0 -1
- package/dist/commands/channel/interrupt.d.ts.map +0 -1
- package/dist/commands/channel/interrupt.js +0 -22
- package/dist/commands/channel/interrupt.js.map +0 -1
- package/dist/commands/channel/kill.d.ts +0 -7
- package/dist/commands/channel/kill.d.ts.map +0 -1
- package/dist/commands/channel/kill.js.map +0 -1
- package/dist/commands/channel/list.d.ts +0 -18
- package/dist/commands/channel/list.d.ts.map +0 -1
- package/dist/commands/channel/list.js.map +0 -1
- package/dist/commands/channel/messages.d.ts.map +0 -1
- package/dist/commands/channel/messages.js.map +0 -1
- package/dist/commands/channel/rm.d.ts +0 -27
- package/dist/commands/channel/rm.d.ts.map +0 -1
- package/dist/commands/channel/rm.js.map +0 -1
- package/dist/commands/channel/run.d.ts +0 -32
- package/dist/commands/channel/run.js +0 -141
- package/dist/commands/channel/run.js.map +0 -1
- package/dist/commands/channel/send.d.ts.map +0 -1
- package/dist/commands/channel/send.js.map +0 -1
- package/dist/commands/channel/spawn.d.ts.map +0 -1
- package/dist/commands/channel/spawn.js.map +0 -1
- package/dist/commands/channel/store/events.d.ts +0 -22
- package/dist/commands/channel/store/events.d.ts.map +0 -1
- package/dist/commands/channel/store/events.js.map +0 -1
- package/dist/commands/channel/store/filter.d.ts +0 -3
- package/dist/commands/channel/store/filter.d.ts.map +0 -1
- package/dist/commands/channel/store/filter.js +0 -2
- package/dist/commands/channel/store/filter.js.map +0 -1
- package/dist/commands/channel/store/lock.d.ts.map +0 -1
- package/dist/commands/channel/store/lock.js.map +0 -1
- package/dist/commands/channel/store/paths.d.ts.map +0 -1
- package/dist/commands/channel/store/paths.js.map +0 -1
- package/dist/commands/channel/store/schema.d.ts +0 -27
- package/dist/commands/channel/store/schema.d.ts.map +0 -1
- package/dist/commands/channel/store/schema.js +0 -34
- package/dist/commands/channel/store/schema.js.map +0 -1
- package/dist/commands/channel/store/thread-state.d.ts.map +0 -1
- package/dist/commands/channel/store/thread-state.js.map +0 -1
- package/dist/commands/channel/store/watch.d.ts +0 -19
- package/dist/commands/channel/store/watch.d.ts.map +0 -1
- package/dist/commands/channel/store/watch.js.map +0 -1
- package/dist/commands/channel/supervisor/idle.d.ts.map +0 -1
- package/dist/commands/channel/supervisor/idle.js.map +0 -1
- package/dist/commands/channel/supervisor/inbox.d.ts.map +0 -1
- package/dist/commands/channel/supervisor/inbox.js.map +0 -1
- package/dist/commands/channel/supervisor/shutdown.d.ts.map +0 -1
- package/dist/commands/channel/supervisor/shutdown.js.map +0 -1
- package/dist/commands/channel/supervisor/stdout.d.ts.map +0 -1
- package/dist/commands/channel/supervisor/stdout.js.map +0 -1
- package/dist/commands/channel/supervisor/turns.d.ts.map +0 -1
- package/dist/commands/channel/supervisor/turns.js.map +0 -1
- package/dist/commands/channel/supervisor/warning.d.ts.map +0 -1
- package/dist/commands/channel/supervisor/warning.js.map +0 -1
- package/dist/commands/channel/supervisor.d.ts.map +0 -1
- package/dist/commands/channel/supervisor.js.map +0 -1
- package/dist/commands/channel/text-body.d.ts +0 -13
- package/dist/commands/channel/text-body.d.ts.map +0 -1
- package/dist/commands/channel/text-body.js.map +0 -1
- package/dist/commands/channel/threads.d.ts +0 -39
- package/dist/commands/channel/threads.d.ts.map +0 -1
- package/dist/commands/channel/threads.js.map +0 -1
- package/dist/commands/channel/title.d.ts +0 -12
- package/dist/commands/channel/title.d.ts.map +0 -1
- package/dist/commands/channel/title.js +0 -24
- package/dist/commands/channel/title.js.map +0 -1
- package/dist/commands/channel/wait.d.ts.map +0 -1
- package/dist/commands/channel/wait.js.map +0 -1
- package/dist/commands/channel/workers.d.ts +0 -9
- package/dist/commands/channel/workers.d.ts.map +0 -1
- package/dist/commands/channel/workers.js +0 -31
- package/dist/commands/channel/workers.js.map +0 -1
- package/dist/templates/common/bundled-skills/trellis-channel/SKILL.md +0 -69
- package/dist/templates/common/bundled-skills/trellis-channel/references/command-reference.md +0 -549
- package/dist/templates/common/bundled-skills/trellis-channel/references/forum.md +0 -233
- package/dist/templates/common/bundled-skills/trellis-channel/references/progress-debugging.md +0 -237
- package/dist/templates/common/bundled-skills/trellis-channel/references/subnode-work.md +0 -222
- package/dist/templates/common/bundled-skills/trellis-channel/references/workers.md +0 -295
- package/dist/templates/common/bundled-skills/trellis-channel/references/workflows.md +0 -131
- package/dist/templates/common/bundled-skills/trellis-meta/references/local-architecture/multi-agent-channel.md +0 -70
- package/dist/templates/common/bundled-skills/trellis-research-record/SKILL.md +0 -14
- package/dist/templates/copilot/prompts/parallel.prompt.md +0 -204
- package/dist/templates/trellis/agents/check.md +0 -70
- package/dist/templates/trellis/agents/implement.md +0 -71
- package/dist/templates/trellis/agents/subnode.env +0 -4
- package/dist/templates/trellis/agents/subnode.md +0 -76
- package/dist/templates/trellis/scripts/common/context_projection.py +0 -508
- package/dist/templates/trellis/scripts/common/continuation_record.py +0 -450
- package/dist/templates/trellis/scripts/common/ownership_record.py +0 -439
- package/dist/templates/trellis/scripts/subnode_artifact.py +0 -735
- package/dist/templates/trellis/scripts/workspace_note.py +0 -126
- /package/dist/commands/{channel → teamwork}/adapters/types.js +0 -0
- /package/dist/commands/{channel → teamwork}/supervisor/idle.d.ts +0 -0
- /package/dist/commands/{channel → teamwork}/supervisor/idle.js +0 -0
- /package/dist/commands/{channel → teamwork}/supervisor/turns.d.ts +0 -0
- /package/dist/commands/{channel → teamwork}/supervisor/turns.js +0 -0
|
@@ -162,7 +162,7 @@ def _resolve_active_task(root: Path, input_data: dict):
|
|
|
162
162
|
|
|
163
163
|
def get_active_task(
|
|
164
164
|
root: Path, input_data: dict
|
|
165
|
-
) -> tuple[str, str, str] | None:
|
|
165
|
+
) -> tuple[str, str, str, str | None] | None:
|
|
166
166
|
"""Return active task data, a task-record error, or no task pointer.
|
|
167
167
|
|
|
168
168
|
``(task_id, "task_error", source)`` is distinct from ``None``: a session
|
|
@@ -171,9 +171,6 @@ def get_active_task(
|
|
|
171
171
|
prompt.
|
|
172
172
|
"""
|
|
173
173
|
active = _resolve_active_task(root, input_data)
|
|
174
|
-
if active.source_type == "unbound_ambiguous":
|
|
175
|
-
candidates = ", ".join(active.candidate_paths)
|
|
176
|
-
return candidates, "unbound_ambiguous", active.source
|
|
177
174
|
if not active.task_path:
|
|
178
175
|
return None
|
|
179
176
|
|
|
@@ -181,25 +178,34 @@ def get_active_task(
|
|
|
181
178
|
if not task_dir.is_absolute():
|
|
182
179
|
task_dir = root / task_dir
|
|
183
180
|
if active.stale:
|
|
184
|
-
return task_dir.name, f"stale_{active.source_type}", active.source
|
|
181
|
+
return task_dir.name, f"stale_{active.source_type}", active.source, None
|
|
185
182
|
|
|
186
183
|
task_json = task_dir / "task.json"
|
|
187
184
|
if not task_json.is_file():
|
|
188
|
-
return task_dir.name, "task_error", active.source
|
|
185
|
+
return task_dir.name, "task_error", active.source, None
|
|
189
186
|
try:
|
|
190
187
|
data = json.loads(task_json.read_text(encoding="utf-8"))
|
|
191
188
|
except (json.JSONDecodeError, OSError):
|
|
192
|
-
return task_dir.name, "task_error", active.source
|
|
189
|
+
return task_dir.name, "task_error", active.source, None
|
|
193
190
|
if not isinstance(data, dict):
|
|
194
|
-
return task_dir.name, "task_error", active.source
|
|
191
|
+
return task_dir.name, "task_error", active.source, None
|
|
195
192
|
|
|
196
193
|
task_id = data.get("id") or task_dir.name
|
|
197
194
|
status = data.get("status", "")
|
|
198
195
|
if not isinstance(status, str) or not status:
|
|
199
|
-
return task_dir.name, "task_error", active.source
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
196
|
+
return task_dir.name, "task_error", active.source, None
|
|
197
|
+
phase_workflow = data.get("meta", {}).get("task_workflow") if isinstance(data.get("meta"), dict) else None
|
|
198
|
+
if isinstance(phase_workflow, dict):
|
|
199
|
+
phase_id = phase_workflow.get("current_phase_id")
|
|
200
|
+
phases = phase_workflow.get("phases")
|
|
201
|
+
if phase_id is None:
|
|
202
|
+
routed = phase_workflow.get("phase_ids")
|
|
203
|
+
phase_id = routed[-1] if isinstance(routed, list) and routed else None
|
|
204
|
+
phase = phases.get(phase_id) if isinstance(phases, dict) and isinstance(phase_id, str) else None
|
|
205
|
+
if isinstance(phase_id, str) and isinstance(phase, dict):
|
|
206
|
+
phase_status = phase.get("status")
|
|
207
|
+
return task_id, phase_id, active.source, phase_status if isinstance(phase_status, str) else None
|
|
208
|
+
return task_id, status, active.source, None
|
|
203
209
|
|
|
204
210
|
|
|
205
211
|
# ---------------------------------------------------------------------------
|
|
@@ -317,14 +323,13 @@ def prompt_has_skip_keyword(prompt: str, keyword: str) -> bool:
|
|
|
317
323
|
def _resolve_codex_dispatch_mode(config: dict) -> str:
|
|
318
324
|
"""Normalize `codex.dispatch_mode` from .trellis/config.yaml to "auto" or "inline".
|
|
319
325
|
|
|
320
|
-
Defaults to `
|
|
321
|
-
|
|
322
|
-
(including invalid ones) falls back to `inline`
|
|
326
|
+
Defaults to `auto`. The legacy `sub-agent` value is an alias for `auto`.
|
|
327
|
+
Any other explicit value (including invalid ones) falls back to `inline`
|
|
323
328
|
without per-turn warnings. Shared by `_codex_mode_banner` (the per-turn
|
|
324
329
|
banner) and `resolve_breadcrumb_key` (the breadcrumb tag key) so the two
|
|
325
330
|
stay in lockstep.
|
|
326
331
|
"""
|
|
327
|
-
mode = "
|
|
332
|
+
mode = "auto"
|
|
328
333
|
if isinstance(config, dict):
|
|
329
334
|
codex_cfg = config.get("codex")
|
|
330
335
|
if isinstance(codex_cfg, dict):
|
|
@@ -342,16 +347,16 @@ def _codex_mode_banner(config: dict) -> str:
|
|
|
342
347
|
"""Emit a `<codex-mode>` banner for the additionalContext payload.
|
|
343
348
|
|
|
344
349
|
Reads `codex.dispatch_mode` from .trellis/config.yaml; defaults to
|
|
345
|
-
`
|
|
346
|
-
explicitly dispatches Trellis sub-agents using native Codex context
|
|
350
|
+
`auto`, which dispatches Trellis sub-agents using native Codex context
|
|
347
351
|
injection with a child-side fallback. This does not rely on inherited
|
|
348
352
|
parent transcripts: `fork_turns` remains caller-controlled, and
|
|
349
353
|
fresh-history sub-agents still receive their explicit delegated task and
|
|
350
|
-
inherited session configuration.
|
|
351
|
-
for `auto`. Invalid explicit values
|
|
352
|
-
warnings. The banner makes the
|
|
353
|
-
|
|
354
|
-
which
|
|
354
|
+
inherited session configuration. `inline` is an explicit opt-out; the
|
|
355
|
+
legacy `sub-agent` value is an alias for `auto`. Invalid explicit values
|
|
356
|
+
fall back to `inline` without per-turn warnings. The banner makes the
|
|
357
|
+
active mode explicit to Codex AI per turn, complementing the workflow-state
|
|
358
|
+
body which is per-status. Mode tells AI which dispatch protocol to follow;
|
|
359
|
+
workflow-state tells AI what step it's at.
|
|
355
360
|
"""
|
|
356
361
|
mode = _resolve_codex_dispatch_mode(config)
|
|
357
362
|
if mode == "auto":
|
|
@@ -373,12 +378,12 @@ def resolve_breadcrumb_key(
|
|
|
373
378
|
) -> str:
|
|
374
379
|
"""Pick the breadcrumb tag key based on Codex dispatch_mode.
|
|
375
380
|
|
|
376
|
-
Codex defaults to ``
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
381
|
+
Codex defaults to ``auto`` and therefore uses the ordinary ``<status>``
|
|
382
|
+
breadcrumb for native SubagentStart dispatch with child-side fallback;
|
|
383
|
+
it does not depend on an inherited parent transcript. ``inline`` selects
|
|
384
|
+
the parallel ``<status>-inline`` tag; ``sub-agent`` remains an alias for
|
|
385
|
+
``auto``. Invalid explicit values fall back to inline without per-turn
|
|
386
|
+
warnings.
|
|
382
387
|
|
|
383
388
|
Non-codex platforms return the plain status unchanged.
|
|
384
389
|
"""
|
|
@@ -394,6 +399,7 @@ def build_breadcrumb(
|
|
|
394
399
|
templates: dict[str, str],
|
|
395
400
|
source: str | None = None,
|
|
396
401
|
breadcrumb_key: str | None = None,
|
|
402
|
+
phase_status: str | None = None,
|
|
397
403
|
) -> str:
|
|
398
404
|
"""Build the <workflow-state>...</workflow-state> block.
|
|
399
405
|
|
|
@@ -408,10 +414,12 @@ def build_breadcrumb(
|
|
|
408
414
|
body = templates.get(status)
|
|
409
415
|
if body is None:
|
|
410
416
|
body = "Refer to workflow.md for current step."
|
|
411
|
-
if
|
|
412
|
-
header = f"Status: {status}
|
|
417
|
+
if task_id is None:
|
|
418
|
+
header = f"Status: {status}"
|
|
419
|
+
elif phase_status:
|
|
420
|
+
header = f"Task: {task_id}\nPhase: {status} ({phase_status})"
|
|
413
421
|
else:
|
|
414
|
-
header = f"
|
|
422
|
+
header = f"Task: {task_id} ({status})"
|
|
415
423
|
return f"<workflow-state>\n{header}\n{body}\n</workflow-state>"
|
|
416
424
|
|
|
417
425
|
|
|
@@ -473,18 +481,18 @@ def main() -> int:
|
|
|
473
481
|
platform = _detect_platform(data)
|
|
474
482
|
task = get_active_task(root, data)
|
|
475
483
|
if task is None:
|
|
476
|
-
# No active task — still emit a breadcrumb
|
|
477
|
-
# trellis-brainstorm + task.py create when user describes real work.
|
|
484
|
+
# No active task — still emit a breadcrumb for classifying new work.
|
|
478
485
|
no_task_key = resolve_breadcrumb_key("no_task", platform, config)
|
|
479
486
|
breadcrumb = build_breadcrumb(
|
|
480
487
|
None, "no_task", templates, breadcrumb_key=no_task_key
|
|
481
488
|
)
|
|
482
489
|
else:
|
|
483
|
-
task_id, status, source = task
|
|
490
|
+
task_id, status, source, phase_status = task
|
|
484
491
|
status_key = resolve_breadcrumb_key(status, platform, config)
|
|
485
492
|
source_for_breadcrumb = None if platform == "codex" else source
|
|
486
493
|
breadcrumb = build_breadcrumb(
|
|
487
|
-
task_id, status, templates, source_for_breadcrumb, breadcrumb_key=status_key
|
|
494
|
+
task_id, status, templates, source_for_breadcrumb, breadcrumb_key=status_key,
|
|
495
|
+
phase_status=phase_status,
|
|
488
496
|
)
|
|
489
497
|
if platform == "codex":
|
|
490
498
|
parts: list[str] = []
|
|
@@ -462,12 +462,9 @@ def _get_task_status(trellis_dir: Path, input_data: dict) -> str:
|
|
|
462
462
|
return (
|
|
463
463
|
f"Status: COMPLETED\nTask: {task_title}\n"
|
|
464
464
|
f"Present: {present_line}\n"
|
|
465
|
-
"Next-Action:
|
|
465
|
+
"Next-Action: Task lifecycle is complete. Start another task or end the session; finish-work only records the session journal."
|
|
466
466
|
)
|
|
467
467
|
|
|
468
|
-
has_prd = (task_dir / "prd.md").is_file()
|
|
469
|
-
has_design = (task_dir / "design.md").is_file()
|
|
470
|
-
has_implement_plan = (task_dir / "implement.md").is_file()
|
|
471
468
|
implement_jsonl = task_dir / "implement.jsonl"
|
|
472
469
|
check_jsonl = task_dir / "check.jsonl"
|
|
473
470
|
jsonl_ready = (
|
|
@@ -475,31 +472,13 @@ def _get_task_status(trellis_dir: Path, input_data: dict) -> str:
|
|
|
475
472
|
and (not check_jsonl.is_file() or _has_curated_jsonl_entry(check_jsonl))
|
|
476
473
|
)
|
|
477
474
|
|
|
478
|
-
if task_status == "planning" and not has_prd:
|
|
479
|
-
return (
|
|
480
|
-
f"Status: PLANNING\nTask: {task_title}\n"
|
|
481
|
-
f"Present: {present_line}\n"
|
|
482
|
-
"Next-Action: Load `trellis-brainstorm` and write `prd.md`. Stay in planning."
|
|
483
|
-
)
|
|
484
|
-
|
|
485
475
|
if task_status == "planning":
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
("implement.md", has_implement_plan),
|
|
490
|
-
)
|
|
491
|
-
if not exists
|
|
476
|
+
next_bits = [
|
|
477
|
+
"Follow the current per-turn workflow-state; task lifecycle status and artifact presence do not identify the business phase",
|
|
478
|
+
"If no phase route is initialized, load `trellis-goal-exploration-and-requirements` and confirm the requirements baseline before initializing the route",
|
|
492
479
|
]
|
|
493
|
-
next_bits: list[str] = []
|
|
494
|
-
if missing_complex:
|
|
495
|
-
next_bits.append(
|
|
496
|
-
"Lightweight task can request start review with PRD-only; "
|
|
497
|
-
f"complex task must add {', '.join(missing_complex)} before start"
|
|
498
|
-
)
|
|
499
|
-
else:
|
|
500
|
-
next_bits.append("Planning artifacts are present; ask for review before `task.py start`")
|
|
501
480
|
if not jsonl_ready:
|
|
502
|
-
next_bits.append("curate
|
|
481
|
+
next_bits.append("curate task context manifests only when a dispatched agent needs them")
|
|
503
482
|
return (
|
|
504
483
|
f"Status: PLANNING\nTask: {task_title}\n"
|
|
505
484
|
f"Present: {present_line}\n"
|
|
@@ -509,7 +488,7 @@ def _get_task_status(trellis_dir: Path, input_data: dict) -> str:
|
|
|
509
488
|
return (
|
|
510
489
|
f"Status: {str(task_status).upper()}\nTask: {task_title}\n"
|
|
511
490
|
f"Present: {present_line}\n"
|
|
512
|
-
"Next-Action: Follow the matching per-turn workflow-state. "
|
|
491
|
+
"Next-Action: Follow the matching per-turn workflow-state; task lifecycle status does not identify the business phase. "
|
|
513
492
|
"Implementation/check context order is jsonl entries -> `prd.md` -> `design.md if present` -> `implement.md if present`."
|
|
514
493
|
)
|
|
515
494
|
|
|
@@ -764,14 +743,23 @@ def _extract_range(content: str, start_header: str, end_header: str) -> str:
|
|
|
764
743
|
lines = content.splitlines()
|
|
765
744
|
start: int | None = None
|
|
766
745
|
end: int = len(lines)
|
|
767
|
-
|
|
768
|
-
|
|
746
|
+
start_matches = {f"## {start_header}", "## 阶段索引", "## Phase Index"}
|
|
747
|
+
end_matches = {
|
|
748
|
+
f"## {end_header}",
|
|
749
|
+
f"### {end_header}",
|
|
750
|
+
}
|
|
751
|
+
phase_titles = ("目标探索与需求核对阶段", "Goal Exploration and Requirements Confirmation Phase")
|
|
769
752
|
for i, line in enumerate(lines):
|
|
770
753
|
stripped = line.strip()
|
|
771
|
-
if start is None and stripped
|
|
754
|
+
if start is None and stripped in start_matches:
|
|
772
755
|
start = i
|
|
773
756
|
continue
|
|
774
|
-
|
|
757
|
+
heading = stripped.lstrip("#").strip()
|
|
758
|
+
is_phase_heading = stripped.startswith(("## ", "### ")) and any(
|
|
759
|
+
heading == title or heading.endswith((f":{title}", f": {title}"))
|
|
760
|
+
for title in phase_titles
|
|
761
|
+
)
|
|
762
|
+
if start is not None and (stripped in end_matches or is_phase_heading):
|
|
775
763
|
end = i
|
|
776
764
|
break
|
|
777
765
|
if start is None:
|
|
@@ -829,11 +817,11 @@ def _build_workflow_overview(workflow_path: Path) -> str:
|
|
|
829
817
|
|
|
830
818
|
out_lines = [
|
|
831
819
|
"# Development Workflow - Session Summary",
|
|
832
|
-
"Full guide: .trellis/workflow.md.
|
|
820
|
+
"Full guide: .trellis/workflow.md. Phase detail: load the Skill named in the active phase breadcrumb.",
|
|
833
821
|
"",
|
|
834
822
|
]
|
|
835
823
|
|
|
836
|
-
phases = _extract_range(content, "
|
|
824
|
+
phases = _extract_range(content, "阶段索引", "目标探索与需求核对阶段")
|
|
837
825
|
if phases:
|
|
838
826
|
out_lines.append(_strip_breadcrumb_tag_blocks(phases).rstrip())
|
|
839
827
|
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: delegated-worktree-primary-agent
|
|
3
|
+
description: Executes an authorized Trellis child task in a Paseo worktree.
|
|
4
|
+
labels: [trellis, delegated-worktree]
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# Delegated worktree primary agent
|
|
8
|
+
|
|
9
|
+
Read the repository instructions and applicable specs before editing. The child
|
|
10
|
+
task's `prd.md` is the sole task-specific implementation contract. Work within
|
|
11
|
+
that contract and the supplied worktree and branch, using the smallest complete
|
|
12
|
+
change that satisfies it. Preserve unrelated changes.
|
|
13
|
+
|
|
14
|
+
Do not change Trellis task lifecycle or phase state, accept task results, or
|
|
15
|
+
start another delegated run. Verify the changes with relevant project checks
|
|
16
|
+
and report the files changed, evidence, and any remaining limitation. Stop and
|
|
17
|
+
report if the contract conflicts with repository instructions or requires a
|
|
18
|
+
materially different scope.
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: teammate
|
|
3
|
+
description: Provider-neutral Trellis evidence and review role.
|
|
4
|
+
labels: [trellis, teammate]
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# Teammate (Teamwork runtime)
|
|
8
|
+
|
|
9
|
+
You are a bounded Trellis teammate assigned one frozen teammate assignment. Produce
|
|
10
|
+
independently reviewable investigation, research, review, verification, or
|
|
11
|
+
evidence. The coordinator owns dispatch, retry, acceptance, and final
|
|
12
|
+
disposition.
|
|
13
|
+
|
|
14
|
+
Read the immutable brief before substantive work. For the assigned teammate
|
|
15
|
+
assignment,
|
|
16
|
+
the paths are:
|
|
17
|
+
|
|
18
|
+
```text
|
|
19
|
+
.trellis/tasks/<task>/teammates/<batch>/<assignment>/brief.json
|
|
20
|
+
.trellis/tasks/<task>/teammates/<batch>/<assignment>/queue.json
|
|
21
|
+
.trellis/tasks/<task>/teammates/<batch>/<assignment>/attempts/<attempt-id>/claim.json
|
|
22
|
+
.trellis/tasks/<task>/teammates/<batch>/<assignment>/attempts/<attempt-id>/worklog.md
|
|
23
|
+
.trellis/tasks/<task>/teammates/<batch>/<assignment>/attempts/<attempt-id>/report.json
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
Read the brief and claim, append material progress to the assigned worklog,
|
|
27
|
+
and create exactly one pending report for this attempt using this JSON shape:
|
|
28
|
+
|
|
29
|
+
```json
|
|
30
|
+
{
|
|
31
|
+
"schema_version": 1,
|
|
32
|
+
"task_id": "<task-id>",
|
|
33
|
+
"batch_id": "<batch-id>",
|
|
34
|
+
"assignment_id": "<assignment-id>",
|
|
35
|
+
"attempt_id": "<attempt-id>",
|
|
36
|
+
"teammate_id": "<teammate-id>",
|
|
37
|
+
"status": "complete",
|
|
38
|
+
"source_digest": "<source_digest from the brief>",
|
|
39
|
+
"evidence": [
|
|
40
|
+
{
|
|
41
|
+
"id": "<evidence-id>",
|
|
42
|
+
"locator": "<path or symbol>",
|
|
43
|
+
"summary": "<finding>"
|
|
44
|
+
}
|
|
45
|
+
]
|
|
46
|
+
}
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
Use only the explicit context paths frozen in the brief. Do not read or use
|
|
50
|
+
ambient personal, session, or cross-project memory, including memory tools or
|
|
51
|
+
environment-provided memory. If the host exposes such memory and cannot isolate
|
|
52
|
+
it, stop and report the host-boundary failure through the assigned failure
|
|
53
|
+
protocol.
|
|
54
|
+
|
|
55
|
+
Only submit `status: complete` when every acceptance criterion is met and at
|
|
56
|
+
least one evidence item supports the result. If the work cannot be completed,
|
|
57
|
+
record the blocker in the worklog and end the attempt through its failure
|
|
58
|
+
protocol without creating a misleading completion report. The coordinator
|
|
59
|
+
owns the queue and final disposition. Do not change the brief, task state,
|
|
60
|
+
product source, protected configuration, tests, or Git state. Write only the
|
|
61
|
+
current attempt artifacts. Do not create another teammate, delegate through a
|
|
62
|
+
provider-native mechanism, retry yourself, or claim that a report has been
|
|
63
|
+
accepted.
|
|
@@ -18,11 +18,9 @@ max_journal_lines: 2000
|
|
|
18
18
|
# Session Auto-Commit
|
|
19
19
|
#-------------------------------------------------------------------------------
|
|
20
20
|
|
|
21
|
-
# Auto-commit behavior for session journal
|
|
22
|
-
# - true (default):
|
|
23
|
-
#
|
|
24
|
-
# - false: scripts do not touch git. Files (journal-*.md, task archive moves)
|
|
25
|
-
# are still written to disk; you decide whether to git add / commit.
|
|
21
|
+
# Auto-commit behavior for session journal updates.
|
|
22
|
+
# - true (default): add_session.py auto-stages and commits journal changes.
|
|
23
|
+
# - false: the script writes journal files without touching git.
|
|
26
24
|
#
|
|
27
25
|
# Use `false` if your project's .gitignore intentionally excludes `.trellis/`
|
|
28
26
|
# and you want session data kept local-only, or if you prefer to review
|
|
@@ -45,12 +43,10 @@ max_journal_lines: 2000
|
|
|
45
43
|
# - "echo 'Task created'"
|
|
46
44
|
# after_start:
|
|
47
45
|
# - "echo 'Task started'"
|
|
48
|
-
# after_replan:
|
|
49
|
-
# - "echo 'Task returned to planning'"
|
|
50
46
|
# after_finish:
|
|
51
47
|
# - "echo 'Task finished'"
|
|
52
|
-
#
|
|
53
|
-
# - "echo 'Task
|
|
48
|
+
# after_complete:
|
|
49
|
+
# - "echo 'Task completed'"
|
|
54
50
|
|
|
55
51
|
#-------------------------------------------------------------------------------
|
|
56
52
|
# Monorepo / Packages
|
|
@@ -94,55 +90,50 @@ max_journal_lines: 2000
|
|
|
94
90
|
# default_workflow: native
|
|
95
91
|
|
|
96
92
|
#-------------------------------------------------------------------------------
|
|
97
|
-
#
|
|
93
|
+
# Teamwork teammate process guard
|
|
98
94
|
#-------------------------------------------------------------------------------
|
|
99
|
-
# Default safeguards for `trellis
|
|
100
|
-
# at spawn time (cleans expired idle
|
|
101
|
-
# budget) and inside each supervisor (self-terminates a
|
|
95
|
+
# Default safeguards for `trellis teamwork spawn` teammates. The guard runs
|
|
96
|
+
# at spawn time (cleans expired idle teammates, then enforces the live-teammate
|
|
97
|
+
# budget) and inside each supervisor (self-terminates a teammate that stays
|
|
102
98
|
# continuously idle past `idle_timeout`).
|
|
103
99
|
#
|
|
104
|
-
# Precedence: CLI flag > env var (
|
|
105
|
-
#
|
|
106
|
-
# subnodes, `channel.worker_guard` otherwise) > built-in default.
|
|
100
|
+
# Precedence: CLI flag > env var (TRELLIS_TEAMWORK_IDLE_TIMEOUT /
|
|
101
|
+
# TRELLIS_TEAMWORK_MAX_LIVE_TEAMMATES) > this config > built-in default.
|
|
107
102
|
#
|
|
108
|
-
# `idle_timeout: 0` disables idle cleanup (
|
|
103
|
+
# `idle_timeout: 0` disables idle cleanup (teammates can sit idle forever
|
|
109
104
|
# unless explicitly killed or given `--timeout`).
|
|
110
|
-
# `
|
|
105
|
+
# `max_live_teammates: 0` disables the spawn-time budget check.
|
|
111
106
|
#
|
|
112
107
|
# `trusted_context_dirs` extends the `--file`/`--jsonl`/`--agent` containment
|
|
113
|
-
# check beyond the
|
|
108
|
+
# check beyond the teammate cwd — useful when `.trellis/tasks` or
|
|
114
109
|
# `.trellis/workspace` is a symlink to an external directory. Realpaths under
|
|
115
110
|
# any listed dir are accepted in addition to cwd.
|
|
116
111
|
# `auto_trust_trellis_symlinks: false` disables the narrow auto-trust of
|
|
117
112
|
# `.trellis/tasks` / `.trellis/workspace` when either is itself a top-level
|
|
118
113
|
# symlink (auto-trust is on by default).
|
|
119
114
|
#
|
|
120
|
-
|
|
121
|
-
|
|
115
|
+
teamwork:
|
|
116
|
+
teammate_guard:
|
|
122
117
|
idle_timeout: 5m
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
# flags still override these values; ordinary workers use worker_guard.
|
|
126
|
-
subnode:
|
|
127
|
-
idle_timeout: 5m
|
|
128
|
-
max_live_workers: 8
|
|
129
|
-
timeout: 30m
|
|
130
|
-
warn_before: 5m
|
|
118
|
+
max_live_teammates: 6
|
|
119
|
+
non_batch_reserved: 0
|
|
131
120
|
# trusted_context_dirs:
|
|
132
121
|
# - /work/user/trellis_workspace
|
|
133
122
|
# auto_trust_trellis_symlinks: false
|
|
123
|
+
teammate:
|
|
124
|
+
max_concurrency: 1
|
|
134
125
|
|
|
135
126
|
#-------------------------------------------------------------------------------
|
|
136
127
|
# Codex (dispatch behavior)
|
|
137
128
|
#-------------------------------------------------------------------------------
|
|
138
|
-
# Codex-only knob; other platforms ignore it.
|
|
139
|
-
#
|
|
140
|
-
#
|
|
141
|
-
#
|
|
142
|
-
#
|
|
143
|
-
#
|
|
144
|
-
#
|
|
145
|
-
#
|
|
129
|
+
# Codex-only knob; other platforms ignore it. Default ("auto") dispatches
|
|
130
|
+
# trellis-implement / trellis-check / trellis-research sub-agents. This does
|
|
131
|
+
# not rely on inherited parent transcripts: `fork_turns` remains
|
|
132
|
+
# caller-controlled, while Codex's native SubagentStart hook injects task
|
|
133
|
+
# context when trusted and child-side loading remains the fallback when it is
|
|
134
|
+
# unavailable. Set to "inline" only to keep implementation and checks in the
|
|
135
|
+
# main session. "sub-agent" remains a backwards-compatible alias for "auto".
|
|
136
|
+
# Invalid explicit values safely use inline mode.
|
|
146
137
|
#
|
|
147
138
|
# In "auto" mode, dispatched sub-agents inherit the main session's model
|
|
148
139
|
# unless you pin one. To use a cheaper/faster model for implement/check/
|
|
@@ -152,7 +143,7 @@ channel:
|
|
|
152
143
|
# `trellis update` preserves your edits across regeneration.
|
|
153
144
|
#
|
|
154
145
|
# codex:
|
|
155
|
-
# dispatch_mode: auto #
|
|
146
|
+
# dispatch_mode: auto # or "inline"; legacy alias: "sub-agent"
|
|
156
147
|
|
|
157
148
|
#-------------------------------------------------------------------------------
|
|
158
149
|
# Sub-agent context injection limits
|
|
@@ -10,8 +10,8 @@
|
|
|
10
10
|
* │ ├── __init__.py
|
|
11
11
|
* │ ├── common/ # Shared utilities (Python)
|
|
12
12
|
* │ └── *.py # Main scripts (Python)
|
|
13
|
-
* ├── agents/ #
|
|
14
|
-
* │ └── *.md
|
|
13
|
+
* ├── agents/ # Teamwork runtime agent definitions
|
|
14
|
+
* │ └── *.md # Loaded by `trellis teamwork spawn --agent <name>`
|
|
15
15
|
* ├── scripts-shell-archive/ # Archived shell scripts (for reference)
|
|
16
16
|
* ├── workflow.md # Workflow guide
|
|
17
17
|
* ├── config.yaml # Trellis configuration
|
|
@@ -34,11 +34,10 @@ export declare const commonGit: string;
|
|
|
34
34
|
export declare const commonTypes: string;
|
|
35
35
|
export declare const commonTasks: string;
|
|
36
36
|
export declare const commonTaskContext: string;
|
|
37
|
-
export declare const commonContextProjection: string;
|
|
38
37
|
export declare const commonTaskStore: string;
|
|
38
|
+
export declare const commonTaskWorkflow: string;
|
|
39
|
+
export declare const commonTaskContinuity: string;
|
|
39
40
|
export declare const commonSessionContext: string;
|
|
40
|
-
export declare const commonContinuationRecord: string;
|
|
41
|
-
export declare const commonOwnershipRecord: string;
|
|
42
41
|
export declare const commonPackagesContext: string;
|
|
43
42
|
export declare const commonWorkflowPhase: string;
|
|
44
43
|
export declare const commonWorkflowSelection: string;
|
|
@@ -51,22 +50,19 @@ export declare const initDeveloperScript: string;
|
|
|
51
50
|
export declare const taskScript: string;
|
|
52
51
|
export declare const getContextScript: string;
|
|
53
52
|
export declare const addSessionScript: string;
|
|
54
|
-
export declare const subnodeArtifactScript: string;
|
|
55
|
-
export declare const workspaceNoteScript: string;
|
|
56
53
|
export declare const workflowMdTemplate: string;
|
|
57
54
|
export declare const configYamlTemplate: string;
|
|
58
55
|
export declare const gitignoreTemplate: string;
|
|
59
56
|
export declare const gitattributesTemplate: string;
|
|
60
|
-
export declare const
|
|
61
|
-
export declare const
|
|
62
|
-
export declare const
|
|
63
|
-
export declare const subnodeEnvTemplate: string;
|
|
57
|
+
export declare const teammateAgentTemplate: string;
|
|
58
|
+
export declare const delegatedWorktreeAgentTemplate: string;
|
|
59
|
+
export declare const teammateProfilesTemplate: string;
|
|
64
60
|
/**
|
|
65
61
|
* Get all script templates as a map of relative path to content
|
|
66
62
|
*/
|
|
67
63
|
export declare function getAllScripts(): Map<string, string>;
|
|
68
64
|
/**
|
|
69
|
-
* Get
|
|
65
|
+
* Get project agent role assets as a map of relative path
|
|
70
66
|
* (under `.trellis/agents/`) to content.
|
|
71
67
|
*
|
|
72
68
|
* Consumed by `trellis init` (to dispatch on first install) and by
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/templates/trellis/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAcH,eAAO,MAAM,WAAW,QAAsC,CAAC;AAG/D,eAAO,MAAM,UAAU,QAA6C,CAAC;AACrE,eAAO,MAAM,WAAW,QAA0C,CAAC;AACnE,eAAO,MAAM,eAAe,QAA8C,CAAC;AAC3E,eAAO,MAAM,gBAAgB,QAAgD,CAAC;AAC9E,eAAO,MAAM,eAAe,QAA+C,CAAC;AAC5E,eAAO,MAAM,eAAe,QAA+C,CAAC;AAC5E,eAAO,MAAM,gBAAgB,QAAgD,CAAC;AAC9E,eAAO,MAAM,gBAAgB,QAAgD,CAAC;AAC9E,eAAO,MAAM,YAAY,QAA2C,CAAC;AACrE,eAAO,MAAM,QAAQ,QAAuC,CAAC;AAC7D,eAAO,MAAM,SAAS,QAAwC,CAAC;AAC/D,eAAO,MAAM,SAAS,QAAwC,CAAC;AAC/D,eAAO,MAAM,WAAW,QAA0C,CAAC;AACnE,eAAO,MAAM,WAAW,QAA0C,CAAC;AACnE,eAAO,MAAM,iBAAiB,QAAiD,CAAC;AAChF,eAAO,MAAM,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/templates/trellis/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAcH,eAAO,MAAM,WAAW,QAAsC,CAAC;AAG/D,eAAO,MAAM,UAAU,QAA6C,CAAC;AACrE,eAAO,MAAM,WAAW,QAA0C,CAAC;AACnE,eAAO,MAAM,eAAe,QAA8C,CAAC;AAC3E,eAAO,MAAM,gBAAgB,QAAgD,CAAC;AAC9E,eAAO,MAAM,eAAe,QAA+C,CAAC;AAC5E,eAAO,MAAM,eAAe,QAA+C,CAAC;AAC5E,eAAO,MAAM,gBAAgB,QAAgD,CAAC;AAC9E,eAAO,MAAM,gBAAgB,QAAgD,CAAC;AAC9E,eAAO,MAAM,YAAY,QAA2C,CAAC;AACrE,eAAO,MAAM,QAAQ,QAAuC,CAAC;AAC7D,eAAO,MAAM,SAAS,QAAwC,CAAC;AAC/D,eAAO,MAAM,SAAS,QAAwC,CAAC;AAC/D,eAAO,MAAM,WAAW,QAA0C,CAAC;AACnE,eAAO,MAAM,WAAW,QAA0C,CAAC;AACnE,eAAO,MAAM,iBAAiB,QAAiD,CAAC;AAChF,eAAO,MAAM,eAAe,QAA+C,CAAC;AAC5E,eAAO,MAAM,kBAAkB,QAE9B,CAAC;AACF,eAAO,MAAM,oBAAoB,QAEhC,CAAC;AACF,eAAO,MAAM,oBAAoB,QAEhC,CAAC;AACF,eAAO,MAAM,qBAAqB,QAEjC,CAAC;AACF,eAAO,MAAM,mBAAmB,QAE/B,CAAC;AACF,eAAO,MAAM,uBAAuB,QAEnC,CAAC;AACF,eAAO,MAAM,mBAAmB,QAE/B,CAAC;AACF,eAAO,MAAM,eAAe,QAA+C,CAAC;AAC5E,eAAO,MAAM,gBAAgB,QAAgD,CAAC;AAC9E,eAAO,MAAM,gBAAgB,QAAgD,CAAC;AAG9E,eAAO,MAAM,kBAAkB,QAA2C,CAAC;AAC3E,eAAO,MAAM,mBAAmB,QAA4C,CAAC;AAC7E,eAAO,MAAM,UAAU,QAAkC,CAAC;AAC1D,eAAO,MAAM,gBAAgB,QAAyC,CAAC;AACvE,eAAO,MAAM,gBAAgB,QAAyC,CAAC;AAGvE,eAAO,MAAM,kBAAkB,QAA8B,CAAC;AAC9D,eAAO,MAAM,kBAAkB,QAA8B,CAAC;AAC9D,eAAO,MAAM,iBAAiB,QAAgC,CAAC;AAC/D,eAAO,MAAM,qBAAqB,QAAoC,CAAC;AAGvE,eAAO,MAAM,qBAAqB,QAAqC,CAAC;AACxE,eAAO,MAAM,8BAA8B,QAE1C,CAAC;AACF,eAAO,MAAM,wBAAwB,QAEpC,CAAC;AAEF;;GAEG;AACH,wBAAgB,aAAa,IAAI,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,CA0CnD;AAED;;;;;;;GAOG;AACH,wBAAgB,YAAY,IAAI,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,CASlD"}
|