code-ai-installer 4.0.0 → 4.0.1-a
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +83 -67
- package/dist/index.js +2 -0
- package/dist/mcp/audit_ledger.d.ts +12 -0
- package/dist/mcp/audit_ledger.js +82 -0
- package/dist/mcp/cli.js +7 -1
- package/dist/mcp/config.d.ts +23 -0
- package/dist/mcp/config.js +36 -0
- package/dist/mcp/index.d.ts +1 -2
- package/dist/mcp/index.js +1 -2
- package/dist/mcp/paths.d.ts +20 -2
- package/dist/mcp/paths.js +29 -5
- package/dist/mcp/proposal_dedup.d.ts +32 -0
- package/dist/mcp/proposal_dedup.js +102 -0
- package/dist/mcp/proposal_store.d.ts +18 -0
- package/dist/mcp/proposal_store.js +74 -0
- package/dist/mcp/scorecard.d.ts +140 -0
- package/dist/mcp/scorecard.js +103 -0
- package/dist/mcp/skill_invocations.d.ts +15 -0
- package/dist/mcp/skill_invocations.js +28 -0
- package/dist/mcp/task_state.d.ts +77 -2
- package/dist/mcp/tools/_subprocess.d.ts +16 -0
- package/dist/mcp/tools/_subprocess.js +56 -0
- package/dist/mcp/tools/advance_gate.js +2 -2
- package/dist/mcp/tools/aggregate_run_metrics.d.ts +19 -0
- package/dist/mcp/tools/aggregate_run_metrics.js +139 -0
- package/dist/mcp/tools/apply_diff.d.ts +2 -0
- package/dist/mcp/tools/apply_diff.js +29 -0
- package/dist/mcp/tools/audit_bilocale_parity.d.ts +2 -0
- package/dist/mcp/tools/audit_bilocale_parity.js +146 -0
- package/dist/mcp/tools/audit_budget_compliance.d.ts +35 -0
- package/dist/mcp/tools/audit_budget_compliance.js +172 -0
- package/dist/mcp/tools/build.d.ts +2 -0
- package/dist/mcp/tools/build.js +47 -0
- package/dist/mcp/tools/check_lint.d.ts +2 -0
- package/dist/mcp/tools/check_lint.js +23 -0
- package/dist/mcp/tools/classify_gate.js +2 -2
- package/dist/mcp/tools/current_gate.js +2 -2
- package/dist/mcp/tools/dependency_supply_chain.d.ts +2 -0
- package/dist/mcp/tools/dependency_supply_chain.js +59 -0
- package/dist/mcp/tools/docker_compose.d.ts +2 -0
- package/dist/mcp/tools/docker_compose.js +24 -0
- package/dist/mcp/tools/e2e_playwright.d.ts +2 -0
- package/dist/mcp/tools/e2e_playwright.js +88 -0
- package/dist/mcp/tools/get_skill.js +17 -0
- package/dist/mcp/tools/git_commit.d.ts +2 -0
- package/dist/mcp/tools/git_commit.js +30 -0
- package/dist/mcp/tools/list_proposals.d.ts +6 -0
- package/dist/mcp/tools/list_proposals.js +16 -0
- package/dist/mcp/tools/list_skills.js +9 -1
- package/dist/mcp/tools/load_role.d.ts +3 -4
- package/dist/mcp/tools/load_role.js +11 -13
- package/dist/mcp/tools/propose_change.d.ts +8 -0
- package/dist/mcp/tools/propose_change.js +36 -0
- package/dist/mcp/tools/record_decision.js +25 -25
- package/dist/mcp/tools/review_proposal.d.ts +17 -0
- package/dist/mcp/tools/review_proposal.js +99 -0
- package/dist/mcp/tools/run_drift_audit.d.ts +11 -0
- package/dist/mcp/tools/run_drift_audit.js +79 -0
- package/dist/mcp/tools/run_tests.d.ts +2 -0
- package/dist/mcp/tools/run_tests.js +92 -0
- package/dist/mcp/tools/sign_off.js +14 -2
- package/dist/mcp/tools/stubs.js +30 -9
- package/dist/mcp/tools/verify_claim.js +33 -6
- package/dist/mcp_setup.d.ts +8 -0
- package/dist/mcp_setup.js +4 -1
- package/dist/shared/frontmatter.d.ts +44 -2
- package/dist/shared/frontmatter.js +54 -6
- package/dist/shared/index.d.ts +0 -5
- package/dist/shared/index.js +0 -5
- package/dist/shared/persona.d.ts +2 -2
- package/dist/shared/persona.js +1 -1
- package/dist/shared/pipeline.d.ts +46 -1
- package/dist/shared/tools.d.ts +1382 -16
- package/dist/shared/tools.js +229 -0
- package/dist/shared/vocabulary.d.ts +99 -4
- package/dist/shared/vocabulary.js +94 -5
- package/domains/analytics/.agents/skills/ansoff-matrix/SKILL.md +316 -300
- package/domains/analytics/.agents/skills/bcg-matrix/SKILL.md +345 -329
- package/domains/analytics/.agents/skills/blue-ocean-strategy/SKILL.md +432 -416
- package/domains/analytics/.agents/skills/board/SKILL.md +22 -0
- package/domains/analytics/.agents/skills/cohort-analysis/SKILL.md +338 -322
- package/domains/analytics/.agents/skills/competitive-analysis/SKILL.md +413 -395
- package/domains/analytics/.agents/skills/customer-journey-mapping/SKILL.md +347 -331
- package/domains/analytics/.agents/skills/gates/SKILL.md +388 -366
- package/domains/analytics/.agents/skills/handoff/SKILL.md +402 -380
- package/domains/analytics/.agents/skills/html-pdf-report/SKILL.md +21 -289
- package/domains/analytics/.agents/skills/html-pdf-report-reference/SKILL.md +325 -0
- package/domains/analytics/.agents/skills/html-pdf-report-reference/agents/claude.json +17 -0
- package/domains/analytics/.agents/skills/html-pdf-report-reference/agents/copilot.json +17 -0
- package/domains/analytics/.agents/skills/html-pdf-report-reference/agents/gemini.json +17 -0
- package/domains/analytics/.agents/skills/html-pdf-report-reference/agents/kimi.yaml +15 -0
- package/domains/analytics/.agents/skills/html-pdf-report-reference/agents/openai.yaml +10 -0
- package/domains/analytics/.agents/skills/html-pdf-report-reference/agents/qwen.json +17 -0
- package/domains/analytics/.agents/skills/html-pdf-report-reference/agents/skill.yaml +23 -0
- package/domains/analytics/.agents/skills/icp-buyer-persona/SKILL.md +407 -390
- package/domains/analytics/.agents/skills/jtbd-analysis/SKILL.md +357 -341
- package/domains/analytics/.agents/skills/karpathy-guidelines/SKILL.md +32 -0
- package/domains/analytics/.agents/skills/pest-analysis/SKILL.md +324 -305
- package/domains/analytics/.agents/skills/porters-five-forces/SKILL.md +377 -361
- package/domains/analytics/.agents/skills/report-design/SKILL.md +416 -398
- package/domains/analytics/.agents/skills/rfm-analysis/SKILL.md +330 -314
- package/domains/analytics/.agents/skills/session-prompt-generator/SKILL.md +400 -378
- package/domains/analytics/.agents/skills/swot-analysis/SKILL.md +340 -324
- package/domains/analytics/.agents/skills/tam-sam-som/SKILL.md +329 -312
- package/domains/analytics/.agents/skills/trend-analysis/SKILL.md +347 -331
- package/domains/analytics/.agents/skills/unit-economics/SKILL.md +430 -413
- package/domains/analytics/.agents/skills/value-chain-analysis/SKILL.md +346 -330
- package/domains/analytics/.agents/skills/web-research/SKILL.md +323 -308
- package/domains/analytics/AGENTS.md +1 -0
- package/domains/analytics/agents/auditor.md +76 -0
- package/domains/analytics/agents/conductor.md +11 -0
- package/domains/analytics/agents/data_analyst.md +11 -0
- package/domains/analytics/agents/designer.md +11 -0
- package/domains/analytics/agents/interviewer.md +11 -0
- package/domains/analytics/agents/layouter.md +11 -0
- package/domains/analytics/agents/mediator.md +11 -0
- package/domains/analytics/agents/researcher.md +11 -0
- package/domains/analytics/agents/strategist.md +11 -0
- package/domains/analytics/locales/en/.agents/skills/ansoff-matrix/SKILL.md +316 -300
- package/domains/analytics/locales/en/.agents/skills/bcg-matrix/SKILL.md +345 -329
- package/domains/analytics/locales/en/.agents/skills/blue-ocean-strategy/SKILL.md +432 -416
- package/domains/analytics/locales/en/.agents/skills/board/SKILL.md +22 -0
- package/domains/analytics/locales/en/.agents/skills/cohort-analysis/SKILL.md +338 -322
- package/domains/analytics/locales/en/.agents/skills/competitive-analysis/SKILL.md +413 -395
- package/domains/analytics/locales/en/.agents/skills/customer-journey-mapping/SKILL.md +347 -331
- package/domains/analytics/locales/en/.agents/skills/gates/SKILL.md +388 -366
- package/domains/analytics/locales/en/.agents/skills/handoff/SKILL.md +402 -380
- package/domains/analytics/locales/en/.agents/skills/html-pdf-report/SKILL.md +21 -289
- package/domains/analytics/locales/en/.agents/skills/html-pdf-report-reference/SKILL.md +325 -0
- package/domains/analytics/locales/en/.agents/skills/html-pdf-report-reference/agents/claude.json +17 -0
- package/domains/analytics/locales/en/.agents/skills/html-pdf-report-reference/agents/copilot.json +17 -0
- package/domains/analytics/locales/en/.agents/skills/html-pdf-report-reference/agents/gemini.json +17 -0
- package/domains/analytics/locales/en/.agents/skills/html-pdf-report-reference/agents/kimi.yaml +15 -0
- package/domains/analytics/locales/en/.agents/skills/html-pdf-report-reference/agents/openai.yaml +10 -0
- package/domains/analytics/locales/en/.agents/skills/html-pdf-report-reference/agents/qwen.json +17 -0
- package/domains/analytics/locales/en/.agents/skills/html-pdf-report-reference/agents/skill.yaml +29 -0
- package/domains/analytics/locales/en/.agents/skills/icp-buyer-persona/SKILL.md +407 -390
- package/domains/analytics/locales/en/.agents/skills/jtbd-analysis/SKILL.md +357 -341
- package/domains/analytics/locales/en/.agents/skills/karpathy-guidelines/SKILL.md +32 -0
- package/domains/analytics/locales/en/.agents/skills/pest-analysis/SKILL.md +324 -305
- package/domains/analytics/locales/en/.agents/skills/porters-five-forces/SKILL.md +377 -361
- package/domains/analytics/locales/en/.agents/skills/report-design/SKILL.md +416 -398
- package/domains/analytics/locales/en/.agents/skills/rfm-analysis/SKILL.md +330 -314
- package/domains/analytics/locales/en/.agents/skills/session-prompt-generator/SKILL.md +400 -378
- package/domains/analytics/locales/en/.agents/skills/swot-analysis/SKILL.md +340 -324
- package/domains/analytics/locales/en/.agents/skills/tam-sam-som/SKILL.md +329 -312
- package/domains/analytics/locales/en/.agents/skills/trend-analysis/SKILL.md +347 -331
- package/domains/analytics/locales/en/.agents/skills/unit-economics/SKILL.md +430 -413
- package/domains/analytics/locales/en/.agents/skills/value-chain-analysis/SKILL.md +366 -350
- package/domains/analytics/locales/en/.agents/skills/web-research/SKILL.md +324 -309
- package/domains/analytics/locales/en/AGENTS.md +1 -0
- package/domains/analytics/locales/en/agents/auditor.md +76 -0
- package/domains/analytics/locales/en/agents/conductor.md +27 -0
- package/domains/analytics/locales/en/agents/data_analyst.md +29 -0
- package/domains/analytics/locales/en/agents/designer.md +27 -0
- package/domains/analytics/locales/en/agents/interviewer.md +11 -0
- package/domains/analytics/locales/en/agents/layouter.md +11 -0
- package/domains/analytics/locales/en/agents/mediator.md +11 -0
- package/domains/analytics/locales/en/agents/researcher.md +11 -0
- package/domains/analytics/locales/en/agents/strategist.md +11 -0
- package/domains/analytics/persona/persona-base.md +94 -0
- package/domains/analytics/pipeline.yaml +102 -0
- package/domains/content/.agents/skills/audience-analysis/SKILL.md +15 -0
- package/domains/content/.agents/skills/board/SKILL.md +20 -0
- package/domains/content/.agents/skills/brand-compliance/SKILL.md +15 -0
- package/domains/content/.agents/skills/brand-guidelines/SKILL.md +17 -0
- package/domains/content/.agents/skills/competitor-content-analysis/SKILL.md +15 -0
- package/domains/content/.agents/skills/content-brief/SKILL.md +15 -0
- package/domains/content/.agents/skills/content-calendar/SKILL.md +15 -0
- package/domains/content/.agents/skills/content-release-gate/SKILL.md +15 -0
- package/domains/content/.agents/skills/content-review-checklist/SKILL.md +15 -0
- package/domains/content/.agents/skills/cta-optimization/SKILL.md +15 -0
- package/domains/content/.agents/skills/data-storytelling/SKILL.md +15 -0
- package/domains/content/.agents/skills/email-copywriting/SKILL.md +15 -0
- package/domains/content/.agents/skills/email-engagement-tiers/SKILL.md +15 -0
- package/domains/content/.agents/skills/fact-checking/SKILL.md +15 -0
- package/domains/content/.agents/skills/gates/SKILL.md +20 -0
- package/domains/content/.agents/skills/google-stitch-content/SKILL.md +15 -0
- package/domains/content/.agents/skills/handoff/SKILL.md +24 -0
- package/domains/content/.agents/skills/headline-formulas/SKILL.md +15 -0
- package/domains/content/.agents/skills/image-prompt-engineering/SKILL.md +15 -0
- package/domains/content/.agents/skills/karpathy-guidelines/SKILL.md +28 -0
- package/domains/content/.agents/skills/mailerlite-email-ops/SKILL.md +15 -0
- package/domains/content/.agents/skills/marketing-psychology/SKILL.md +15 -0
- package/domains/content/.agents/skills/moodboard/SKILL.md +15 -0
- package/domains/content/.agents/skills/platform-compliance/SKILL.md +15 -0
- package/domains/content/.agents/skills/platform-strategy/SKILL.md +15 -0
- package/domains/content/.agents/skills/platform-visual-specs/SKILL.md +15 -0
- package/domains/content/.agents/skills/readability-scoring/SKILL.md +15 -0
- package/domains/content/.agents/skills/seo-copywriting/SKILL.md +15 -0
- package/domains/content/.agents/skills/social-media-formats/SKILL.md +15 -0
- package/domains/content/.agents/skills/source-verification/SKILL.md +15 -0
- package/domains/content/.agents/skills/storytelling-framework/SKILL.md +15 -0
- package/domains/content/.agents/skills/tone-of-voice/SKILL.md +15 -0
- package/domains/content/.agents/skills/topic-research/SKILL.md +15 -0
- package/domains/content/.agents/skills/trend-research/SKILL.md +15 -0
- package/domains/content/.agents/skills/visual-brief/SKILL.md +15 -0
- package/domains/content/AGENTS.md +4 -0
- package/domains/content/agents/auditor.md +76 -0
- package/domains/content/agents/conductor.md +11 -0
- package/domains/content/agents/copywriter.md +11 -0
- package/domains/content/agents/researcher.md +11 -0
- package/domains/content/agents/reviewer.md +11 -0
- package/domains/content/agents/strategist.md +11 -0
- package/domains/content/agents/visual_concept.md +11 -0
- package/domains/content/locales/en/.agents/skills/audience-analysis/SKILL.md +15 -0
- package/domains/content/locales/en/.agents/skills/board/SKILL.md +20 -0
- package/domains/content/locales/en/.agents/skills/brand-compliance/SKILL.md +15 -0
- package/domains/content/locales/en/.agents/skills/brand-guidelines/SKILL.md +17 -0
- package/domains/content/locales/en/.agents/skills/competitor-content-analysis/SKILL.md +15 -0
- package/domains/content/locales/en/.agents/skills/content-brief/SKILL.md +15 -0
- package/domains/content/locales/en/.agents/skills/content-calendar/SKILL.md +15 -0
- package/domains/content/locales/en/.agents/skills/content-release-gate/SKILL.md +15 -0
- package/domains/content/locales/en/.agents/skills/content-review-checklist/SKILL.md +15 -0
- package/domains/content/locales/en/.agents/skills/cta-optimization/SKILL.md +15 -0
- package/domains/content/locales/en/.agents/skills/data-storytelling/SKILL.md +15 -0
- package/domains/content/locales/en/.agents/skills/email-copywriting/SKILL.md +15 -0
- package/domains/content/locales/en/.agents/skills/email-engagement-tiers/SKILL.md +15 -0
- package/domains/content/locales/en/.agents/skills/fact-checking/SKILL.md +15 -0
- package/domains/content/locales/en/.agents/skills/gates/SKILL.md +20 -0
- package/domains/content/locales/en/.agents/skills/google-stitch-content/SKILL.md +15 -0
- package/domains/content/locales/en/.agents/skills/handoff/SKILL.md +24 -0
- package/domains/content/locales/en/.agents/skills/headline-formulas/SKILL.md +15 -0
- package/domains/content/locales/en/.agents/skills/image-prompt-engineering/SKILL.md +15 -0
- package/domains/content/locales/en/.agents/skills/karpathy-guidelines/SKILL.md +30 -1
- package/domains/content/locales/en/.agents/skills/mailerlite-email-ops/SKILL.md +15 -0
- package/domains/content/locales/en/.agents/skills/marketing-psychology/SKILL.md +15 -0
- package/domains/content/locales/en/.agents/skills/moodboard/SKILL.md +15 -0
- package/domains/content/locales/en/.agents/skills/platform-compliance/SKILL.md +15 -0
- package/domains/content/locales/en/.agents/skills/platform-strategy/SKILL.md +15 -0
- package/domains/content/locales/en/.agents/skills/platform-visual-specs/SKILL.md +15 -0
- package/domains/content/locales/en/.agents/skills/readability-scoring/SKILL.md +15 -0
- package/domains/content/locales/en/.agents/skills/seo-copywriting/SKILL.md +15 -0
- package/domains/content/locales/en/.agents/skills/social-media-formats/SKILL.md +15 -0
- package/domains/content/locales/en/.agents/skills/source-verification/SKILL.md +15 -0
- package/domains/content/locales/en/.agents/skills/storytelling-framework/SKILL.md +15 -0
- package/domains/content/locales/en/.agents/skills/tone-of-voice/SKILL.md +15 -0
- package/domains/content/locales/en/.agents/skills/topic-research/SKILL.md +15 -0
- package/domains/content/locales/en/.agents/skills/trend-research/SKILL.md +15 -0
- package/domains/content/locales/en/.agents/skills/visual-brief/SKILL.md +15 -0
- package/domains/content/locales/en/AGENTS.md +4 -0
- package/domains/content/locales/en/agents/auditor.md +76 -0
- package/domains/content/locales/en/agents/conductor.md +12 -0
- package/domains/content/locales/en/agents/copywriter.md +12 -0
- package/domains/content/locales/en/agents/researcher.md +12 -0
- package/domains/content/locales/en/agents/reviewer.md +12 -0
- package/domains/content/locales/en/agents/strategist.md +12 -0
- package/domains/content/locales/en/agents/visual_concept.md +12 -0
- package/domains/content/persona/persona-base.md +94 -0
- package/domains/content/pipeline.yaml +96 -0
- package/domains/development/.agents/skills/adr-log/SKILL.md +1 -0
- package/domains/development/.agents/skills/design-intake/SKILL.md +0 -4
- package/domains/development/.agents/skills/karpathy-guidelines/SKILL.md +2 -1
- package/domains/development/.agents/skills/lava-flow-legacy-detection/SKILL.md +15 -1
- package/domains/development/.agents/skills/mcp-integration/SKILL.md +211 -0
- package/domains/development/.agents/skills/mcp-integration/agents/claude.json +22 -0
- package/domains/development/.agents/skills/mcp-integration/agents/copilot.json +22 -0
- package/domains/development/.agents/skills/mcp-integration/agents/gemini.json +22 -0
- package/domains/development/.agents/skills/mcp-integration/agents/kimi.yaml +18 -0
- package/domains/development/.agents/skills/mcp-integration/agents/openai.yaml +8 -0
- package/domains/development/.agents/skills/mcp-integration/agents/qwen.json +22 -0
- package/domains/development/.agents/skills/mcp-integration/agents/skill.yaml +26 -0
- package/domains/development/.agents/skills/qa-ui-a11y-smoke/SKILL.md +1 -1
- package/domains/development/.agents/skills/ui-a11y-smoke-review/SKILL.md +1 -1
- package/domains/development/AGENTS.md +1 -0
- package/domains/development/AGENTS.yaml +1 -0
- package/domains/development/agents/architect.md +13 -1
- package/domains/development/agents/auditor.md +74 -0
- package/domains/development/agents/conductor.md +14 -3
- package/domains/development/agents/devops.md +8 -9
- package/domains/development/agents/reviewer.md +12 -0
- package/domains/development/agents/senior_full_stack.md +12 -0
- package/domains/development/agents/tester.md +10 -16
- package/domains/development/locales/en/.agents/skills/adr-log/SKILL.md +1 -0
- package/domains/development/locales/en/.agents/skills/current-state-analysis/SKILL.md +256 -172
- package/domains/development/locales/en/.agents/skills/karpathy-guidelines/SKILL.md +2 -1
- package/domains/development/locales/en/.agents/skills/lava-flow-legacy-detection/SKILL.md +15 -1
- package/domains/development/locales/en/.agents/skills/mcp-integration/SKILL.md +211 -0
- package/domains/development/locales/en/.agents/skills/mcp-integration/agents/claude.json +22 -0
- package/domains/development/locales/en/.agents/skills/mcp-integration/agents/copilot.json +22 -0
- package/domains/development/locales/en/.agents/skills/mcp-integration/agents/gemini.json +22 -0
- package/domains/development/locales/en/.agents/skills/mcp-integration/agents/kimi.yaml +18 -0
- package/domains/development/locales/en/.agents/skills/mcp-integration/agents/openai.yaml +8 -0
- package/domains/development/locales/en/.agents/skills/mcp-integration/agents/qwen.json +22 -0
- package/domains/development/locales/en/.agents/skills/mcp-integration/agents/skill.yaml +26 -0
- package/domains/development/locales/en/.agents/skills/qa-ui-a11y-smoke/SKILL.md +1 -1
- package/domains/development/locales/en/.agents/skills/ui-a11y-smoke-review/SKILL.md +1 -1
- package/domains/development/locales/en/AGENTS.md +5 -0
- package/domains/development/locales/en/AGENTS.yaml +1 -0
- package/domains/development/locales/en/agents/architect.md +13 -1
- package/domains/development/locales/en/agents/auditor.md +74 -0
- package/domains/development/locales/en/agents/conductor.md +14 -3
- package/domains/development/locales/en/agents/devops.md +8 -9
- package/domains/development/locales/en/agents/reviewer.md +12 -0
- package/domains/development/locales/en/agents/senior_full_stack.md +12 -0
- package/domains/development/locales/en/agents/tester.md +10 -16
- package/domains/development/persona/persona-base.md +94 -0
- package/domains/product/.agents/skills/aarrr-metrics/SKILL.md +451 -433
- package/domains/product/.agents/skills/ab-test-design/SKILL.md +428 -412
- package/domains/product/.agents/skills/acceptance-criteria/SKILL.md +422 -406
- package/domains/product/.agents/skills/assumption-mapping/SKILL.md +323 -307
- package/domains/product/.agents/skills/board/SKILL.md +24 -0
- package/domains/product/.agents/skills/design-brief/SKILL.md +433 -418
- package/domains/product/.agents/skills/epic-breakdown/SKILL.md +435 -420
- package/domains/product/.agents/skills/gates/SKILL.md +470 -446
- package/domains/product/.agents/skills/gtm-brief/SKILL.md +18 -321
- package/domains/product/.agents/skills/gtm-brief-reference/SKILL.md +348 -0
- package/domains/product/.agents/skills/gtm-brief-reference/agents/claude.json +17 -0
- package/domains/product/.agents/skills/gtm-brief-reference/agents/copilot.json +17 -0
- package/domains/product/.agents/skills/gtm-brief-reference/agents/gemini.json +17 -0
- package/domains/product/.agents/skills/gtm-brief-reference/agents/kimi.yaml +15 -0
- package/domains/product/.agents/skills/gtm-brief-reference/agents/openai.yaml +10 -0
- package/domains/product/.agents/skills/gtm-brief-reference/agents/qwen.json +17 -0
- package/domains/product/.agents/skills/gtm-brief-reference/agents/skill.yaml +22 -0
- package/domains/product/.agents/skills/handoff/SKILL.md +463 -439
- package/domains/product/.agents/skills/html-pdf-report/SKILL.md +21 -663
- package/domains/product/.agents/skills/html-pdf-report-reference/SKILL.md +699 -0
- package/domains/product/.agents/skills/html-pdf-report-reference/agents/claude.json +17 -0
- package/domains/product/.agents/skills/html-pdf-report-reference/agents/copilot.json +17 -0
- package/domains/product/.agents/skills/html-pdf-report-reference/agents/gemini.json +17 -0
- package/domains/product/.agents/skills/html-pdf-report-reference/agents/kimi.yaml +15 -0
- package/domains/product/.agents/skills/html-pdf-report-reference/agents/openai.yaml +10 -0
- package/domains/product/.agents/skills/html-pdf-report-reference/agents/qwen.json +17 -0
- package/domains/product/.agents/skills/html-pdf-report-reference/agents/skill.yaml +22 -0
- package/domains/product/.agents/skills/hypothesis-template/SKILL.md +484 -469
- package/domains/product/.agents/skills/jtbd-canvas/SKILL.md +274 -258
- package/domains/product/.agents/skills/kano-model/SKILL.md +370 -355
- package/domains/product/.agents/skills/karpathy-guidelines/SKILL.md +36 -0
- package/domains/product/.agents/skills/launch-checklist/SKILL.md +434 -419
- package/domains/product/.agents/skills/moscow-prioritization/SKILL.md +407 -392
- package/domains/product/.agents/skills/north-star-metric/SKILL.md +317 -301
- package/domains/product/.agents/skills/okr-framework/SKILL.md +299 -284
- package/domains/product/.agents/skills/opportunity-solution-tree/SKILL.md +472 -456
- package/domains/product/.agents/skills/prd-template/SKILL.md +18 -258
- package/domains/product/.agents/skills/prd-template-reference/SKILL.md +285 -0
- package/domains/product/.agents/skills/prd-template-reference/agents/claude.json +17 -0
- package/domains/product/.agents/skills/prd-template-reference/agents/copilot.json +17 -0
- package/domains/product/.agents/skills/prd-template-reference/agents/gemini.json +17 -0
- package/domains/product/.agents/skills/prd-template-reference/agents/kimi.yaml +16 -0
- package/domains/product/.agents/skills/prd-template-reference/agents/openai.yaml +10 -0
- package/domains/product/.agents/skills/prd-template-reference/agents/qwen.json +17 -0
- package/domains/product/.agents/skills/prd-template-reference/agents/skill.yaml +23 -0
- package/domains/product/.agents/skills/problem-statement/SKILL.md +327 -312
- package/domains/product/.agents/skills/product-roadmap/SKILL.md +320 -304
- package/domains/product/.agents/skills/product-vision/SKILL.md +409 -394
- package/domains/product/.agents/skills/release-notes/SKILL.md +18 -258
- package/domains/product/.agents/skills/release-notes-reference/SKILL.md +285 -0
- package/domains/product/.agents/skills/release-notes-reference/agents/claude.json +17 -0
- package/domains/product/.agents/skills/release-notes-reference/agents/copilot.json +17 -0
- package/domains/product/.agents/skills/release-notes-reference/agents/gemini.json +17 -0
- package/domains/product/.agents/skills/release-notes-reference/agents/kimi.yaml +15 -0
- package/domains/product/.agents/skills/release-notes-reference/agents/openai.yaml +10 -0
- package/domains/product/.agents/skills/release-notes-reference/agents/qwen.json +17 -0
- package/domains/product/.agents/skills/release-notes-reference/agents/skill.yaml +22 -0
- package/domains/product/.agents/skills/report-design/SKILL.md +17 -307
- package/domains/product/.agents/skills/report-design-reference/SKILL.md +331 -0
- package/domains/product/.agents/skills/report-design-reference/agents/claude.json +17 -0
- package/domains/product/.agents/skills/report-design-reference/agents/copilot.json +17 -0
- package/domains/product/.agents/skills/report-design-reference/agents/gemini.json +17 -0
- package/domains/product/.agents/skills/report-design-reference/agents/kimi.yaml +15 -0
- package/domains/product/.agents/skills/report-design-reference/agents/openai.yaml +10 -0
- package/domains/product/.agents/skills/report-design-reference/agents/qwen.json +17 -0
- package/domains/product/.agents/skills/report-design-reference/agents/skill.yaml +22 -0
- package/domains/product/.agents/skills/rice-scoring/SKILL.md +266 -251
- package/domains/product/.agents/skills/saas-metrics/SKILL.md +422 -404
- package/domains/product/.agents/skills/session-prompt-generator/SKILL.md +474 -450
- package/domains/product/.agents/skills/user-flow/SKILL.md +491 -476
- package/domains/product/.agents/skills/user-interview-script/SKILL.md +315 -298
- package/domains/product/.agents/skills/user-story/SKILL.md +401 -385
- package/domains/product/.agents/skills/wsjf-scoring/SKILL.md +333 -315
- package/domains/product/AGENTS.md +5 -0
- package/domains/product/AGENTS.yaml +1 -0
- package/domains/product/agents/auditor.md +76 -0
- package/domains/product/agents/conductor.md +11 -0
- package/domains/product/agents/data_analyst.md +11 -0
- package/domains/product/agents/designer.md +11 -0
- package/domains/product/agents/discovery.md +11 -0
- package/domains/product/agents/layouter.md +11 -0
- package/domains/product/agents/mediator.md +11 -0
- package/domains/product/agents/pm.md +11 -0
- package/domains/product/agents/product_strategist.md +11 -0
- package/domains/product/agents/tech_lead.md +11 -0
- package/domains/product/agents/ux_designer.md +11 -0
- package/domains/product/locales/en/.agents/skills/aarrr-metrics/SKILL.md +451 -433
- package/domains/product/locales/en/.agents/skills/ab-test-design/SKILL.md +428 -412
- package/domains/product/locales/en/.agents/skills/acceptance-criteria/SKILL.md +422 -406
- package/domains/product/locales/en/.agents/skills/assumption-mapping/SKILL.md +323 -307
- package/domains/product/locales/en/.agents/skills/board/SKILL.md +24 -0
- package/domains/product/locales/en/.agents/skills/design-brief/SKILL.md +433 -418
- package/domains/product/locales/en/.agents/skills/epic-breakdown/SKILL.md +435 -420
- package/domains/product/locales/en/.agents/skills/gates/SKILL.md +470 -446
- package/domains/product/locales/en/.agents/skills/gtm-brief/SKILL.md +18 -321
- package/domains/product/locales/en/.agents/skills/gtm-brief-reference/SKILL.md +348 -0
- package/domains/product/locales/en/.agents/skills/gtm-brief-reference/agents/claude.json +17 -0
- package/domains/product/locales/en/.agents/skills/gtm-brief-reference/agents/copilot.json +17 -0
- package/domains/product/locales/en/.agents/skills/gtm-brief-reference/agents/gemini.json +17 -0
- package/domains/product/locales/en/.agents/skills/gtm-brief-reference/agents/kimi.yaml +15 -0
- package/domains/product/locales/en/.agents/skills/gtm-brief-reference/agents/openai.yaml +10 -0
- package/domains/product/locales/en/.agents/skills/gtm-brief-reference/agents/qwen.json +17 -0
- package/domains/product/locales/en/.agents/skills/gtm-brief-reference/agents/skill.yaml +22 -0
- package/domains/product/locales/en/.agents/skills/handoff/SKILL.md +463 -439
- package/domains/product/locales/en/.agents/skills/html-pdf-report/SKILL.md +21 -663
- package/domains/product/locales/en/.agents/skills/html-pdf-report-reference/SKILL.md +699 -0
- package/domains/product/locales/en/.agents/skills/html-pdf-report-reference/agents/claude.json +17 -0
- package/domains/product/locales/en/.agents/skills/html-pdf-report-reference/agents/copilot.json +17 -0
- package/domains/product/locales/en/.agents/skills/html-pdf-report-reference/agents/gemini.json +17 -0
- package/domains/product/locales/en/.agents/skills/html-pdf-report-reference/agents/kimi.yaml +15 -0
- package/domains/product/locales/en/.agents/skills/html-pdf-report-reference/agents/openai.yaml +10 -0
- package/domains/product/locales/en/.agents/skills/html-pdf-report-reference/agents/qwen.json +17 -0
- package/domains/product/locales/en/.agents/skills/html-pdf-report-reference/agents/skill.yaml +22 -0
- package/domains/product/locales/en/.agents/skills/hypothesis-template/SKILL.md +484 -469
- package/domains/product/locales/en/.agents/skills/jtbd-canvas/SKILL.md +273 -257
- package/domains/product/locales/en/.agents/skills/kano-model/SKILL.md +370 -355
- package/domains/product/locales/en/.agents/skills/karpathy-guidelines/SKILL.md +36 -0
- package/domains/product/locales/en/.agents/skills/launch-checklist/SKILL.md +434 -419
- package/domains/product/locales/en/.agents/skills/moscow-prioritization/SKILL.md +407 -392
- package/domains/product/locales/en/.agents/skills/north-star-metric/SKILL.md +317 -301
- package/domains/product/locales/en/.agents/skills/okr-framework/SKILL.md +299 -284
- package/domains/product/locales/en/.agents/skills/opportunity-solution-tree/SKILL.md +472 -456
- package/domains/product/locales/en/.agents/skills/prd-template/SKILL.md +18 -258
- package/domains/product/locales/en/.agents/skills/prd-template-reference/SKILL.md +285 -0
- package/domains/product/locales/en/.agents/skills/prd-template-reference/agents/claude.json +16 -0
- package/domains/product/locales/en/.agents/skills/prd-template-reference/agents/copilot.json +16 -0
- package/domains/product/locales/en/.agents/skills/prd-template-reference/agents/gemini.json +16 -0
- package/domains/product/locales/en/.agents/skills/prd-template-reference/agents/kimi.yaml +15 -0
- package/domains/product/locales/en/.agents/skills/prd-template-reference/agents/openai.yaml +10 -0
- package/domains/product/locales/en/.agents/skills/prd-template-reference/agents/qwen.json +16 -0
- package/domains/product/locales/en/.agents/skills/prd-template-reference/agents/skill.yaml +22 -0
- package/domains/product/locales/en/.agents/skills/problem-statement/SKILL.md +327 -312
- package/domains/product/locales/en/.agents/skills/product-roadmap/SKILL.md +321 -305
- package/domains/product/locales/en/.agents/skills/product-vision/SKILL.md +410 -395
- package/domains/product/locales/en/.agents/skills/release-notes/SKILL.md +18 -258
- package/domains/product/locales/en/.agents/skills/release-notes-reference/SKILL.md +285 -0
- package/domains/product/locales/en/.agents/skills/release-notes-reference/agents/claude.json +16 -0
- package/domains/product/locales/en/.agents/skills/release-notes-reference/agents/copilot.json +16 -0
- package/domains/product/locales/en/.agents/skills/release-notes-reference/agents/gemini.json +16 -0
- package/domains/product/locales/en/.agents/skills/release-notes-reference/agents/kimi.yaml +14 -0
- package/domains/product/locales/en/.agents/skills/release-notes-reference/agents/openai.yaml +10 -0
- package/domains/product/locales/en/.agents/skills/release-notes-reference/agents/qwen.json +16 -0
- package/domains/product/locales/en/.agents/skills/release-notes-reference/agents/skill.yaml +21 -0
- package/domains/product/locales/en/.agents/skills/report-design/SKILL.md +17 -307
- package/domains/product/locales/en/.agents/skills/report-design-reference/SKILL.md +331 -0
- package/domains/product/locales/en/.agents/skills/report-design-reference/agents/claude.json +17 -0
- package/domains/product/locales/en/.agents/skills/report-design-reference/agents/copilot.json +17 -0
- package/domains/product/locales/en/.agents/skills/report-design-reference/agents/gemini.json +17 -0
- package/domains/product/locales/en/.agents/skills/report-design-reference/agents/kimi.yaml +15 -0
- package/domains/product/locales/en/.agents/skills/report-design-reference/agents/openai.yaml +10 -0
- package/domains/product/locales/en/.agents/skills/report-design-reference/agents/qwen.json +17 -0
- package/domains/product/locales/en/.agents/skills/report-design-reference/agents/skill.yaml +22 -0
- package/domains/product/locales/en/.agents/skills/rice-scoring/SKILL.md +266 -251
- package/domains/product/locales/en/.agents/skills/saas-metrics/SKILL.md +422 -404
- package/domains/product/locales/en/.agents/skills/session-prompt-generator/SKILL.md +474 -450
- package/domains/product/locales/en/.agents/skills/user-flow/SKILL.md +491 -476
- package/domains/product/locales/en/.agents/skills/user-interview-script/SKILL.md +314 -297
- package/domains/product/locales/en/.agents/skills/user-story/SKILL.md +401 -385
- package/domains/product/locales/en/.agents/skills/wsjf-scoring/SKILL.md +333 -315
- package/domains/product/locales/en/AGENTS.md +5 -0
- package/domains/product/locales/en/agents/auditor.md +76 -0
- package/domains/product/locales/en/agents/conductor.md +11 -0
- package/domains/product/locales/en/agents/data_analyst.md +11 -0
- package/domains/product/locales/en/agents/designer.md +11 -0
- package/domains/product/locales/en/agents/discovery.md +11 -0
- package/domains/product/locales/en/agents/layouter.md +11 -0
- package/domains/product/locales/en/agents/mediator.md +11 -0
- package/domains/product/locales/en/agents/pm.md +11 -0
- package/domains/product/locales/en/agents/product_strategist.md +11 -0
- package/domains/product/locales/en/agents/tech_lead.md +11 -0
- package/domains/product/locales/en/agents/ux_designer.md +11 -0
- package/domains/product/persona/persona-base.md +94 -0
- package/domains/product/pipeline.yaml +115 -0
- package/package.json +72 -70
package/README.md
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<div align="center">
|
|
2
2
|
<h1>🤖 Code-AI Installer</h1>
|
|
3
|
-
<p><b>
|
|
4
|
-
|
|
3
|
+
<p><b>Write a gated, multi-agent pipeline once — deploy it to any AI coding assistant, and run it through a bundled MCP orchestration server.</b></p>
|
|
4
|
+
|
|
5
5
|
[](https://www.npmjs.com/package/code-ai-installer)
|
|
6
6
|
[](https://opensource.org/licenses/MIT)
|
|
7
7
|
[](https://nodejs.org)
|
|
@@ -9,149 +9,165 @@
|
|
|
9
9
|
|
|
10
10
|
<br/>
|
|
11
11
|
|
|
12
|
-
**Code-AI Installer**
|
|
12
|
+
**Code-AI Installer** ships two things in one npm package:
|
|
13
|
+
|
|
14
|
+
1. **`code-ai`** — a production-ready CLI that injects your `.agents/`, `.agents/skills/`, and `.agents/workflows/` into the exact environment layout each AI tool expects. Author your agentic pipelines once, deploy them to Copilot, Codex, Claude, Qwen, Kimi, or Google Antigravity.
|
|
15
|
+
2. **`code-ai-mcp`** — a bundled MCP (Model Context Protocol) server that turns those agents and skills into a **governed, gate-by-gate pipeline**: each stage produces an artifact, gets classified, and waits for a human sign-off before the next stage runs. Auto-registered for Claude via `.mcp.json`.
|
|
16
|
+
|
|
17
|
+
> The agents, the skills, and the MCP server are one product: the agents assume the MCP gate tools exist, and the MCP server assumes the installer registered it. `npm install -g code-ai-installer` brings the whole thing.
|
|
13
18
|
|
|
14
19
|
---
|
|
15
20
|
|
|
16
21
|
## ✨ Features
|
|
17
22
|
|
|
18
|
-
-
|
|
19
|
-
-
|
|
20
|
-
-
|
|
21
|
-
-
|
|
22
|
-
-
|
|
23
|
-
-
|
|
23
|
+
- 🚪 **Gate-based pipeline** — agents don't free-run. Work advances through ordered gates (classify → produce → human sign-off → advance), enforced by the MCP server's state machine, with a circuit breaker on repeated rollbacks.
|
|
24
|
+
- 🧰 **Bundled MCP server** — `code-ai-mcp` exposes 31 tools (gate machine, skill fetch with telemetry, artifact/decision log, audit + action tools). Auto-wired into Claude's `.mcp.json` at install time.
|
|
25
|
+
- 🔭 **Self-improving Auditor** — a meta-agent reads aggregate run metrics after ≥3 completed runs and *proposes* (never forces) tweaks to skills/agents; the human approves.
|
|
26
|
+
- 🚀 **Interactive wizard** — pick target, domain, agents, and skills from a guided CLI.
|
|
27
|
+
- 🌍 **Multi-AI support** — adapts instructions, reasoning hints, and file layout for Copilot, GPT Codex, Claude, Qwen 3.5, Moonshot Kimi, and Google Antigravity.
|
|
28
|
+
- 🛡️ **Bulletproof safety** — default `dry-run`, automatic backups, built-in rollbacks.
|
|
29
|
+
- 🧠 **Smart transformation** — normalizes markdown and translates native AI hints (e.g. maps `codex reasoning` to `claude thinking` / `gemini reasoning`).
|
|
30
|
+
- 🌐 **Localization** — first-class English (`en`) and Russian (`ru`).
|
|
24
31
|
|
|
25
32
|
---
|
|
26
33
|
|
|
27
34
|
## 🏛️ Domain Architecture
|
|
28
35
|
|
|
29
|
-
Code-AI
|
|
36
|
+
Code-AI ships dedicated, self-contained professional systems separated by **domain**, each with its own roles, skills, and gate pipeline. Pick one per project at install time.
|
|
37
|
+
|
|
38
|
+
| Domain | Gates | What it is |
|
|
39
|
+
|---|:---:|---|
|
|
40
|
+
| 💻 **`development`** | 8 | End-to-end web app delivery: PM → UX → Architecture → Dev → Review → Ops → Test → Release Gate. Roles: Product Manager, UX/UI Designer, Architect, Senior Full-Stack, Reviewer, DevOps, QA Tester. |
|
|
41
|
+
| 📝 **`content`** | 6 | Digital content production: Strategist → Researcher → Copywriter → Visual Concept → Reviewer → Release Gate. |
|
|
42
|
+
| 📊 **`analytics`** | 8 | Business analysis modeled adversarially (Analysts vs Critics with a Mediator): Interviewer → Researcher → Data Analyst → Strategist → Mediator → Designer → Layouter → Release Gate. Strategic frameworks (SWOT, PEST, Porter, BCG, Blue Ocean, Ansoff, Unit Economics, Cohort, …). |
|
|
43
|
+
| 📦 **`product`** | 10 | B2B SaaS product management: Discovery → Product Strategist → PM → UX Designer → Tech Lead → Data Analyst → Mediator → Designer → Layouter → Release Gate. |
|
|
44
|
+
|
|
45
|
+
Every domain also carries a meta **Auditor** beside the pipeline. Each skill declares structured metadata (`type`, `owners`, `gates`, `triggers`) so the MCP server can surface the right skill at the right gate. Large reference libraries are split into a lean workflow skill + a `*-reference` companion.
|
|
46
|
+
|
|
47
|
+
---
|
|
48
|
+
|
|
49
|
+
## 🚪 The MCP Gate Pipeline
|
|
30
50
|
|
|
31
|
-
|
|
32
|
-
- 📝 **Content Production Domain** (`content`): A creative pipeline dedicated to producing digital content (social media, blogs, visuals). Orchestrates roles such as Content Strategist, Copywriter, Researcher, and Visual Concept Designer.
|
|
33
|
-
- 📊 **Business Analytics Domain** (`analytics`): An adversarial analytical pipeline with two competing teams (Analysts vs Critics) and a Mediator — plus Designer and Layouter for PDF reports. Strategic frameworks (SWOT, PEST, Porter's Five Forces, BCG, Blue Ocean, Ansoff, Unit Economics, Cohort, etc.).
|
|
34
|
-
- 📦 **Product Management Domain** (`product`): A B2B SaaS product management pipeline — discovery → strategy → prioritization → PRD → UX → release → measurement. Dual adversarial axes: Customer-Champion vs Business-Champion on strategy, Build-Camp vs Cut-Camp on prioritization. Includes Discovery, Product Strategist, PM, UX Designer, Tech Lead, Data Analyst, Mediator, Designer, Layouter.
|
|
51
|
+
When you install for **Claude**, the installer registers `code-ai-mcp` in your project's `.mcp.json`. From then on, the agents drive the work *through the server*, not by free-form prompting:
|
|
35
52
|
|
|
36
|
-
|
|
53
|
+
1. **`current_gate` / `classify_gate`** — the conductor reads where the run is and classifies the gate outcome (`auto_resolve` / `fork` / `exception`).
|
|
54
|
+
2. **`get_skill`** — the active role fetches the skills it owns at this gate (the fetch is logged as telemetry for the Auditor).
|
|
55
|
+
3. **`submit_artifact` / `verify_claim`** — the role produces its deliverable; structured frontmatter and budgets are validated.
|
|
56
|
+
4. **`sign_off` → `advance_gate`** — a human (or, where wired, an auto-check) signs the gate; only then does the pipeline move on. A circuit breaker halts repeated dev rollbacks and escalates to an architecture audit.
|
|
57
|
+
5. **`record_decision` / `audit_trail`** — ADR-style decisions and exceptions are logged per run.
|
|
58
|
+
|
|
59
|
+
After enough completed runs, the **Auditor** calls `aggregate_run_metrics` and files `propose_change` suggestions (reviewed via `review_proposal`) — a build → run → measure → improve loop for the toolkit itself.
|
|
60
|
+
|
|
61
|
+
> MCP is currently a **Claude-specific** capability. Other targets receive the agent/skill markdown and run them as plain instructions.
|
|
37
62
|
|
|
38
63
|
---
|
|
39
64
|
|
|
40
65
|
## 🎯 Supported AI Targets
|
|
41
66
|
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
- `
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
67
|
+
| CLI target (and aliases) | Tool |
|
|
68
|
+
|---|---|
|
|
69
|
+
| `vscode-copilot` / `copilot` | VS Code Copilot |
|
|
70
|
+
| `gpt-codex` / `codex` | GPT Codex |
|
|
71
|
+
| `claude` | Claude (Claude Code) — **MCP server auto-wired** |
|
|
72
|
+
| `qwen-3.5` / `qwen` | Qwen 3.5 |
|
|
73
|
+
| `google-antigravity` / `antigravity` | Google Antigravity |
|
|
74
|
+
| `moonshot-kimi` / `kimi` | Moonshot Kimi (Kimi CLI + Kimi Code for VS Code) |
|
|
48
75
|
|
|
49
76
|
---
|
|
50
77
|
|
|
51
78
|
## 🔧 Installation
|
|
52
79
|
|
|
53
|
-
###
|
|
54
|
-
|
|
55
|
-
Install the CLI globally to run it in any of your projects:
|
|
80
|
+
### Global (recommended)
|
|
56
81
|
|
|
57
82
|
```bash
|
|
58
|
-
# via npm
|
|
59
83
|
npm install -g code-ai-installer
|
|
60
|
-
|
|
61
|
-
# via pnpm, yarn, or bun
|
|
62
|
-
pnpm add -g code-ai-installer
|
|
63
|
-
yarn global add code-ai-installer
|
|
64
|
-
bun add -g code-ai-installer
|
|
84
|
+
# or: pnpm add -g code-ai-installer / yarn global add code-ai-installer / bun add -g code-ai-installer
|
|
65
85
|
```
|
|
66
86
|
|
|
67
|
-
Verify
|
|
87
|
+
Verify:
|
|
68
88
|
```bash
|
|
69
89
|
code-ai --help
|
|
70
90
|
```
|
|
71
91
|
|
|
72
|
-
###
|
|
92
|
+
### From source (for development / contributing)
|
|
93
|
+
|
|
94
|
+
This is an npm-workspaces monorepo; the published package lives in `packages/installer`.
|
|
73
95
|
|
|
74
|
-
If you are cloning this repository to build or contribute:
|
|
75
96
|
```bash
|
|
76
|
-
git clone https://github.com/denish12/
|
|
77
|
-
cd
|
|
97
|
+
git clone https://github.com/denish12/code-ai-monorepo.git
|
|
98
|
+
cd code-ai-monorepo
|
|
78
99
|
npm install
|
|
79
100
|
npm run build
|
|
80
|
-
npm install -g
|
|
101
|
+
npm install -g ./packages/installer
|
|
81
102
|
```
|
|
82
103
|
|
|
83
104
|
---
|
|
84
105
|
|
|
85
106
|
## 🚀 Usage
|
|
86
107
|
|
|
87
|
-
###
|
|
88
|
-
|
|
108
|
+
### Interactive wizard
|
|
109
|
+
|
|
110
|
+
Run `code-ai` inside your project to launch the guided installer (it also offers to wire the MCP server for Claude):
|
|
111
|
+
|
|
89
112
|
```bash
|
|
90
113
|
code-ai
|
|
91
114
|
```
|
|
92
115
|
|
|
93
|
-
### CLI
|
|
116
|
+
### CLI commands & flags
|
|
94
117
|
|
|
95
118
|
```bash
|
|
96
|
-
# List
|
|
119
|
+
# List supported targets
|
|
97
120
|
code-ai targets
|
|
98
121
|
|
|
99
|
-
# List
|
|
122
|
+
# List agents and skills in a domain (--domain required since v3.0.0)
|
|
100
123
|
code-ai list --domain development
|
|
101
124
|
code-ai list --domain content --lang en
|
|
102
125
|
|
|
103
|
-
#
|
|
126
|
+
# Health-check a target + domain
|
|
104
127
|
code-ai doctor --target claude --domain development
|
|
105
128
|
|
|
106
|
-
#
|
|
129
|
+
# Dry-run preview (default — writes nothing)
|
|
107
130
|
code-ai install --target claude --domain development --agents conductor,reviewer --skills board
|
|
108
131
|
|
|
109
|
-
# Apply
|
|
132
|
+
# Apply for real
|
|
110
133
|
code-ai install --target gpt-codex --domain analytics --agents all --skills all --apply
|
|
111
134
|
|
|
112
|
-
# Overwrite existing files
|
|
135
|
+
# Overwrite existing files
|
|
113
136
|
code-ai install --target claude --domain content --agents all --skills all --overwrite --apply
|
|
114
137
|
|
|
115
|
-
#
|
|
116
|
-
code-ai install --target claude --domain product --agents all --skills all --
|
|
138
|
+
# For Claude: skip the optional MemPalace memory server (code-ai-mcp is still wired)
|
|
139
|
+
code-ai install --target claude --domain product --agents all --skills all --no-mempalace --apply
|
|
117
140
|
|
|
118
|
-
# Uninstall /
|
|
141
|
+
# Uninstall / clean up AI assets
|
|
119
142
|
code-ai uninstall --target claude --apply
|
|
120
143
|
```
|
|
121
144
|
|
|
122
145
|
---
|
|
123
146
|
|
|
124
|
-
##
|
|
125
|
-
|
|
126
|
-
**v3.0.0 is a breaking release.** The legacy root layout (`AGENTS.md` + `agents/` + `.agents/` at package root) was removed. The CLI now exclusively reads from the `domains/<id>/` layout.
|
|
147
|
+
## 🏗️ What gets generated?
|
|
127
148
|
|
|
128
|
-
|
|
129
|
-
|---|---|---|
|
|
130
|
-
| Required flag | `--domain` optional | `--domain <name>` required (or `cwd` must contain a `domains/` directory) |
|
|
131
|
-
| EN locale path | `locales/en/` | `domains/<id>/locales/en/` |
|
|
132
|
-
| `--project-dir` accepts | legacy root or `domains/` layout | `domains/` layout only |
|
|
133
|
-
| Bundled files | 11 entries incl. root `AGENTS.md` | 4 entries: `dist`, `LICENSE`, `README.md`, `domains` |
|
|
149
|
+
Depending on `--target`, `code-ai` restructures your project:
|
|
134
150
|
|
|
135
|
-
**
|
|
151
|
+
1. **Orchestration entry** — `AGENTS.md` (plus tool aliases like `CLAUDE.md`, `CODEX.md`, `GEMINI.md`, `QWEN.md`, `KIMI.md`).
|
|
152
|
+
2. **Agents** — roles copied into the target's layout (e.g. `.claude/agents/<role>.md`, `.github/copilot-instructions.md`).
|
|
153
|
+
3. **Skills & workflows** — the execution skillsets, with per-tool metadata sidecars.
|
|
154
|
+
4. **MCP wiring (Claude only)** — `.mcp.json` registering `code-ai-mcp` (run as `npx -p code-ai-installer code-ai-mcp`), plus an optional [MemPalace](https://www.npmjs.com/package/mempalace) memory server when present, and a `.code-ai/config.json` that records the active domain and decision-store backend.
|
|
136
155
|
|
|
137
156
|
---
|
|
138
157
|
|
|
139
|
-
##
|
|
158
|
+
## 🧬 Versions & migration
|
|
140
159
|
|
|
141
|
-
|
|
160
|
+
`code-ai-installer` is on **v4.0.0**.
|
|
142
161
|
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
3. **Skills & Workflows**: Deploys the necessary execution skillsets and custom workflows specific to the target AI.
|
|
146
|
-
4. **Configuration**: Generates workspace settings (e.g., `.qwen/settings.json`).
|
|
162
|
+
- **v4.0.0** — consolidated the previously separate `code-ai-mcp` and types packages into this single package with **two bins** (`code-ai` + `code-ai-mcp`). Installing the CLI now also delivers the MCP server; for Claude it is auto-registered in `.mcp.json`. Existing 3.x CLI behavior is unchanged.
|
|
163
|
+
- **v3.0.0 (breaking)** — removed the legacy flat root layout (`AGENTS.md` + `agents/` + `.agents/` at package root); the CLI now reads exclusively from `domains/<id>/`. **Migrating from v2.x:** add `--domain <development|content|analytics|product>` to every CLI call. If you used a custom `--project-dir`, restructure it to `domains/<id>/` instead of a flat layout.
|
|
147
164
|
|
|
148
165
|
---
|
|
149
166
|
|
|
150
167
|
## 🤝 Contributing
|
|
151
168
|
|
|
152
|
-
Contributions, issues, and feature requests are welcome
|
|
153
|
-
Feel free to check out the [issues page](https://github.com/denish12/codex-ai-agent-and-skills/issues).
|
|
169
|
+
Contributions, issues, and feature requests are welcome — see the [issues page](https://github.com/denish12/code-ai-monorepo/issues).
|
|
154
170
|
|
|
155
171
|
## 📄 License
|
|
156
172
|
|
|
157
|
-
|
|
173
|
+
[MIT](https://opensource.org/licenses/MIT).
|
package/dist/index.js
CHANGED
|
@@ -224,6 +224,7 @@ program
|
|
|
224
224
|
destinationDir,
|
|
225
225
|
wantMempalace: options.withMempalace,
|
|
226
226
|
dryRun: false,
|
|
227
|
+
...(domainId ? { domain: domainId } : {}),
|
|
227
228
|
});
|
|
228
229
|
for (const notice of report.notices)
|
|
229
230
|
info(` ${notice}`);
|
|
@@ -484,6 +485,7 @@ async function runInteractiveWizard() {
|
|
|
484
485
|
destinationDir,
|
|
485
486
|
wantMempalace,
|
|
486
487
|
dryRun: false,
|
|
488
|
+
...(selectedDomainId ? { domain: selectedDomainId } : {}),
|
|
487
489
|
});
|
|
488
490
|
for (const notice of report.notices)
|
|
489
491
|
info(` ${notice}`);
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { RunScorecard } from "./scorecard.js";
|
|
2
|
+
import type { TaskState } from "./task_state.js";
|
|
3
|
+
/** Append one scorecard as a JSON line to the run ledger (creates dir if needed). */
|
|
4
|
+
export declare function appendScorecard(card: RunScorecard): Promise<void>;
|
|
5
|
+
/** Read all scorecards from the ledger. Malformed / partial lines are skipped. */
|
|
6
|
+
export declare function readLedger(): Promise<RunScorecard[]>;
|
|
7
|
+
/**
|
|
8
|
+
* Build + append a scorecard for a completed run. Called from sign_off when RG
|
|
9
|
+
* is signed. Best-effort by contract: callers MUST NOT let a ledger failure
|
|
10
|
+
* break a sign-off (telemetry is never load-bearing for the gate).
|
|
11
|
+
*/
|
|
12
|
+
export declare function recordRunScorecard(state: TaskState): Promise<void>;
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
import { mkdir, readFile, appendFile } from "node:fs/promises";
|
|
2
|
+
import { dirname, join } from "node:path";
|
|
3
|
+
import { resolveAuditLedgerPath } from "./paths.js";
|
|
4
|
+
import { RunScorecard, buildScorecard } from "./scorecard.js";
|
|
5
|
+
import { readSkillInvocations } from "./skill_invocations.js";
|
|
6
|
+
/** Append one scorecard as a JSON line to the run ledger (creates dir if needed). */
|
|
7
|
+
export async function appendScorecard(card) {
|
|
8
|
+
const path = resolveAuditLedgerPath();
|
|
9
|
+
await mkdir(dirname(path), { recursive: true });
|
|
10
|
+
await appendFile(path, JSON.stringify(card) + "\n", "utf8");
|
|
11
|
+
}
|
|
12
|
+
/** Read all scorecards from the ledger. Malformed / partial lines are skipped. */
|
|
13
|
+
export async function readLedger() {
|
|
14
|
+
const raw = await readFile(resolveAuditLedgerPath(), "utf8").catch(() => "");
|
|
15
|
+
if (!raw)
|
|
16
|
+
return [];
|
|
17
|
+
const cards = [];
|
|
18
|
+
for (const line of raw.split("\n")) {
|
|
19
|
+
if (!line.trim())
|
|
20
|
+
continue;
|
|
21
|
+
try {
|
|
22
|
+
cards.push(RunScorecard.parse(JSON.parse(line)));
|
|
23
|
+
}
|
|
24
|
+
catch {
|
|
25
|
+
continue; // tolerate hand-edits / schema drift; surfacing tool, not enforcer
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
return cards;
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* Count exceptions (grouped by gate) and decisions for a task from the jsonl
|
|
32
|
+
* side logs. Plain reads — no DecisionStore/MemPalace dependency in the hot path.
|
|
33
|
+
*/
|
|
34
|
+
async function readSideCounts(taskId) {
|
|
35
|
+
const stateDir = join(process.cwd(), ".code-ai", "state");
|
|
36
|
+
const exceptions_by_gate = {};
|
|
37
|
+
const rawExc = await readFile(join(stateDir, "exceptions.jsonl"), "utf8").catch(() => "");
|
|
38
|
+
for (const line of rawExc.split("\n")) {
|
|
39
|
+
if (!line.trim())
|
|
40
|
+
continue;
|
|
41
|
+
try {
|
|
42
|
+
const o = JSON.parse(line);
|
|
43
|
+
if (o.task_id !== taskId)
|
|
44
|
+
continue;
|
|
45
|
+
const g = typeof o.gate === "string" ? o.gate : "unknown";
|
|
46
|
+
exceptions_by_gate[g] = (exceptions_by_gate[g] ?? 0) + 1;
|
|
47
|
+
}
|
|
48
|
+
catch {
|
|
49
|
+
continue;
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
let decisions_count = 0;
|
|
53
|
+
const rawDec = await readFile(join(stateDir, "decisions.jsonl"), "utf8").catch(() => "");
|
|
54
|
+
for (const line of rawDec.split("\n")) {
|
|
55
|
+
if (!line.trim())
|
|
56
|
+
continue;
|
|
57
|
+
try {
|
|
58
|
+
const o = JSON.parse(line);
|
|
59
|
+
if (o.task_id === taskId && !String(o.adr_id ?? "").startsWith("ADR-PENDING-")) {
|
|
60
|
+
decisions_count++;
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
catch {
|
|
64
|
+
continue;
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
const skillEvents = await readSkillInvocations(taskId);
|
|
68
|
+
return {
|
|
69
|
+
exceptions_by_gate,
|
|
70
|
+
decisions_count,
|
|
71
|
+
skill_invocations: skillEvents.map((e) => ({ skill: e.skill, gate: e.gate })),
|
|
72
|
+
};
|
|
73
|
+
}
|
|
74
|
+
/**
|
|
75
|
+
* Build + append a scorecard for a completed run. Called from sign_off when RG
|
|
76
|
+
* is signed. Best-effort by contract: callers MUST NOT let a ledger failure
|
|
77
|
+
* break a sign-off (telemetry is never load-bearing for the gate).
|
|
78
|
+
*/
|
|
79
|
+
export async function recordRunScorecard(state) {
|
|
80
|
+
const extras = await readSideCounts(state.task_id);
|
|
81
|
+
await appendScorecard(buildScorecard(state, extras));
|
|
82
|
+
}
|
package/dist/mcp/cli.js
CHANGED
|
@@ -26,7 +26,7 @@ const SERVER_INFO = {
|
|
|
26
26
|
const TOOL_DESCRIPTIONS = {
|
|
27
27
|
load_role: "Load an agent role: frontmatter, body, merged persona, and the role's skill list. Use at SessionStart for an agent.",
|
|
28
28
|
list_skills: "List skills in a domain. Optional filters: type, gate, tech, topic, owner.",
|
|
29
|
-
get_skill: "Fetch a skill's frontmatter + body by name.",
|
|
29
|
+
get_skill: "Fetch a skill's frontmatter + body by name. Pass task_id (+ optional gate) to log the fetch as a skill invocation for Auditor telemetry; omit for plain lookups.",
|
|
30
30
|
request_decision: "Open a pending decision envelope. Returns a synthetic ADR-PENDING id; Claude relays the question to DEN in chat, then commits the answer via record_decision.",
|
|
31
31
|
record_decision: "Commit a chosen decision: writes ADR file, decision log entry, and KG triple. Resets the circuit breaker on new ARCH ADR.",
|
|
32
32
|
classify_gate: "Record the current gate's classification (auto_resolve / fork / exception) with a rationale.",
|
|
@@ -42,6 +42,12 @@ const TOOL_DESCRIPTIONS = {
|
|
|
42
42
|
recent_decisions: "Read recent ADR decisions from the decision log with optional domain/signer/since filters.",
|
|
43
43
|
regenerate_manifest: "Regenerate AGENTS.yaml skills list from disk SKILL.md frontmatter. Detects AGENTS.md drift (skills on disk but not referenced).",
|
|
44
44
|
run_drift_audit: "[stub] Detect drift between SKILL.md frontmatter and AGENTS.md references.",
|
|
45
|
+
audit_budget_compliance: "Audit budget_lines compliance for agent.md and SKILL.md across a domain. Surfaces schema-cap violations (declared > schema max) and budget violations (actual lines > declared budget). Pass domain='*' to scan all domains. Read-only; scans both RU and EN locales.",
|
|
46
|
+
audit_bilocale_parity: "Audit RU/EN locale parity for agent.md and SKILL.md across a domain. Pairs each file with its sibling in the other locale and surfaces declared-budget mismatches (ru budget_lines != en), actual line-count mismatches (ru lines != en — the design-intake drift class), and orphans (file present in one locale only). Pass domain='*' to scan all domains. Read-only.",
|
|
47
|
+
aggregate_run_metrics: "Aggregate completed-run scorecards from the local audit ledger (.code-ai/state/audit/runs.jsonl) into deterministic per-agent (gate→role), per-workflow (mode), and per-skill (invocation frequency) statistics. min_runs (default 3) guards small samples. Read-only; the Auditor's data foundation — numbers only, no judgment.",
|
|
48
|
+
propose_change: "Record an Auditor proposal (a draft change to an agent/skill) as a pending entry in the local proposal store (.code-ai/state/audit/proposals.jsonl). Carries change_kind (edit_minor/add_asset/destructive → risk tier), rationale, evidence, threshold_met, and the inline draft. Pure surfacing — writes nothing to the asset; inert until approved/applied (item 4b).",
|
|
49
|
+
list_proposals: "List stored Auditor proposals, newest first, with optional filters (status / risk / domain). Read-only.",
|
|
50
|
+
review_proposal: "Authorize a proposal status transition (approve/reject a pending one; mark an approved one applied) and get a mandatory report. Enforces the autonomy matrix + .code-ai/config.json approval gate: decided_by='auditor_auto' may approve only low/additive AND only when the gate is OFF; destructive (high) and gate-ON always require den. Auto-adding a new skill also runs an additive-dedup guard — if it overlaps an existing skill it is routed to den, not auto-added. Authorization only — the byte write into the asset is a separate submit_artifact/edit step (see next_step).",
|
|
45
51
|
run_tests: "[stub] Run the test suite for a target (vitest / pytest).",
|
|
46
52
|
apply_diff: "[stub] Apply a unified diff to a file with safety checks.",
|
|
47
53
|
git_commit: "[stub] Stage and commit changes through a typed contract instead of raw shell.",
|
package/dist/mcp/config.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
|
+
import { DomainId } from "../shared/index.js";
|
|
2
3
|
/**
|
|
3
4
|
* Runtime configuration read from `.code-ai/config.json` (cwd-relative).
|
|
4
5
|
*
|
|
@@ -15,8 +16,17 @@ declare const CodeAiConfigSchema: z.ZodObject<{
|
|
|
15
16
|
mempalace: "mempalace";
|
|
16
17
|
jsonl: "jsonl";
|
|
17
18
|
}>>;
|
|
19
|
+
domain: z.ZodDefault<z.ZodEnum<{
|
|
20
|
+
development: "development";
|
|
21
|
+
content: "content";
|
|
22
|
+
analytics: "analytics";
|
|
23
|
+
product: "product";
|
|
24
|
+
}>>;
|
|
18
25
|
mempalace_command: z.ZodDefault<z.ZodString>;
|
|
19
26
|
mempalace_args: z.ZodDefault<z.ZodArray<z.ZodString>>;
|
|
27
|
+
auditor: z.ZodDefault<z.ZodObject<{
|
|
28
|
+
approval_gate: z.ZodDefault<z.ZodBoolean>;
|
|
29
|
+
}, z.core.$strip>>;
|
|
20
30
|
}, z.core.$strip>;
|
|
21
31
|
export type CodeAiConfig = z.infer<typeof CodeAiConfigSchema>;
|
|
22
32
|
/**
|
|
@@ -25,4 +35,17 @@ export type CodeAiConfig = z.infer<typeof CodeAiConfigSchema>;
|
|
|
25
35
|
* Failure is silent — the caller proceeds with `JsonlStore`.
|
|
26
36
|
*/
|
|
27
37
|
export declare function loadCodeAiConfig(): Promise<CodeAiConfig>;
|
|
38
|
+
/**
|
|
39
|
+
* The active domain for this project — which `pipeline.yaml` the gate tools
|
|
40
|
+
* (classify_gate, advance_gate, current_gate, sign_off, record_decision,
|
|
41
|
+
* aggregate_run_metrics) read. Sourced from `.code-ai/config.json`; defaults to
|
|
42
|
+
* "development" when unset.
|
|
43
|
+
*
|
|
44
|
+
* This is an ADDRESS, not a safety control: gate enforcement (no skipping,
|
|
45
|
+
* sign-off-before-advance, classify-required, circuit breaker) lives in the
|
|
46
|
+
* tool logic + the domain's `pipeline.yaml`, not in this string. De-hardcoding
|
|
47
|
+
* the address only makes each project read its OWN pipeline instead of always
|
|
48
|
+
* development's.
|
|
49
|
+
*/
|
|
50
|
+
export declare function resolveActiveDomain(): Promise<DomainId>;
|
|
28
51
|
export {};
|
package/dist/mcp/config.js
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { readFile } from "node:fs/promises";
|
|
2
2
|
import { join } from "node:path";
|
|
3
3
|
import { z } from "zod";
|
|
4
|
+
import { DomainId } from "../shared/index.js";
|
|
4
5
|
/**
|
|
5
6
|
* Runtime configuration read from `.code-ai/config.json` (cwd-relative).
|
|
6
7
|
*
|
|
@@ -14,16 +15,36 @@ import { z } from "zod";
|
|
|
14
15
|
*/
|
|
15
16
|
const CodeAiConfigSchema = z.object({
|
|
16
17
|
decision_store: z.enum(["jsonl", "mempalace"]).default("jsonl"),
|
|
18
|
+
/**
|
|
19
|
+
* The active domain — which `domains/<domain>/pipeline.yaml` the gate tools
|
|
20
|
+
* read. Written by the installer at install time. Defaults to "development"
|
|
21
|
+
* for backward compatibility: a project with no `domain` field (or no config
|
|
22
|
+
* file at all) behaves exactly as before this field existed.
|
|
23
|
+
*/
|
|
24
|
+
domain: DomainId.default("development"),
|
|
17
25
|
/** Override the binary name for the MemPalace MCP server. */
|
|
18
26
|
mempalace_command: z.string().min(1).default("mempalace"),
|
|
19
27
|
/** Optional extra args appended after the `mcp` subcommand. */
|
|
20
28
|
mempalace_args: z.array(z.string()).default(["mcp"]),
|
|
29
|
+
/** Auditor self-improvement controls (ADR-DEV-124). */
|
|
30
|
+
auditor: z
|
|
31
|
+
.object({
|
|
32
|
+
/**
|
|
33
|
+
* Approval gate. true (default) = Auditor proposes, a human approves every change.
|
|
34
|
+
* false = autonomy on: the Auditor may self-approve low/additive changes; destructive
|
|
35
|
+
* always still needs a human (ADR-DEV-122 matrix). Enforced in review_proposal.
|
|
36
|
+
*/
|
|
37
|
+
approval_gate: z.boolean().default(true),
|
|
38
|
+
})
|
|
39
|
+
.default({ approval_gate: true }),
|
|
21
40
|
});
|
|
22
41
|
/** Empty config defaults — returned when the file is missing or unreadable. */
|
|
23
42
|
const DEFAULT_CONFIG = {
|
|
24
43
|
decision_store: "jsonl",
|
|
25
44
|
mempalace_command: "mempalace",
|
|
26
45
|
mempalace_args: ["mcp"],
|
|
46
|
+
auditor: { approval_gate: true },
|
|
47
|
+
domain: "development",
|
|
27
48
|
};
|
|
28
49
|
/**
|
|
29
50
|
* Load `.code-ai/config.json` relative to `process.cwd()`. Returns safe
|
|
@@ -46,3 +67,18 @@ export async function loadCodeAiConfig() {
|
|
|
46
67
|
return DEFAULT_CONFIG;
|
|
47
68
|
}
|
|
48
69
|
}
|
|
70
|
+
/**
|
|
71
|
+
* The active domain for this project — which `pipeline.yaml` the gate tools
|
|
72
|
+
* (classify_gate, advance_gate, current_gate, sign_off, record_decision,
|
|
73
|
+
* aggregate_run_metrics) read. Sourced from `.code-ai/config.json`; defaults to
|
|
74
|
+
* "development" when unset.
|
|
75
|
+
*
|
|
76
|
+
* This is an ADDRESS, not a safety control: gate enforcement (no skipping,
|
|
77
|
+
* sign-off-before-advance, classify-required, circuit breaker) lives in the
|
|
78
|
+
* tool logic + the domain's `pipeline.yaml`, not in this string. De-hardcoding
|
|
79
|
+
* the address only makes each project read its OWN pipeline instead of always
|
|
80
|
+
* development's.
|
|
81
|
+
*/
|
|
82
|
+
export async function resolveActiveDomain() {
|
|
83
|
+
return (await loadCodeAiConfig()).domain;
|
|
84
|
+
}
|
package/dist/mcp/index.d.ts
CHANGED
|
@@ -6,8 +6,7 @@
|
|
|
6
6
|
* stubs until pre-req #3 (baseline prototype) wires the first four:
|
|
7
7
|
* load_role, list_skills, request_decision, record_decision.
|
|
8
8
|
*
|
|
9
|
-
* See README.md for the full tool surface
|
|
10
|
-
* for the architectural plan this package implements.
|
|
9
|
+
* See README.md for the full tool surface and architectural overview.
|
|
11
10
|
*/
|
|
12
11
|
export declare const VERSION = "0.0.0";
|
|
13
12
|
export { CodeAiMcpServer } from "./server.js";
|
package/dist/mcp/index.js
CHANGED
|
@@ -6,8 +6,7 @@
|
|
|
6
6
|
* stubs until pre-req #3 (baseline prototype) wires the first four:
|
|
7
7
|
* load_role, list_skills, request_decision, record_decision.
|
|
8
8
|
*
|
|
9
|
-
* See README.md for the full tool surface
|
|
10
|
-
* for the architectural plan this package implements.
|
|
9
|
+
* See README.md for the full tool surface and architectural overview.
|
|
11
10
|
*/
|
|
12
11
|
export const VERSION = "0.0.0";
|
|
13
12
|
export { CodeAiMcpServer } from "./server.js";
|
package/dist/mcp/paths.d.ts
CHANGED
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
import { type DomainId } from "../shared/index.js";
|
|
2
2
|
export declare const INSTALLER_ROOT: string;
|
|
3
|
-
export declare const DOCS_ROOT: string;
|
|
4
|
-
export declare const PERSONA_ROOT: string;
|
|
5
3
|
/**
|
|
6
4
|
* ADR write root. Resolved at call time relative to process.cwd() so the MCP
|
|
7
5
|
* doesn't pollute the monorepo when invoked from a user project. Tests rely
|
|
@@ -9,6 +7,12 @@ export declare const PERSONA_ROOT: string;
|
|
|
9
7
|
*/
|
|
10
8
|
export declare function resolveAdrRoot(): string;
|
|
11
9
|
export declare function resolveDomainRoot(domain: DomainId): string;
|
|
10
|
+
/**
|
|
11
|
+
* Universal base-persona markdown for a domain. Shipped inside the package at
|
|
12
|
+
* `domains/<domain>/persona/persona-base.md` (was `docs/architecture-redesign/`
|
|
13
|
+
* pre-migration, which never shipped to npm). Same content across domains.
|
|
14
|
+
*/
|
|
15
|
+
export declare function resolvePersonaBase(domain: DomainId): string;
|
|
12
16
|
export declare function resolveSkillsRoot(domain: DomainId): string;
|
|
13
17
|
export declare function resolveAgentsDir(domain: DomainId): string;
|
|
14
18
|
export declare function resolveAgentMd(domain: DomainId, role: string): string;
|
|
@@ -18,3 +22,17 @@ export declare function resolvePipelineYaml(domain: DomainId): string;
|
|
|
18
22
|
* convention as resolveAdrRoot() so the MCP doesn't pollute the host repo.
|
|
19
23
|
*/
|
|
20
24
|
export declare function resolveTaskStateRoot(): string;
|
|
25
|
+
/**
|
|
26
|
+
* Audit run-ledger path. Same cwd-relative convention as resolveTaskStateRoot()
|
|
27
|
+
* so the Auditor reads the user-install's local history; tests chdir into a tmp
|
|
28
|
+
* dir. Append-only JSONL, one run scorecard per line.
|
|
29
|
+
*/
|
|
30
|
+
export declare function resolveAuditLedgerPath(): string;
|
|
31
|
+
/** Skill-invocation telemetry log. Same cwd-relative convention as the run ledger. */
|
|
32
|
+
export declare function resolveSkillInvocationsPath(): string;
|
|
33
|
+
/**
|
|
34
|
+
* Auditor proposal store. Same cwd-relative convention as the run ledger;
|
|
35
|
+
* append-only JSONL, one proposal per line. Written by propose_change, read by
|
|
36
|
+
* list_proposals (and later the approval/apply machinery, item 4b).
|
|
37
|
+
*/
|
|
38
|
+
export declare function resolveProposalsPath(): string;
|
package/dist/mcp/paths.js
CHANGED
|
@@ -5,7 +5,7 @@ import { dirname, join, resolve } from "node:path";
|
|
|
5
5
|
*
|
|
6
6
|
* Convention: the MCP runs from inside the `code-ai-installer` package, so we
|
|
7
7
|
* walk up from this file's location to the installer root (where `domains/`
|
|
8
|
-
* lives
|
|
8
|
+
* lives — everything the runtime reads ships under it).
|
|
9
9
|
*
|
|
10
10
|
* Layout reference:
|
|
11
11
|
* src layout (vitest, tsx):
|
|
@@ -17,10 +17,6 @@ import { dirname, join, resolve } from "node:path";
|
|
|
17
17
|
const HERE = dirname(fileURLToPath(import.meta.url));
|
|
18
18
|
// .../packages/installer/{src|dist}/mcp/paths.{ts|js} → .../packages/installer
|
|
19
19
|
export const INSTALLER_ROOT = resolve(HERE, "..", "..");
|
|
20
|
-
// → .../packages → monorepo
|
|
21
|
-
const MONOREPO_ROOT = resolve(INSTALLER_ROOT, "..", "..");
|
|
22
|
-
export const DOCS_ROOT = join(MONOREPO_ROOT, "docs");
|
|
23
|
-
export const PERSONA_ROOT = join(DOCS_ROOT, "architecture-redesign");
|
|
24
20
|
/**
|
|
25
21
|
* ADR write root. Resolved at call time relative to process.cwd() so the MCP
|
|
26
22
|
* doesn't pollute the monorepo when invoked from a user project. Tests rely
|
|
@@ -32,6 +28,14 @@ export function resolveAdrRoot() {
|
|
|
32
28
|
export function resolveDomainRoot(domain) {
|
|
33
29
|
return join(INSTALLER_ROOT, "domains", domain);
|
|
34
30
|
}
|
|
31
|
+
/**
|
|
32
|
+
* Universal base-persona markdown for a domain. Shipped inside the package at
|
|
33
|
+
* `domains/<domain>/persona/persona-base.md` (was `docs/architecture-redesign/`
|
|
34
|
+
* pre-migration, which never shipped to npm). Same content across domains.
|
|
35
|
+
*/
|
|
36
|
+
export function resolvePersonaBase(domain) {
|
|
37
|
+
return join(resolveDomainRoot(domain), "persona", "persona-base.md");
|
|
38
|
+
}
|
|
35
39
|
export function resolveSkillsRoot(domain) {
|
|
36
40
|
return join(resolveDomainRoot(domain), ".agents", "skills");
|
|
37
41
|
}
|
|
@@ -51,3 +55,23 @@ export function resolvePipelineYaml(domain) {
|
|
|
51
55
|
export function resolveTaskStateRoot() {
|
|
52
56
|
return join(process.cwd(), ".code-ai", "state", "tasks");
|
|
53
57
|
}
|
|
58
|
+
/**
|
|
59
|
+
* Audit run-ledger path. Same cwd-relative convention as resolveTaskStateRoot()
|
|
60
|
+
* so the Auditor reads the user-install's local history; tests chdir into a tmp
|
|
61
|
+
* dir. Append-only JSONL, one run scorecard per line.
|
|
62
|
+
*/
|
|
63
|
+
export function resolveAuditLedgerPath() {
|
|
64
|
+
return join(process.cwd(), ".code-ai", "state", "audit", "runs.jsonl");
|
|
65
|
+
}
|
|
66
|
+
/** Skill-invocation telemetry log. Same cwd-relative convention as the run ledger. */
|
|
67
|
+
export function resolveSkillInvocationsPath() {
|
|
68
|
+
return join(process.cwd(), ".code-ai", "state", "skill_invocations.jsonl");
|
|
69
|
+
}
|
|
70
|
+
/**
|
|
71
|
+
* Auditor proposal store. Same cwd-relative convention as the run ledger;
|
|
72
|
+
* append-only JSONL, one proposal per line. Written by propose_change, read by
|
|
73
|
+
* list_proposals (and later the approval/apply machinery, item 4b).
|
|
74
|
+
*/
|
|
75
|
+
export function resolveProposalsPath() {
|
|
76
|
+
return join(process.cwd(), ".code-ai", "state", "audit", "proposals.jsonl");
|
|
77
|
+
}
|