@xulthekl/team-flow 0.22.4
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/.agents/plugins/marketplace.json +20 -0
- package/.agents/skills +1 -0
- package/.claude/always/phase-guard.md +3 -0
- package/.claude-plugin/marketplace.json +20 -0
- package/.claude-plugin/plugin.json +31 -0
- package/.codex-plugin/plugin.json +45 -0
- package/.codexignore +6 -0
- package/.cursor-plugin/marketplace.json +17 -0
- package/.cursor-plugin/plugin.json +31 -0
- package/.github/copilot-instructions.md +15 -0
- package/.github/dependabot.yml +10 -0
- package/.github/plugin/marketplace.json +42 -0
- package/.github/workflows/ci.yml +98 -0
- package/.github/workflows/hol-plugin-scanner.yml +17 -0
- package/.opencode/INSTALL.md +61 -0
- package/.opencode/plugins/team-flow.js +70 -0
- package/AGENTS.md +280 -0
- package/CHANGELOG.md +635 -0
- package/CONTRIBUTING.md +115 -0
- package/GEMINI.md +14 -0
- package/HANDOFF.md +219 -0
- package/INSTALL.md +810 -0
- package/LICENSE +21 -0
- package/README.md +185 -0
- package/SECURITY.md +37 -0
- package/agents/bug-investigator.md +180 -0
- package/agents/change-split-auditor.md +257 -0
- package/agents/code-reviewer.md +171 -0
- package/agents/cross-change-consistency-checker.md +215 -0
- package/agents/prd-completeness-reviewer.md +197 -0
- package/agents/prototype-builder.md +230 -0
- package/agents/prototype-env-scout.md +156 -0
- package/agents/prototype-reviewer.md +226 -0
- package/assets/icon.svg +6 -0
- package/dist/index.d.ts +13 -0
- package/dist/index.js +5 -0
- package/dist/parsing/change-parser.d.ts +12 -0
- package/dist/parsing/change-parser.js +54 -0
- package/dist/parsing/requirement-blocks.d.ts +31 -0
- package/dist/parsing/requirement-blocks.js +192 -0
- package/dist/schema/base.d.ts +7 -0
- package/dist/schema/base.js +1 -0
- package/dist/schema/change.d.ts +25 -0
- package/dist/schema/change.js +1 -0
- package/dist/schema/index.d.ts +3 -0
- package/dist/schema/index.js +1 -0
- package/dist/schema/spec.d.ts +11 -0
- package/dist/schema/spec.js +1 -0
- package/dist/validation/constants.d.ts +42 -0
- package/dist/validation/constants.js +42 -0
- package/dist/validation/tokenizer.d.ts +17 -0
- package/dist/validation/tokenizer.js +173 -0
- package/dist/validation/types.d.ts +40 -0
- package/dist/validation/types.js +1 -0
- package/dist/validation/validator.d.ts +21 -0
- package/dist/validation/validator.js +489 -0
- package/docs/README_en.md +358 -0
- package/docs/artifact-contract.md +96 -0
- package/docs/decision-points.md +88 -0
- package/docs/e2e-integration-design.md +207 -0
- package/docs/examples/README.md +25 -0
- package/docs/examples/add-dark-mode/README.md +13 -0
- package/docs/examples/add-dark-mode/design.md +49 -0
- package/docs/examples/add-dark-mode/execution-contract.md +56 -0
- package/docs/examples/add-dark-mode/proposal.md +46 -0
- package/docs/examples/add-dark-mode/specs/ui-theme/spec.md +35 -0
- package/docs/examples/add-dark-mode/tasks.md +26 -0
- package/docs/examples/refactor-auth-boundary/README.md +15 -0
- package/docs/examples/refactor-auth-boundary/design.md +41 -0
- package/docs/examples/refactor-auth-boundary/execution-contract.md +61 -0
- package/docs/examples/refactor-auth-boundary/proposal.md +47 -0
- package/docs/examples/refactor-auth-boundary/specs/auth-boundary/spec.md +45 -0
- package/docs/examples/refactor-auth-boundary/tasks.md +25 -0
- package/docs/plans/2026-07-07-fix-batch-design.md +68 -0
- package/docs/plans/2026-07-20-001-refactor-skill-collaboration-protocol-plan.md +128 -0
- package/docs/platform-matrix.md +45 -0
- package/docs/prototype-design-research.md +206 -0
- package/docs/release-checklist.md +96 -0
- package/docs/showcase.html +699 -0
- package/docs/skill-rename-v0.8.0.md +49 -0
- package/docs/state-machine.md +162 -0
- package/gemini-extension.json +6 -0
- package/hooks/hooks-cursor.json +8 -0
- package/hooks/hooks.json +26 -0
- package/hooks/pre-tool-use-guard +116 -0
- package/hooks/session-start +14 -0
- package/llms.txt +51 -0
- package/package.json +48 -0
- package/plugin.json +27 -0
- package/prd/v1/plan.md +443 -0
- package/prd/v1/prd.md +580 -0
- package/scripts/check-update.mjs +91 -0
- package/scripts/check-version-consistency.mjs +345 -0
- package/scripts/ensure-branch.mjs +71 -0
- package/scripts/get-config +31 -0
- package/scripts/guard/checks/artifacts-exist.mjs +36 -0
- package/scripts/guard/checks/contract-current.mjs +33 -0
- package/scripts/guard/checks/contract-fresh.mjs +17 -0
- package/scripts/guard/checks/dp-gate-passed.mjs +35 -0
- package/scripts/guard/checks/dp3-approved.mjs +22 -0
- package/scripts/guard/checks/execution-plan-ready.mjs +40 -0
- package/scripts/guard/checks/execution-reviews-passed.mjs +36 -0
- package/scripts/guard/checks/schema-valid.mjs +63 -0
- package/scripts/guard/checks/specs-merged.mjs +51 -0
- package/scripts/guard/checks/tasks-complete.mjs +31 -0
- package/scripts/guard/checks/tests-passing.mjs +31 -0
- package/scripts/guard/design-token-guard.mjs +237 -0
- package/scripts/guard/guard.mjs +205 -0
- package/scripts/infer-workflow.mjs +136 -0
- package/scripts/install-amazon-q.mjs +9 -0
- package/scripts/install-cline.mjs +9 -0
- package/scripts/install-continue.mjs +9 -0
- package/scripts/install-cursor.mjs +265 -0
- package/scripts/install-git-hooks.mjs +82 -0
- package/scripts/install-kiro.mjs +9 -0
- package/scripts/install-pi.mjs +9 -0
- package/scripts/install-qoder.mjs +9 -0
- package/scripts/install-qwen.mjs +9 -0
- package/scripts/install-roocode.mjs +9 -0
- package/scripts/install-windsurf.mjs +9 -0
- package/scripts/install-zcode.mjs +265 -0
- package/scripts/lib/cmd-audit.mjs +127 -0
- package/scripts/lib/cmd-checkpoint.mjs +118 -0
- package/scripts/lib/cmd-config.mjs +88 -0
- package/scripts/lib/cmd-doctor.mjs +267 -0
- package/scripts/lib/cmd-execution.mjs +206 -0
- package/scripts/lib/cmd-handoff.mjs +94 -0
- package/scripts/lib/cmd-inject.mjs +310 -0
- package/scripts/lib/cmd-install-amazon-q.mjs +11 -0
- package/scripts/lib/cmd-install-cline.mjs +11 -0
- package/scripts/lib/cmd-install-continue.mjs +11 -0
- package/scripts/lib/cmd-install-cursor.mjs +14 -0
- package/scripts/lib/cmd-install-kiro.mjs +11 -0
- package/scripts/lib/cmd-install-pi.mjs +11 -0
- package/scripts/lib/cmd-install-qoder.mjs +11 -0
- package/scripts/lib/cmd-install-qwen.mjs +11 -0
- package/scripts/lib/cmd-install-roocode.mjs +11 -0
- package/scripts/lib/cmd-install-windsurf.mjs +11 -0
- package/scripts/lib/cmd-install-workbuddy.mjs +359 -0
- package/scripts/lib/cmd-install-zcode.mjs +14 -0
- package/scripts/lib/cmd-isolate.mjs +37 -0
- package/scripts/lib/cmd-list.mjs +71 -0
- package/scripts/lib/cmd-runtime.mjs +85 -0
- package/scripts/lib/cmd-solutions.mjs +71 -0
- package/scripts/lib/cmd-state.mjs +231 -0
- package/scripts/lib/cmd-sync.mjs +102 -0
- package/scripts/lib/cmd-validate.mjs +105 -0
- package/scripts/lib/cmd-version.mjs +148 -0
- package/scripts/lib/config-loader.mjs +107 -0
- package/scripts/lib/execution-plan.mjs +492 -0
- package/scripts/lib/execution-recommendation.mjs +221 -0
- package/scripts/lib/hash.mjs +74 -0
- package/scripts/lib/install.mjs +267 -0
- package/scripts/lib/platform-runtime-inventory.mjs +27 -0
- package/scripts/lib/platforms.mjs +165 -0
- package/scripts/lib/prototype-sync.mjs +192 -0
- package/scripts/lib/sdd-overlay.mjs +262 -0
- package/scripts/lib/shell-quote.mjs +4 -0
- package/scripts/lib/solutions-capture.mjs +102 -0
- package/scripts/lib/solutions-index-gen.mjs +112 -0
- package/scripts/lib/solutions-inject.mjs +77 -0
- package/scripts/lib/solutions-promote.mjs +145 -0
- package/scripts/lib/spec-paths.mjs +85 -0
- package/scripts/lib/state-loader.mjs +154 -0
- package/scripts/lint/lint-skills.mjs +149 -0
- package/scripts/lint/rules/behavior-consistency.mjs +56 -0
- package/scripts/lint/rules/dp-trigger-points.mjs +60 -0
- package/scripts/lint/rules/exception-handling.mjs +59 -0
- package/scripts/lint/rules/no-contradictory-instructions.mjs +67 -0
- package/scripts/lint/rules/no-redundant-checks.mjs +50 -0
- package/scripts/lint/rules/token-rules.mjs +122 -0
- package/scripts/review-package +44 -0
- package/scripts/task-brief +40 -0
- package/scripts/team-flow.mjs +164 -0
- package/scripts/token-baseline.mjs +158 -0
- package/scripts/validate-artifacts +96 -0
- package/scripts/verify-marketplace-release.mjs +59 -0
- package/skills/architecture-design/SKILL.md +140 -0
- package/skills/architecture-design/chapters/ch01-4a-domains.md +27 -0
- package/skills/architecture-design/chapters/ch02-change-cascade.md +27 -0
- package/skills/architecture-design/chapters/ch03-architecture-outputs.md +25 -0
- package/skills/architecture-design/chapters/ch04-entity-to-aggregate.md +27 -0
- package/skills/architecture-design/chapters/ch05-cqrs.md +32 -0
- package/skills/architecture-design/chapters/ch06-integration.md +54 -0
- package/skills/architecture-design/cheatsheet.md +51 -0
- package/skills/architecture-design/glossary.md +23 -0
- package/skills/architecture-design/patterns.md +32 -0
- package/skills/bug-investigator/SKILL.md +77 -0
- package/skills/build-executor/SKILL.md +163 -0
- package/skills/build-executor/implementer-prompt.md +162 -0
- package/skills/build-executor/references/execution-modes.md +86 -0
- package/skills/build-executor/task-reviewer-prompt.md +195 -0
- package/skills/ce-brainstorm/SKILL.md +415 -0
- package/skills/ce-brainstorm/references/agents/slack-researcher.md +127 -0
- package/skills/ce-brainstorm/references/blindspot-pass.md +70 -0
- package/skills/ce-brainstorm/references/brainstorm-sections.md +285 -0
- package/skills/ce-brainstorm/references/handoff.md +168 -0
- package/skills/ce-brainstorm/references/html-rendering.md +634 -0
- package/skills/ce-brainstorm/references/markdown-rendering.md +241 -0
- package/skills/ce-brainstorm/references/model-tiers.md +9 -0
- package/skills/ce-brainstorm/references/prd-mapping.md +71 -0
- package/skills/ce-brainstorm/references/product-pressure-test.md +42 -0
- package/skills/ce-brainstorm/references/reasoning-elevation.md +63 -0
- package/skills/ce-brainstorm/references/settled-decisions.md +45 -0
- package/skills/ce-brainstorm/references/synthesis-summary.md +282 -0
- package/skills/ce-brainstorm/references/universal-brainstorming.md +73 -0
- package/skills/ce-brainstorm/references/verdict-routing.md +26 -0
- package/skills/ce-brainstorm/references/visual-probes.md +158 -0
- package/skills/ce-brainstorm/scripts/visual-probe-server.js +418 -0
- package/skills/ce-compound/SKILL.md +114 -0
- package/skills/ce-compound/assets/resolution-template.md +94 -0
- package/skills/ce-compound/references/agents/best-practices-researcher.md +115 -0
- package/skills/ce-compound/references/agents/data-integrity-guardian.md +68 -0
- package/skills/ce-compound/references/agents/framework-docs-researcher.md +93 -0
- package/skills/ce-compound/references/agents/pattern-recognition-specialist.md +55 -0
- package/skills/ce-compound/references/agents/performance-oracle.md +108 -0
- package/skills/ce-compound/references/agents/security-sentinel.md +91 -0
- package/skills/ce-compound/references/agents/session-historian.md +83 -0
- package/skills/ce-compound/references/concepts-vocabulary.md +78 -0
- package/skills/ce-compound/references/full-mode-workflow.md +413 -0
- package/skills/ce-compound/references/grounding-validation.md +84 -0
- package/skills/ce-compound/references/lightweight-mode.md +53 -0
- package/skills/ce-compound/references/output-standards.md +182 -0
- package/skills/ce-compound/references/promotion-rules.md +38 -0
- package/skills/ce-compound/references/schema.yaml +231 -0
- package/skills/ce-compound/references/three-tier-index.md +55 -0
- package/skills/ce-compound/references/v0.5-upgrade.md +32 -0
- package/skills/ce-compound/references/write-flow.md +36 -0
- package/skills/ce-compound/references/yaml-schema.md +118 -0
- package/skills/ce-compound/scripts/session-history/discover-sessions.sh +130 -0
- package/skills/ce-compound/scripts/session-history/extract-errors.py +254 -0
- package/skills/ce-compound/scripts/session-history/extract-metadata.py +456 -0
- package/skills/ce-compound/scripts/session-history/extract-skeleton.py +575 -0
- package/skills/ce-compound/scripts/validate-doc-claims.py +346 -0
- package/skills/ce-compound/scripts/validate-frontmatter.py +137 -0
- package/skills/ce-ideate/SKILL.md +402 -0
- package/skills/ce-ideate/references/agents/issue-intelligence-analyst.md +200 -0
- package/skills/ce-ideate/references/agents/learnings-researcher.md +247 -0
- package/skills/ce-ideate/references/agents/slack-researcher.md +127 -0
- package/skills/ce-ideate/references/agents/web-researcher.md +121 -0
- package/skills/ce-ideate/references/divergent-ideation.md +89 -0
- package/skills/ce-ideate/references/html-rendering.md +634 -0
- package/skills/ce-ideate/references/ideation-sections.md +191 -0
- package/skills/ce-ideate/references/markdown-rendering.md +238 -0
- package/skills/ce-ideate/references/post-ideation-workflow.md +167 -0
- package/skills/ce-ideate/references/universal-ideation.md +107 -0
- package/skills/ce-ideate/references/web-research-cache.md +56 -0
- package/skills/ce-plan/SKILL.md +137 -0
- package/skills/ce-plan/references/agents/agent-native-planning-strategist.md +62 -0
- package/skills/ce-plan/references/agents/architecture-strategist.md +46 -0
- package/skills/ce-plan/references/agents/best-practices-researcher.md +114 -0
- package/skills/ce-plan/references/agents/data-integrity-guardian.md +68 -0
- package/skills/ce-plan/references/agents/data-migration-reviewer.md +103 -0
- package/skills/ce-plan/references/agents/deployment-verification-agent.md +157 -0
- package/skills/ce-plan/references/agents/framework-docs-researcher.md +93 -0
- package/skills/ce-plan/references/agents/git-history-analyzer.md +40 -0
- package/skills/ce-plan/references/agents/learnings-researcher.md +247 -0
- package/skills/ce-plan/references/agents/pattern-recognition-specialist.md +55 -0
- package/skills/ce-plan/references/agents/performance-oracle.md +108 -0
- package/skills/ce-plan/references/agents/repo-research-analyst.md +258 -0
- package/skills/ce-plan/references/agents/security-sentinel.md +91 -0
- package/skills/ce-plan/references/agents/slack-researcher.md +127 -0
- package/skills/ce-plan/references/agents/spec-flow-analyzer.md +80 -0
- package/skills/ce-plan/references/agents/web-researcher.md +121 -0
- package/skills/ce-plan/references/approach-altitude.md +55 -0
- package/skills/ce-plan/references/change-splitting.md +65 -0
- package/skills/ce-plan/references/completion-contract.md +33 -0
- package/skills/ce-plan/references/core-principles.md +40 -0
- package/skills/ce-plan/references/deepening-workflow.md +263 -0
- package/skills/ce-plan/references/dependency-graph.md +36 -0
- package/skills/ce-plan/references/html-rendering.md +634 -0
- package/skills/ce-plan/references/intake-routing.md +189 -0
- package/skills/ce-plan/references/markdown-rendering.md +238 -0
- package/skills/ce-plan/references/plan-handoff.md +150 -0
- package/skills/ce-plan/references/plan-sections.md +427 -0
- package/skills/ce-plan/references/plan-structure.md +120 -0
- package/skills/ce-plan/references/planning-modes.md +69 -0
- package/skills/ce-plan/references/reasoning-elevation.md +63 -0
- package/skills/ce-plan/references/research-workflow.md +165 -0
- package/skills/ce-plan/references/review-and-write.md +127 -0
- package/skills/ce-plan/references/settled-decisions.md +45 -0
- package/skills/ce-plan/references/synthesis-summary.md +418 -0
- package/skills/ce-plan/references/universal-planning.md +168 -0
- package/skills/ce-proof/SKILL.md +346 -0
- package/skills/ce-strategy/SKILL.md +97 -0
- package/skills/ce-strategy/references/interview.md +143 -0
- package/skills/ce-strategy/references/strategy-template.md +89 -0
- package/skills/code-reviewer/SKILL.md +84 -0
- package/skills/code-reviewer/code-reviewer-prompt.md +195 -0
- package/skills/contract-builder/SKILL.md +72 -0
- package/skills/design-system/SKILL.md +75 -0
- package/skills/design-system/references/agents/design-system-architect.md +138 -0
- package/skills/design-system/references/creation-flow.md +170 -0
- package/skills/design-system/references/preview-template.html +319 -0
- package/skills/design-system/references/token-derivation.md +115 -0
- package/skills/design-system/references/variant-schema.md +60 -0
- package/skills/e2e/SKILL.md +56 -0
- package/skills/e2e/references/test-verifier.md +40 -0
- package/skills/need-explorer/SKILL.md +79 -0
- package/skills/prototype/SKILL.md +98 -0
- package/skills/prototype/references/agents/design-system-architect.md +122 -0
- package/skills/prototype/references/checklist.md +82 -0
- package/skills/prototype/references/craft/accessibility-baseline.md +71 -0
- package/skills/prototype/references/craft/anti-ai-slop.md +87 -0
- package/skills/prototype/references/craft/laws-of-ux.md +60 -0
- package/skills/prototype/references/craft/state-coverage.md +81 -0
- package/skills/prototype/references/craft/typography-hierarchy.md +50 -0
- package/skills/prototype/references/layouts.md +223 -0
- package/skills/prototype/references/orchestration-flow.md +101 -0
- package/skills/prototype/references/prototype-scaffold/assets/design-tokens.css +19 -0
- package/skills/prototype/references/prototype-scaffold/components/button.html +3 -0
- package/skills/prototype/references/prototype-scaffold/design-system.md +7 -0
- package/skills/prototype/references/prototype-scaffold/flow.md +11 -0
- package/skills/prototype/references/prototype-scaffold/index.html +20 -0
- package/skills/prototype/references/prototype-scaffold/pages/index.html +11 -0
- package/skills/prototype/references/template.html +396 -0
- package/skills/release-archivist/SKILL.md +166 -0
- package/skills/release-archivist/references/closing-procedures.md +81 -0
- package/skills/session-handoff/SKILL.md +110 -0
- package/skills/session-handoff/references/context-extraction.md +70 -0
- package/skills/session-handoff/references/handoff-template.md +90 -0
- package/skills/session-handoff/references/skill-recommendation.md +43 -0
- package/skills/spec-merger/SKILL.md +66 -0
- package/skills/spec-writer/SKILL.md +149 -0
- package/skills/workflow-bootstrap/SKILL.md +148 -0
- package/skills/workflow-bootstrap/references/agents/codebase-recon-analyst.md +121 -0
- package/skills/workflow-bootstrap/references/b1-reconnaissance.md +80 -0
- package/skills/workflow-bootstrap/scripts/recon-probe.sh +328 -0
- package/skills/workflow-feedback/SKILL.md +120 -0
- package/skills/workflow-feedback/references/category-guide.md +121 -0
- package/skills/workflow-feedback/references/feedback-template.md +73 -0
- package/skills/workflow-feedback/references/review-mode.md +92 -0
- package/skills/workflow-orchestrator/SKILL.md +94 -0
- package/skills/workflow-orchestrator/references/feedback-loops.md +56 -0
- package/skills/workflow-orchestrator/references/s1-path-router.md +81 -0
- package/skills/workflow-orchestrator/references/s2-prd-prototype-loop.md +96 -0
- package/skills/workflow-orchestrator/references/s3-plan-pipeline.md +50 -0
- package/skills/workflow-orchestrator/references/s4-split-validate.md +108 -0
- package/skills/workflow-orchestrator/references/s5-monitoring.md +61 -0
- package/skills/workflow-orchestrator/references/state-model.md +185 -0
- package/skills/workflow-start/SKILL.md +147 -0
- package/skills/workflow-start/references/routing-rules.md +155 -0
- package/src/index.ts +16 -0
- package/src/parsing/change-parser.ts +79 -0
- package/src/parsing/requirement-blocks.ts +244 -0
- package/src/schema/base.ts +8 -0
- package/src/schema/change.ts +29 -0
- package/src/schema/index.ts +3 -0
- package/src/schema/spec.ts +12 -0
- package/src/validation/constants.ts +53 -0
- package/src/validation/tokenizer.ts +180 -0
- package/src/validation/types.ts +47 -0
- package/src/validation/validator.ts +552 -0
- package/templates/abandonment-summary.md +29 -0
- package/templates/design.md +37 -0
- package/templates/execution-contract.md +99 -0
- package/templates/plan.md +86 -0
- package/templates/prd.md +468 -0
- package/templates/proposal.md +37 -0
- package/templates/spec.md +31 -0
- package/templates/tasks.md +47 -0
- package/tests/e2e.test.mjs +266 -0
- package/tests/lib/cmd-audit.test.mjs +202 -0
- package/tests/lib/cmd-checkpoint.test.mjs +98 -0
- package/tests/lib/cmd-config.test.mjs +101 -0
- package/tests/lib/cmd-doctor.test.mjs +450 -0
- package/tests/lib/cmd-execution.test.mjs +647 -0
- package/tests/lib/cmd-handoff.test.mjs +137 -0
- package/tests/lib/cmd-inject.test.mjs +218 -0
- package/tests/lib/cmd-install-workbuddy.test.mjs +113 -0
- package/tests/lib/cmd-install-zcode.test.mjs +42 -0
- package/tests/lib/cmd-isolate.test.mjs +68 -0
- package/tests/lib/cmd-list.test.mjs +127 -0
- package/tests/lib/cmd-runtime.test.mjs +83 -0
- package/tests/lib/cmd-state-missing.test.mjs +65 -0
- package/tests/lib/cmd-state.test.mjs +365 -0
- package/tests/lib/cmd-sync-paths.test.mjs +84 -0
- package/tests/lib/cmd-validate-paths.test.mjs +90 -0
- package/tests/lib/config-loader.test.mjs +175 -0
- package/tests/lib/ensure-branch.test.mjs +59 -0
- package/tests/lib/execution-control-plane.test.mjs +168 -0
- package/tests/lib/execution-plan.test.mjs +474 -0
- package/tests/lib/guard-specs-merged.test.mjs +108 -0
- package/tests/lib/guard-tests-passing.test.mjs +112 -0
- package/tests/lib/guard-transitions.test.mjs +262 -0
- package/tests/lib/guard.test.mjs +611 -0
- package/tests/lib/hash.test.mjs +138 -0
- package/tests/lib/infer-workflow.test.mjs +161 -0
- package/tests/lib/install-git-hooks.test.mjs +20 -0
- package/tests/lib/marketplace-release-docs.test.mjs +31 -0
- package/tests/lib/minimality-discipline.test.mjs +37 -0
- package/tests/lib/model-profiles-docs.test.mjs +33 -0
- package/tests/lib/node20-compatibility.test.mjs +73 -0
- package/tests/lib/node20-test-entry.test.mjs +17 -0
- package/tests/lib/platform-runtime-distribution.test.mjs +150 -0
- package/tests/lib/raw-mode-smoke.test.mjs +42 -0
- package/tests/lib/sdd-overlay.test.mjs +118 -0
- package/tests/lib/spec-paths.test.mjs +80 -0
- package/tests/lib/state-loader.test.mjs +251 -0
- package/tests/lib/token-baseline.test.mjs +72 -0
- package/tests/lib/token-rules.test.mjs +94 -0
- package/tests/lib/verify-marketplace-release.test.mjs +128 -0
- package/tests/tsconfig.json +12 -0
- package/token-baseline.json +95 -0
- package/tsconfig.json +14 -0
|
@@ -0,0 +1,241 @@
|
|
|
1
|
+
# Markdown Rendering
|
|
2
|
+
|
|
3
|
+
This is a format-rendering reference — it describes how to render any
|
|
4
|
+
artifact in markdown, independent of which skill is producing it.
|
|
5
|
+
|
|
6
|
+
It is paired with a section contract (`plan-sections.md`,
|
|
7
|
+
`brainstorm-sections.md`, `prd-mapping.md`, etc.) that describes *what* the
|
|
8
|
+
artifact contains. This reference describes *how* markdown specifically
|
|
9
|
+
presents it. The same content rendered by different skills shares the same
|
|
10
|
+
markdown principles.
|
|
11
|
+
|
|
12
|
+
## Hard invariants
|
|
13
|
+
|
|
14
|
+
These hold regardless of which skill produced the artifact.
|
|
15
|
+
|
|
16
|
+
- **YAML frontmatter at the top of the file.** Standard `---` delimited block
|
|
17
|
+
containing the artifact's stable metadata (title, date, type, etc.
|
|
18
|
+
— exact fields are per-skill, defined in the section contract).
|
|
19
|
+
- **ASCII identifiers in anchors.** Markdown headings auto-generate anchors
|
|
20
|
+
from the heading text. Keep headings ASCII so anchors are predictable
|
|
21
|
+
(`#implementation-units`, not `#implementación-units`).
|
|
22
|
+
- **Repo-relative paths for file references.** Always. Never absolute paths
|
|
23
|
+
— they break portability across machines, worktrees, teammates.
|
|
24
|
+
- **No HTML mixed in.** Keep the markdown pure. No `<div>`, no `<details>`,
|
|
25
|
+
no inline `<style>`. If a layout idea only works as HTML, defer it to the
|
|
26
|
+
HTML rendering. Markdown stays markdown.
|
|
27
|
+
- **No fixed-width line wrapping.** Do not hard-wrap prose to a column (e.g.
|
|
28
|
+
80 chars). Write one sentence per line, or let each paragraph flow as a
|
|
29
|
+
single line. The artifact is read rendered and shared, where fixed wraps add
|
|
30
|
+
nothing and only produce noisy mid-sentence diffs; markdown joins soft line
|
|
31
|
+
breaks within a paragraph, so wrapping never changes the rendered output.
|
|
32
|
+
- **PRD sections use stable headings.** For PRD artifacts, render the 11
|
|
33
|
+
chapters with exact headings matching the PRD template: `## 一、版本修订记录`,
|
|
34
|
+
`## 二、业务流程一览`, `## 三、D7.1_业务流程`, `## 四、D7.2_画面原型及设计`,
|
|
35
|
+
`## 五、D7.3_报表清单`, `## 六、D7.4_业务术语字典`, `## 七、D7.5_系统功能清单`,
|
|
36
|
+
`## 八、D7.6_系统功能处理说明书`, `## 九、D7.7_要件定义自查报告`,
|
|
37
|
+
`## 十、D7.8_要件定义完成报告`, `## 十一、D7.9_评审会议纪`.
|
|
38
|
+
These stable headings are the wayfinding contract: consumers scan them
|
|
39
|
+
(markdown headings, or `<h1>`–`<h3>` / anchor ids in HTML) instead of reading
|
|
40
|
+
the whole document.
|
|
41
|
+
- **版本修订记录 is top-loaded.** It appears first in the PRD for fast
|
|
42
|
+
orientation — document metadata, iteration version, and revision history.
|
|
43
|
+
|
|
44
|
+
## Format principles
|
|
45
|
+
|
|
46
|
+
These shape what "good" markdown looks like; the agent applies them per
|
|
47
|
+
artifact based on content shape.
|
|
48
|
+
|
|
49
|
+
### ID prefix format
|
|
50
|
+
|
|
51
|
+
Stable IDs (R, U, A, F, AE, KTD) appear as plain prefixes at the start of
|
|
52
|
+
the bullet or heading — do NOT bold the prefix. The prefix is visually
|
|
53
|
+
distinctive on its own; bolding it inflates visual noise.
|
|
54
|
+
|
|
55
|
+
```markdown
|
|
56
|
+
- R1. The plan returns paginated sessions. ← right
|
|
57
|
+
- **R1.** The plan returns paginated sessions. ← wrong (bolded prefix)
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
Same applies to unit headings: `### U1. Cloak detection in preflight contract`.
|
|
61
|
+
|
|
62
|
+
### Content shape: prose vs bullets vs tables
|
|
63
|
+
|
|
64
|
+
The same content can be rendered three ways; the agent picks per content
|
|
65
|
+
shape, not by template default.
|
|
66
|
+
|
|
67
|
+
- **Prose** when the content has narrative flow (motivation, decision
|
|
68
|
+
rationale, problem framing). Bullets fragment narrative into
|
|
69
|
+
disconnected pieces.
|
|
70
|
+
- **Bullets** when items share a parallel shape but each carries enough
|
|
71
|
+
prose to not fit a table cell.
|
|
72
|
+
- **Tables** when 5+ items share uniform structure (`ID + body`,
|
|
73
|
+
`name + value`, `decision + rationale`, `risk + mitigation`). Tables
|
|
74
|
+
scan faster at that scale and unlock additional columns (status,
|
|
75
|
+
traceability, severity) that bullets can't accommodate cleanly.
|
|
76
|
+
|
|
77
|
+
The test: which shape would a reader scan fastest for this content? If
|
|
78
|
+
items have parallel structure and 5+ instances, table. If items are 3-5
|
|
79
|
+
and each has a few lines of prose, bullets. If the content is a single
|
|
80
|
+
narrative thought, prose.
|
|
81
|
+
|
|
82
|
+
### Bold leader labels within bullets
|
|
83
|
+
|
|
84
|
+
When a bullet has substructure that benefits from named fields (Key Flows
|
|
85
|
+
with Trigger / Actors / Steps / Outcome, Acceptance Examples with Covers
|
|
86
|
+
/ Given / When / Then), use bold leader labels at the start of nested
|
|
87
|
+
bullets — not deeper heading levels.
|
|
88
|
+
|
|
89
|
+
```markdown
|
|
90
|
+
- F1. Anonymous capture
|
|
91
|
+
- **Trigger:** Agent enters Step 2a with no session.
|
|
92
|
+
- **Actors:** A1, A2
|
|
93
|
+
- **Steps:** Preflight detects cloak; agent launches; capture proceeds.
|
|
94
|
+
- **Covered by:** R1, R2, R5
|
|
95
|
+
```
|
|
96
|
+
|
|
97
|
+
This gives the bullet structure without needing H4/H5 headings that would
|
|
98
|
+
clutter the doc and break TOC generation.
|
|
99
|
+
|
|
100
|
+
### Section separators
|
|
101
|
+
|
|
102
|
+
For substantial artifacts, use horizontal rules (`---`) between top-level
|
|
103
|
+
H2 sections. Omit for short docs where separators would dominate.
|
|
104
|
+
|
|
105
|
+
### Tables for genuinely comparative info only
|
|
106
|
+
|
|
107
|
+
Use tables for the uniform-shape case in "Content shape" above. Don't use
|
|
108
|
+
tables to render content lists that are really bullets — markdown tables
|
|
109
|
+
are noisier in raw form and worse for diffs.
|
|
110
|
+
|
|
111
|
+
## Section anatomy
|
|
112
|
+
|
|
113
|
+
How section types commonly render in markdown. These are patterns, not
|
|
114
|
+
contracts — the agent picks the shape that fits the content.
|
|
115
|
+
|
|
116
|
+
- **版本修订记录 (§一)** — small table for document metadata (status,
|
|
117
|
+
version, author, date) and a revision-history table below.
|
|
118
|
+
- **业务流程一览 (§二)** — table with L1–L4 process taxonomy columns,
|
|
119
|
+
stakeholders, value description, change type, and related systems.
|
|
120
|
+
- **D7.1_业务流程 (§三)** — per-flow subsections with a mermaid flowchart
|
|
121
|
+
table, summary prose, and step-by-step explanation. Appendix table for
|
|
122
|
+
the full process ledger.
|
|
123
|
+
- **D7.2_画面原型及设计 (§四)** — per-module subsections with prototype
|
|
124
|
+
tables (ID, screenshot, summary columns), screen migration tables, and
|
|
125
|
+
information-structure diagrams.
|
|
126
|
+
- **D7.3_报表清单 (§五)** — table with report ID, linked flow/activity/task,
|
|
127
|
+
report type, and description. Appendix table for the full report ledger.
|
|
128
|
+
- **D7.4_业务术语字典 (§六)** — table with term name, definition, part of
|
|
129
|
+
speech, synonyms, and source. Appendix table for the full term ledger.
|
|
130
|
+
- **D7.5_系统功能清单 (§七)** — table with function ID, linked
|
|
131
|
+
flow/activity, function name, description, parent function, and change
|
|
132
|
+
type. Appendix table for the full function ledger.
|
|
133
|
+
- **D7.6_系统功能处理说明书 (§八)** — the largest chapter: function
|
|
134
|
+
overview table, global notes (permissions, interactions, exceptions,
|
|
135
|
+
sorting, search, loading), hardware/network specs, per-module function
|
|
136
|
+
detail tables, non-functional requirements (performance, availability,
|
|
137
|
+
security), analytics tracking, and encoding rules.
|
|
138
|
+
- **D7.7_要件定义自查报告 (§九)** — structured self-check tables across
|
|
139
|
+
nine categories (accounts/roles, data, state/interaction, hardware,
|
|
140
|
+
other, UX, product framework, flow design, reading experience) with
|
|
141
|
+
pass/fail/not-applicable checkboxes.
|
|
142
|
+
- **D7.8_要件定义完成报告 (§十)** — project overview prose, requirements
|
|
143
|
+
achievement matrix, deliverable completeness table, self-check summary
|
|
144
|
+
table, project team table, deliverable handover table, next-steps table,
|
|
145
|
+
and section prose summary.
|
|
146
|
+
- **D7.9_评审会议纪 (§十一)** — review record table with project info,
|
|
147
|
+
review content summary, attendee matrix with opinions, review findings
|
|
148
|
+
with countermeasures, and conclusion prose.
|
|
149
|
+
|
|
150
|
+
The agent picks more elaborate or simpler shapes based on what each
|
|
151
|
+
specific artifact's content needs.
|
|
152
|
+
|
|
153
|
+
## Diagrams
|
|
154
|
+
|
|
155
|
+
When the section contract calls for a diagram (architecture, sequence,
|
|
156
|
+
flowchart, state machine, swim lane, data-flow), markdown renders it as
|
|
157
|
+
a fenced mermaid block:
|
|
158
|
+
|
|
159
|
+
```markdown
|
|
160
|
+
` ``mermaid
|
|
161
|
+
flowchart TB
|
|
162
|
+
A[Start] --> B{Decision}
|
|
163
|
+
B -->|yes| C[Action]
|
|
164
|
+
B -->|no| D[Other action]
|
|
165
|
+
` ``
|
|
166
|
+
```
|
|
167
|
+
|
|
168
|
+
(`TB` direction default — keeps diagrams narrow in source view and in
|
|
169
|
+
narrow rendered viewports.)
|
|
170
|
+
|
|
171
|
+
Markdown's diagram affordances are limited compared to HTML. For
|
|
172
|
+
quantitative comparisons (bar charts, scatter plots) markdown has no
|
|
173
|
+
native equivalent — use a table with the data and let prose or caption
|
|
174
|
+
carry the interpretation. The richer visualization happens in the HTML
|
|
175
|
+
rendering.
|
|
176
|
+
|
|
177
|
+
For a **UI/layout shape** that would be a wireframe in HTML, markdown has
|
|
178
|
+
no inline-SVG wireframe affordance. Render the region composition as a
|
|
179
|
+
mermaid layout `flowchart` (or describe it in prose) — never hand-draw a
|
|
180
|
+
box-drawing/ASCII wireframe; it violates the no-box-drawing-characters rule
|
|
181
|
+
and reads poorly. The wireframe proper is an HTML-only affordance.
|
|
182
|
+
|
|
183
|
+
## Inline code and code blocks
|
|
184
|
+
|
|
185
|
+
- **Inline code** for identifiers (variable names, function names,
|
|
186
|
+
flag names, file paths, IDs that aren't section anchors).
|
|
187
|
+
- **Fenced code blocks** with language tag for code, shell commands,
|
|
188
|
+
API request/response samples. Always specify the language for syntax
|
|
189
|
+
highlighting and accessibility.
|
|
190
|
+
|
|
191
|
+
```markdown
|
|
192
|
+
The flag `--cdp-url` accepts a URL.
|
|
193
|
+
|
|
194
|
+
` ``bash
|
|
195
|
+
browser-use --cdp-url http://localhost:9222
|
|
196
|
+
` ``
|
|
197
|
+
```
|
|
198
|
+
|
|
199
|
+
## No process exhaust
|
|
200
|
+
|
|
201
|
+
Engineering process metadata stays out of the artifact:
|
|
202
|
+
|
|
203
|
+
- No "captured at Phase X" notes
|
|
204
|
+
- No `## Next Steps` pointing to the next skill
|
|
205
|
+
- No italic provenance lines ("*Brainstorm completed 2026-05-13*")
|
|
206
|
+
- No engineering-flow shepherding ("Now read this file:", "Next, run that
|
|
207
|
+
command:")
|
|
208
|
+
|
|
209
|
+
This information belongs in commit messages, tool output, and agent
|
|
210
|
+
transcripts — not in the artifact a reader returns to weeks later.
|
|
211
|
+
|
|
212
|
+
## Frontmatter shape
|
|
213
|
+
|
|
214
|
+
Per-skill frontmatter fields are defined in each skill's section contract
|
|
215
|
+
(`plan-sections.md` lists plan frontmatter; `brainstorm-sections.md` lists
|
|
216
|
+
brainstorm frontmatter; `prd-mapping.md` maps brainstorm output to PRD
|
|
217
|
+
chapters). Common rules:
|
|
218
|
+
|
|
219
|
+
- YAML at the top of the file, delimited by `---` on its own line above
|
|
220
|
+
and below.
|
|
221
|
+
- Field names in lowercase snake_case (`created_at`, `topic`, not
|
|
222
|
+
`CreatedAt`, `Topic`).
|
|
223
|
+
- **No status / lifecycle field.** Artifacts are point-in-time records
|
|
224
|
+
(decision or discovery), not tracked work items. Do not introduce a
|
|
225
|
+
mutable `status` field or an `active → completed` lifecycle — whether
|
|
226
|
+
the work shipped is derived from git, not stored in the doc.
|
|
227
|
+
- Stable across artifact revisions — never rename or repurpose a field.
|
|
228
|
+
|
|
229
|
+
## Post-write audit
|
|
230
|
+
|
|
231
|
+
Before declaring the markdown file written, scan it for these common
|
|
232
|
+
slips:
|
|
233
|
+
|
|
234
|
+
- All stable IDs are plain-prefix format, not bolded.
|
|
235
|
+
- No HTML elements mixed in.
|
|
236
|
+
- All file paths are repo-relative.
|
|
237
|
+
- Horizontal rule separators between H2s (for Standard / Deep artifacts).
|
|
238
|
+
- No process exhaust (Phase X notes, Next Steps pointers, provenance
|
|
239
|
+
lines).
|
|
240
|
+
- Tables only where 5+ uniform-shape items justify them.
|
|
241
|
+
- Frontmatter has all the per-skill required fields with reasonable values.
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
# Model Tiers
|
|
2
|
+
|
|
3
|
+
Read this when dispatching a sub-agent (the Phase 1.1 grounding scout, the Phase 2.6 claim verifier, or the opt-in Slack researcher). Sub-agent dispatch is tiered by task shape, never hardcoded to a model name:
|
|
4
|
+
|
|
5
|
+
- **Extraction tier** — the grounding scout: retrieval and quoting work. Use the platform's cheapest capable model when the current harness exposes a known override. "Capable" is part of the spec — escalate to the generation tier when the repo is large or the stack obscure.
|
|
6
|
+
- **Generation tier** — the claim verifier: evidence-driven mechanical verification. Use the platform's mid-tier model when the current harness exposes a known override. If model names are unknown, omit the override and inherit rather than guessing.
|
|
7
|
+
- **Ceiling tier** — the dialogue itself. Questions, approaches, synthesis, and the requirements-only unified plan run in the main conversation on the orchestrator's model; nothing is dispatched for them.
|
|
8
|
+
|
|
9
|
+
**Degradation rule.** When the platform's subagent primitive does not support per-agent model selection, dispatch the scout and verifier on the inherited model and keep their read budgets and output caps — cost control then comes from structure, not tiering. When the platform has no subagent primitive at all, do the topic scan inline at Phase 1.1 — still writing the grounding dossier to the scratch path, because downstream consumers (the Phase 2.6 verifier, the ce-plan handoff) receive that path — and verify claims inline before the Phase 3 write, with the same budgets.
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
# Brainstorm → PRD 章节映射
|
|
2
|
+
|
|
3
|
+
ce-brainstorm 的对话流程收集的信息需要映射到 PRD 模板的 11 个章节。
|
|
4
|
+
|
|
5
|
+
## 映射关系
|
|
6
|
+
|
|
7
|
+
| PRD 章节 | 信息来源 | 填充策略 |
|
|
8
|
+
|---|---|---|
|
|
9
|
+
| 一、版本修订记录 | 元数据(日期、作者、版本、状态) | **自动填充**:从对话上下文提取日期、用户信息;版本/状态按下方「版本格式规范」填充,**文档状态必须与 frontmatter `frozen` 一致** |
|
|
10
|
+
| 二、业务流程一览 | Phase 1.3 对话:用户/流程/系统交互 | **对话填充**:brainstorm 对话中收集的业务流程信息 |
|
|
11
|
+
| 三、D7.1_业务流程 | Phase 1.3 对话:Key Flows | **对话填充**:从 brainstorm 的 Key Flows 映射 |
|
|
12
|
+
| 四、D7.2_画面原型及设计 | Phase 1.3 对话:UI/交互需求 | **对话填充**:如涉及 UI,从对话中收集原型信息 |
|
|
13
|
+
| 五、D7.3_报表清单 | Phase 1.3 对话 | **占位保留**:brainstorm 不涉及报表细节,保留模板占位符 |
|
|
14
|
+
| 六、D7.4_业务术语字典 | Phase 1.3 对话 + CONCEPTS.md | **部分填充**:从对话中提取的领域术语,其余保留占位符 |
|
|
15
|
+
| 七、D7.5_系统功能清单 | Phase 1.3 对话:Requirements | **对话填充**:从 brainstorm 的 Requirements 映射 |
|
|
16
|
+
| 八、D7.6_系统功能处理说明书 | Phase 1.3 对话:Key Decisions + Constraints | **部分填充**:权限/交互/异常等从对话收集,硬件/网络保留占位符 |
|
|
17
|
+
| 九、D7.7_要件定义自查报告 | 自动 | **占位保留**:这是 BA 自查工具,brainstorm 阶段不填充 |
|
|
18
|
+
| 十、D7.8_要件定义完成报告 | 自动 | **占位保留**:这是完成态产物,brainstorm 阶段不填充 |
|
|
19
|
+
| 十一、D7.9_评审会议纪 | 自动 | **占位保留**:这是评审产物,brainstorm 阶段不填充 |
|
|
20
|
+
|
|
21
|
+
## 关键映射规则
|
|
22
|
+
|
|
23
|
+
1. **brainstorm 对话中没有信息的章节保留模板占位符**,不硬填
|
|
24
|
+
2. **版本修订记录(§1)** 从元数据自动填充:日期、撰写人(如可获取)
|
|
25
|
+
3. **业务流程(§2-§3)** 从 brainstorm 的 Key Flows 和 Actors 映射
|
|
26
|
+
4. **画面原型(§4)** 仅在 brainstorm 涉及 UI 时填充
|
|
27
|
+
5. **业务术语(§6)** 从对话中提取已定义的领域术语
|
|
28
|
+
6. **系统功能(§7-§8)** 从 Requirements 和 Key Decisions 映射
|
|
29
|
+
7. **自查/完成/评审(§9-§11)** 全部保留占位符,由后续流程填充
|
|
30
|
+
|
|
31
|
+
## 迭代版本(vN)
|
|
32
|
+
|
|
33
|
+
- `prd/vN/` 中的 N 是产品迭代版本(v1=MVP, v2=扩展),不是文档版本
|
|
34
|
+
- ce-brainstorm 启动时扫描 `prd/` 目录检测已有迭代
|
|
35
|
+
- 自动建议最新迭代或创建新迭代,用户确认后继续
|
|
36
|
+
- 每个迭代目录下只有一个 `prd.md` 文件
|
|
37
|
+
|
|
38
|
+
## 版本格式规范(v0.8 新增,修复格式不统一 BUG)
|
|
39
|
+
|
|
40
|
+
> **背景**:曾出现 frontmatter `iteration_version: v1`/`frozen: true`,正文却写「产品版本 v1.0」「文档状态 编辑中」——格式两套且状态自相矛盾。本节钉死格式,写入时自检。
|
|
41
|
+
|
|
42
|
+
**两层版本号,分工明确**:
|
|
43
|
+
|
|
44
|
+
| 字段 | 位置 | 格式 | 含义 | 递增时机 |
|
|
45
|
+
|------|------|------|------|---------|
|
|
46
|
+
| `iteration_version` | frontmatter | `vN`(v1/v2/…) | **产品迭代版本** | 仅新迭代/新用户故事(vN+1)|
|
|
47
|
+
| 产品版本 | 正文 §1.1 版本信息 | `vN.M`(v1.0/v1.1/…) | **文档修订次版本** | vN 内每次修订递增 M(呼应反馈环路「vN 内修订不升版」)|
|
|
48
|
+
|
|
49
|
+
- vN 内修订(S3→S2 回退修订)→ 只递增正文 `vN.M` 的 M,**frontmatter `iteration_version` 不变**,并在 §1.2 修订记录追加一行 + 「决策与变更履历」章节记录。
|
|
50
|
+
- 新迭代 → frontmatter `iteration_version` 升 vN+1,正文产品版本重置为 `v(N+1).0`,新建 `prd/v(N+1)/` 目录。
|
|
51
|
+
|
|
52
|
+
**文档状态枚举(§1.1)——必须与 frontmatter `frozen` 一致**:
|
|
53
|
+
|
|
54
|
+
| 文档状态 | frontmatter | 含义 |
|
|
55
|
+
|---------|-------------|------|
|
|
56
|
+
| `编辑中` | 无 `frozen` 或 `frozen: false` | 仍在编写/对话中 |
|
|
57
|
+
| `已冻结-下游` | `frozen: true`(默认)| `frozen_downstream`:下游不可直接改,可经 S3→S2 回退在 vN 内修订 |
|
|
58
|
+
| `已冻结-绝对` | `frozen: absolute` | `frozen_absolute`:任何修改必须升版 vN+1 |
|
|
59
|
+
|
|
60
|
+
> **一致性硬约束**:frontmatter `frozen: true` 时,正文文档状态**不得**为「编辑中」。PRD 写入/冻结时自检,不一致即修正。
|
|
61
|
+
|
|
62
|
+
## 冻结声明(v0.8 新增,修复冻结措辞 BUG)
|
|
63
|
+
|
|
64
|
+
PRD 冻结时(`frozen_downstream`),在正文标题下方插入冻结声明 blockquote。**措辞必须区分双层冻结,不得写"升版 v2"**(那是 `frozen_absolute` 语义,违反反馈环路设计):
|
|
65
|
+
|
|
66
|
+
```markdown
|
|
67
|
+
> **本文档已于 {YYYY-MM-DD} 冻结**(`frozen_downstream`,经原型循环验证 + 人工评审通过)。
|
|
68
|
+
> 下游阶段(plan/spec/build)**不可直接修改**;如 plan 或实施暴露 scope 问题,经 **S3→S2 回退在 vN 内修订**并记录「决策与变更履历」(不升版)。
|
|
69
|
+
> 仅当**启动新迭代 vN+1** 或**用户显式绝对冻结**(`frozen_absolute`)时,才需升版。
|
|
70
|
+
```
|
|
71
|
+
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
# Product Pressure Test — rigor-gap lenses
|
|
2
|
+
|
|
3
|
+
Read this at Phase 1.2, before generating approaches. This is agent-internal analysis, not a user-facing checklist. Read the opening, note which gaps actually exist, and raise only those as questions during Phase 1.3 — folded into the normal flow of dialogue, not fired as a pre-flight gauntlet. A fuzzy opening may earn three or four probes; a concrete, well-framed one may earn zero because no scope-appropriate gaps were found.
|
|
4
|
+
|
|
5
|
+
Match depth to the Phase 0.3 scope.
|
|
6
|
+
|
|
7
|
+
## Lightweight
|
|
8
|
+
|
|
9
|
+
- Is this solving the real user problem?
|
|
10
|
+
- Are we duplicating something that already covers this?
|
|
11
|
+
- Is there a clearly better framing with near-zero extra cost?
|
|
12
|
+
|
|
13
|
+
## Standard — scan for these gaps
|
|
14
|
+
|
|
15
|
+
- **Evidence gap.** The opening asserts want or need, but doesn't point to anything the would-be user has already done — time spent, money paid, workarounds built — that would make the want observable. When present, ask for the most concrete thing someone has already done about this.
|
|
16
|
+
|
|
17
|
+
- **Specificity gap.** The opening describes the beneficiary at a level of abstraction where the agent couldn't design without silently inventing who they are and what changes for them. When present, ask the user to name a specific person or narrow segment, and what changes for that person when this ships.
|
|
18
|
+
|
|
19
|
+
- **Counterfactual gap.** The opening doesn't make visible what users do today when this problem arises, nor what changes if nothing ships. When present, ask what the current workaround is, even if it's messy — and what it costs them.
|
|
20
|
+
|
|
21
|
+
- **Attachment gap.** The opening treats a particular solution shape as the thing being built, rather than the value that shape is supposed to deliver, and hasn't been examined against smaller forms that might deliver the same value. When present, ask what the smallest version that still delivers real value would look like.
|
|
22
|
+
|
|
23
|
+
Plus these synthesis questions — not gap lenses, product-judgment the agent weighs in its own reasoning:
|
|
24
|
+
- Is there a nearby framing that creates more user value without more carrying cost? If so, what complexity does it add?
|
|
25
|
+
- Given the current project state, user goal, and constraints, what is the single highest-leverage move right now: the request as framed, a reframing, one adjacent addition, a simplification, or doing nothing?
|
|
26
|
+
|
|
27
|
+
Favor moves that compound value, reduce future carrying cost, or make the product meaningfully more useful or compelling. Use the result to sharpen the conversation, not to bulldoze the user's intent.
|
|
28
|
+
|
|
29
|
+
## Deep — Standard lenses and synthesis questions plus
|
|
30
|
+
|
|
31
|
+
- Is this a local patch, or does it move the broader system toward where it wants to be?
|
|
32
|
+
|
|
33
|
+
## Deep — product — Deep plus
|
|
34
|
+
|
|
35
|
+
- **Durability gap.** The opening's value proposition rests on a current state of the world that may shift in predictable ways within the horizon the user cares about. When present, ask how the idea fares under the most plausible near-term shifts — and push past rising-tide answers every competitor could make.
|
|
36
|
+
|
|
37
|
+
- What adjacent product could we accidentally build instead, and why is that the wrong one?
|
|
38
|
+
- What would have to be true in the world for this to fail?
|
|
39
|
+
|
|
40
|
+
These questions force an explicit product thesis and feed the Scope Boundaries subsections ("Deferred for later" and "Outside this product's identity") and Dependencies / Assumptions in the Product Contract.
|
|
41
|
+
|
|
42
|
+
Phase 1.3 owns how these gaps fire as probes: each scope-appropriate gap found here becomes a separate open-ended probe (the "when present, ask..." line is the probe), surfaced progressively but all probed before Phase 2.
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
# Fable Elevation (Claude Code only)
|
|
2
|
+
|
|
3
|
+
This reference is loaded ONLY after a positive Claude Code host check (the gate below). It carries the entire elevation engine; the calling `SKILL.md` holds only a model-name-free pointer. Never inline any part of this file into an always-loaded `SKILL.md` — the silent no-op on other harnesses depends on this text never shipping in a non-Claude context.
|
|
4
|
+
|
|
5
|
+
Elevation dispatches the reasoning-heavy authoring/interpretation step to a higher-reasoning model (in Claude Code, **Fable**) via a subagent, so a user on a cheaper session model still gets a high-reasoning result without switching their whole session.
|
|
6
|
+
|
|
7
|
+
## Mechanical host gate — the first ordered step
|
|
8
|
+
|
|
9
|
+
Before reading any Fable config key, parsing Fable intent, or emitting any Fable string, self-identify the host with the same env-var union `ce-code-review` uses:
|
|
10
|
+
|
|
11
|
+
```bash
|
|
12
|
+
if [ -n "${CURSOR_AGENT:-}${CURSOR_CONVERSATION_ID:-}" ]; then HOST=cursor;
|
|
13
|
+
elif [ "${CLAUDECODE:-}" = "1" ]; then HOST=claude;
|
|
14
|
+
elif [ -n "${CODEX_SANDBOX:-}${CODEX_SESSION_ID:-}${CODEX_THREAD_ID:-}${CODEX_CI:-}" ]; then HOST=codex;
|
|
15
|
+
else HOST=unknown; fi;
|
|
16
|
+
echo "HOST: $HOST"
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
These are **host-provided environment variables** — the Claude Code runtime sets `CLAUDECODE=1`, Cursor sets `CURSOR_AGENT` / `CURSOR_CONVERSATION_ID`, Codex sets the `CODEX_*` markers. This skill only reads them; it never sets them. You must actually **run this check with the shell tool** and **branch on the emitted `HOST:` line** — the `echo` is load-bearing: the variable is set inside the shell process and is gone once the command exits, so without reading the printed value you have no observable host to gate on. The value is not knowable from context.
|
|
20
|
+
|
|
21
|
+
Proceed with elevation ONLY when `HOST=claude`. On `cursor`, `codex`, or `unknown`: elevation is off and inert — do not read Fable config, do not parse intent, do not dispatch, do not mention Fable. (A stray "use fable" prompt on those hosts is handled by the SKILL.md pointer without naming a model.)
|
|
22
|
+
|
|
23
|
+
## Activation resolution (only after `HOST=claude`)
|
|
24
|
+
|
|
25
|
+
Resolve a per-skill boolean by precedence:
|
|
26
|
+
|
|
27
|
+
1. **In-prompt intent** — reason over THIS run's prompt. Affirmative intent ("use fable", "get fable help", "have fable plan this") → elevate. Negative intent ("don't use fable", "no fable") → do not elevate. Intent is *reasoned, not keyword-matched*: a passing mention of "fable" as subject matter (e.g. "design a fable-generator feature") is NOT activation.
|
|
28
|
+
2. **Config** — otherwise the per-skill key: `plan_use_fable` for ce-plan, `brainstorm_use_fable` for ce-brainstorm. Read it from the config file the **same way this skill's Phase 0.0 already resolves `plan_output` / `brainstorm_output`**: reuse the repo root the skill already resolved if you have it, else run `git rev-parse --show-toplevel`, then read `<repo-root>/.compound-engineering/config.local.yaml` with the native file-read tool. This skill already read that file once at Phase 0.0 — reuse that result if you still have it rather than re-reading. Ignore commented (`#`-prefixed) lines. `true` → elevate; missing / commented / invalid / `false` / no file → off.
|
|
29
|
+
3. **Pipeline runs** — in pipeline / `disable-model-invocation` runs there is no prompt, so resolution is config-only; if the key is on, elevate. Still subordinate to the host gate — a config copied to a non-Claude harness never fires it.
|
|
30
|
+
|
|
31
|
+
If the session model is already Fable, elevation is moot: skip dispatch and the nudge.
|
|
32
|
+
|
|
33
|
+
## Elevated dispatch
|
|
34
|
+
|
|
35
|
+
When elevation is active, dispatch the reasoning-heavy step to a Fable subagent:
|
|
36
|
+
|
|
37
|
+
- Use the platform subagent primitive with a per-agent model override of **fable** (`model: "fable"` on the Claude Code `Agent`/`Task` tool).
|
|
38
|
+
- Pass the main agent's full working context as **file paths the subagent reads itself**, never a re-narrated prose brief. If a needed piece lives only in context, **write it to a fresh scratch file you create** (e.g. `mktemp` under the OS temp dir) rather than skipping it or summarizing it:
|
|
39
|
+
- **Research / grounding evidence.** ce-brainstorm already wrote a Phase 1.1 grounding dossier to a scratch path — pass it. ce-plan consolidates its Phase 1 research findings *in context only* (Phase 1.4 summarizes; it does not write a file), so **serialize those consolidated findings to a scratch file now and pass it** — the elevated author must interpret the same research evidence the inline path had, not just the resulting decisions.
|
|
40
|
+
- **Dialogue / decisions.** Write the accumulated dialogue/decisions this skill holds in context to a fresh scratch file and pass that path too.
|
|
41
|
+
|
|
42
|
+
Re-narration is forbidden: the main model's default tendency is to compress, and a lossy summary is the failure the quality bet cannot absorb — so hand over files, not a summary.
|
|
43
|
+
- Tell the subagent that, for this run, elevation **supersedes this skill's default ceiling-tier convention** — that the reasoning-heavy step runs inline in the main conversation with nothing dispatched — for this step only.
|
|
44
|
+
- Relay the Fable output through the main agent, which stays the orchestrator.
|
|
45
|
+
|
|
46
|
+
The elevated steps: **ce-plan** — interpret research findings and author the plan, folded into one interpret-then-author call. **ce-brainstorm** — generate approaches. The ce-brainstorm integration-check consult is deferred and is NOT wired in this version.
|
|
47
|
+
|
|
48
|
+
## Transparency
|
|
49
|
+
|
|
50
|
+
- `HOST=claude`, elevation fired → surface a brief confirmation that Fable is handling the step.
|
|
51
|
+
- `HOST=claude`, Fable requested but unavailable (no Fable access / failed dispatch) → run the step inline on the main model and surface a brief fallback notice. Elevation is never a correctness dependency and never blocks the workflow.
|
|
52
|
+
- `HOST≠claude` → silent (the gate already stopped before this file loaded).
|
|
53
|
+
|
|
54
|
+
## Discoverability nudge
|
|
55
|
+
|
|
56
|
+
When ALL hold — `HOST=claude`, the run completed with elevation NOT active (no intent, config off), the session is not already on Fable, `fable_nudge` is not `false` in config, this is not a pipeline run, and the tip has not already been shown once — surface the one-line tip, then record that it was shown.
|
|
57
|
+
|
|
58
|
+
"Shown once" is enforced by a **per-user marker file at a stable path outside the repo** (per-user, not per-checkout — e.g. `~/.config/compound-engineering/fable-nudge-seen`). Before showing: if the marker exists, skip the nudge. After showing: create the marker (with its parent dir). A missing marker means "not yet shown."
|
|
59
|
+
|
|
60
|
+
- **ce-plan:** `💡 Tip: add "use fable" to your prompt and Fable will author your plan with deeper reasoning — your session model stays as-is. Set plan_use_fable: true to make it the default.`
|
|
61
|
+
- **ce-brainstorm:** `💡 Tip: say "use fable" and Fable will generate sharper approaches — no session switch needed. Set brainstorm_use_fable: true to default it on.`
|
|
62
|
+
|
|
63
|
+
Never show the nudge when elevation was active (redundant), in pipeline runs (no reader), or off-Claude (the gate stopped earlier).
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
# Session-Settled Decisions
|
|
2
|
+
|
|
3
|
+
Protocol and schema for carrying decisions the user already made in the invoking conversation, so this skill augments them instead of re-litigating them. This file is byte-duplicated between `ce-plan` and `ce-brainstorm` (skills cannot share files); any edit must land in both copies and is guarded by `tests/settled-decisions-parity.test.ts`.
|
|
4
|
+
|
|
5
|
+
## The settlement test
|
|
6
|
+
|
|
7
|
+
Classify each conversation-carried decision by whether it survived examination — not by how confident the user sounded.
|
|
8
|
+
|
|
9
|
+
- **Settled** — a tradeoff, alternative, or risk was surfaced in the conversation and the user chose with it in view. Record with a provenance class (below).
|
|
10
|
+
- **Directive** — the user asserted a choice no one examined (e.g., a cold "build it with X"). Not settled. It receives exactly one in-pipeline challenge, spent during this skill's research/pressure-test phase; the outcome lands in the artifact as a (labeled or unlabeled) decision entry. The artifact is the only challenge ledger — later stages do not get a second challenge, and an unanswered pipeline-surfaced challenge may resurface only through the divergent/residual channel of the calling pipeline.
|
|
11
|
+
- **Unlabeled** — anything only the agent inferred or proposed without user engagement. Ordinary planning input; never annotated.
|
|
12
|
+
|
|
13
|
+
Contrast pair: the user rejected option A after seeing the tradeoff -> settled (`user-directed`); the user said "sounds good" to a passing mention -> at most `user-approved`; the agent proposed X and the user never engaged -> no label.
|
|
14
|
+
|
|
15
|
+
**No self-settling.** An agent never labels its own unexamined proposal, and never upgrades bare assent to `user-directed`. Only the user's conversation acts mint provenance.
|
|
16
|
+
|
|
17
|
+
## Provenance classes
|
|
18
|
+
|
|
19
|
+
Exactly two classes; both render as visible English in the artifact:
|
|
20
|
+
|
|
21
|
+
- `user-directed` — the user chose against or between surfaced options ("no, do X").
|
|
22
|
+
- `user-approved` — the agent proposed with the tradeoff surfaced; the user assented.
|
|
23
|
+
|
|
24
|
+
The class records decision strength for human readers (plan annotation, PR provenance line) and is the relabel target when a later interactive acceptance changes a settled decision (the change was proposed and accepted -> `user-approved`). Consumers do not route differently by class today.
|
|
25
|
+
|
|
26
|
+
## The annotation
|
|
27
|
+
|
|
28
|
+
A settled decision is recorded on its Key Technical Decision entry (plan) or Key Decision entry (brainstorm Product Contract) as an inline English parenthetical:
|
|
29
|
+
|
|
30
|
+
`(session-settled: user-directed — chosen over <alternative>: <one-line reason>)`
|
|
31
|
+
|
|
32
|
+
- The stem `session-settled:` and the class tokens `user-directed` / `user-approved` are stable protocol — greppable and test-pinned. The rest of the sentence is free-form prose.
|
|
33
|
+
- Self-contained: decision, rejected alternative, and reason must be readable by a consumer with no access to the conversation.
|
|
34
|
+
- No sidecar files, no frontmatter registry, no numeric weights, no lifecycle field. An unrecognized consumer sees a normal decision entry; the worst-case degradation is today's re-litigation, never corruption.
|
|
35
|
+
|
|
36
|
+
## Capture rules
|
|
37
|
+
|
|
38
|
+
- Never re-ask a settled decision. In the scoping synthesis it renders as a "Carrying forward:" line, not a call-out, and question phases skip it.
|
|
39
|
+
- Research augments settled decisions and may contradict them only on evidence, routed by the severity ladder: nothing found -> proceed silently; suboptimal-but-workable -> proceed as settled and attach a conflict call-out to the decision entry (artifact-write time only — post-write consumers never mutate the artifact); invalidating (infeasible, wrong-thing, destructive) -> stop as blocked per this skill's pipeline contract.
|
|
40
|
+
- A settled label never suppresses defect evidence: a real bug or infeasibility finding inside a settled approach keeps full severity everywhere.
|
|
41
|
+
- When passing research context to subagents, include settled decisions as scope — with their rejected alternatives, so researchers do not re-survey them — plus the standing line: "If you find evidence a settled decision cannot work, report it — do not suppress it." Do not pass the advocacy or rationale for the decision (the decision as fact scopes the work; advocacy anchors), and keep any adversarial/validation lens blind to settlement markers.
|
|
42
|
+
|
|
43
|
+
## Brief entries (pipeline input)
|
|
44
|
+
|
|
45
|
+
A calling skill (e.g. `lfg`) may pass a distilled brief as invocation input — from the user or a calling skill. Each settled-decision entry requires: the decision, its class, the rejected alternative, and a one-line reason. An entry that cannot state its rejected alternative fails the settlement test — demote it to a directive (one challenge) or an open area. The required fields are a compliance aid; the settlement classification itself remains this skill's judgment. The brief is transient: once the artifact is written with labeled entries, the artifact is canonical and the brief carries no further authority.
|