contextdevkit 1.8.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/CHANGELOG.md +592 -0
- package/LICENSE +21 -0
- package/README.md +401 -0
- package/docs/AGENT-PACKAGE-FORMAT.md +140 -0
- package/docs/ARCHITECTURE.md +258 -0
- package/docs/CHANGELOG.md +559 -0
- package/docs/CUSTOMIZING.md +211 -0
- package/docs/LEVELS.md +151 -0
- package/docs/ROADMAP.md +385 -0
- package/docs/SQUAD-PIPELINE-FORMAT.md +258 -0
- package/docs/SQUADS/agent-forge.md +65 -0
- package/docs/SQUADS/design-team.md +161 -0
- package/docs/token-economy-plan.md +135 -0
- package/install.mjs +273 -0
- package/instrucoes.md +274 -0
- package/package.json +46 -0
- package/templates/CLAUDE.md.tpl +133 -0
- package/templates/claude/agents/_TEMPLATE.md +52 -0
- package/templates/claude/agents/accessibility.md +36 -0
- package/templates/claude/agents/agent-architect.md +37 -0
- package/templates/claude/agents/architect.md +39 -0
- package/templates/claude/agents/code-reviewer.md +43 -0
- package/templates/claude/agents/code-security.md +59 -0
- package/templates/claude/agents/context-keeper.md +40 -0
- package/templates/claude/agents/devops.md +40 -0
- package/templates/claude/agents/eval-designer.md +40 -0
- package/templates/claude/agents/forge-orchestrator.md +42 -0
- package/templates/claude/agents/governance-officer.md +45 -0
- package/templates/claude/agents/growth.md +92 -0
- package/templates/claude/agents/infra-security.md +53 -0
- package/templates/claude/agents/landing-architect.md +154 -0
- package/templates/claude/agents/model-router.md +34 -0
- package/templates/claude/agents/packager.md +38 -0
- package/templates/claude/agents/privacy-lgpd.md +64 -0
- package/templates/claude/agents/product-owner.md +51 -0
- package/templates/claude/agents/prompt-engineer.md +33 -0
- package/templates/claude/agents/qa-e2e.md +52 -0
- package/templates/claude/agents/qa-fuzzer.md +24 -0
- package/templates/claude/agents/qa-integration.md +21 -0
- package/templates/claude/agents/qa-orchestrator.md +40 -0
- package/templates/claude/agents/qa-perf.md +40 -0
- package/templates/claude/agents/qa-unit.md +39 -0
- package/templates/claude/agents/rag-designer.md +54 -0
- package/templates/claude/agents/retention.md +85 -0
- package/templates/claude/agents/security.md +48 -0
- package/templates/claude/agents/seo-specialist.md +106 -0
- package/templates/claude/agents/test-engineer.md +48 -0
- package/templates/claude/agents/tool-designer.md +32 -0
- package/templates/claude/agents/ui-designer.md +37 -0
- package/templates/claude/agents/ux-designer.md +38 -0
- package/templates/claude/commands/README.md +95 -0
- package/templates/claude/commands/advise.md +80 -0
- package/templates/claude/commands/audit/analyze-code-ia-practices.md +75 -0
- package/templates/claude/commands/audit/audit.md +35 -0
- package/templates/claude/commands/audit/contract-check.md +21 -0
- package/templates/claude/commands/audit/deep-analysis.md +48 -0
- package/templates/claude/commands/audit/deps-audit.md +49 -0
- package/templates/claude/commands/audit/security-setup.md +35 -0
- package/templates/claude/commands/audit/seo-audit.md +63 -0
- package/templates/claude/commands/audit/tech-debt-sweep.md +35 -0
- package/templates/claude/commands/bug-hunt.md +42 -0
- package/templates/claude/commands/claude-md.md +36 -0
- package/templates/claude/commands/close-version.md +25 -0
- package/templates/claude/commands/context-refresh.md +19 -0
- package/templates/claude/commands/context-stats.md +15 -0
- package/templates/claude/commands/dashboard.md +66 -0
- package/templates/claude/commands/distill-apply.md +19 -0
- package/templates/claude/commands/distill-sessions.md +26 -0
- package/templates/claude/commands/fleet.md +47 -0
- package/templates/claude/commands/forge/forge-audit.md +16 -0
- package/templates/claude/commands/forge/forge-budget.md +16 -0
- package/templates/claude/commands/forge/forge-deprecate.md +16 -0
- package/templates/claude/commands/forge/forge-doctor.md +17 -0
- package/templates/claude/commands/forge/forge-eval.md +16 -0
- package/templates/claude/commands/forge/forge-fallback-test.md +17 -0
- package/templates/claude/commands/forge/forge-killswitch.md +17 -0
- package/templates/claude/commands/forge/forge-list.md +17 -0
- package/templates/claude/commands/forge/forge-new.md +41 -0
- package/templates/claude/commands/forge/forge-policy.md +16 -0
- package/templates/claude/commands/forge/forge-redteam.md +17 -0
- package/templates/claude/commands/forge/forge-refresh-matrix.md +20 -0
- package/templates/claude/commands/forge/forge-route.md +17 -0
- package/templates/claude/commands/forge/forge-show.md +16 -0
- package/templates/claude/commands/landing-page.md +71 -0
- package/templates/claude/commands/log-session.md +59 -0
- package/templates/claude/commands/media-gen.md +93 -0
- package/templates/claude/commands/new-adr.md +30 -0
- package/templates/claude/commands/pipeline/dev-start.md +64 -0
- package/templates/claude/commands/pipeline/pipeline.md +36 -0
- package/templates/claude/commands/pipeline/resume.md +70 -0
- package/templates/claude/commands/pipeline/retro.md +34 -0
- package/templates/claude/commands/pipeline/runs.md +63 -0
- package/templates/claude/commands/pipeline/ship.md +54 -0
- package/templates/claude/commands/pipeline/workflow.md +85 -0
- package/templates/claude/commands/playbook.md +27 -0
- package/templates/claude/commands/predictions-review.md +28 -0
- package/templates/claude/commands/qa/qa-signoff.md +24 -0
- package/templates/claude/commands/qa/scaffold-tests.md +27 -0
- package/templates/claude/commands/qa/test-plan.md +26 -0
- package/templates/claude/commands/qa/visual-test.md +42 -0
- package/templates/claude/commands/roadmap.md +48 -0
- package/templates/claude/commands/setup/aidevtool-from0.md +104 -0
- package/templates/claude/commands/setup/context-config.md +25 -0
- package/templates/claude/commands/setup/context-doctor.md +21 -0
- package/templates/claude/commands/setup/context-level.md +17 -0
- package/templates/claude/commands/setup/setupcontextdevkit.md +121 -0
- package/templates/claude/commands/simulate-impact.md +32 -0
- package/templates/claude/commands/squad.md +44 -0
- package/templates/claude/commands/state.md +21 -0
- package/templates/claude/commands/token-report.md +29 -0
- package/templates/claude/commands/tune-agents.md +35 -0
- package/templates/claude/commands/vcs/claim.md +18 -0
- package/templates/claude/commands/vcs/git.md +83 -0
- package/templates/claude/commands/vcs/release.md +15 -0
- package/templates/claude/commands/vcs/worktree-new.md +18 -0
- package/templates/claude/commands/watch.md +47 -0
- package/templates/contextkit/.env.example +36 -0
- package/templates/contextkit/CLAUDE.child.md.tpl +38 -0
- package/templates/contextkit/README.md +74 -0
- package/templates/contextkit/behaviors-examples.md +183 -0
- package/templates/contextkit/behaviors.md +116 -0
- package/templates/contextkit/best-practices.md +323 -0
- package/templates/contextkit/config.json +66 -0
- package/templates/contextkit/detectors/README.md +45 -0
- package/templates/contextkit/detectors/example-detector.mjs.example +25 -0
- package/templates/contextkit/instrucoes.md +114 -0
- package/templates/contextkit/memory/GLOSSARY.md +13 -0
- package/templates/contextkit/memory/SESSIONS.md +9 -0
- package/templates/contextkit/memory/WORKSPACE.md +7 -0
- package/templates/contextkit/memory/business-rules/_TEMPLATE.md +33 -0
- package/templates/contextkit/memory/decisions/0000-record-architecture-decisions.md +34 -0
- package/templates/contextkit/memory/decisions/_TEMPLATE.md +25 -0
- package/templates/contextkit/memory/predictions/.gitkeep +0 -0
- package/templates/contextkit/memory/roadmap.md +28 -0
- package/templates/contextkit/memory/sessions/.gitkeep +0 -0
- package/templates/contextkit/memory/workflows/.gitkeep +0 -0
- package/templates/contextkit/pipeline/backlog/.gitkeep +0 -0
- package/templates/contextkit/pipeline/conclusion/.gitkeep +0 -0
- package/templates/contextkit/pipeline/devpipeline.md +9 -0
- package/templates/contextkit/pipeline/testing/.gitkeep +0 -0
- package/templates/contextkit/pipeline/working/.gitkeep +0 -0
- package/templates/contextkit/review-protocol.md +214 -0
- package/templates/contextkit/runtime/config/defaults.mjs +215 -0
- package/templates/contextkit/runtime/config/levels.mjs +42 -0
- package/templates/contextkit/runtime/config/load.mjs +105 -0
- package/templates/contextkit/runtime/config/paths.mjs +92 -0
- package/templates/contextkit/runtime/config/presets.mjs +47 -0
- package/templates/contextkit/runtime/config/schema.mjs +88 -0
- package/templates/contextkit/runtime/config/settings-compose.mjs +55 -0
- package/templates/contextkit/runtime/git-hooks/commit-msg.mjs +55 -0
- package/templates/contextkit/runtime/git-hooks/pre-commit.mjs +47 -0
- package/templates/contextkit/runtime/git-hooks/pre-push.mjs +102 -0
- package/templates/contextkit/runtime/hooks/boot-context-readers.mjs +111 -0
- package/templates/contextkit/runtime/hooks/boot-signals.mjs +135 -0
- package/templates/contextkit/runtime/hooks/check-registration.mjs +228 -0
- package/templates/contextkit/runtime/hooks/concurrency-guard.mjs +110 -0
- package/templates/contextkit/runtime/hooks/ledger.mjs +231 -0
- package/templates/contextkit/runtime/hooks/md-extract.mjs +65 -0
- package/templates/contextkit/runtime/hooks/path-classification.mjs +62 -0
- package/templates/contextkit/runtime/hooks/safe-io.mjs +84 -0
- package/templates/contextkit/runtime/hooks/session-digest-core.mjs +85 -0
- package/templates/contextkit/runtime/hooks/session-start.mjs +248 -0
- package/templates/contextkit/runtime/hooks/simulate-gate.mjs +108 -0
- package/templates/contextkit/runtime/hooks/track-edits.mjs +154 -0
- package/templates/contextkit/runtime/providers/media/_adapter.mjs +120 -0
- package/templates/contextkit/runtime/providers/media/nano-banana.mjs +110 -0
- package/templates/contextkit/runtime/providers/media/veo.mjs +162 -0
- package/templates/contextkit/runtime/providers/review/_adapter.mjs +71 -0
- package/templates/contextkit/runtime/providers/review/detect.mjs +115 -0
- package/templates/contextkit/runtime/providers/review/gh.mjs +103 -0
- package/templates/contextkit/runtime/state/state-io.mjs +172 -0
- package/templates/contextkit/runtime/statusline.mjs +51 -0
- package/templates/contextkit/squads/README.md +115 -0
- package/templates/contextkit/squads/_BRIEFING.md.tpl +27 -0
- package/templates/contextkit/squads/agent-forge/README.md +69 -0
- package/templates/contextkit/squads/agent-forge/ROADMAP.md +108 -0
- package/templates/contextkit/squads/agent-forge/best-practices.md +89 -0
- package/templates/contextkit/squads/agent-forge/cli/forge-admin.mjs +132 -0
- package/templates/contextkit/squads/agent-forge/cli/forge-eval-cli.mjs +163 -0
- package/templates/contextkit/squads/agent-forge/cli/forge-new.mjs +97 -0
- package/templates/contextkit/squads/agent-forge/cli/forge-ops.mjs +177 -0
- package/templates/contextkit/squads/agent-forge/lib/architect.mjs +112 -0
- package/templates/contextkit/squads/agent-forge/lib/eval-designer.mjs +133 -0
- package/templates/contextkit/squads/agent-forge/lib/eval-runner.mjs +167 -0
- package/templates/contextkit/squads/agent-forge/lib/governance-officer.mjs +178 -0
- package/templates/contextkit/squads/agent-forge/lib/package-ops.mjs +101 -0
- package/templates/contextkit/squads/agent-forge/lib/packager.mjs +219 -0
- package/templates/contextkit/squads/agent-forge/lib/prompt-gen.mjs +122 -0
- package/templates/contextkit/squads/agent-forge/lib/rag-designer.mjs +102 -0
- package/templates/contextkit/squads/agent-forge/lib/router.mjs +165 -0
- package/templates/contextkit/squads/agent-forge/lib/tool-gen.mjs +113 -0
- package/templates/contextkit/squads/agent-forge/lib/yaml.mjs +47 -0
- package/templates/contextkit/squads/agent-forge/pipeline.yaml +65 -0
- package/templates/contextkit/squads/agent-forge/router/capability-matrix.json +112 -0
- package/templates/contextkit/squads/agent-forge/router/decision-rules.json +120 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/.agentforgerc +12 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/CHANGELOG.md +13 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/LICENSE +5 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/README.md +39 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/adapters/go/README.md +10 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/adapters/go/agent.go +14 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/adapters/go/go.mod +3 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/adapters/node/README.md +11 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/adapters/node/index.js +53 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/adapters/node/package.json +9 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/adapters/python/README.md +10 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/adapters/python/agent.py +16 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/adapters/python/pyproject.toml +10 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/evals/golden.jsonl +1 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/evals/red-team.jsonl +3 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/evals/rubric.yaml +14 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/evals/run-eval.md +17 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/evals/thresholds.yaml +18 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/examples/basic.node.md +17 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/examples/with-fallback.node.md +24 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/examples/with-rag.python.md +20 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/governance/audit.schema.json +23 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/governance/compliance.policy.yaml +43 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/governance/cost.policy.yaml +36 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/governance/fallback-chain.yaml +16 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/governance/quality.policy.yaml +43 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/manifest.yaml +91 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/prompts/system.anthropic.md +19 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/prompts/system.canonical.md +25 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/prompts/system.deepseek.md +21 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/prompts/system.google.md +19 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/prompts/system.ollama.md +21 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/prompts/system.openai.md +20 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/rag/config.yaml +17 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/rag/index/.gitkeep +3 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/rag/ingestion/chunker.config.yaml +6 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/rag/ingestion/sources.yaml +8 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/rag/retrieval/query-template.md +16 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/rag/retrieval/rerank.config.yaml +6 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/tools/adapters/anthropic.tools.json +11 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/tools/adapters/deepseek.tools.json +14 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/tools/adapters/google.tools.json +11 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/tools/adapters/ollama.tools.json +14 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/tools/adapters/openai.tools.json +14 -0
- package/templates/contextkit/squads/agent-forge/templates/agent-package/tools/schemas.canonical.json +25 -0
- package/templates/contextkit/starters/tanstack/README.md +86 -0
- package/templates/contextkit/starters/tanstack/index.html +12 -0
- package/templates/contextkit/starters/tanstack/package.json +25 -0
- package/templates/contextkit/starters/tanstack/src/main.tsx +40 -0
- package/templates/contextkit/starters/tanstack/src/router.tsx +12 -0
- package/templates/contextkit/starters/tanstack/src/routes/__root.tsx +10 -0
- package/templates/contextkit/starters/tanstack/src/routes/index.tsx +17 -0
- package/templates/contextkit/starters/tanstack/tsconfig.json +19 -0
- package/templates/contextkit/starters/tanstack/vite.config.ts +10 -0
- package/templates/contextkit/tools/scripts/adr-digest-core.mjs +42 -0
- package/templates/contextkit/tools/scripts/adr-digest.mjs +78 -0
- package/templates/contextkit/tools/scripts/agent-tuning.mjs +74 -0
- package/templates/contextkit/tools/scripts/aiso-audit.mjs +174 -0
- package/templates/contextkit/tools/scripts/audit-shared.mjs +129 -0
- package/templates/contextkit/tools/scripts/claim.mjs +133 -0
- package/templates/contextkit/tools/scripts/claude-md.mjs +123 -0
- package/templates/contextkit/tools/scripts/clean-drive.mjs +78 -0
- package/templates/contextkit/tools/scripts/context-config.mjs +111 -0
- package/templates/contextkit/tools/scripts/context-level.mjs +98 -0
- package/templates/contextkit/tools/scripts/context-pack.mjs +120 -0
- package/templates/contextkit/tools/scripts/contract-scan.mjs +186 -0
- package/templates/contextkit/tools/scripts/dashboard-data.mjs +198 -0
- package/templates/contextkit/tools/scripts/dashboard-html.mjs +215 -0
- package/templates/contextkit/tools/scripts/dashboard-server.mjs +129 -0
- package/templates/contextkit/tools/scripts/dashboard.mjs +107 -0
- package/templates/contextkit/tools/scripts/deep-analysis.mjs +62 -0
- package/templates/contextkit/tools/scripts/deps-audit.mjs +201 -0
- package/templates/contextkit/tools/scripts/detect-stack.mjs +164 -0
- package/templates/contextkit/tools/scripts/distill-detect.mjs +90 -0
- package/templates/contextkit/tools/scripts/doctor.mjs +165 -0
- package/templates/contextkit/tools/scripts/fleet.mjs +170 -0
- package/templates/contextkit/tools/scripts/generate-context.mjs +142 -0
- package/templates/contextkit/tools/scripts/gh-alerts.mjs +117 -0
- package/templates/contextkit/tools/scripts/git.mjs +97 -0
- package/templates/contextkit/tools/scripts/home.mjs +106 -0
- package/templates/contextkit/tools/scripts/mark-simulation.mjs +78 -0
- package/templates/contextkit/tools/scripts/media-gen.mjs +154 -0
- package/templates/contextkit/tools/scripts/pipeline-board.mjs +74 -0
- package/templates/contextkit/tools/scripts/pipeline-prioritize.mjs +68 -0
- package/templates/contextkit/tools/scripts/pipeline-session.mjs +99 -0
- package/templates/contextkit/tools/scripts/pipeline-validate.mjs +136 -0
- package/templates/contextkit/tools/scripts/pipeline.mjs +302 -0
- package/templates/contextkit/tools/scripts/playbook.mjs +123 -0
- package/templates/contextkit/tools/scripts/predictions-review.mjs +113 -0
- package/templates/contextkit/tools/scripts/release.mjs +60 -0
- package/templates/contextkit/tools/scripts/resume.mjs +114 -0
- package/templates/contextkit/tools/scripts/roadmap.mjs +86 -0
- package/templates/contextkit/tools/scripts/runs.mjs +116 -0
- package/templates/contextkit/tools/scripts/seo-audit.mjs +150 -0
- package/templates/contextkit/tools/scripts/session-digest.mjs +89 -0
- package/templates/contextkit/tools/scripts/session-reindex.mjs +91 -0
- package/templates/contextkit/tools/scripts/setup-complete.mjs +69 -0
- package/templates/contextkit/tools/scripts/squad-meta.mjs +23 -0
- package/templates/contextkit/tools/scripts/squad-pipeline-condition.mjs +192 -0
- package/templates/contextkit/tools/scripts/squad-pipeline.mjs +301 -0
- package/templates/contextkit/tools/scripts/squad.mjs +80 -0
- package/templates/contextkit/tools/scripts/stats.mjs +138 -0
- package/templates/contextkit/tools/scripts/sync-check.mjs +235 -0
- package/templates/contextkit/tools/scripts/tech-debt-detectors.mjs +76 -0
- package/templates/contextkit/tools/scripts/tech-debt-scan.mjs +164 -0
- package/templates/contextkit/tools/scripts/token-report.mjs +153 -0
- package/templates/contextkit/tools/scripts/visual-test.mjs +132 -0
- package/templates/contextkit/tools/scripts/watch.mjs +106 -0
- package/templates/contextkit/tools/scripts/workflow.mjs +136 -0
- package/templates/contextkit/tools/scripts/workspace-sync.mjs +220 -0
- package/templates/contextkit/tools/scripts/worktree-new.mjs +50 -0
- package/templates/contextkit/workflows/L1-static-loading.md +59 -0
- package/templates/contextkit/workflows/L2-session-ledger.md +86 -0
- package/templates/contextkit/workflows/L3-multi-session.md +80 -0
- package/templates/contextkit/workflows/L4-squads.md +68 -0
- package/templates/contextkit/workflows/L5-proactive.md +88 -0
- package/templates/contextkit/workflows/README.md +47 -0
- package/templates/contextkit/workflows/playbooks/distillation-cycle.md +74 -0
- package/templates/contextkit/workflows/playbooks/landing-page.md +197 -0
- package/templates/contextkit/workflows/playbooks/security-batch.md +68 -0
- package/templates/contextkit/workflows/playbooks/seo-aiso.md +288 -0
- package/templates/contextkit/workflows/playbooks/simulate-impact.md +83 -0
- package/templates/contextkit/workflows/playbooks/tanstack.md +164 -0
- package/templates/contextkit/workflows/playbooks/tech-debt-sweep.md +77 -0
- package/templates/docs/CHANGELOG.md.tpl +11 -0
- package/templates/gitattributes +3 -0
- package/templates/github/ISSUE_TEMPLATE/bug_report.md +30 -0
- package/templates/github/ISSUE_TEMPLATE/feature_request.md +22 -0
- package/templates/github/PULL_REQUEST_TEMPLATE.md +27 -0
- package/templates/github/dependabot.yml +27 -0
- package/templates/github/workflows/quality.yml +36 -0
- package/templates/github/workflows/security.yml +54 -0
- package/tools/install/cli.mjs +62 -0
- package/tools/install/fs.mjs +56 -0
- package/tools/install/git.mjs +114 -0
- package/tools/install/project.mjs +51 -0
- package/tools/install/uninstall.mjs +54 -0
- package/tools/integration-test-compozy.mjs +88 -0
- package/tools/integration-test-guards.mjs +269 -0
- package/tools/integration-test-tooling-agent-forge.mjs +189 -0
- package/tools/integration-test-tooling-pipeline.mjs +164 -0
- package/tools/integration-test-tooling.mjs +172 -0
- package/tools/integration-test.mjs +228 -0
- package/tools/it-helpers.mjs +60 -0
- package/tools/selfcheck-agent-forge-ops.mjs +107 -0
- package/tools/selfcheck-agent-forge.mjs +304 -0
- package/tools/selfcheck-config.mjs +80 -0
- package/tools/selfcheck-runtime.mjs +135 -0
- package/tools/selfcheck-source.mjs +326 -0
- package/tools/selfcheck.mjs +268 -0
package/README.md
ADDED
|
@@ -0,0 +1,401 @@
|
|
|
1
|
+
# 🌀 ContextDevKit
|
|
2
|
+
|
|
3
|
+
[](https://github.com/reiTavares/ContextDevKit/actions/workflows/ci.yml)
|
|
4
|
+
[](https://www.npmjs.com/package/contextdevkit)
|
|
5
|
+

|
|
6
|
+

|
|
7
|
+

|
|
8
|
+
|
|
9
|
+
> A portable, **level-based AI-assisted development platform** for Claude Code.
|
|
10
|
+
> Drop it into any project — greenfield or existing, any stack — and get durable
|
|
11
|
+
> project memory, automatic context loading, drift detection, specialized
|
|
12
|
+
> sub-agents, **opinionated playbooks** (TanStack, landing pages, SEO+AISO), and
|
|
13
|
+
> proactive governance. Activate as much or as little as you want.
|
|
14
|
+
|
|
15
|
+
ContextDevKit is the generalized, stack-agnostic distillation of a production context
|
|
16
|
+
system. It treats "AI-assisted coding" as **engineering**: instead of hoping the AI
|
|
17
|
+
remembers things, it makes the harness *enforce* them with hooks, and it records
|
|
18
|
+
the *why* in version control so any future session — human or AI — can pick up
|
|
19
|
+
where the last one left off.
|
|
20
|
+
|
|
21
|
+
## What's new in v1.7
|
|
22
|
+
|
|
23
|
+
| Feature | What it does |
|
|
24
|
+
|---|---|
|
|
25
|
+
| **Landing-page skills** ([ADR-0023](contextkit/memory/decisions/0023-landing-page-and-conversion-posture.md)) | `landing-architect` agent + `/landing-page` command + opinionated anti-Lovable playbook (fold rules min 3 / ideal 5–7 / max 9; dated package recs) |
|
|
26
|
+
| **Media generation** ([ADR-0024](contextkit/memory/decisions/0024-media-generation-veo-nano-banana.md)) | `/media-gen` with Veo (video) + Nano Banana (image) adapters; `.env`-based; refuse-on-missing-creds + per-process cost cap |
|
|
27
|
+
| **SEO + AISO** ([ADR-0025](contextkit/memory/decisions/0025-seo-and-aiso-posture.md)) | `seo-specialist` agent + `/seo-audit` running 16 static checks (SEO + AI Search Optimization); refuse-on-unindexable SPAs |
|
|
28
|
+
| **GitHub sync awareness** ([ADR-0026](contextkit/memory/decisions/0026-github-sync-awareness-dev-flow.md)) | `sync-check.mjs` shows open PRs with CI/review status at `/dev-start` + detects duplicate PRs pre-push |
|
|
29
|
+
| **`/dashboard`** | Visual project state (kanban + ADRs + sessions + roadmap) — single self-contained HTML or live SSE-driven (`--watch`) |
|
|
30
|
+
| **`/watch`** | Tail the active session ledger; optional `--follow` mode |
|
|
31
|
+
| **`/workflow`** | Macro chaining roadmap → ADR → pipeline → ship with breadcrumbs |
|
|
32
|
+
| **`/resume`** | Re-bind to a previously unregistered drift session |
|
|
33
|
+
| **`/runs`** | List recent task transitions + pipeline runs across squads |
|
|
34
|
+
| **Provider adapters** | `runtime/providers/review/` (gh) + `runtime/providers/media/` (Veo + Nano Banana) — same five-point contract |
|
|
35
|
+
| **Task metadata v2** | Strict DAG `dependencies: []` + `complexity: S\|M\|L\|XL` + `spike` / `docs` types |
|
|
36
|
+
|
|
37
|
+
## Why
|
|
38
|
+
|
|
39
|
+
A plain `CLAUDE.md` is just instructions the AI can ignore. ContextDevKit adds the
|
|
40
|
+
parts that don't depend on the AI's goodwill:
|
|
41
|
+
|
|
42
|
+
- **Hooks** inject context at session start, track every edit, and *block* the
|
|
43
|
+
session from ending with unregistered work.
|
|
44
|
+
- **Durable memory** — ADRs (the *why*), session logs (the *what*), a glossary
|
|
45
|
+
(the naming authority), and an auto-generated changelog — all in your repo.
|
|
46
|
+
- **Levels (1–7)** so you adopt it gradually: start with memory only, turn on
|
|
47
|
+
more as the project (and your trust) grows.
|
|
48
|
+
- **Squads of specialists** — devteam, qa-team, design-team (with SEO + landing
|
|
49
|
+
architect), agent-forge, compliance-team, ops-team — each agent sharp and narrow.
|
|
50
|
+
|
|
51
|
+
## Requirements
|
|
52
|
+
|
|
53
|
+
- **Node.js ≥ 18** (the hooks/scripts are plain `.mjs`; Levels 1–3 need **zero**
|
|
54
|
+
npm packages). Node 20.6+ unlocks `--env-file` for the media-gen credentials
|
|
55
|
+
flow.
|
|
56
|
+
- **git** (for divergence detection and the Level 3 git hooks).
|
|
57
|
+
- **Claude Code** (CLI, desktop, web, or IDE extension).
|
|
58
|
+
- *Optional:* `gh` (GitHub CLI) for sync-check PR awareness; `GOOGLE_AI_API_KEY`
|
|
59
|
+
for `/media-gen`.
|
|
60
|
+
|
|
61
|
+
## Install
|
|
62
|
+
|
|
63
|
+
**One command, from anywhere** (the repo is the installer):
|
|
64
|
+
|
|
65
|
+
```bash
|
|
66
|
+
# from npm (recommended) — auto-picks L3 for an empty folder, L7 if it already has code
|
|
67
|
+
npx contextdevkit --target . --yes
|
|
68
|
+
|
|
69
|
+
# or straight from GitHub (no npm needed)
|
|
70
|
+
npx github:reiTavares/ContextDevKit --target . --yes
|
|
71
|
+
```
|
|
72
|
+
|
|
73
|
+
Or clone and run locally:
|
|
74
|
+
|
|
75
|
+
```bash
|
|
76
|
+
# interactive — asks name / mode / level
|
|
77
|
+
node install.mjs --target /path/to/your-project
|
|
78
|
+
|
|
79
|
+
# non-interactive (omit --level to auto-pick L3/L7; pass --level <1-7> to pin one)
|
|
80
|
+
node install.mjs --target /path/to/your-project --name "My App" --yes
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
Greenfield? Run it in an empty (or `git init`-ed) folder and it scaffolds the
|
|
84
|
+
whole thing. Existing project? It detects your stack, never clobbers your
|
|
85
|
+
`CLAUDE.md` (it writes `CLAUDE.contextdevkit.md` to merge by hand), and preserves
|
|
86
|
+
any hooks you already had.
|
|
87
|
+
|
|
88
|
+
### Security & trust (read before installing)
|
|
89
|
+
|
|
90
|
+
ContextDevKit is a code-execution tool — install it like any dependency you run:
|
|
91
|
+
|
|
92
|
+
- **`npx` runs the installer**, which writes git hooks under `.git/hooks/` (at
|
|
93
|
+
L≥3) and Claude Code hooks into `.claude/settings.json`. Those hooks then run
|
|
94
|
+
`node` on each session/commit/push. **Pin a tag** for a reproducible install
|
|
95
|
+
rather than tracking the moving default branch:
|
|
96
|
+
`npx github:reiTavares/ContextDevKit#v1.7.0 --target . --yes`.
|
|
97
|
+
- **An existing git hook is never clobbered** — the installer backs it up to
|
|
98
|
+
`<hook>.bak` before writing its wrapper. Worktrees are detected via the
|
|
99
|
+
`gitdir:` pointer and hooks are installed in the resolved real `.git/`.
|
|
100
|
+
- **`/fleet`** reads/executes scripts across *other* repos you register, and
|
|
101
|
+
**custom detectors** in `contextkit/detectors/*.mjs` are executed by the tech-debt
|
|
102
|
+
scanner with full Node privileges. Only register repos and add detectors you
|
|
103
|
+
trust — treat them as code review surface.
|
|
104
|
+
|
|
105
|
+
### Then: one-shot self-configuration
|
|
106
|
+
|
|
107
|
+
Open the project in Claude Code, approve the hooks once — and **ContextDevKit tells
|
|
108
|
+
you it isn't configured yet** (a first-run trigger fires from the boot hook).
|
|
109
|
+
Run:
|
|
110
|
+
|
|
111
|
+
```
|
|
112
|
+
/setupcontextdevkit
|
|
113
|
+
```
|
|
114
|
+
|
|
115
|
+
This inspects the project, tunes the config to your stack (`ledger` path lists,
|
|
116
|
+
high-risk paths), fills in `CLAUDE.md` (rules, stack, glossary), scaffolds domain
|
|
117
|
+
sub-agents, installs what's needed (with your OK), records a baseline ADR, and
|
|
118
|
+
logs the session — going from "kit installed" to "kit fitted to *this* project"
|
|
119
|
+
in a single pass. After it finishes, the trigger stops nagging.
|
|
120
|
+
|
|
121
|
+
### What you'll see
|
|
122
|
+
|
|
123
|
+
```text
|
|
124
|
+
$ npx contextdevkit --target . --yes
|
|
125
|
+
✓ .claude/settings.json wired for L7
|
|
126
|
+
✓ engine installed (contextkit/runtime, contextkit/tools)
|
|
127
|
+
✓ slash commands installed (.claude/commands)
|
|
128
|
+
✓ providers installed (review/, media/)
|
|
129
|
+
✓ CLAUDE.md created · docs/CHANGELOG.md created
|
|
130
|
+
✅ ContextDevKit installed at Level 7 (existing project — full toolkit)
|
|
131
|
+
|
|
132
|
+
# open in Claude Code → the boot hook greets you with:
|
|
133
|
+
## 🚀 First run — ContextDevKit not configured yet → run /setupcontextdevkit
|
|
134
|
+
|
|
135
|
+
> /setupcontextdevkit
|
|
136
|
+
Phase 1 — Inspect …… detected: TypeScript · Vite · React · vitest
|
|
137
|
+
Phase 3 — Apply …… ledger tuned (src/, tests/); high-risk: src/db/schema.ts
|
|
138
|
+
Phase 4 — CLAUDE.md … stack + immutable rules filled in
|
|
139
|
+
Phase 7 — baseline ADR-0001 recorded; session logged
|
|
140
|
+
✅ ContextDevKit fitted to this project.
|
|
141
|
+
```
|
|
142
|
+
|
|
143
|
+
## The seven levels
|
|
144
|
+
|
|
145
|
+
| Level | Name | Adds |
|
|
146
|
+
| --- | --- | --- |
|
|
147
|
+
| **1** | Memory | Boot context injection, `/log-session`, ADRs, changelog |
|
|
148
|
+
| **2** | Ledger | Drift detection — tracks edits, nudges you to register the session |
|
|
149
|
+
| **3** | Multi-session | `/claim` · `/worktree-new`, derived indices, git hooks (Conventional Commits + conflict-blocking pre-push) |
|
|
150
|
+
| **4** | Squads | Specialized sub-agents — devteam, qa-team, design-team (5 specialists incl. `seo-specialist` + `landing-architect`), compliance-team, ops-team |
|
|
151
|
+
| **5** | Proactive | `/simulate-impact` gate on high-risk paths, `/tech-debt-sweep` (deterministic), `/contract-check`, auto-distill nudge |
|
|
152
|
+
| **6** | Autonomy & Insight | `/ship` (orchestrated squad pipeline), `/retro` (learning loop), `/context-stats`, agent-forge squad |
|
|
153
|
+
| **7** | Ecosystem | `/fleet` multi-repo control plane, `/tune-agents`, visual tests, playbook runner |
|
|
154
|
+
|
|
155
|
+
Change level anytime — from inside the project:
|
|
156
|
+
|
|
157
|
+
```bash
|
|
158
|
+
node contextkit/tools/scripts/context-level.mjs # show
|
|
159
|
+
node contextkit/tools/scripts/context-level.mjs 4 # move to L4
|
|
160
|
+
```
|
|
161
|
+
|
|
162
|
+
…or via the `/context-level` slash command. Going up adds capability; going down
|
|
163
|
+
cleanly removes the now-disabled hooks. See [docs/LEVELS.md](docs/LEVELS.md).
|
|
164
|
+
|
|
165
|
+
## What gets installed into your project
|
|
166
|
+
|
|
167
|
+
```
|
|
168
|
+
your-project/
|
|
169
|
+
CLAUDE.md # boot context + your coding constitution
|
|
170
|
+
.claude/
|
|
171
|
+
settings.json # hook wiring (composed for your level)
|
|
172
|
+
commands/ # 60+ slash commands, organised in packs
|
|
173
|
+
audit/ # security + tech-debt + SEO/AISO audits
|
|
174
|
+
pipeline/ # DevPipeline + ship + dev-start + retro + runs
|
|
175
|
+
qa/ # qa-signoff, test-plan, scaffold-tests, visual-test
|
|
176
|
+
vcs/ # git, claim, release, worktree-new
|
|
177
|
+
forge/ # 14 agent-forge lifecycle commands (L6+)
|
|
178
|
+
setup/ # setupcontextdevkit, context-doctor, context-level
|
|
179
|
+
agents/ # 28 sub-agent archetypes (L4+)
|
|
180
|
+
contextkit/
|
|
181
|
+
.env.example # optional credentials template (media-gen)
|
|
182
|
+
runtime/hooks/ # the engine: boot, ledger, drift, L5 gate
|
|
183
|
+
runtime/config/ # zero-dep loader, defaults, settings composer
|
|
184
|
+
runtime/git-hooks/ # pre-commit (reindex), commit-msg, pre-push (block conflicts)
|
|
185
|
+
runtime/providers/
|
|
186
|
+
review/ # PR/review CLI adapters (gh)
|
|
187
|
+
media/ # Veo + Nano Banana adapters
|
|
188
|
+
runtime/state/ # canonical state.json substrate (ADR-0015)
|
|
189
|
+
tools/scripts/ # 50+ helpers (reindex, dashboard, sync-check, audits, …)
|
|
190
|
+
memory/decisions/ # ADRs (the why)
|
|
191
|
+
memory/sessions/ # one file per session (the what)
|
|
192
|
+
memory/GLOSSARY.md
|
|
193
|
+
pipeline/ # DevPipeline lanes: backlog / working / testing / conclusion
|
|
194
|
+
workflows/playbooks/ # tanstack, landing-page, seo-aiso, tech-debt-sweep, …
|
|
195
|
+
squads/agent-forge/ # the "agent that builds agents" (L6+)
|
|
196
|
+
config.json # level + ledger path lists + L5 params
|
|
197
|
+
docs/CHANGELOG.md
|
|
198
|
+
```
|
|
199
|
+
|
|
200
|
+
## Slash commands
|
|
201
|
+
|
|
202
|
+
Organised into **domain packs** so the `/` menu doesn't read as a 60-file scroll.
|
|
203
|
+
The basename resolver is path-agnostic — `/qa-signoff` finds `qa/qa-signoff.md`
|
|
204
|
+
exactly the same as a flat layout.
|
|
205
|
+
|
|
206
|
+
**Setup:** `/aidevtool-from0` (empty project) · `/setupcontextdevkit` (existing project)
|
|
207
|
+
|
|
208
|
+
**Daily** (root pack): `/state` · `/log-session` · `/new-adr` · `/close-version`
|
|
209
|
+
· `/context-refresh` · `/bug-hunt` · `/dashboard` · `/watch` · `/landing-page`
|
|
210
|
+
· `/media-gen` · `/playbook` · `/predictions-review` · `/squad` · `/token-report`
|
|
211
|
+
· `/tune-agents` · `/context-stats` · `/fleet` · `/distill-sessions` · `/distill-apply`
|
|
212
|
+
· `/simulate-impact` · `/roadmap`
|
|
213
|
+
|
|
214
|
+
**`pipeline/`:** `/pipeline` · `/ship` · `/dev-start` · `/retro` · `/runs` · `/workflow`
|
|
215
|
+
|
|
216
|
+
**`vcs/`:** `/git` · `/claim` · `/release` · `/worktree-new` · `/resume`
|
|
217
|
+
|
|
218
|
+
**`qa/`:** `/qa-signoff` · `/test-plan` · `/scaffold-tests` · `/visual-test`
|
|
219
|
+
|
|
220
|
+
**`audit/`:** `/audit` · `/deep-analysis` · `/security-setup` · `/deps-audit` ·
|
|
221
|
+
`/tech-debt-sweep` · `/analyze-code-ia-practices` · `/contract-check` · `/seo-audit`
|
|
222
|
+
|
|
223
|
+
**`forge/`** (L6+, agent-forge squad): `/forge-new` and 13 lifecycle commands
|
|
224
|
+
(`forge-{list,show,doctor,policy,budget,audit,eval,redteam,route,
|
|
225
|
+
fallback-test,refresh-matrix,killswitch,deprecate}`)
|
|
226
|
+
|
|
227
|
+
**`setup/`:** `/setupcontextdevkit` · `/aidevtool-from0` · `/context-doctor`
|
|
228
|
+
· `/context-level` · `/context-config`
|
|
229
|
+
|
|
230
|
+
## Squads — sub-agents organised by domain
|
|
231
|
+
|
|
232
|
+
Each squad has a **router agent** that picks specialists by intent.
|
|
233
|
+
|
|
234
|
+
| Squad | Specialists | When |
|
|
235
|
+
|---|---|---|
|
|
236
|
+
| **devteam** | `architect`, `code-reviewer`, `context-keeper`, `test-engineer` | Cross-cutting design + PR review + memory hygiene |
|
|
237
|
+
| **qa-team** | `qa-orchestrator` + `qa-unit` / `qa-integration` / `qa-fuzzer` / `qa-perf` / `qa-e2e` | Testing strategy + execution |
|
|
238
|
+
| **design-team** | `ui-designer`, `ux-designer`, `accessibility`, **`seo-specialist`** *(new in v1.7)*, **`landing-architect`** *(new in v1.7)* | UI/UX, WCAG AA, SEO + AISO, high-conversion landing pages |
|
|
239
|
+
| **security-team** | `security`, `code-security`, `infra-security` | Auth, secrets, dependencies, IaC, supply chain |
|
|
240
|
+
| **compliance-team** | `privacy-lgpd`, `governance-officer` | LGPD (Brazilian data protection), policy |
|
|
241
|
+
| **ops-team** | `devops` | CI/CD, deploys, environments, observability |
|
|
242
|
+
| **agent-forge** *(L6+)* | `forge-orchestrator`, `model-router`, `prompt-engineer`, `tool-designer`, `eval-designer`, `packager`, `rag-designer`, `agent-architect` | The "agent that builds agents" — produces portable Agent Packages |
|
|
243
|
+
|
|
244
|
+
Grow your own — or new squads — from `_BRIEFING.md.tpl` via `/squad`.
|
|
245
|
+
See [`docs/SQUADS/design-team.md`](docs/SQUADS/design-team.md) for the
|
|
246
|
+
landing-page + SEO/AISO specialists in detail and
|
|
247
|
+
[`docs/SQUADS/agent-forge.md`](docs/SQUADS/agent-forge.md) for the L6+ squad.
|
|
248
|
+
|
|
249
|
+
## Playbooks
|
|
250
|
+
|
|
251
|
+
Reusable procedures in `contextkit/workflows/playbooks/`. Run with `/playbook
|
|
252
|
+
run <name>` or read on demand:
|
|
253
|
+
|
|
254
|
+
| Playbook | Authority | What it covers |
|
|
255
|
+
|---|---|---|
|
|
256
|
+
| **`landing-page.md`** | [ADR-0023](contextkit/memory/decisions/0023-landing-page-and-conversion-posture.md) | Fold rules, anti-Lovable refusals, dated package recs (Astro, Tailwind, Motion, Lucide, Plausible, GrowthBook), Core Web Vitals budget |
|
|
257
|
+
| **`seo-aiso.md`** | [ADR-0025](contextkit/memory/decisions/0025-seo-and-aiso-posture.md) | SEO checklist + AISO checklist (`llms.txt`, FAQ schema, semantic HTML5, AI-crawler robots.txt detection) |
|
|
258
|
+
| **`tanstack.md`** | [ADR-0017](contextkit/memory/decisions/0017-tanstack-stack-recognition-and-opt-in-starter.md) | TanStack family (Query/Router/Table/Form/Virtual/Start), cache-key discipline, typed router params |
|
|
259
|
+
| **`simulate-impact.md`** | L5 gate | Map blast radius before editing high-risk paths |
|
|
260
|
+
| **`tech-debt-sweep.md`** | L5 audit | Deterministic constitution scan + interpretation |
|
|
261
|
+
| **`distillation-cycle.md`** | L5 retro | Propose CLAUDE.md refinements from session history |
|
|
262
|
+
| **`security-batch.md`** | security-team | Batch security findings → ADRs + backlog |
|
|
263
|
+
|
|
264
|
+
## Provider adapters
|
|
265
|
+
|
|
266
|
+
Pluggable runtime adapters that shell out to user-installed CLIs or external
|
|
267
|
+
APIs. Each adapter is zero-dep (`node:fetch` or `child_process.spawn`) with a
|
|
268
|
+
typed error contract and refuse-on-missing-creds posture.
|
|
269
|
+
|
|
270
|
+
### Review providers — `contextkit/runtime/providers/review/`
|
|
271
|
+
|
|
272
|
+
| Adapter | Binary | What |
|
|
273
|
+
|---|---|---|
|
|
274
|
+
| **`gh`** | `gh` CLI | PR creation, review comments listing, top-level review comment posting |
|
|
275
|
+
|
|
276
|
+
Add `glab.mjs` / `bb.mjs` / `tea.mjs` for GitLab / Bitbucket / Gitea — each
|
|
277
|
+
follows the same `_adapter.mjs` contract. `detect.mjs` resolves the adapter
|
|
278
|
+
from `git remote get-url origin` and records the choice in `contextkit/config.json`.
|
|
279
|
+
|
|
280
|
+
### Media providers — `contextkit/runtime/providers/media/` *(new in v1.7)*
|
|
281
|
+
|
|
282
|
+
| Adapter | Kind | Auth | Cost floor (dated 2026-06-02) |
|
|
283
|
+
|---|---|---|---|
|
|
284
|
+
| **`nano-banana`** | image (Imagen 3) | `GOOGLE_AI_API_KEY` | ~$0.04 / image |
|
|
285
|
+
| **`veo`** | video (Veo 3) | `GOOGLE_AI_API_KEY` | ~$0.50 / second |
|
|
286
|
+
|
|
287
|
+
Run via:
|
|
288
|
+
|
|
289
|
+
```bash
|
|
290
|
+
node --env-file=contextkit/.env contextkit/tools/scripts/media-gen.mjs image \
|
|
291
|
+
--prompt "editorial product hero, asymmetric grid" --out public/hero.png
|
|
292
|
+
|
|
293
|
+
# or video
|
|
294
|
+
node --env-file=contextkit/.env contextkit/tools/scripts/media-gen.mjs video \
|
|
295
|
+
--prompt "macro slow-motion of ink hitting paper" --out public/hero.mp4 \
|
|
296
|
+
--duration 8 --aspect-ratio 16:9
|
|
297
|
+
|
|
298
|
+
# or dry-run first (no API call, no charge)
|
|
299
|
+
node contextkit/tools/scripts/media-gen.mjs image --prompt "..." --out p.png --dry-run
|
|
300
|
+
```
|
|
301
|
+
|
|
302
|
+
Set `CONTEXTDEVKIT_MEDIA_MAX_USD=5.00` to cap per-process spend — the adapter
|
|
303
|
+
refuses the next call that would push the total over the cap.
|
|
304
|
+
|
|
305
|
+
## SEO + AISO audit
|
|
306
|
+
|
|
307
|
+
Two static analysers callable as a single command. Audit-first, refuse-on-SPA
|
|
308
|
+
on indexable surfaces (see [ADR-0025](contextkit/memory/decisions/0025-seo-and-aiso-posture.md)):
|
|
309
|
+
|
|
310
|
+
```bash
|
|
311
|
+
node contextkit/tools/scripts/seo-audit.mjs # 8 SEO codes, exit 1 on SPA_ENTRYPOINT
|
|
312
|
+
node contextkit/tools/scripts/aiso-audit.mjs --json # 8 AISO codes, machine-readable
|
|
313
|
+
```
|
|
314
|
+
|
|
315
|
+
| SEO codes | AISO codes |
|
|
316
|
+
|---|---|
|
|
317
|
+
| `SPA_ENTRYPOINT` ⚠️ critical, `MISSING_TITLE`, `MISSING_DESCRIPTION`, `MULTIPLE_H1`, `MISSING_CANONICAL`, `MISSING_ALT`, `MISSING_SITEMAP`, `MISSING_ROBOTS` | `MISSING_LLMS_TXT`, `MISSING_FAQ_SCHEMA`, `MISSING_ORG_SCHEMA`, `DIV_SOUP`, `JS_RENDERED_CONTENT`, `MISSING_AUTHOR_SCHEMA`, `MISSING_DATE_STAMP`, `BLOCKS_AI_CRAWLERS` |
|
|
318
|
+
|
|
319
|
+
## Visual surfaces — `/dashboard` + `/watch`
|
|
320
|
+
|
|
321
|
+
Two zero-dep visual surfaces over the kit's existing files:
|
|
322
|
+
|
|
323
|
+
- **`/dashboard`** writes a self-contained HTML (inline CSS + vanilla JS, no
|
|
324
|
+
external assets) showing pipeline lanes + ADRs + sessions + roadmap +
|
|
325
|
+
`[Unreleased]` CHANGELOG. `--watch` mode binds `127.0.0.1:4242` and pushes
|
|
326
|
+
updates via Server-Sent Events when files change.
|
|
327
|
+
- **`/watch`** tails the active session ledger — what got edited, in order.
|
|
328
|
+
`--follow` streams new entries every 500ms.
|
|
329
|
+
|
|
330
|
+
```bash
|
|
331
|
+
node contextkit/tools/scripts/dashboard.mjs # snapshot → dashboard.html
|
|
332
|
+
node contextkit/tools/scripts/dashboard.mjs --watch # live on 127.0.0.1:4242
|
|
333
|
+
node contextkit/tools/scripts/watch.mjs --follow # tail the ledger
|
|
334
|
+
```
|
|
335
|
+
|
|
336
|
+
## Roadmap vs DevPipeline
|
|
337
|
+
|
|
338
|
+
Two different artifacts: **`contextkit/memory/roadmap.md`** is the *product/business
|
|
339
|
+
plan* (capabilities, P-IDs, the what/why). The **DevPipeline**
|
|
340
|
+
(`contextkit/pipeline/`, board in `devpipeline.md`) is *execution control* — bugs,
|
|
341
|
+
increments, chores, and roadmap items broken into tasks with priority, SLA, DAG
|
|
342
|
+
dependencies, and complexity, flowing `backlog → working → testing → conclusion`.
|
|
343
|
+
The roadmap says what to build; the pipeline runs the work.
|
|
344
|
+
|
|
345
|
+
🇧🇷 Guia em português: [instrucoes.md](instrucoes.md).
|
|
346
|
+
|
|
347
|
+
## Maintenance
|
|
348
|
+
|
|
349
|
+
```bash
|
|
350
|
+
# diagnose an install (node, config, hook wiring vs level, git hooks, onboarding)
|
|
351
|
+
/context-doctor # or: node contextkit/tools/scripts/doctor.mjs
|
|
352
|
+
|
|
353
|
+
# safe update — refresh engine + slash commands + hook wiring for your CURRENT
|
|
354
|
+
# level. NEVER touches CLAUDE.md, contextkit/config.json, memory (ADRs/sessions/
|
|
355
|
+
# roadmap), pipeline tasks, or scoped module CLAUDE.md files.
|
|
356
|
+
npx contextdevkit@latest --target . --update
|
|
357
|
+
# (offline / from GitHub: npx github:reiTavares/ContextDevKit --target . --update)
|
|
358
|
+
|
|
359
|
+
# change level (rewires settings.json, installs git hooks at L>=3)
|
|
360
|
+
/context-level 4
|
|
361
|
+
|
|
362
|
+
# uninstall — keeps your memory (ADRs, sessions) and CLAUDE.md
|
|
363
|
+
node /path/to/contextdevkit/install.mjs --target . --uninstall
|
|
364
|
+
# ...or also remove the engine/commands/agents:
|
|
365
|
+
node /path/to/contextdevkit/install.mjs --target . --uninstall --purge
|
|
366
|
+
```
|
|
367
|
+
|
|
368
|
+
## Customizing for your stack
|
|
369
|
+
|
|
370
|
+
The one thing worth tuning per project: **which paths matter**. Edit
|
|
371
|
+
`contextkit/config.json` → `ledger.*` (or use `/context-config`). A Python project adds
|
|
372
|
+
`app/`, `tests/`; a Go project adds `cmd/`, `internal/`. Everything else works
|
|
373
|
+
out of the box. See [docs/CUSTOMIZING.md](docs/CUSTOMIZING.md) for growing your
|
|
374
|
+
own squad of sub-agents, adding slash commands, the provider-adapter pattern, and
|
|
375
|
+
the media-gen credentials flow.
|
|
376
|
+
|
|
377
|
+
## Develop the kit itself
|
|
378
|
+
|
|
379
|
+
```bash
|
|
380
|
+
npm test # selfcheck + 6 integration suites (what CI runs)
|
|
381
|
+
node tools/selfcheck.mjs # static: loads the engine, asserts wiring per level
|
|
382
|
+
node tools/integration-test.mjs # end-to-end: installs to a temp dir, drives real hooks
|
|
383
|
+
```
|
|
384
|
+
|
|
385
|
+
See [CONTRIBUTING.md](CONTRIBUTING.md) for the rules (zero hot-path deps, hooks
|
|
386
|
+
never break work, add a test for anything you add).
|
|
387
|
+
|
|
388
|
+
## Docs
|
|
389
|
+
|
|
390
|
+
- [docs/LEVELS.md](docs/LEVELS.md) — what each level does and when to climb.
|
|
391
|
+
- [docs/ARCHITECTURE.md](docs/ARCHITECTURE.md) — how the engine works internally (hooks, providers, state substrate).
|
|
392
|
+
- [docs/CUSTOMIZING.md](docs/CUSTOMIZING.md) — tune config, add agents/commands, provider adapters, rebrand.
|
|
393
|
+
- [docs/SQUADS/design-team.md](docs/SQUADS/design-team.md) — UI/UX/a11y + SEO + landing-architect specialists.
|
|
394
|
+
- [docs/SQUADS/agent-forge.md](docs/SQUADS/agent-forge.md) — the L6+ "agent that builds agents".
|
|
395
|
+
- [docs/ROADMAP.md](docs/ROADMAP.md) — architect analysis, the L6/L7 capability tiers, future directions.
|
|
396
|
+
- [docs/AGENT-PACKAGE-FORMAT.md](docs/AGENT-PACKAGE-FORMAT.md) + [docs/SQUAD-PIPELINE-FORMAT.md](docs/SQUAD-PIPELINE-FORMAT.md) — agent-forge specs.
|
|
397
|
+
- [instrucoes.md](instrucoes.md) — guia de uso em português (pt-BR).
|
|
398
|
+
|
|
399
|
+
## License
|
|
400
|
+
|
|
401
|
+
MIT — see [LICENSE](LICENSE).
|
|
@@ -0,0 +1,140 @@
|
|
|
1
|
+
# Agent Package Format (APF) v1
|
|
2
|
+
|
|
3
|
+
> The portable, multi-provider, **zero-dep-at-consume-time** artefact that
|
|
4
|
+
> `agent-forge` produces. One directory per agent + semver; consumed by a
|
|
5
|
+
> client project's runtime adapter. The canonical template lives at
|
|
6
|
+
> [`templates/contextkit/squads/agent-forge/templates/agent-package/`](../templates/contextkit/squads/agent-forge/templates/agent-package/).
|
|
7
|
+
|
|
8
|
+
## Tree
|
|
9
|
+
|
|
10
|
+
```
|
|
11
|
+
agent-packages/
|
|
12
|
+
<agent-name>@<semver>/
|
|
13
|
+
manifest.yaml # SINGLE source of truth
|
|
14
|
+
README.md # human entry — carries the Model Selection Rationale
|
|
15
|
+
CHANGELOG.md # per-package semver chronology
|
|
16
|
+
LICENSE # set by the author (UNLICENSED by default)
|
|
17
|
+
.agentforgerc # provenance: forge version + blueprint hash + eval run
|
|
18
|
+
|
|
19
|
+
prompts/
|
|
20
|
+
system.canonical.md # neutral annotated source
|
|
21
|
+
system.anthropic.md # XML, cache=ephemeral
|
|
22
|
+
system.openai.md # Markdown # Role / ## Section
|
|
23
|
+
system.google.md # systemInstruction body + safetySettings note
|
|
24
|
+
system.deepseek.md # OpenAI-compat + explicit CoT cue
|
|
25
|
+
system.ollama.md # Markdown; chat_template applied by host
|
|
26
|
+
|
|
27
|
+
tools/
|
|
28
|
+
schemas.canonical.json # JSON Schema canonical (source of truth)
|
|
29
|
+
adapters/
|
|
30
|
+
anthropic.tools.json # { tools: [{ name, description, input_schema }] }
|
|
31
|
+
openai.tools.json # { tools: [{ type: "function", function: { … } }] }
|
|
32
|
+
google.tools.json # { functionDeclarations: [{ name, description, parameters }] }
|
|
33
|
+
deepseek.tools.json # OpenAI-compat
|
|
34
|
+
ollama.tools.json # OpenAI-compat
|
|
35
|
+
|
|
36
|
+
rag/ # only if `spec.capabilities.rag: true`
|
|
37
|
+
config.yaml # embedding model, index backend, retrieval params
|
|
38
|
+
ingestion/
|
|
39
|
+
retrieval/
|
|
40
|
+
index/.gitkeep # built by client, not embarked
|
|
41
|
+
|
|
42
|
+
evals/
|
|
43
|
+
golden.jsonl # seed cases + dev-expanded set (10–50)
|
|
44
|
+
red-team.jsonl # baseline: injection / jailbreak / PII + domain
|
|
45
|
+
rubric.yaml # field-match rules
|
|
46
|
+
thresholds.yaml # release_gate + monitoring_gate
|
|
47
|
+
run-eval.md # language-neutral runner contract
|
|
48
|
+
|
|
49
|
+
governance/
|
|
50
|
+
cost.policy.yaml # populated by governance-officer
|
|
51
|
+
compliance.policy.yaml # PII / LGPD / residency / retention / audit
|
|
52
|
+
quality.policy.yaml # eval_gates + fallback + kill_switch + retry
|
|
53
|
+
fallback-chain.yaml # ordered chain from router decision
|
|
54
|
+
audit.schema.json # audit-log line schema
|
|
55
|
+
|
|
56
|
+
adapters/ # only the runtimes requested by the blueprint
|
|
57
|
+
node/
|
|
58
|
+
python/
|
|
59
|
+
go/
|
|
60
|
+
|
|
61
|
+
examples/
|
|
62
|
+
basic.node.md
|
|
63
|
+
with-rag.python.md
|
|
64
|
+
with-fallback.node.md
|
|
65
|
+
```
|
|
66
|
+
|
|
67
|
+
## manifest.yaml
|
|
68
|
+
|
|
69
|
+
```yaml
|
|
70
|
+
apiVersion: agentforge.contextdevkit.io/v1
|
|
71
|
+
kind: Agent
|
|
72
|
+
metadata:
|
|
73
|
+
name: <agent-name>
|
|
74
|
+
version: 0.1.0
|
|
75
|
+
description: >
|
|
76
|
+
<one-paragraph what this agent does>
|
|
77
|
+
author: <email>
|
|
78
|
+
created: <YYYY-MM-DD>
|
|
79
|
+
provenance:
|
|
80
|
+
forged_by: agent-forge@<semver>
|
|
81
|
+
blueprint_hash: <sha256>
|
|
82
|
+
eval_passed_at: null # NULL until eval gate returns PASS
|
|
83
|
+
spec:
|
|
84
|
+
intent: # category × complexity × multimodal × domain
|
|
85
|
+
sla: # latency_p95_ms + availability_target
|
|
86
|
+
cost: # per-call + monthly budgets (alerted)
|
|
87
|
+
volume: # expected_qpd + burst_qps
|
|
88
|
+
privacy: # PII + LGPD basis + residency + zero-retention
|
|
89
|
+
capabilities: # tools / rag / streaming / structured_output
|
|
90
|
+
model_selection: # PRODUCED BY router, do not hand-edit
|
|
91
|
+
primary: { provider, model, temperature, max_tokens }
|
|
92
|
+
fallback: [{ provider, model, condition }]
|
|
93
|
+
cheap_path: { provider, model }
|
|
94
|
+
premium_path: { provider, model }
|
|
95
|
+
rules_applied: [<rule-id>...]
|
|
96
|
+
tools: [...]
|
|
97
|
+
rag: # block omitted if not enabled
|
|
98
|
+
evals: { golden: …, thresholds: … }
|
|
99
|
+
governance: { cost: …, compliance: …, quality: …, fallback: … }
|
|
100
|
+
runtime_adapters: [node, python]
|
|
101
|
+
```
|
|
102
|
+
|
|
103
|
+
## Versioning rules
|
|
104
|
+
|
|
105
|
+
- **Major** — contract break: tool removed/renamed, `intent` shifts, input/output schema breaks.
|
|
106
|
+
- **Minor** — additive: new tool, new capability, no break.
|
|
107
|
+
- **Patch** — prompt fix, threshold tweak, model swap within same family + generation.
|
|
108
|
+
|
|
109
|
+
Every version stamps `provenance.blueprint_hash` — re-forging a hand-edited
|
|
110
|
+
manifest changes the hash, surfacing the drift.
|
|
111
|
+
|
|
112
|
+
## Runtime contract
|
|
113
|
+
|
|
114
|
+
Every runtime adapter exposes the same interface — switching provider is a
|
|
115
|
+
manifest edit, not a code change:
|
|
116
|
+
|
|
117
|
+
```ts
|
|
118
|
+
interface AgentRuntime {
|
|
119
|
+
invoke(input): Promise<AgentOutput>
|
|
120
|
+
invokeStream(input): AsyncIterable<AgentChunk>
|
|
121
|
+
preflight(): Promise<HealthReport> // checks fallback-chain providers
|
|
122
|
+
estimate(input): CostEstimate
|
|
123
|
+
onEvent(handler): Unsubscribe // audit events per audit.schema.json
|
|
124
|
+
}
|
|
125
|
+
```
|
|
126
|
+
|
|
127
|
+
## Shadow-eval hook
|
|
128
|
+
|
|
129
|
+
The Node adapter ships a `createShadowEval` scaffold (see
|
|
130
|
+
`adapters/node/index.js`). Sample rate comes from
|
|
131
|
+
`quality.policy.yaml.eval_gates.drift_monitoring.sample_pct`. Real eval scoring
|
|
132
|
+
is delegated to the package's `evals/` + the kit's `eval-runner.mjs` so the
|
|
133
|
+
adapter stays thin.
|
|
134
|
+
|
|
135
|
+
## Approvals + decisions
|
|
136
|
+
|
|
137
|
+
- **[ADR-0012](../contextkit/memory/decisions/0012-agent-forge-squad-for-portable-agent-packages.md)** — adoption + 7 binding constraints.
|
|
138
|
+
- **[ADR-0013](../contextkit/memory/decisions/0013-agent-forge-yaml-via-optional-dynamic-import.md)** — YAML via optional dynamic import.
|
|
139
|
+
|
|
140
|
+
Full coverage map at the squad ROADMAP.
|