@harness-engineering/cli 1.14.0 → 1.16.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/agents/commands/codex/AGENTS.md +39 -0
- package/dist/agents/commands/codex/harness/add-harness-component/SKILL.md +195 -0
- package/dist/agents/commands/codex/harness/add-harness-component/agents/openai.yaml +3 -0
- package/dist/agents/commands/codex/harness/cleanup-dead-code/SKILL.md +248 -0
- package/dist/agents/commands/codex/harness/cleanup-dead-code/agents/openai.yaml +3 -0
- package/dist/agents/commands/codex/harness/detect-doc-drift/SKILL.md +182 -0
- package/dist/agents/commands/codex/harness/detect-doc-drift/agents/openai.yaml +3 -0
- package/dist/agents/commands/codex/harness/enforce-architecture/SKILL.md +299 -0
- package/dist/agents/commands/codex/harness/enforce-architecture/agents/openai.yaml +3 -0
- package/dist/agents/commands/codex/harness/harness-architecture-advisor/SKILL.md +452 -0
- package/dist/agents/commands/codex/harness/harness-architecture-advisor/agents/openai.yaml +3 -0
- package/dist/agents/commands/codex/harness/harness-autopilot/SKILL.md +919 -0
- package/dist/agents/commands/codex/harness/harness-autopilot/agents/openai.yaml +3 -0
- package/dist/agents/commands/codex/harness/harness-brainstorming/SKILL.md +409 -0
- package/dist/agents/commands/codex/harness/harness-brainstorming/agents/openai.yaml +3 -0
- package/dist/agents/commands/codex/harness/harness-code-review/SKILL.md +860 -0
- package/dist/agents/commands/codex/harness/harness-code-review/agents/openai.yaml +3 -0
- package/dist/agents/commands/codex/harness/harness-codebase-cleanup/SKILL.md +227 -0
- package/dist/agents/commands/codex/harness/harness-codebase-cleanup/agents/openai.yaml +3 -0
- package/dist/agents/commands/codex/harness/harness-debugging/SKILL.md +369 -0
- package/dist/agents/commands/codex/harness/harness-debugging/agents/openai.yaml +3 -0
- package/dist/agents/commands/codex/harness/harness-dependency-health/SKILL.md +182 -0
- package/dist/agents/commands/codex/harness/harness-dependency-health/agents/openai.yaml +3 -0
- package/dist/agents/commands/codex/harness/harness-docs-pipeline/SKILL.md +463 -0
- package/dist/agents/commands/codex/harness/harness-docs-pipeline/agents/openai.yaml +3 -0
- package/dist/agents/commands/codex/harness/harness-execution/SKILL.md +513 -0
- package/dist/agents/commands/codex/harness/harness-execution/agents/openai.yaml +3 -0
- package/dist/agents/commands/codex/harness/harness-hotspot-detector/SKILL.md +164 -0
- package/dist/agents/commands/codex/harness/harness-hotspot-detector/agents/openai.yaml +3 -0
- package/dist/agents/commands/codex/harness/harness-impact-analysis/SKILL.md +187 -0
- package/dist/agents/commands/codex/harness/harness-impact-analysis/agents/openai.yaml +3 -0
- package/dist/agents/commands/codex/harness/harness-integrity/SKILL.md +170 -0
- package/dist/agents/commands/codex/harness/harness-integrity/agents/openai.yaml +3 -0
- package/dist/agents/commands/codex/harness/harness-onboarding/SKILL.md +291 -0
- package/dist/agents/commands/codex/harness/harness-onboarding/agents/openai.yaml +3 -0
- package/dist/agents/commands/codex/harness/harness-perf/SKILL.md +263 -0
- package/dist/agents/commands/codex/harness/harness-perf/agents/openai.yaml +3 -0
- package/dist/agents/commands/codex/harness/harness-planning/SKILL.md +582 -0
- package/dist/agents/commands/codex/harness/harness-planning/agents/openai.yaml +3 -0
- package/dist/agents/commands/codex/harness/harness-refactoring/SKILL.md +172 -0
- package/dist/agents/commands/codex/harness/harness-refactoring/agents/openai.yaml +3 -0
- package/dist/agents/commands/codex/harness/harness-release-readiness/SKILL.md +692 -0
- package/dist/agents/commands/codex/harness/harness-release-readiness/agents/openai.yaml +3 -0
- package/dist/agents/commands/codex/harness/harness-roadmap/SKILL.md +598 -0
- package/dist/agents/commands/codex/harness/harness-roadmap/agents/openai.yaml +3 -0
- package/dist/agents/commands/codex/harness/harness-security-scan/SKILL.md +157 -0
- package/dist/agents/commands/codex/harness/harness-security-scan/agents/openai.yaml +3 -0
- package/dist/agents/commands/codex/harness/harness-skill-authoring/SKILL.md +295 -0
- package/dist/agents/commands/codex/harness/harness-skill-authoring/agents/openai.yaml +3 -0
- package/dist/agents/commands/codex/harness/harness-soundness-review/SKILL.md +1270 -0
- package/dist/agents/commands/codex/harness/harness-soundness-review/agents/openai.yaml +3 -0
- package/dist/agents/commands/codex/harness/harness-supply-chain-audit/SKILL.md +247 -0
- package/dist/agents/commands/codex/harness/harness-supply-chain-audit/agents/openai.yaml +3 -0
- package/dist/agents/commands/codex/harness/harness-tdd/SKILL.md +180 -0
- package/dist/agents/commands/codex/harness/harness-tdd/agents/openai.yaml +3 -0
- package/dist/agents/commands/codex/harness/harness-test-advisor/SKILL.md +163 -0
- package/dist/agents/commands/codex/harness/harness-test-advisor/agents/openai.yaml +3 -0
- package/dist/agents/commands/codex/harness/harness-verification/SKILL.md +424 -0
- package/dist/agents/commands/codex/harness/harness-verification/agents/openai.yaml +3 -0
- package/dist/agents/commands/codex/harness/harness-verify/SKILL.md +162 -0
- package/dist/agents/commands/codex/harness/harness-verify/agents/openai.yaml +3 -0
- package/dist/agents/commands/codex/harness/initialize-harness-project/SKILL.md +235 -0
- package/dist/agents/commands/codex/harness/initialize-harness-project/agents/openai.yaml +3 -0
- package/dist/agents/commands/cursor/harness/add-harness-component.mdc +200 -0
- package/dist/agents/commands/cursor/harness/cleanup-dead-code.mdc +253 -0
- package/dist/agents/commands/cursor/harness/detect-doc-drift.mdc +187 -0
- package/dist/agents/commands/cursor/harness/enforce-architecture.mdc +304 -0
- package/dist/agents/commands/cursor/harness/harness-architecture-advisor.mdc +457 -0
- package/dist/agents/commands/cursor/harness/harness-autopilot.mdc +924 -0
- package/dist/agents/commands/cursor/harness/harness-brainstorming.mdc +414 -0
- package/dist/agents/commands/cursor/harness/harness-code-review.mdc +865 -0
- package/dist/agents/commands/cursor/harness/harness-codebase-cleanup.mdc +232 -0
- package/dist/agents/commands/cursor/harness/harness-debugging.mdc +374 -0
- package/dist/agents/commands/cursor/harness/harness-dependency-health.mdc +187 -0
- package/dist/agents/commands/cursor/harness/harness-docs-pipeline.mdc +468 -0
- package/dist/agents/commands/cursor/harness/harness-execution.mdc +518 -0
- package/dist/agents/commands/cursor/harness/harness-hotspot-detector.mdc +169 -0
- package/dist/agents/commands/cursor/harness/harness-impact-analysis.mdc +192 -0
- package/dist/agents/commands/cursor/harness/harness-integrity.mdc +175 -0
- package/dist/agents/commands/cursor/harness/harness-onboarding.mdc +296 -0
- package/dist/agents/commands/cursor/harness/harness-perf.mdc +268 -0
- package/dist/agents/commands/cursor/harness/harness-planning.mdc +587 -0
- package/dist/agents/commands/cursor/harness/harness-refactoring.mdc +177 -0
- package/dist/agents/commands/cursor/harness/harness-release-readiness.mdc +697 -0
- package/dist/agents/commands/cursor/harness/harness-roadmap.mdc +603 -0
- package/dist/agents/commands/cursor/harness/harness-security-scan.mdc +162 -0
- package/dist/agents/commands/cursor/harness/harness-skill-authoring.mdc +300 -0
- package/dist/agents/commands/cursor/harness/harness-soundness-review.mdc +1275 -0
- package/dist/agents/commands/cursor/harness/harness-supply-chain-audit.mdc +252 -0
- package/dist/agents/commands/cursor/harness/harness-tdd.mdc +185 -0
- package/dist/agents/commands/cursor/harness/harness-test-advisor.mdc +168 -0
- package/dist/agents/commands/cursor/harness/harness-verification.mdc +429 -0
- package/dist/agents/commands/cursor/harness/harness-verify.mdc +167 -0
- package/dist/agents/commands/cursor/harness/initialize-harness-project.mdc +240 -0
- package/dist/agents/skills/claude-code/enforce-architecture/SKILL.md +52 -0
- package/dist/agents/skills/claude-code/harness-api-design/SKILL.md +52 -0
- package/dist/agents/skills/claude-code/harness-architecture-advisor/SKILL.md +52 -0
- package/dist/agents/skills/claude-code/harness-auth/SKILL.md +52 -0
- package/dist/agents/skills/claude-code/harness-autopilot/SKILL.md +355 -45
- package/dist/agents/skills/claude-code/harness-autopilot/skill.yaml +12 -0
- package/dist/agents/skills/claude-code/harness-code-review/SKILL.md +97 -3
- package/dist/agents/skills/claude-code/harness-code-review/skill.yaml +6 -0
- package/dist/agents/skills/claude-code/harness-codebase-cleanup/SKILL.md +2 -4
- package/dist/agents/skills/claude-code/harness-database/SKILL.md +52 -0
- package/dist/agents/skills/claude-code/harness-deployment/SKILL.md +52 -0
- package/dist/agents/skills/claude-code/harness-planning/SKILL.md +99 -3
- package/dist/agents/skills/claude-code/harness-planning/skill.yaml +6 -0
- package/dist/agents/skills/claude-code/harness-pre-commit-review/SKILL.md +1 -1
- package/dist/agents/skills/claude-code/harness-product-spec/SKILL.md +5 -5
- package/dist/agents/skills/claude-code/harness-security-review/SKILL.md +27 -7
- package/dist/agents/skills/claude-code/harness-security-scan/SKILL.md +52 -0
- package/dist/agents/skills/claude-code/harness-supply-chain-audit/SKILL.md +281 -0
- package/dist/agents/skills/claude-code/harness-supply-chain-audit/skill.yaml +51 -0
- package/dist/agents/skills/codex/add-harness-component/SKILL.md +192 -0
- package/dist/agents/skills/codex/add-harness-component/skill.yaml +33 -0
- package/dist/agents/skills/codex/align-documentation/SKILL.md +213 -0
- package/dist/agents/skills/codex/align-documentation/skill.yaml +32 -0
- package/dist/agents/skills/codex/check-mechanical-constraints/SKILL.md +191 -0
- package/dist/agents/skills/codex/check-mechanical-constraints/skill.yaml +33 -0
- package/dist/agents/skills/codex/cleanup-dead-code/SKILL.md +245 -0
- package/dist/agents/skills/codex/cleanup-dead-code/skill.yaml +34 -0
- package/dist/agents/skills/codex/detect-doc-drift/SKILL.md +179 -0
- package/dist/agents/skills/codex/detect-doc-drift/skill.yaml +31 -0
- package/dist/agents/skills/codex/enforce-architecture/SKILL.md +296 -0
- package/dist/agents/skills/codex/enforce-architecture/skill.yaml +35 -0
- package/dist/agents/skills/codex/harness-accessibility/SKILL.md +281 -0
- package/dist/agents/skills/codex/harness-accessibility/skill.yaml +52 -0
- package/dist/agents/skills/codex/harness-api-design/SKILL.md +356 -0
- package/dist/agents/skills/codex/harness-api-design/skill.yaml +74 -0
- package/dist/agents/skills/codex/harness-architecture-advisor/SKILL.md +449 -0
- package/dist/agents/skills/codex/harness-architecture-advisor/skill.yaml +49 -0
- package/dist/agents/skills/codex/harness-auth/SKILL.md +331 -0
- package/dist/agents/skills/codex/harness-auth/skill.yaml +81 -0
- package/dist/agents/skills/codex/harness-autopilot/SKILL.md +916 -0
- package/dist/agents/skills/codex/harness-autopilot/skill.yaml +67 -0
- package/dist/agents/skills/codex/harness-brainstorming/SKILL.md +406 -0
- package/dist/agents/skills/codex/harness-brainstorming/skill.yaml +50 -0
- package/dist/agents/skills/codex/harness-caching/SKILL.md +309 -0
- package/dist/agents/skills/codex/harness-caching/skill.yaml +73 -0
- package/dist/agents/skills/codex/harness-chaos/SKILL.md +295 -0
- package/dist/agents/skills/codex/harness-chaos/skill.yaml +72 -0
- package/dist/agents/skills/codex/harness-code-review/SKILL.md +857 -0
- package/dist/agents/skills/codex/harness-code-review/skill.yaml +52 -0
- package/dist/agents/skills/codex/harness-codebase-cleanup/SKILL.md +224 -0
- package/dist/agents/skills/codex/harness-codebase-cleanup/skill.yaml +65 -0
- package/dist/agents/skills/codex/harness-compliance/SKILL.md +303 -0
- package/dist/agents/skills/codex/harness-compliance/skill.yaml +78 -0
- package/dist/agents/skills/codex/harness-containerization/SKILL.md +284 -0
- package/dist/agents/skills/codex/harness-containerization/skill.yaml +80 -0
- package/dist/agents/skills/codex/harness-data-pipeline/SKILL.md +274 -0
- package/dist/agents/skills/codex/harness-data-pipeline/skill.yaml +81 -0
- package/dist/agents/skills/codex/harness-data-validation/SKILL.md +343 -0
- package/dist/agents/skills/codex/harness-data-validation/skill.yaml +75 -0
- package/dist/agents/skills/codex/harness-database/SKILL.md +310 -0
- package/dist/agents/skills/codex/harness-database/skill.yaml +80 -0
- package/dist/agents/skills/codex/harness-debugging/SKILL.md +366 -0
- package/dist/agents/skills/codex/harness-debugging/skill.yaml +48 -0
- package/dist/agents/skills/codex/harness-dependency-health/SKILL.md +179 -0
- package/dist/agents/skills/codex/harness-dependency-health/skill.yaml +42 -0
- package/dist/agents/skills/codex/harness-deployment/SKILL.md +307 -0
- package/dist/agents/skills/codex/harness-deployment/skill.yaml +77 -0
- package/dist/agents/skills/codex/harness-design/SKILL.md +265 -0
- package/dist/agents/skills/codex/harness-design/skill.yaml +54 -0
- package/dist/agents/skills/codex/harness-design-mobile/SKILL.md +336 -0
- package/dist/agents/skills/codex/harness-design-mobile/skill.yaml +50 -0
- package/dist/agents/skills/codex/harness-design-system/SKILL.md +282 -0
- package/dist/agents/skills/codex/harness-design-system/skill.yaml +51 -0
- package/dist/agents/skills/codex/harness-design-web/SKILL.md +360 -0
- package/dist/agents/skills/codex/harness-design-web/skill.yaml +53 -0
- package/dist/agents/skills/codex/harness-diagnostics/SKILL.md +318 -0
- package/dist/agents/skills/codex/harness-diagnostics/skill.yaml +51 -0
- package/dist/agents/skills/codex/harness-docs-pipeline/SKILL.md +460 -0
- package/dist/agents/skills/codex/harness-docs-pipeline/skill.yaml +70 -0
- package/dist/agents/skills/codex/harness-dx/SKILL.md +276 -0
- package/dist/agents/skills/codex/harness-dx/skill.yaml +76 -0
- package/dist/agents/skills/codex/harness-e2e/SKILL.md +245 -0
- package/dist/agents/skills/codex/harness-e2e/skill.yaml +78 -0
- package/dist/agents/skills/codex/harness-event-driven/SKILL.md +280 -0
- package/dist/agents/skills/codex/harness-event-driven/skill.yaml +77 -0
- package/dist/agents/skills/codex/harness-execution/SKILL.md +510 -0
- package/dist/agents/skills/codex/harness-execution/skill.yaml +52 -0
- package/dist/agents/skills/codex/harness-feature-flags/SKILL.md +287 -0
- package/dist/agents/skills/codex/harness-feature-flags/skill.yaml +74 -0
- package/dist/agents/skills/codex/harness-git-workflow/SKILL.md +268 -0
- package/dist/agents/skills/codex/harness-git-workflow/skill.yaml +32 -0
- package/dist/agents/skills/codex/harness-hotspot-detector/SKILL.md +161 -0
- package/dist/agents/skills/codex/harness-hotspot-detector/skill.yaml +45 -0
- package/dist/agents/skills/codex/harness-i18n/SKILL.md +484 -0
- package/dist/agents/skills/codex/harness-i18n/skill.yaml +55 -0
- package/dist/agents/skills/codex/harness-i18n-process/SKILL.md +388 -0
- package/dist/agents/skills/codex/harness-i18n-process/skill.yaml +44 -0
- package/dist/agents/skills/codex/harness-i18n-workflow/SKILL.md +512 -0
- package/dist/agents/skills/codex/harness-i18n-workflow/skill.yaml +54 -0
- package/dist/agents/skills/codex/harness-impact-analysis/SKILL.md +184 -0
- package/dist/agents/skills/codex/harness-impact-analysis/skill.yaml +45 -0
- package/dist/agents/skills/codex/harness-incident-response/SKILL.md +223 -0
- package/dist/agents/skills/codex/harness-incident-response/skill.yaml +78 -0
- package/dist/agents/skills/codex/harness-infrastructure-as-code/SKILL.md +279 -0
- package/dist/agents/skills/codex/harness-infrastructure-as-code/skill.yaml +80 -0
- package/dist/agents/skills/codex/harness-integration-test/SKILL.md +271 -0
- package/dist/agents/skills/codex/harness-integration-test/skill.yaml +73 -0
- package/dist/agents/skills/codex/harness-integrity/SKILL.md +167 -0
- package/dist/agents/skills/codex/harness-integrity/skill.yaml +48 -0
- package/dist/agents/skills/codex/harness-knowledge-mapper/SKILL.md +195 -0
- package/dist/agents/skills/codex/harness-knowledge-mapper/skill.yaml +50 -0
- package/dist/agents/skills/codex/harness-load-testing/SKILL.md +274 -0
- package/dist/agents/skills/codex/harness-load-testing/skill.yaml +79 -0
- package/dist/agents/skills/codex/harness-ml-ops/SKILL.md +341 -0
- package/dist/agents/skills/codex/harness-ml-ops/skill.yaml +79 -0
- package/dist/agents/skills/codex/harness-mobile-patterns/SKILL.md +326 -0
- package/dist/agents/skills/codex/harness-mobile-patterns/skill.yaml +82 -0
- package/dist/agents/skills/codex/harness-mutation-test/SKILL.md +251 -0
- package/dist/agents/skills/codex/harness-mutation-test/skill.yaml +70 -0
- package/dist/agents/skills/codex/harness-observability/SKILL.md +283 -0
- package/dist/agents/skills/codex/harness-observability/skill.yaml +78 -0
- package/dist/agents/skills/codex/harness-onboarding/SKILL.md +288 -0
- package/dist/agents/skills/codex/harness-onboarding/skill.yaml +31 -0
- package/dist/agents/skills/codex/harness-parallel-agents/SKILL.md +256 -0
- package/dist/agents/skills/codex/harness-parallel-agents/skill.yaml +34 -0
- package/dist/agents/skills/codex/harness-perf/SKILL.md +260 -0
- package/dist/agents/skills/codex/harness-perf/skill.yaml +51 -0
- package/dist/agents/skills/codex/harness-perf-tdd/SKILL.md +249 -0
- package/dist/agents/skills/codex/harness-perf-tdd/skill.yaml +48 -0
- package/dist/agents/skills/codex/harness-planning/SKILL.md +579 -0
- package/dist/agents/skills/codex/harness-planning/skill.yaml +56 -0
- package/dist/agents/skills/codex/harness-pre-commit-review/SKILL.md +324 -0
- package/dist/agents/skills/codex/harness-pre-commit-review/skill.yaml +34 -0
- package/dist/agents/skills/codex/harness-product-spec/SKILL.md +285 -0
- package/dist/agents/skills/codex/harness-product-spec/skill.yaml +72 -0
- package/dist/agents/skills/codex/harness-property-test/SKILL.md +281 -0
- package/dist/agents/skills/codex/harness-property-test/skill.yaml +71 -0
- package/dist/agents/skills/codex/harness-refactoring/SKILL.md +169 -0
- package/dist/agents/skills/codex/harness-refactoring/skill.yaml +34 -0
- package/dist/agents/skills/codex/harness-release-readiness/SKILL.md +689 -0
- package/dist/agents/skills/codex/harness-release-readiness/skill.yaml +58 -0
- package/dist/agents/skills/codex/harness-resilience/SKILL.md +255 -0
- package/dist/agents/skills/codex/harness-resilience/skill.yaml +76 -0
- package/dist/agents/skills/codex/harness-roadmap/SKILL.md +595 -0
- package/dist/agents/skills/codex/harness-roadmap/skill.yaml +44 -0
- package/dist/agents/skills/codex/harness-secrets/SKILL.md +293 -0
- package/dist/agents/skills/codex/harness-secrets/skill.yaml +76 -0
- package/dist/agents/skills/codex/harness-security-review/SKILL.md +260 -0
- package/dist/agents/skills/codex/harness-security-review/skill.yaml +53 -0
- package/dist/agents/skills/codex/harness-security-scan/SKILL.md +154 -0
- package/dist/agents/skills/codex/harness-security-scan/skill.yaml +42 -0
- package/dist/agents/skills/codex/harness-skill-authoring/SKILL.md +292 -0
- package/dist/agents/skills/codex/harness-skill-authoring/skill.yaml +33 -0
- package/dist/agents/skills/codex/harness-soundness-review/SKILL.md +1267 -0
- package/dist/agents/skills/codex/harness-soundness-review/skill.yaml +49 -0
- package/dist/agents/skills/codex/harness-sql-review/SKILL.md +315 -0
- package/dist/agents/skills/codex/harness-sql-review/skill.yaml +74 -0
- package/dist/agents/skills/codex/harness-state-management/SKILL.md +309 -0
- package/dist/agents/skills/codex/harness-state-management/skill.yaml +33 -0
- package/dist/agents/skills/codex/harness-supply-chain-audit/SKILL.md +281 -0
- package/dist/agents/skills/codex/harness-supply-chain-audit/skill.yaml +51 -0
- package/dist/agents/skills/codex/harness-tdd/SKILL.md +177 -0
- package/dist/agents/skills/codex/harness-tdd/skill.yaml +49 -0
- package/dist/agents/skills/codex/harness-test-advisor/SKILL.md +160 -0
- package/dist/agents/skills/codex/harness-test-advisor/skill.yaml +45 -0
- package/dist/agents/skills/codex/harness-test-data/SKILL.md +268 -0
- package/dist/agents/skills/codex/harness-test-data/skill.yaml +74 -0
- package/dist/agents/skills/codex/harness-ux-copy/SKILL.md +271 -0
- package/dist/agents/skills/codex/harness-ux-copy/skill.yaml +77 -0
- package/dist/agents/skills/codex/harness-verification/SKILL.md +421 -0
- package/dist/agents/skills/codex/harness-verification/skill.yaml +43 -0
- package/dist/agents/skills/codex/harness-verify/SKILL.md +159 -0
- package/dist/agents/skills/codex/harness-verify/skill.yaml +41 -0
- package/dist/agents/skills/codex/harness-visual-regression/SKILL.md +257 -0
- package/dist/agents/skills/codex/harness-visual-regression/skill.yaml +74 -0
- package/dist/agents/skills/codex/initialize-harness-project/SKILL.md +232 -0
- package/dist/agents/skills/codex/initialize-harness-project/skill.yaml +32 -0
- package/dist/agents/skills/codex/validate-context-engineering/SKILL.md +150 -0
- package/dist/agents/skills/codex/validate-context-engineering/skill.yaml +32 -0
- package/dist/agents/skills/cursor/add-harness-component/SKILL.md +192 -0
- package/dist/agents/skills/cursor/add-harness-component/skill.yaml +33 -0
- package/dist/agents/skills/cursor/align-documentation/SKILL.md +213 -0
- package/dist/agents/skills/cursor/align-documentation/skill.yaml +32 -0
- package/dist/agents/skills/cursor/check-mechanical-constraints/SKILL.md +191 -0
- package/dist/agents/skills/cursor/check-mechanical-constraints/skill.yaml +33 -0
- package/dist/agents/skills/cursor/cleanup-dead-code/SKILL.md +245 -0
- package/dist/agents/skills/cursor/cleanup-dead-code/skill.yaml +34 -0
- package/dist/agents/skills/cursor/detect-doc-drift/SKILL.md +179 -0
- package/dist/agents/skills/cursor/detect-doc-drift/skill.yaml +31 -0
- package/dist/agents/skills/cursor/enforce-architecture/SKILL.md +296 -0
- package/dist/agents/skills/cursor/enforce-architecture/skill.yaml +35 -0
- package/dist/agents/skills/cursor/harness-accessibility/SKILL.md +281 -0
- package/dist/agents/skills/cursor/harness-accessibility/skill.yaml +52 -0
- package/dist/agents/skills/cursor/harness-api-design/SKILL.md +356 -0
- package/dist/agents/skills/cursor/harness-api-design/skill.yaml +74 -0
- package/dist/agents/skills/cursor/harness-architecture-advisor/SKILL.md +449 -0
- package/dist/agents/skills/cursor/harness-architecture-advisor/skill.yaml +49 -0
- package/dist/agents/skills/cursor/harness-auth/SKILL.md +331 -0
- package/dist/agents/skills/cursor/harness-auth/skill.yaml +81 -0
- package/dist/agents/skills/cursor/harness-autopilot/SKILL.md +916 -0
- package/dist/agents/skills/cursor/harness-autopilot/skill.yaml +67 -0
- package/dist/agents/skills/cursor/harness-brainstorming/SKILL.md +406 -0
- package/dist/agents/skills/cursor/harness-brainstorming/skill.yaml +50 -0
- package/dist/agents/skills/cursor/harness-caching/SKILL.md +309 -0
- package/dist/agents/skills/cursor/harness-caching/skill.yaml +73 -0
- package/dist/agents/skills/cursor/harness-chaos/SKILL.md +295 -0
- package/dist/agents/skills/cursor/harness-chaos/skill.yaml +72 -0
- package/dist/agents/skills/cursor/harness-code-review/SKILL.md +857 -0
- package/dist/agents/skills/cursor/harness-code-review/skill.yaml +52 -0
- package/dist/agents/skills/cursor/harness-codebase-cleanup/SKILL.md +224 -0
- package/dist/agents/skills/cursor/harness-codebase-cleanup/skill.yaml +65 -0
- package/dist/agents/skills/cursor/harness-compliance/SKILL.md +303 -0
- package/dist/agents/skills/cursor/harness-compliance/skill.yaml +78 -0
- package/dist/agents/skills/cursor/harness-containerization/SKILL.md +284 -0
- package/dist/agents/skills/cursor/harness-containerization/skill.yaml +80 -0
- package/dist/agents/skills/cursor/harness-data-pipeline/SKILL.md +274 -0
- package/dist/agents/skills/cursor/harness-data-pipeline/skill.yaml +81 -0
- package/dist/agents/skills/cursor/harness-data-validation/SKILL.md +343 -0
- package/dist/agents/skills/cursor/harness-data-validation/skill.yaml +75 -0
- package/dist/agents/skills/cursor/harness-database/SKILL.md +310 -0
- package/dist/agents/skills/cursor/harness-database/skill.yaml +80 -0
- package/dist/agents/skills/cursor/harness-debugging/SKILL.md +366 -0
- package/dist/agents/skills/cursor/harness-debugging/skill.yaml +48 -0
- package/dist/agents/skills/cursor/harness-dependency-health/SKILL.md +179 -0
- package/dist/agents/skills/cursor/harness-dependency-health/skill.yaml +42 -0
- package/dist/agents/skills/cursor/harness-deployment/SKILL.md +307 -0
- package/dist/agents/skills/cursor/harness-deployment/skill.yaml +77 -0
- package/dist/agents/skills/cursor/harness-design/SKILL.md +265 -0
- package/dist/agents/skills/cursor/harness-design/skill.yaml +54 -0
- package/dist/agents/skills/cursor/harness-design-mobile/SKILL.md +336 -0
- package/dist/agents/skills/cursor/harness-design-mobile/skill.yaml +50 -0
- package/dist/agents/skills/cursor/harness-design-system/SKILL.md +282 -0
- package/dist/agents/skills/cursor/harness-design-system/skill.yaml +51 -0
- package/dist/agents/skills/cursor/harness-design-web/SKILL.md +360 -0
- package/dist/agents/skills/cursor/harness-design-web/skill.yaml +53 -0
- package/dist/agents/skills/cursor/harness-diagnostics/SKILL.md +318 -0
- package/dist/agents/skills/cursor/harness-diagnostics/skill.yaml +51 -0
- package/dist/agents/skills/cursor/harness-docs-pipeline/SKILL.md +460 -0
- package/dist/agents/skills/cursor/harness-docs-pipeline/skill.yaml +70 -0
- package/dist/agents/skills/cursor/harness-dx/SKILL.md +276 -0
- package/dist/agents/skills/cursor/harness-dx/skill.yaml +76 -0
- package/dist/agents/skills/cursor/harness-e2e/SKILL.md +245 -0
- package/dist/agents/skills/cursor/harness-e2e/skill.yaml +78 -0
- package/dist/agents/skills/cursor/harness-event-driven/SKILL.md +280 -0
- package/dist/agents/skills/cursor/harness-event-driven/skill.yaml +77 -0
- package/dist/agents/skills/cursor/harness-execution/SKILL.md +510 -0
- package/dist/agents/skills/cursor/harness-execution/skill.yaml +52 -0
- package/dist/agents/skills/cursor/harness-feature-flags/SKILL.md +287 -0
- package/dist/agents/skills/cursor/harness-feature-flags/skill.yaml +74 -0
- package/dist/agents/skills/cursor/harness-git-workflow/SKILL.md +268 -0
- package/dist/agents/skills/cursor/harness-git-workflow/skill.yaml +32 -0
- package/dist/agents/skills/cursor/harness-hotspot-detector/SKILL.md +161 -0
- package/dist/agents/skills/cursor/harness-hotspot-detector/skill.yaml +45 -0
- package/dist/agents/skills/cursor/harness-i18n/SKILL.md +484 -0
- package/dist/agents/skills/cursor/harness-i18n/skill.yaml +55 -0
- package/dist/agents/skills/cursor/harness-i18n-process/SKILL.md +388 -0
- package/dist/agents/skills/cursor/harness-i18n-process/skill.yaml +44 -0
- package/dist/agents/skills/cursor/harness-i18n-workflow/SKILL.md +512 -0
- package/dist/agents/skills/cursor/harness-i18n-workflow/skill.yaml +54 -0
- package/dist/agents/skills/cursor/harness-impact-analysis/SKILL.md +184 -0
- package/dist/agents/skills/cursor/harness-impact-analysis/skill.yaml +45 -0
- package/dist/agents/skills/cursor/harness-incident-response/SKILL.md +223 -0
- package/dist/agents/skills/cursor/harness-incident-response/skill.yaml +78 -0
- package/dist/agents/skills/cursor/harness-infrastructure-as-code/SKILL.md +279 -0
- package/dist/agents/skills/cursor/harness-infrastructure-as-code/skill.yaml +80 -0
- package/dist/agents/skills/cursor/harness-integration-test/SKILL.md +271 -0
- package/dist/agents/skills/cursor/harness-integration-test/skill.yaml +73 -0
- package/dist/agents/skills/cursor/harness-integrity/SKILL.md +167 -0
- package/dist/agents/skills/cursor/harness-integrity/skill.yaml +48 -0
- package/dist/agents/skills/cursor/harness-knowledge-mapper/SKILL.md +195 -0
- package/dist/agents/skills/cursor/harness-knowledge-mapper/skill.yaml +50 -0
- package/dist/agents/skills/cursor/harness-load-testing/SKILL.md +274 -0
- package/dist/agents/skills/cursor/harness-load-testing/skill.yaml +79 -0
- package/dist/agents/skills/cursor/harness-ml-ops/SKILL.md +341 -0
- package/dist/agents/skills/cursor/harness-ml-ops/skill.yaml +79 -0
- package/dist/agents/skills/cursor/harness-mobile-patterns/SKILL.md +326 -0
- package/dist/agents/skills/cursor/harness-mobile-patterns/skill.yaml +82 -0
- package/dist/agents/skills/cursor/harness-mutation-test/SKILL.md +251 -0
- package/dist/agents/skills/cursor/harness-mutation-test/skill.yaml +70 -0
- package/dist/agents/skills/cursor/harness-observability/SKILL.md +283 -0
- package/dist/agents/skills/cursor/harness-observability/skill.yaml +78 -0
- package/dist/agents/skills/cursor/harness-onboarding/SKILL.md +288 -0
- package/dist/agents/skills/cursor/harness-onboarding/skill.yaml +31 -0
- package/dist/agents/skills/cursor/harness-parallel-agents/SKILL.md +256 -0
- package/dist/agents/skills/cursor/harness-parallel-agents/skill.yaml +34 -0
- package/dist/agents/skills/cursor/harness-perf/SKILL.md +260 -0
- package/dist/agents/skills/cursor/harness-perf/skill.yaml +51 -0
- package/dist/agents/skills/cursor/harness-perf-tdd/SKILL.md +249 -0
- package/dist/agents/skills/cursor/harness-perf-tdd/skill.yaml +48 -0
- package/dist/agents/skills/cursor/harness-planning/SKILL.md +579 -0
- package/dist/agents/skills/cursor/harness-planning/skill.yaml +56 -0
- package/dist/agents/skills/cursor/harness-pre-commit-review/SKILL.md +324 -0
- package/dist/agents/skills/cursor/harness-pre-commit-review/skill.yaml +34 -0
- package/dist/agents/skills/cursor/harness-product-spec/SKILL.md +285 -0
- package/dist/agents/skills/cursor/harness-product-spec/skill.yaml +72 -0
- package/dist/agents/skills/cursor/harness-property-test/SKILL.md +281 -0
- package/dist/agents/skills/cursor/harness-property-test/skill.yaml +71 -0
- package/dist/agents/skills/cursor/harness-refactoring/SKILL.md +169 -0
- package/dist/agents/skills/cursor/harness-refactoring/skill.yaml +34 -0
- package/dist/agents/skills/cursor/harness-release-readiness/SKILL.md +689 -0
- package/dist/agents/skills/cursor/harness-release-readiness/skill.yaml +58 -0
- package/dist/agents/skills/cursor/harness-resilience/SKILL.md +255 -0
- package/dist/agents/skills/cursor/harness-resilience/skill.yaml +76 -0
- package/dist/agents/skills/cursor/harness-roadmap/SKILL.md +595 -0
- package/dist/agents/skills/cursor/harness-roadmap/skill.yaml +44 -0
- package/dist/agents/skills/cursor/harness-secrets/SKILL.md +293 -0
- package/dist/agents/skills/cursor/harness-secrets/skill.yaml +76 -0
- package/dist/agents/skills/cursor/harness-security-review/SKILL.md +260 -0
- package/dist/agents/skills/cursor/harness-security-review/skill.yaml +53 -0
- package/dist/agents/skills/cursor/harness-security-scan/SKILL.md +154 -0
- package/dist/agents/skills/cursor/harness-security-scan/skill.yaml +42 -0
- package/dist/agents/skills/cursor/harness-skill-authoring/SKILL.md +292 -0
- package/dist/agents/skills/cursor/harness-skill-authoring/skill.yaml +33 -0
- package/dist/agents/skills/cursor/harness-soundness-review/SKILL.md +1267 -0
- package/dist/agents/skills/cursor/harness-soundness-review/skill.yaml +49 -0
- package/dist/agents/skills/cursor/harness-sql-review/SKILL.md +315 -0
- package/dist/agents/skills/cursor/harness-sql-review/skill.yaml +74 -0
- package/dist/agents/skills/cursor/harness-state-management/SKILL.md +309 -0
- package/dist/agents/skills/cursor/harness-state-management/skill.yaml +33 -0
- package/dist/agents/skills/cursor/harness-supply-chain-audit/SKILL.md +281 -0
- package/dist/agents/skills/cursor/harness-supply-chain-audit/skill.yaml +51 -0
- package/dist/agents/skills/cursor/harness-tdd/SKILL.md +177 -0
- package/dist/agents/skills/cursor/harness-tdd/skill.yaml +49 -0
- package/dist/agents/skills/cursor/harness-test-advisor/SKILL.md +160 -0
- package/dist/agents/skills/cursor/harness-test-advisor/skill.yaml +45 -0
- package/dist/agents/skills/cursor/harness-test-data/SKILL.md +268 -0
- package/dist/agents/skills/cursor/harness-test-data/skill.yaml +74 -0
- package/dist/agents/skills/cursor/harness-ux-copy/SKILL.md +271 -0
- package/dist/agents/skills/cursor/harness-ux-copy/skill.yaml +77 -0
- package/dist/agents/skills/cursor/harness-verification/SKILL.md +421 -0
- package/dist/agents/skills/cursor/harness-verification/skill.yaml +43 -0
- package/dist/agents/skills/cursor/harness-verify/SKILL.md +159 -0
- package/dist/agents/skills/cursor/harness-verify/skill.yaml +41 -0
- package/dist/agents/skills/cursor/harness-visual-regression/SKILL.md +257 -0
- package/dist/agents/skills/cursor/harness-visual-regression/skill.yaml +74 -0
- package/dist/agents/skills/cursor/initialize-harness-project/SKILL.md +232 -0
- package/dist/agents/skills/cursor/initialize-harness-project/skill.yaml +32 -0
- package/dist/agents/skills/cursor/validate-context-engineering/SKILL.md +150 -0
- package/dist/agents/skills/cursor/validate-context-engineering/skill.yaml +32 -0
- package/dist/agents/skills/gemini-cli/enforce-architecture/SKILL.md +52 -0
- package/dist/agents/skills/gemini-cli/harness-api-design/SKILL.md +52 -0
- package/dist/agents/skills/gemini-cli/harness-architecture-advisor/SKILL.md +52 -0
- package/dist/agents/skills/gemini-cli/harness-auth/SKILL.md +52 -0
- package/dist/agents/skills/gemini-cli/harness-autopilot/SKILL.md +355 -45
- package/dist/agents/skills/gemini-cli/harness-autopilot/skill.yaml +12 -0
- package/dist/agents/skills/gemini-cli/harness-code-review/SKILL.md +97 -3
- package/dist/agents/skills/gemini-cli/harness-code-review/skill.yaml +6 -0
- package/dist/agents/skills/gemini-cli/harness-codebase-cleanup/SKILL.md +2 -4
- package/dist/agents/skills/gemini-cli/harness-database/SKILL.md +52 -0
- package/dist/agents/skills/gemini-cli/harness-deployment/SKILL.md +52 -0
- package/dist/agents/skills/gemini-cli/harness-planning/SKILL.md +99 -3
- package/dist/agents/skills/gemini-cli/harness-planning/skill.yaml +6 -0
- package/dist/agents/skills/gemini-cli/harness-pre-commit-review/SKILL.md +1 -1
- package/dist/agents/skills/gemini-cli/harness-product-spec/SKILL.md +5 -5
- package/dist/agents/skills/gemini-cli/harness-security-review/SKILL.md +27 -7
- package/dist/agents/skills/gemini-cli/harness-security-scan/SKILL.md +52 -0
- package/dist/agents/skills/gemini-cli/harness-supply-chain-audit/SKILL.md +281 -0
- package/dist/agents/skills/gemini-cli/harness-supply-chain-audit/skill.yaml +51 -0
- package/dist/agents/skills/package.json +1 -0
- package/dist/agents/skills/templates/discipline-template.md +49 -0
- package/dist/agents/skills/tests/schema.ts +1 -1
- package/dist/agents/skills/vitest.config.mts +5 -0
- package/dist/{agents-md-YTYQDA3P.js → agents-md-VYDFPIRW.js} +1 -1
- package/dist/{architecture-JQZYM4US.js → architecture-K5HSRBGB.js} +2 -2
- package/dist/bin/harness-mcp.js +13 -13
- package/dist/bin/harness.js +21 -19
- package/dist/{check-phase-gate-L3RADYWO.js → check-phase-gate-5AS6SXL6.js} +3 -3
- package/dist/{chunk-6KTUUFRN.js → chunk-5ZXHMCPL.js} +1 -1
- package/dist/{chunk-RCWZBSK5.js → chunk-6KWBH4EO.js} +1 -1
- package/dist/{chunk-ABQHQ6I5.js → chunk-ALFKNAZW.js} +2436 -233
- package/dist/{chunk-OXLLOSSR.js → chunk-AV6KMDO5.js} +2 -2
- package/dist/{chunk-7IP4JIFL.js → chunk-C7DTKLPW.js} +4 -4
- package/dist/{chunk-ZOAWBDWU.js → chunk-CJDVBBPB.js} +5 -1
- package/dist/{chunk-YPYGXRDR.js → chunk-DNDBFIZN.js} +18 -4
- package/dist/{chunk-XYLGHKG6.js → chunk-HKUX2X7O.js} +11 -2
- package/dist/{chunk-YZD2MRNQ.js → chunk-JOP2NDNB.js} +684 -142
- package/dist/{chunk-YBJ262QL.js → chunk-LRG3B43J.js} +1 -1
- package/dist/{chunk-AOZRDOIP.js → chunk-M6TIO6NF.js} +1 -1
- package/dist/{chunk-O5OJVPL6.js → chunk-OCDDCGDE.js} +9 -1
- package/dist/{chunk-OSXBPAMK.js → chunk-QDF7COPQ.js} +1 -1
- package/dist/{chunk-TPOTOBR7.js → chunk-RWZPHW4H.js} +3 -3
- package/dist/{chunk-3C2MLBPJ.js → chunk-SFRGPAK6.js} +1 -1
- package/dist/{chunk-XKECDXJS.js → chunk-SHYWICGA.js} +2184 -456
- package/dist/{chunk-S2FXOWOR.js → chunk-TF6ZLHJV.js} +2 -2
- package/dist/{chunk-NLVUVUGD.js → chunk-ZJMU7MEV.js} +1 -1
- package/dist/{ci-workflow-EQZFVX3P.js → ci-workflow-CRWU723U.js} +1 -1
- package/dist/{create-skill-XSWHMSM5.js → create-skill-NDXQSTIK.js} +2 -2
- package/dist/{dist-HWXF2C3R.js → dist-4LPXJYVZ.js} +105 -1
- package/dist/{docs-7ECGYMAV.js → docs-4JRHTLUZ.js} +3 -3
- package/dist/{engine-EG4EH4IX.js → engine-3G3VIM6L.js} +1 -1
- package/dist/{entropy-5USWKLVS.js → entropy-G6CZ2A6P.js} +2 -2
- package/dist/{feedback-UTBXZZHF.js → feedback-QYKQ65HB.js} +1 -1
- package/dist/{generate-agent-definitions-3PM5EU7V.js → generate-agent-definitions-SAAOAPT4.js} +3 -3
- package/dist/index.d.ts +25 -4
- package/dist/index.js +18 -18
- package/dist/{loader-ZPALXIVR.js → loader-VCOK3PF7.js} +1 -1
- package/dist/{mcp-362EZHF4.js → mcp-YENEPHBW.js} +13 -13
- package/dist/{performance-OQAFMJUD.js → performance-UBCFI2UP.js} +4 -2
- package/dist/{review-pipeline-C4GCFVGP.js → review-pipeline-IQAVCWAX.js} +1 -1
- package/dist/{runtime-7YLVK453.js → runtime-PYFFIESU.js} +1 -1
- package/dist/{security-PZOX7AQS.js → security-ZDADTPYW.js} +1 -1
- package/dist/{skill-executor-XZLYZYAK.js → skill-executor-XEVDGXUM.js} +2 -2
- package/dist/{validate-FD3Z6VJD.js → validate-VRTUHALQ.js} +2 -2
- package/dist/{validate-cross-check-WNJM6H2D.js → validate-cross-check-4Y6NHNK3.js} +1 -1
- package/package.json +8 -5
|
@@ -0,0 +1,309 @@
|
|
|
1
|
+
# Harness State Management
|
|
2
|
+
|
|
3
|
+
> Manage persistent state across agent sessions so that context, decisions, progress, and learnings survive context resets. Load state at session start, track position and decisions throughout, and save state for the next session.
|
|
4
|
+
|
|
5
|
+
## When to Use
|
|
6
|
+
|
|
7
|
+
- At the start of every session that continues previous work (load state)
|
|
8
|
+
- When completing a task, phase, or milestone (update progress)
|
|
9
|
+
- When making a decision that future sessions need to know about (record decision)
|
|
10
|
+
- When discovering something non-obvious that would be lost on context reset (capture learning)
|
|
11
|
+
- When hitting a blocker that cannot be resolved in the current session (log blocker)
|
|
12
|
+
- At the end of every session (save state)
|
|
13
|
+
- NOT for storing code — code belongs in git commits, not state files
|
|
14
|
+
- NOT for storing large outputs or logs — state should be concise and navigable
|
|
15
|
+
- NOT as a replacement for a plan document — plans live in `docs/`, state tracks progress through plans
|
|
16
|
+
|
|
17
|
+
## Process
|
|
18
|
+
|
|
19
|
+
### Phase 1: LOAD — Restore Context from Previous Sessions
|
|
20
|
+
|
|
21
|
+
0. **Resolve the stream.** State is organized into streams — isolated directories under `.harness/streams/<name>/`. Before loading any state files:
|
|
22
|
+
- If you know which work item you're resuming, pass `--stream <name>` or use `manage_state` with `stream: "<name>"`.
|
|
23
|
+
- Otherwise, the system auto-resolves from the current git branch (e.g., `feature/auth-rework` → `auth-rework` stream) or falls back to the active stream.
|
|
24
|
+
- If resolution fails, ask the user: "Which stream should I use?" and list known streams via `harness state streams list` or the `list_streams` MCP tool.
|
|
25
|
+
- When starting new work on a new branch, create a new stream: `harness state streams create <name> --branch <branch>`.
|
|
26
|
+
- Announce which stream was resolved so the human has visibility.
|
|
27
|
+
|
|
28
|
+
1. **Read `.harness/state.json`.** This is the primary state file. It contains:
|
|
29
|
+
- Current position (phase, task, step)
|
|
30
|
+
- Progress map (which tasks are complete, in progress, or blocked)
|
|
31
|
+
- Decisions made in previous sessions (date, what, why)
|
|
32
|
+
- Blockers encountered and their status
|
|
33
|
+
- Last session summary
|
|
34
|
+
|
|
35
|
+
2. **Run `harness state show`** to get a formatted view of current state. This is equivalent to reading the JSON but formatted for readability.
|
|
36
|
+
|
|
37
|
+
3. **Read `.harness/learnings.md`.** This is the append-only knowledge base. Scan for:
|
|
38
|
+
- Recent learnings (last 2-3 sessions) — these are most likely still relevant
|
|
39
|
+
- Gotchas and warnings — these prevent repeating mistakes
|
|
40
|
+
- Decisions with rationale — these explain why things are the way they are
|
|
41
|
+
|
|
42
|
+
4. **Read `.harness/failures.md` if exists.** Scan for active anti-patterns and dead ends.
|
|
43
|
+
|
|
44
|
+
5. **Read `.harness/handoff.json` if exists.** Structured context from last skill.
|
|
45
|
+
|
|
46
|
+
6. **Check `.harness/archive/` for historical failure logs.**
|
|
47
|
+
|
|
48
|
+
7. **If no state exists,** this is a fresh start. Create `.harness/state.json` with initial structure:
|
|
49
|
+
|
|
50
|
+
```json
|
|
51
|
+
{
|
|
52
|
+
"schemaVersion": 1,
|
|
53
|
+
"position": { "phase": "start", "task": null },
|
|
54
|
+
"progress": {},
|
|
55
|
+
"decisions": [],
|
|
56
|
+
"blockers": [],
|
|
57
|
+
"lastSession": { "date": null, "summary": null }
|
|
58
|
+
}
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
8. **Announce the loaded context.** Briefly summarize: "Resuming from [position]. [N] tasks complete. [N] blockers. Key learnings: [summary]." This confirms the state was loaded and gives the human visibility.
|
|
62
|
+
|
|
63
|
+
### Phase 2: TRACK — Maintain State During the Session
|
|
64
|
+
|
|
65
|
+
1. **Update position when moving between phases or tasks.** Every time work shifts to a new task or phase, update `position` in state:
|
|
66
|
+
|
|
67
|
+
```json
|
|
68
|
+
"position": { "phase": "execute", "task": "Task 3", "step": "writing tests" }
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
2. **Record decisions when they are made.** Decisions are choices that affect future work. Record them immediately — do not wait until the end of the session:
|
|
72
|
+
|
|
73
|
+
```json
|
|
74
|
+
"decisions": [
|
|
75
|
+
{
|
|
76
|
+
"date": "2026-03-14",
|
|
77
|
+
"what": "Use WebSocket instead of SSE for real-time notifications",
|
|
78
|
+
"why": "SSE does not support bidirectional communication, which Task 5 requires"
|
|
79
|
+
}
|
|
80
|
+
]
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
3. **Log blockers when encountered.** A blocker is anything that prevents the current task from completing:
|
|
84
|
+
|
|
85
|
+
```json
|
|
86
|
+
"blockers": [
|
|
87
|
+
{
|
|
88
|
+
"date": "2026-03-14",
|
|
89
|
+
"task": "Task 4",
|
|
90
|
+
"description": "Payment gateway API returns 403 — API key may be expired",
|
|
91
|
+
"status": "open"
|
|
92
|
+
}
|
|
93
|
+
]
|
|
94
|
+
```
|
|
95
|
+
|
|
96
|
+
4. **Update progress after each completed task:**
|
|
97
|
+
|
|
98
|
+
```json
|
|
99
|
+
"progress": {
|
|
100
|
+
"Task 1": "complete",
|
|
101
|
+
"Task 2": "complete",
|
|
102
|
+
"Task 3": "in_progress",
|
|
103
|
+
"Task 4": "blocked"
|
|
104
|
+
}
|
|
105
|
+
```
|
|
106
|
+
|
|
107
|
+
5. **Keep state concise.** State is not a log. Each field should contain the current status, not a history of all changes. History belongs in `.harness/learnings.md` and git commits.
|
|
108
|
+
|
|
109
|
+
### Phase 3: LEARN — Capture Knowledge for Future Sessions
|
|
110
|
+
|
|
111
|
+
1. **Identify learnings as they happen.** A learning is anything that:
|
|
112
|
+
- Was surprising or non-obvious
|
|
113
|
+
- Took significant effort to figure out
|
|
114
|
+
- Would cause repeated wasted time if forgotten
|
|
115
|
+
- Represents a decision that needs rationale preserved
|
|
116
|
+
|
|
117
|
+
2. **Capture learnings with `harness state learn`:**
|
|
118
|
+
|
|
119
|
+
```bash
|
|
120
|
+
harness state learn "Date comparison needs UTC normalization — use Date.now() not new Date()"
|
|
121
|
+
```
|
|
122
|
+
|
|
123
|
+
This appends to `.harness/learnings.md` with a timestamp.
|
|
124
|
+
|
|
125
|
+
3. **Or append directly to `.harness/learnings.md`** with structured format:
|
|
126
|
+
|
|
127
|
+
```markdown
|
|
128
|
+
## 2026-03-14 — Task 3: Notification Expiry
|
|
129
|
+
|
|
130
|
+
- [learning]: PostgreSQL's `now()` returns timestamp with timezone, but our
|
|
131
|
+
application uses UTC epoch milliseconds. Always convert before comparing.
|
|
132
|
+
- [gotcha]: The notifications table has a unique constraint on (userId, type).
|
|
133
|
+
Use upsert (ON CONFLICT DO UPDATE) instead of plain INSERT.
|
|
134
|
+
- [decision]: Chose to store expiry as epoch milliseconds rather than
|
|
135
|
+
ISO timestamp for consistency with the rest of the codebase.
|
|
136
|
+
```
|
|
137
|
+
|
|
138
|
+
4. **Learnings are append-only.** Never edit or delete previous learnings. They are a chronological record. Even if a learning turns out to be wrong, append a correction rather than modifying the original.
|
|
139
|
+
|
|
140
|
+
5. **What belongs in learnings vs. git commits:**
|
|
141
|
+
- **Learnings:** Context, rationale, gotchas, decisions, warnings — things that explain _why_ and _what to watch out for_
|
|
142
|
+
- **Git commits:** Code changes, what was done — things that explain _what_ changed
|
|
143
|
+
- Example: The commit says "feat: add UTC normalization to date comparison." The learning says "Date comparison needs UTC normalization because PostgreSQL returns timezone-aware timestamps but our app uses epoch milliseconds."
|
|
144
|
+
|
|
145
|
+
### Phase 4: SAVE — Persist State for Next Session
|
|
146
|
+
|
|
147
|
+
1. **Update `.harness/state.json`** with final position, progress, and session summary:
|
|
148
|
+
|
|
149
|
+
```json
|
|
150
|
+
{
|
|
151
|
+
"schemaVersion": 1,
|
|
152
|
+
"position": { "phase": "execute", "task": "Task 4" },
|
|
153
|
+
"progress": {
|
|
154
|
+
"Task 1": "complete",
|
|
155
|
+
"Task 2": "complete",
|
|
156
|
+
"Task 3": "complete"
|
|
157
|
+
},
|
|
158
|
+
"decisions": [ ... ],
|
|
159
|
+
"blockers": [ ... ],
|
|
160
|
+
"lastSession": {
|
|
161
|
+
"date": "2026-03-14",
|
|
162
|
+
"summary": "Completed Tasks 2-3. Task 3 required UTC date normalization (see learnings). Starting Task 4 next session."
|
|
163
|
+
}
|
|
164
|
+
}
|
|
165
|
+
```
|
|
166
|
+
|
|
167
|
+
2. **Verify learnings were captured.** Review `.harness/learnings.md` — were all non-obvious discoveries recorded? If something was tricky during the session, it should be in learnings.
|
|
168
|
+
|
|
169
|
+
3. **State is saved to the active stream.** All writes (state, learnings, handoff, failures) go to the resolved stream's directory (e.g., `.harness/streams/auth-rework/state.json`). Switching to a different stream in the next session does not affect the current stream's files.
|
|
170
|
+
|
|
171
|
+
4. **Decide whether to commit state files.** State files (`.harness/streams/*/state.json`, `.harness/streams/*/learnings.md`) should be committed to git so other team members and agents can access them. Commit state updates separately from code changes so they do not clutter code diffs.
|
|
172
|
+
|
|
173
|
+
### Building Institutional Knowledge Over Time
|
|
174
|
+
|
|
175
|
+
The `.harness/learnings.md` file grows over the lifetime of the project. It becomes a valuable resource:
|
|
176
|
+
|
|
177
|
+
- **Week 1:** A few gotchas about the development environment and initial setup decisions.
|
|
178
|
+
- **Month 1:** Patterns emerge — recurring issues, architectural decisions with rationale, team conventions that were established through experience.
|
|
179
|
+
- **Month 6:** New team members read learnings and avoid months of rediscovery. The file captures knowledge that no single person holds.
|
|
180
|
+
- **Year 1:** Learnings are the project's institutional memory. They explain why the architecture looks the way it does, why certain patterns were adopted, and what was tried and abandoned.
|
|
181
|
+
|
|
182
|
+
Treat learnings as a first-class project artifact. They are as valuable as tests and documentation.
|
|
183
|
+
|
|
184
|
+
### Archival Workflow
|
|
185
|
+
|
|
186
|
+
- **Archive failures:** Move `failures.md` to `.harness/archive/` at milestone boundaries.
|
|
187
|
+
- **Do NOT archive learnings** — permanent. Learnings accumulate for the lifetime of the project.
|
|
188
|
+
- **Do NOT archive state** — git handles history. The current `state.json` is always the source of truth.
|
|
189
|
+
- **Handoff is ephemeral** — overwritten by each skill. No archival needed.
|
|
190
|
+
|
|
191
|
+
## Harness Integration
|
|
192
|
+
|
|
193
|
+
- **`harness state show [--stream <name>]`** — Display current state in a formatted, readable view. Use at session start to quickly orient.
|
|
194
|
+
- **`harness state reset [--stream <name>]`** — Reset state to initial values. Use when starting a completely new effort and old state is no longer relevant. Use with caution — this discards progress tracking.
|
|
195
|
+
- **`harness state learn "<message>" [--stream <name>]`** — Append a learning with automatic timestamp formatting.
|
|
196
|
+
- **`harness state streams list`** — List all known streams with branch associations and active status.
|
|
197
|
+
- **`harness state streams create <name> [--branch <branch>]`** — Create a new stream, optionally associated with a git branch.
|
|
198
|
+
- **`harness state streams archive <name>`** — Archive a completed stream.
|
|
199
|
+
- **`harness state streams activate <name>`** — Set the active stream for the project.
|
|
200
|
+
- **`.harness/streams/<name>/state.json`** — Primary state file per stream. Read at session start, updated throughout, saved at session end.
|
|
201
|
+
- **`.harness/streams/<name>/learnings.md`** — Append-only knowledge base per stream.
|
|
202
|
+
- **`.harness/streams/<name>/failures.md`** — Active anti-patterns per stream.
|
|
203
|
+
- **`.harness/streams/<name>/handoff.json`** — Structured context from last skill per stream.
|
|
204
|
+
- **`.harness/streams/index.json`** — Stream index tracking known streams, branch associations, and active stream.
|
|
205
|
+
- **`.harness/trace.md`** — Optional reasoning trace. Useful for debugging agent behavior across sessions.
|
|
206
|
+
- **`.harness/archive/`** — Archived failure logs. Check for historical context when encountering recurring issues.
|
|
207
|
+
|
|
208
|
+
## Success Criteria
|
|
209
|
+
|
|
210
|
+
- State is loaded at the start of every session that continues previous work
|
|
211
|
+
- Position is updated whenever the current phase or task changes
|
|
212
|
+
- Decisions are recorded with date, what, and why — immediately when made, not deferred
|
|
213
|
+
- Blockers are logged with task reference, description, and status
|
|
214
|
+
- Progress is updated after each completed task
|
|
215
|
+
- Learnings are captured for every non-obvious discovery during the session
|
|
216
|
+
- `.harness/learnings.md` entries follow the structured format (date, task, tagged items)
|
|
217
|
+
- Learnings are append-only — no edits or deletions of previous entries
|
|
218
|
+
- State is saved before session end with an accurate session summary
|
|
219
|
+
- State files are committed to git separately from code changes
|
|
220
|
+
|
|
221
|
+
## Examples
|
|
222
|
+
|
|
223
|
+
### Example: Starting a New Session (Resuming Work)
|
|
224
|
+
|
|
225
|
+
**LOAD:**
|
|
226
|
+
|
|
227
|
+
```
|
|
228
|
+
Run: harness state show
|
|
229
|
+
Output:
|
|
230
|
+
Position: execute / Task 3 (writing tests)
|
|
231
|
+
Progress: Task 1 complete, Task 2 complete
|
|
232
|
+
Blockers: none
|
|
233
|
+
Last session: 2026-03-13 — "Completed Tasks 1-2. Task 2 required
|
|
234
|
+
adding a new index on notifications.userId for query performance."
|
|
235
|
+
|
|
236
|
+
Read: .harness/learnings.md
|
|
237
|
+
Most recent:
|
|
238
|
+
- [gotcha]: notifications table needs index on userId — queries
|
|
239
|
+
were timing out without it
|
|
240
|
+
- [decision]: used partial index (WHERE deleted_at IS NULL) to
|
|
241
|
+
avoid indexing soft-deleted rows
|
|
242
|
+
|
|
243
|
+
Summary: "Resuming from Task 3 (writing tests). Tasks 1-2 complete.
|
|
244
|
+
Note: notifications table has a partial index on userId — see learnings."
|
|
245
|
+
```
|
|
246
|
+
|
|
247
|
+
### Example: Recording a Decision Mid-Session
|
|
248
|
+
|
|
249
|
+
```
|
|
250
|
+
Context: Implementing Task 4, need to choose between polling and WebSocket.
|
|
251
|
+
|
|
252
|
+
Record decision:
|
|
253
|
+
date: "2026-03-14"
|
|
254
|
+
what: "Use WebSocket for real-time notification delivery"
|
|
255
|
+
why: "Polling would require 1-second intervals for acceptable latency,
|
|
256
|
+
which creates too much load. WebSocket gives instant delivery with
|
|
257
|
+
one persistent connection per client."
|
|
258
|
+
|
|
259
|
+
Capture learning:
|
|
260
|
+
harness state learn "WebSocket chosen over polling for notifications.
|
|
261
|
+
Polling at 1s intervals = ~86k requests/day per client. WebSocket =
|
|
262
|
+
1 persistent connection. See Task 4 decision in state."
|
|
263
|
+
```
|
|
264
|
+
|
|
265
|
+
### Example: Ending a Session
|
|
266
|
+
|
|
267
|
+
**SAVE:**
|
|
268
|
+
|
|
269
|
+
```
|
|
270
|
+
Update .harness/state.json:
|
|
271
|
+
{
|
|
272
|
+
"schemaVersion": 1,
|
|
273
|
+
"position": { "phase": "execute", "task": "Task 5" },
|
|
274
|
+
"progress": {
|
|
275
|
+
"Task 1": "complete",
|
|
276
|
+
"Task 2": "complete",
|
|
277
|
+
"Task 3": "complete",
|
|
278
|
+
"Task 4": "complete"
|
|
279
|
+
},
|
|
280
|
+
"decisions": [
|
|
281
|
+
{
|
|
282
|
+
"date": "2026-03-14",
|
|
283
|
+
"what": "Use WebSocket for real-time notification delivery",
|
|
284
|
+
"why": "Polling creates too much load at acceptable latency intervals"
|
|
285
|
+
}
|
|
286
|
+
],
|
|
287
|
+
"blockers": [],
|
|
288
|
+
"lastSession": {
|
|
289
|
+
"date": "2026-03-14",
|
|
290
|
+
"summary": "Completed Tasks 3-4. Task 3 added expiry logic with UTC normalization. Task 4 implemented WebSocket delivery (chose over polling — see decisions). Starting Task 5 (UI integration) next session."
|
|
291
|
+
}
|
|
292
|
+
}
|
|
293
|
+
|
|
294
|
+
Verify: .harness/learnings.md has entries for UTC normalization and WebSocket decision.
|
|
295
|
+
Commit: git add .harness/ && git commit -m "chore: update harness state after Tasks 3-4"
|
|
296
|
+
```
|
|
297
|
+
|
|
298
|
+
### Example: What Belongs Where
|
|
299
|
+
|
|
300
|
+
| Information | Where It Goes | Why |
|
|
301
|
+
| ----------------------------------------------------- | ------------------------------- | ---------------------------------------------------- |
|
|
302
|
+
| "Added WebSocket handler in src/ws/" | Git commit message | Describes what changed in code |
|
|
303
|
+
| "Chose WebSocket over polling because..." | `.harness/state.json` decisions | Records the choice and rationale for future sessions |
|
|
304
|
+
| "WebSocket requires sticky sessions in load balancer" | `.harness/learnings.md` | Non-obvious operational concern future sessions need |
|
|
305
|
+
| "Task 4 complete" | `.harness/state.json` progress | Tracks execution position |
|
|
306
|
+
| "The WebSocket library auto-reconnects by default" | `.harness/learnings.md` | Gotcha that saves future debugging time |
|
|
307
|
+
| "Tried approach X, failed because Y" | `.harness/failures.md` | Active anti-pattern to avoid repeating |
|
|
308
|
+
| "Completed Tasks 1-3, Task 4 pending" | `.harness/handoff.json` | Structured context for next skill |
|
|
309
|
+
| "[PREPARE 10:30] Loaded 3 failures" | `.harness/trace.md` | Reasoning trace for debugging agent behavior |
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
name: harness-state-management
|
|
2
|
+
version: "1.0.0"
|
|
3
|
+
description: Manage persistent session state across harness agent sessions
|
|
4
|
+
cognitive_mode: meticulous-implementer
|
|
5
|
+
triggers:
|
|
6
|
+
- manual
|
|
7
|
+
platforms:
|
|
8
|
+
- claude-code
|
|
9
|
+
- gemini-cli
|
|
10
|
+
tools:
|
|
11
|
+
- Bash
|
|
12
|
+
- Read
|
|
13
|
+
- Write
|
|
14
|
+
- Edit
|
|
15
|
+
- Glob
|
|
16
|
+
cli:
|
|
17
|
+
command: harness skill run harness-state-management
|
|
18
|
+
args:
|
|
19
|
+
- name: path
|
|
20
|
+
description: Project root path
|
|
21
|
+
required: false
|
|
22
|
+
mcp:
|
|
23
|
+
tool: run_skill
|
|
24
|
+
input:
|
|
25
|
+
skill: harness-state-management
|
|
26
|
+
path: string
|
|
27
|
+
type: flexible
|
|
28
|
+
internal: true
|
|
29
|
+
state:
|
|
30
|
+
persistent: true
|
|
31
|
+
files:
|
|
32
|
+
- .harness/state.json
|
|
33
|
+
depends_on: []
|
|
@@ -0,0 +1,281 @@
|
|
|
1
|
+
# Harness Supply Chain Audit
|
|
2
|
+
|
|
3
|
+
> 6-factor dependency risk evaluation adapted from Trail of Bits security skill patterns. Surfaces dependency risk flags for human review — not automated verdicts.
|
|
4
|
+
|
|
5
|
+
## When to Use
|
|
6
|
+
|
|
7
|
+
- Before a major release to assess dependency risk
|
|
8
|
+
- After adding new dependencies
|
|
9
|
+
- During security audits or compliance reviews
|
|
10
|
+
- When `on_milestone` trigger fires (part of release gate)
|
|
11
|
+
- NOT as a replacement for `npm audit` — this complements it with risk signals beyond CVEs
|
|
12
|
+
- NOT for license compliance (separate concern)
|
|
13
|
+
|
|
14
|
+
## Iron Law
|
|
15
|
+
|
|
16
|
+
**Present findings as flags for human review, never as verdicts.** A dependency flagged as "high risk" may be entirely appropriate for a project. The skill surfaces signals; humans decide whether to act.
|
|
17
|
+
|
|
18
|
+
---
|
|
19
|
+
|
|
20
|
+
## Process
|
|
21
|
+
|
|
22
|
+
### Phase 1: INVENTORY — Build Dependency List
|
|
23
|
+
|
|
24
|
+
1. **Resolve project root.** Use the path argument or default to the current directory.
|
|
25
|
+
|
|
26
|
+
2. **Detect lockfile.** Check for the following in order:
|
|
27
|
+
- `package-lock.json` (npm)
|
|
28
|
+
- `pnpm-lock.yaml` (pnpm)
|
|
29
|
+
- `yarn.lock` (yarn)
|
|
30
|
+
- If none found: report "No lockfile detected. Run `npm install` first." and stop.
|
|
31
|
+
|
|
32
|
+
3. **Parse direct dependencies** from `package.json`:
|
|
33
|
+
- Read `dependencies` and `devDependencies`
|
|
34
|
+
- Build a list: `{ name, version, isDev }`
|
|
35
|
+
|
|
36
|
+
4. **Parse transitive depth** from lockfile:
|
|
37
|
+
- For `package-lock.json`: read `packages` keys to extract the dependency tree. Nesting depth of `node_modules/` segments in keys indicates transitive depth.
|
|
38
|
+
- For `pnpm-lock.yaml`: read `importers` section for direct dependencies (keyed by workspace path, e.g., `.` for root). Each importer lists `dependencies` and `devDependencies` with version specifiers. Read `packages` section for resolved versions — keys are package identifiers (e.g., `/@scope/pkg@1.2.3`) with `resolution` (tarball URL + integrity hash) and `dependencies` sub-map for transitives.
|
|
39
|
+
- For `yarn.lock`: parse block-format entries. Each block header is `"pkg@version-range":` followed by indented fields: `version` (resolved), `resolved` (tarball URL), `integrity` (hash), and `dependencies` sub-block listing transitive deps as `"name" "version-range"` pairs.
|
|
40
|
+
- Assign each package a depth (0 = direct, 1 = first-level transitive, etc.)
|
|
41
|
+
- Flag packages with depth > 5 for transitive risk evaluation
|
|
42
|
+
|
|
43
|
+
5. **Build inventory table:**
|
|
44
|
+
|
|
45
|
+
```
|
|
46
|
+
INVENTORY: <project-name>
|
|
47
|
+
Direct dependencies: N
|
|
48
|
+
Dev dependencies: N
|
|
49
|
+
Total packages (including transitives): N
|
|
50
|
+
Deep transitive packages (depth > 5): N
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
6. Proceed to EVALUATE.
|
|
54
|
+
|
|
55
|
+
---
|
|
56
|
+
|
|
57
|
+
### Phase 2: EVALUATE — Score Dependencies on 6 Factors
|
|
58
|
+
|
|
59
|
+
For each **direct dependency** (and any transitive with depth > 5), score on 6 factors:
|
|
60
|
+
|
|
61
|
+
> Network access required: npm registry (`https://registry.npmjs.org/<pkg>`) and GitHub API (`https://api.github.com/repos/<owner>/<repo>`).
|
|
62
|
+
>
|
|
63
|
+
> - If npm registry returns 404: mark as "unresolvable", flag for manual review, skip remaining factors
|
|
64
|
+
> - If GitHub API rate limits hit: score `maintenance-status` as "unknown", continue with other factors
|
|
65
|
+
> - If no GitHub repo link in package metadata: skip `maintenance-status` factor, note in report
|
|
66
|
+
|
|
67
|
+
#### Factor 1: Maintainer Concentration
|
|
68
|
+
|
|
69
|
+
- Fetch: `GET https://registry.npmjs.org/<pkg>`
|
|
70
|
+
- Check: `maintainers` array length
|
|
71
|
+
- Score:
|
|
72
|
+
- **High risk:** 1 maintainer (bus factor = 1)
|
|
73
|
+
- **Medium risk:** 2-3 maintainers
|
|
74
|
+
- **Low risk:** 4+ maintainers
|
|
75
|
+
|
|
76
|
+
#### Factor 2: Maintenance Status
|
|
77
|
+
|
|
78
|
+
- Source: npm `time` field (last publish date) + GitHub API commit activity
|
|
79
|
+
- npm: `GET https://registry.npmjs.org/<pkg>` → `time.modified`
|
|
80
|
+
- GitHub: `GET https://api.github.com/repos/<owner>/<repo>/commits?per_page=1` → latest commit date
|
|
81
|
+
- Score:
|
|
82
|
+
- **High risk:** Last publish > 12 months ago AND no GitHub commits in 6 months
|
|
83
|
+
- **Medium risk:** Last publish > 12 months ago OR no commits in 6 months (not both)
|
|
84
|
+
- **Low risk:** Active in both dimensions
|
|
85
|
+
|
|
86
|
+
#### Factor 3: Popularity Signal
|
|
87
|
+
|
|
88
|
+
- Fetch: `GET https://api.npmjs.org/downloads/point/last-week/<pkg>`
|
|
89
|
+
- Score:
|
|
90
|
+
- **High risk:** < 1,000 weekly downloads
|
|
91
|
+
- **Medium risk:** 1,000–10,000 weekly downloads
|
|
92
|
+
- **Low risk:** > 10,000 weekly downloads
|
|
93
|
+
- **Note:** Low popularity is a signal, not a verdict — internal/niche packages are expected to be low
|
|
94
|
+
|
|
95
|
+
#### Factor 4: Install Scripts
|
|
96
|
+
|
|
97
|
+
- Read: `node_modules/<pkg>/package.json` (or lockfile-resolved path) → `scripts` field
|
|
98
|
+
- Check for: `preinstall`, `postinstall`, `install`, `preuninstall`, `postuninstall`
|
|
99
|
+
- Score:
|
|
100
|
+
- **High risk:** Any install script present
|
|
101
|
+
- **Low risk:** No install scripts
|
|
102
|
+
- **Note:** Some install scripts are legitimate (native addon compilation). Flag for review.
|
|
103
|
+
|
|
104
|
+
#### Factor 5: Known CVEs
|
|
105
|
+
|
|
106
|
+
- Run: `npm audit --json` or `pnpm audit --json`
|
|
107
|
+
- Parse: map findings to their package name
|
|
108
|
+
- Score:
|
|
109
|
+
- **Critical:** Any high/critical severity CVE
|
|
110
|
+
- **Medium risk:** Moderate severity CVE
|
|
111
|
+
- **Low risk:** No CVEs or low severity only
|
|
112
|
+
|
|
113
|
+
#### Factor 6: Transitive Risk
|
|
114
|
+
|
|
115
|
+
- Source: Lockfile depth analysis from INVENTORY phase
|
|
116
|
+
- Score:
|
|
117
|
+
- **High risk:** Depth > 5 AND subtree size > 20 transitive packages
|
|
118
|
+
- **Medium risk:** Depth > 5 OR subtree size > 20
|
|
119
|
+
- **Low risk:** Depth ≤ 5 and subtree size ≤ 20
|
|
120
|
+
|
|
121
|
+
#### Risk Scoring
|
|
122
|
+
|
|
123
|
+
Combine factor scores into an overall risk level:
|
|
124
|
+
|
|
125
|
+
| Overall Risk | Condition |
|
|
126
|
+
| ------------ | -------------------------------------------------------------- |
|
|
127
|
+
| **Critical** | Factor 5 is Critical (any high/critical CVE) |
|
|
128
|
+
| **High** | 2+ factors scored High, OR Factor 1 is High + Factor 2 is High |
|
|
129
|
+
| **Medium** | 1 factor scored High, OR 3+ factors scored Medium |
|
|
130
|
+
| **Low** | All factors Low or at most 1 Medium |
|
|
131
|
+
|
|
132
|
+
---
|
|
133
|
+
|
|
134
|
+
### Phase 3: REPORT — Generate Risk Summary
|
|
135
|
+
|
|
136
|
+
1. **Produce risk summary table** sorted by overall risk (Critical first):
|
|
137
|
+
|
|
138
|
+
```
|
|
139
|
+
Supply Chain Audit: <project-name>
|
|
140
|
+
Date: <ISO date>
|
|
141
|
+
Packages evaluated: N direct + M deep transitives
|
|
142
|
+
|
|
143
|
+
┌─────────────────────┬──────────┬────────────┬─────────────┬────────────┬──────┬─────────────┐
|
|
144
|
+
│ Package │ Version │ Maintainers│ Last Publish│ Downloads │ CVEs │ Overall Risk│
|
|
145
|
+
├─────────────────────┼──────────┼────────────┼─────────────┼────────────┼──────┼─────────────┤
|
|
146
|
+
│ example-pkg │ 1.2.3 │ 1 (HIGH) │ 18mo (HIGH) │ 500 (MED) │ none │ HIGH │
|
|
147
|
+
│ another-pkg │ 2.0.0 │ 12 │ 2mo │ 50k │ 1 mod│ MEDIUM │
|
|
148
|
+
└─────────────────────┴──────────┴────────────┴─────────────┴────────────┴──────┴─────────────┘
|
|
149
|
+
```
|
|
150
|
+
|
|
151
|
+
2. **Detail section for Critical and High risk packages:**
|
|
152
|
+
|
|
153
|
+
```
|
|
154
|
+
HIGH RISK: example-pkg@1.2.3
|
|
155
|
+
├── Maintainer concentration: 1 maintainer (bus factor = 1)
|
|
156
|
+
├── Maintenance status: Last publish 18 months ago, no commits in 12 months
|
|
157
|
+
├── Popularity: 500 weekly downloads
|
|
158
|
+
├── Install scripts: none
|
|
159
|
+
├── Known CVEs: none
|
|
160
|
+
└── Transitive risk: depth 2, subtree 4 packages
|
|
161
|
+
Recommendation: Consider replacing with a well-maintained alternative,
|
|
162
|
+
or pin the version and monitor for abandonment.
|
|
163
|
+
```
|
|
164
|
+
|
|
165
|
+
3. **Install script warnings** (any package with install scripts):
|
|
166
|
+
|
|
167
|
+
```
|
|
168
|
+
INSTALL SCRIPTS DETECTED:
|
|
169
|
+
- node-gyp@9.4.0: postinstall — native addon compilation (likely legitimate)
|
|
170
|
+
- suspicious-pkg@1.0.0: postinstall — review script contents before trusting
|
|
171
|
+
```
|
|
172
|
+
|
|
173
|
+
4. **Summary line:**
|
|
174
|
+
|
|
175
|
+
```
|
|
176
|
+
RESULT: 1 Critical, 2 High, 3 Medium, N Low — Review flagged items before release
|
|
177
|
+
```
|
|
178
|
+
|
|
179
|
+
5. **Output:** Print report to stdout. If `--output <file>` was passed, also write to that file.
|
|
180
|
+
|
|
181
|
+
---
|
|
182
|
+
|
|
183
|
+
## Gates
|
|
184
|
+
|
|
185
|
+
- **Stop if no lockfile.** Do not evaluate without a lockfile — results will be unreliable.
|
|
186
|
+
- **Present as flags, not verdicts.** Never state "this package is unsafe." State "this package has signals that warrant review."
|
|
187
|
+
- **Do not block on API failures.** If npm registry or GitHub API is unavailable, note which factors were skipped and continue with available data.
|
|
188
|
+
|
|
189
|
+
## Harness Integration
|
|
190
|
+
|
|
191
|
+
- **`harness validate`** — Run after creating the skill files to verify they are properly placed.
|
|
192
|
+
- **Triggers:** `on_milestone` fires this skill as part of the milestone completion checklist.
|
|
193
|
+
- **Depends on:** `harness-security-scan` — run after mechanical scanning to complete the security picture.
|
|
194
|
+
- **Output:** Stdout report, optionally written to file via `--output`. No state files written.
|
|
195
|
+
|
|
196
|
+
## Evidence Requirements
|
|
197
|
+
|
|
198
|
+
When reporting findings, cite the source for each factor:
|
|
199
|
+
|
|
200
|
+
- Maintainer data: `registry.npmjs.org/<pkg>` → `maintainers` field
|
|
201
|
+
- Publish date: `registry.npmjs.org/<pkg>` → `time.modified`
|
|
202
|
+
- Downloads: `api.npmjs.org/downloads/point/last-week/<pkg>`
|
|
203
|
+
- Install scripts: `node_modules/<pkg>/package.json` → `scripts`
|
|
204
|
+
- CVEs: `npm audit --json` output
|
|
205
|
+
- Depth: lockfile analysis
|
|
206
|
+
|
|
207
|
+
Do not assert risk scores without citing the specific data point that generated the score.
|
|
208
|
+
|
|
209
|
+
## Success Criteria
|
|
210
|
+
|
|
211
|
+
- Running `/harness:supply-chain-audit` on a project with dependencies outputs a risk table with all 6 factors scored
|
|
212
|
+
- A dependency with a sole maintainer and no commits in 12 months scores "high risk"
|
|
213
|
+
- A dependency with a `postinstall` script is flagged in the install scripts section
|
|
214
|
+
- API failures produce "unknown" scores with a note, not errors that stop the audit
|
|
215
|
+
- All findings are framed as flags for human review, not automated verdicts
|
|
216
|
+
|
|
217
|
+
## Escalation
|
|
218
|
+
|
|
219
|
+
- **If a critical CVE is found:** Surface immediately — do not bury it in the table. Recommend blocking the dependency update or requiring an immediate patch before merge.
|
|
220
|
+
- **If all maintainers are unresponsive:** Flag the package as abandoned and recommend finding an alternative. Include download counts to help the user assess how widely adopted the package is.
|
|
221
|
+
- **If an install script has unknown behavior:** Do not guess. State that the script requires manual review and link to the script source.
|
|
222
|
+
- **If the npm or GitHub API is unavailable:** Note which factors were skipped with "unknown" scores. Do not fail the audit — partial results are better than none.
|
|
223
|
+
- **If the user asks for a verdict ("is this safe?"):** Decline to give a binary answer. Supply chain risk is probabilistic. Present the risk signals and let the human decide.
|
|
224
|
+
|
|
225
|
+
## Examples
|
|
226
|
+
|
|
227
|
+
```
|
|
228
|
+
Supply Chain Audit: my-project
|
|
229
|
+
Date: 2026-03-31
|
|
230
|
+
Packages evaluated: 24 direct + 3 deep transitives (depth > 5)
|
|
231
|
+
|
|
232
|
+
CRITICAL (1):
|
|
233
|
+
lodash@4.17.20 — CVE-2021-23337 (high severity, unpatched)
|
|
234
|
+
|
|
235
|
+
HIGH (2):
|
|
236
|
+
abandoned-util@0.9.1 — sole maintainer, last publish 22 months ago
|
|
237
|
+
sketchy-helper@2.1.0 — sole maintainer, postinstall script detected
|
|
238
|
+
|
|
239
|
+
MEDIUM (3):
|
|
240
|
+
small-lib@1.0.0 — 800 weekly downloads (low popularity signal)
|
|
241
|
+
...
|
|
242
|
+
|
|
243
|
+
LOW (18): no significant risk signals
|
|
244
|
+
|
|
245
|
+
INSTALL SCRIPTS:
|
|
246
|
+
node-gyp@9.4.0 — postinstall (native compilation, likely legitimate)
|
|
247
|
+
sketchy-helper@2.1.0 — postinstall (REVIEW: contents unknown)
|
|
248
|
+
|
|
249
|
+
RESULT: 1 Critical, 2 High, 3 Medium, 18 Low
|
|
250
|
+
Next steps: Update lodash to patch CVE. Review sketchy-helper postinstall script.
|
|
251
|
+
Consider alternatives to abandoned-util.
|
|
252
|
+
```
|
|
253
|
+
|
|
254
|
+
## Example Output
|
|
255
|
+
|
|
256
|
+
```
|
|
257
|
+
Supply Chain Audit: my-project
|
|
258
|
+
Date: 2026-03-31
|
|
259
|
+
Packages evaluated: 24 direct + 3 deep transitives (depth > 5)
|
|
260
|
+
|
|
261
|
+
CRITICAL (1):
|
|
262
|
+
lodash@4.17.20 — CVE-2021-23337 (high severity, unpatched)
|
|
263
|
+
|
|
264
|
+
HIGH (2):
|
|
265
|
+
abandoned-util@0.9.1 — sole maintainer, last publish 22 months ago
|
|
266
|
+
sketchy-helper@2.1.0 — sole maintainer, postinstall script detected
|
|
267
|
+
|
|
268
|
+
MEDIUM (3):
|
|
269
|
+
small-lib@1.0.0 — 800 weekly downloads (low popularity signal)
|
|
270
|
+
...
|
|
271
|
+
|
|
272
|
+
LOW (18): no significant risk signals
|
|
273
|
+
|
|
274
|
+
INSTALL SCRIPTS:
|
|
275
|
+
node-gyp@9.4.0 — postinstall (native compilation, likely legitimate)
|
|
276
|
+
sketchy-helper@2.1.0 — postinstall (REVIEW: contents unknown)
|
|
277
|
+
|
|
278
|
+
RESULT: 1 Critical, 2 High, 3 Medium, 18 Low
|
|
279
|
+
Next steps: Update lodash to patch CVE. Review sketchy-helper postinstall script.
|
|
280
|
+
Consider alternatives to abandoned-util.
|
|
281
|
+
```
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
name: harness-supply-chain-audit
|
|
2
|
+
version: "1.0.0"
|
|
3
|
+
description: 6-factor dependency risk evaluation for supply chain security
|
|
4
|
+
cognitive_mode: meticulous-implementer
|
|
5
|
+
triggers:
|
|
6
|
+
- manual
|
|
7
|
+
- on_milestone
|
|
8
|
+
platforms:
|
|
9
|
+
- claude-code
|
|
10
|
+
- gemini-cli
|
|
11
|
+
tools:
|
|
12
|
+
- Bash
|
|
13
|
+
- Read
|
|
14
|
+
- Write
|
|
15
|
+
- Grep
|
|
16
|
+
- Glob
|
|
17
|
+
- WebFetch
|
|
18
|
+
cli:
|
|
19
|
+
command: harness skill run harness-supply-chain-audit
|
|
20
|
+
args:
|
|
21
|
+
- name: path
|
|
22
|
+
description: Project root path
|
|
23
|
+
required: false
|
|
24
|
+
- name: depth
|
|
25
|
+
description: Maximum dependency depth to evaluate (default 3)
|
|
26
|
+
required: false
|
|
27
|
+
- name: output
|
|
28
|
+
description: Write report to file instead of stdout
|
|
29
|
+
required: false
|
|
30
|
+
mcp:
|
|
31
|
+
tool: run_skill
|
|
32
|
+
input:
|
|
33
|
+
skill: harness-supply-chain-audit
|
|
34
|
+
path: string
|
|
35
|
+
type: rigid
|
|
36
|
+
tier: 2
|
|
37
|
+
phases:
|
|
38
|
+
- name: inventory
|
|
39
|
+
description: Build dependency inventory from lockfile
|
|
40
|
+
required: true
|
|
41
|
+
- name: evaluate
|
|
42
|
+
description: Score each dependency on 6 risk factors
|
|
43
|
+
required: true
|
|
44
|
+
- name: report
|
|
45
|
+
description: Generate risk report with actionable findings
|
|
46
|
+
required: true
|
|
47
|
+
state:
|
|
48
|
+
persistent: false
|
|
49
|
+
files: []
|
|
50
|
+
depends_on:
|
|
51
|
+
- harness-security-scan
|