bmad-module-skill-forge 0.6.0 → 0.7.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/docs/agents.md +9 -5
- package/docs/concepts.md +17 -13
- package/docs/examples.md +19 -4
- package/docs/getting-started.md +34 -19
- package/docs/how-it-works.md +87 -84
- package/docs/index.md +1 -1
- package/docs/workflows.md +88 -40
- package/package.json +1 -1
- package/src/agents/forger.agent.yaml +17 -5
- package/src/forger/README.md +1 -1
- package/src/forger/forge-tier.yaml +2 -1
- package/src/forger/preferences.yaml +5 -7
- package/src/knowledge/agentskills-spec.md +1 -1
- package/src/knowledge/architecture-verification.md +102 -0
- package/src/knowledge/ccc-bridge.md +3 -2
- package/src/knowledge/confidence-tiers.md +12 -1
- package/src/knowledge/doc-fetcher.md +1 -1
- package/src/knowledge/manual-section-integrity.md +2 -2
- package/src/knowledge/overview.md +11 -7
- package/src/knowledge/progressive-capability.md +5 -2
- package/src/knowledge/qmd-registry.md +5 -2
- package/src/knowledge/skf-knowledge-index.csv +2 -0
- package/src/knowledge/skill-lifecycle.md +26 -2
- package/src/knowledge/split-body-strategy.md +16 -2
- package/src/knowledge/tool-resolution.md +55 -0
- package/src/knowledge/zero-hallucination.md +11 -8
- package/src/module-help.csv +9 -6
- package/src/module.yaml +3 -0
- package/src/workflows/README.md +35 -17
- package/src/workflows/analyze-source/data/skill-brief-schema.md +18 -5
- package/src/workflows/analyze-source/steps-c/step-01-init.md +2 -2
- package/src/workflows/analyze-source/steps-c/step-01b-continue.md +1 -1
- package/src/workflows/analyze-source/steps-c/step-02-scan-project.md +1 -1
- package/src/workflows/analyze-source/steps-c/step-03-identify-units.md +1 -1
- package/src/workflows/analyze-source/steps-c/step-04-map-and-detect.md +3 -3
- package/src/workflows/analyze-source/steps-c/step-05-recommend.md +1 -1
- package/src/workflows/analyze-source/steps-c/step-06-generate-briefs.md +2 -2
- package/src/workflows/analyze-source/workflow.md +2 -2
- package/src/workflows/audit-skill/data/severity-rules.md +1 -1
- package/src/workflows/audit-skill/steps-c/step-01-init.md +2 -1
- package/src/workflows/audit-skill/steps-c/step-02-re-index.md +8 -1
- package/src/workflows/audit-skill/steps-c/step-03-structural-diff.md +2 -2
- package/src/workflows/audit-skill/steps-c/step-04-semantic-diff.md +2 -2
- package/src/workflows/audit-skill/steps-c/step-05-severity-classify.md +1 -1
- package/src/workflows/audit-skill/workflow.md +2 -1
- package/src/workflows/brief-skill/data/scope-templates.md +10 -0
- package/src/workflows/brief-skill/data/skill-brief-schema.md +25 -23
- package/src/workflows/brief-skill/steps-c/step-01-gather-intent.md +1 -1
- package/src/workflows/brief-skill/steps-c/step-02-analyze-target.md +1 -1
- package/src/workflows/brief-skill/steps-c/step-05-write-brief.md +3 -0
- package/src/workflows/create-skill/data/extraction-patterns.md +7 -1
- package/src/workflows/create-skill/data/skill-sections.md +12 -11
- package/src/workflows/create-skill/data/source-resolution-protocols.md +2 -2
- package/src/workflows/create-skill/data/tier-degradation-rules.md +1 -1
- package/src/workflows/create-skill/steps-c/step-01-load-brief.md +14 -10
- package/src/workflows/create-skill/steps-c/step-02b-ccc-discover.md +4 -0
- package/src/workflows/create-skill/steps-c/step-03-extract.md +19 -19
- package/src/workflows/create-skill/steps-c/step-03b-fetch-temporal.md +3 -3
- package/src/workflows/create-skill/steps-c/step-03c-fetch-docs.md +3 -1
- package/src/workflows/create-skill/steps-c/step-04-enrich.md +3 -1
- package/src/workflows/create-skill/steps-c/step-05-compile.md +4 -3
- package/src/workflows/create-skill/steps-c/step-06-validate.md +2 -2
- package/src/workflows/create-skill/steps-c/step-07-generate-artifacts.md +33 -44
- package/src/workflows/create-skill/steps-c/step-08-report.md +25 -11
- package/src/workflows/create-skill/workflow.md +2 -2
- package/src/workflows/create-stack-skill/data/compose-mode-rules.md +65 -0
- package/src/workflows/create-stack-skill/data/manifest-patterns.md +23 -1
- package/src/workflows/create-stack-skill/data/stack-skill-template.md +28 -6
- package/src/workflows/create-stack-skill/steps-c/step-01-init.md +25 -7
- package/src/workflows/create-stack-skill/steps-c/step-02-detect-manifests.md +37 -3
- package/src/workflows/create-stack-skill/steps-c/step-03-rank-and-confirm.md +29 -3
- package/src/workflows/create-stack-skill/steps-c/step-04-parallel-extract.md +50 -7
- package/src/workflows/create-stack-skill/steps-c/step-05-detect-integrations.md +35 -3
- package/src/workflows/create-stack-skill/steps-c/step-06-compile-stack.md +5 -1
- package/src/workflows/create-stack-skill/steps-c/step-07-generate-output.md +53 -5
- package/src/workflows/create-stack-skill/steps-c/step-08-validate.md +3 -3
- package/src/workflows/create-stack-skill/steps-c/step-09-report.md +8 -2
- package/src/workflows/create-stack-skill/workflow.md +2 -2
- package/src/workflows/export-skill/data/managed-section-format.md +8 -1
- package/src/workflows/export-skill/data/snippet-format.md +1 -1
- package/src/workflows/export-skill/steps-c/step-04-update-context.md +7 -2
- package/src/workflows/export-skill/steps-c/step-05-token-report.md +1 -1
- package/src/workflows/export-skill/workflow.md +3 -1
- package/src/workflows/quick-skill/data/skill-template.md +18 -6
- package/src/workflows/quick-skill/steps-c/step-04-compile.md +26 -6
- package/src/workflows/quick-skill/steps-c/step-05-validate.md +1 -1
- package/src/workflows/quick-skill/steps-c/step-06-write.md +3 -0
- package/src/workflows/quick-skill/workflow.md +1 -1
- package/src/workflows/refine-architecture/data/refinement-rules.md +102 -0
- package/src/workflows/refine-architecture/steps-c/step-01-init.md +188 -0
- package/src/workflows/refine-architecture/steps-c/step-02-gap-analysis.md +179 -0
- package/src/workflows/refine-architecture/steps-c/step-03-issue-detection.md +182 -0
- package/src/workflows/refine-architecture/steps-c/step-04-improvements.md +169 -0
- package/src/workflows/refine-architecture/steps-c/step-05-compile.md +200 -0
- package/src/workflows/refine-architecture/steps-c/step-06-report.md +147 -0
- package/src/workflows/refine-architecture/workflow.md +61 -0
- package/src/workflows/setup-forge/steps-c/step-01-detect-and-tier.md +2 -1
- package/src/workflows/setup-forge/steps-c/step-01b-ccc-index.md +5 -3
- package/src/workflows/setup-forge/steps-c/step-02-write-config.md +15 -16
- package/src/workflows/setup-forge/steps-c/step-03-auto-index.md +1 -1
- package/src/workflows/setup-forge/steps-c/step-04-report.md +2 -2
- package/src/workflows/setup-forge/workflow.md +3 -2
- package/src/workflows/test-skill/data/scoring-rules.md +3 -0
- package/src/workflows/test-skill/data/source-access-protocol.md +1 -1
- package/src/workflows/test-skill/steps-c/step-01-init.md +1 -0
- package/src/workflows/test-skill/steps-c/step-02-detect-mode.md +2 -0
- package/src/workflows/test-skill/workflow.md +2 -2
- package/src/workflows/update-skill/steps-c/step-02-detect-changes.md +3 -3
- package/src/workflows/update-skill/steps-c/step-03-re-extract.md +8 -3
- package/src/workflows/update-skill/steps-c/step-05-validate.md +8 -12
- package/src/workflows/update-skill/steps-c/step-06-write.md +5 -2
- package/src/workflows/update-skill/workflow.md +1 -1
- package/src/workflows/verify-stack/data/coverage-patterns.md +45 -0
- package/src/workflows/verify-stack/data/feasibility-report-template.md +63 -0
- package/src/workflows/verify-stack/data/integration-verification-rules.md +73 -0
- package/src/workflows/verify-stack/steps-c/step-01-init.md +174 -0
- package/src/workflows/verify-stack/steps-c/step-02-coverage.md +181 -0
- package/src/workflows/verify-stack/steps-c/step-03-integrations.md +195 -0
- package/src/workflows/verify-stack/steps-c/step-04-requirements.md +168 -0
- package/src/workflows/verify-stack/steps-c/step-05-synthesize.md +191 -0
- package/src/workflows/verify-stack/steps-c/step-06-report.md +197 -0
- package/src/workflows/verify-stack/workflow.md +61 -0
- package/src/workflows/analyze-source/validation-report.md +0 -657
- package/src/workflows/analyze-source/workflow-plan-analyze-source.md +0 -385
- package/src/workflows/audit-skill/validation-report.md +0 -545
- package/src/workflows/audit-skill/workflow-plan-audit-skill.md +0 -318
- package/src/workflows/brief-skill/validation-report.md +0 -630
- package/src/workflows/brief-skill/workflow-plan-brief-skill.md +0 -360
- package/src/workflows/create-skill/validation-report.md +0 -189
- package/src/workflows/create-skill/workflow-plan-create-skill.md +0 -525
- package/src/workflows/create-stack-skill/validation-report.md +0 -401
- package/src/workflows/create-stack-skill/workflow-plan-create-stack-skill.md +0 -481
- package/src/workflows/export-skill/validation-report.md +0 -263
- package/src/workflows/export-skill/workflow-plan-export-skill.md +0 -369
- package/src/workflows/quick-skill/validation-report.md +0 -543
- package/src/workflows/quick-skill/workflow-plan-quick-skill.md +0 -405
- package/src/workflows/setup-forge/validation-report.md +0 -504
- package/src/workflows/setup-forge/workflow-plan-setup-forge.md +0 -430
- package/src/workflows/test-skill/validation-report.md +0 -390
- package/src/workflows/test-skill/workflow-plan-test-skill.md +0 -292
- package/src/workflows/update-skill/data/tier-degradation-rules.md +0 -46
- package/src/workflows/update-skill/validation-report.md +0 -559
- package/src/workflows/update-skill/workflow-plan-update-skill.md +0 -441
|
@@ -0,0 +1,174 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: 'step-01-init'
|
|
3
|
+
description: 'Load generated skills from skills folder, accept architecture doc path and optional PRD path, validate all inputs exist'
|
|
4
|
+
|
|
5
|
+
nextStepFile: './step-02-coverage.md'
|
|
6
|
+
reportTemplate: '../data/feasibility-report-template.md'
|
|
7
|
+
outputFile: '{forge_data_folder}/feasibility-report-{project_name}.md'
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
# Step 1: Initialize Verification
|
|
11
|
+
|
|
12
|
+
## STEP GOAL:
|
|
13
|
+
|
|
14
|
+
Load all generated skills from the skills output folder, accept the architecture document path (required) and optional PRD/vision document path from the user, validate that all inputs exist and are readable, create the feasibility report document, and present an initialization summary before auto-proceeding.
|
|
15
|
+
|
|
16
|
+
## MANDATORY EXECUTION RULES (READ FIRST):
|
|
17
|
+
|
|
18
|
+
### Universal Rules:
|
|
19
|
+
|
|
20
|
+
- 📖 CRITICAL: Read the complete step file before taking any action
|
|
21
|
+
- ⚙️ TOOL/SUBPROCESS FALLBACK: If any instruction references a subprocess, subagent, or tool you do not have access to, you MUST still achieve the outcome in your main context thread
|
|
22
|
+
- ✅ YOU MUST ALWAYS SPEAK OUTPUT in your Agent communication style with the config `{communication_language}`
|
|
23
|
+
|
|
24
|
+
### Role Reinforcement:
|
|
25
|
+
|
|
26
|
+
- ✅ You are a stack verification analyst operating in Ferris Audit mode
|
|
27
|
+
- ✅ Execute with prescriptive precision — every loaded skill must be validated against actual files
|
|
28
|
+
- ✅ You enforce the zero-hallucination principle: only report skills that physically exist on disk
|
|
29
|
+
|
|
30
|
+
### Step-Specific Rules:
|
|
31
|
+
|
|
32
|
+
- 🎯 Focus ONLY on loading inputs, scanning skills, and creating the report skeleton
|
|
33
|
+
- 🚫 FORBIDDEN to perform any coverage analysis or integration checking
|
|
34
|
+
- 🚫 Auto-proceed init step — no user confirmation needed. Halts only on validation errors
|
|
35
|
+
- 💬 Present a clear initialization summary so downstream steps have validated inputs
|
|
36
|
+
|
|
37
|
+
## EXECUTION PROTOCOLS:
|
|
38
|
+
|
|
39
|
+
- 🎯 Collect and validate all input documents and skill artifacts
|
|
40
|
+
- 💾 Create feasibility report from {reportTemplate} with populated frontmatter
|
|
41
|
+
- 📖 Auto-proceed to next step after successful initialization
|
|
42
|
+
- 🚫 HALT with actionable error if minimum requirements not met
|
|
43
|
+
|
|
44
|
+
## CONTEXT BOUNDARIES:
|
|
45
|
+
|
|
46
|
+
- This is the first step — no prior workflow state exists
|
|
47
|
+
- Requires skills to have been generated by create-skill or quick-skill workflows
|
|
48
|
+
- User provides architecture document path (required) and optional PRD/vision document path
|
|
49
|
+
- No dependency on setup-forge or forge-tier — this workflow operates on skill content only
|
|
50
|
+
|
|
51
|
+
## MANDATORY SEQUENCE
|
|
52
|
+
|
|
53
|
+
**CRITICAL:** Follow this sequence exactly. Do not skip, reorder, or improvise.
|
|
54
|
+
|
|
55
|
+
### 1. Accept Input Documents
|
|
56
|
+
|
|
57
|
+
"**Verify Stack — Feasibility Analysis**
|
|
58
|
+
|
|
59
|
+
Please provide the following:
|
|
60
|
+
1. **Architecture document path** (REQUIRED) — your project's architecture doc
|
|
61
|
+
2. **PRD or vision document path** (OPTIONAL) — for requirements coverage analysis
|
|
62
|
+
3. **Previous feasibility report path** (OPTIONAL) — for delta comparison with a prior run (provide a backup copy)"
|
|
63
|
+
|
|
64
|
+
Wait for user input.
|
|
65
|
+
|
|
66
|
+
**Validate architecture document:**
|
|
67
|
+
- Confirm the file exists and is readable
|
|
68
|
+
- If missing or unreadable → "Architecture document not found at `{path}`. Provide a valid path."
|
|
69
|
+
- HALT until a valid architecture document is provided
|
|
70
|
+
|
|
71
|
+
**Validate PRD document (if provided):**
|
|
72
|
+
- Confirm the file exists and is readable
|
|
73
|
+
- If missing → "PRD document not found at `{path}`. Proceeding without PRD — requirements pass will be skipped."
|
|
74
|
+
- Store PRD availability as `prd_available: true|false`
|
|
75
|
+
|
|
76
|
+
**Validate previous report (if provided):**
|
|
77
|
+
- Confirm the file exists and is readable
|
|
78
|
+
- **Collision check:** Resolve both the provided path and `{outputFile}` to their absolute form before comparing (do not rely on string equality alone). If they resolve to the same location, warn: "The previous report path points to the same location as the new report. This file will be overwritten during this run. Provide a path to a backup copy, or leave empty to skip delta comparison." HALT until resolved.
|
|
79
|
+
- If missing → "Previous report not found at `{path}`. Proceeding without delta comparison."
|
|
80
|
+
- Store as `previous_report: {path}` (or empty string if not provided)
|
|
81
|
+
|
|
82
|
+
### 2. Scan Skills Folder
|
|
83
|
+
|
|
84
|
+
Read the `{skills_output_folder}` directory.
|
|
85
|
+
|
|
86
|
+
For each subdirectory, check for the presence of `SKILL.md` and `metadata.json`.
|
|
87
|
+
|
|
88
|
+
**For each valid skill directory, extract from metadata.json:**
|
|
89
|
+
- `name` — skill name
|
|
90
|
+
- `language` — primary language
|
|
91
|
+
- `confidence_tier` — Quick, Forge, Forge+, or Deep
|
|
92
|
+
- `exports_documented` — read from `stats.exports_documented` in metadata.json (count of documented exports)
|
|
93
|
+
- `source_repo` or `source_root` — original source repository
|
|
94
|
+
|
|
95
|
+
**Build a skill inventory** as an internal list of all loaded skills with the fields above.
|
|
96
|
+
|
|
97
|
+
**If a subdirectory lacks SKILL.md or metadata.json:**
|
|
98
|
+
- Log: "Skipping `{dir_name}` — missing SKILL.md or metadata.json"
|
|
99
|
+
- Do not include in inventory
|
|
100
|
+
|
|
101
|
+
### 3. Validate Minimum Requirements
|
|
102
|
+
|
|
103
|
+
**Check skill count:**
|
|
104
|
+
- At least 2 valid skills must exist (a stack requires multiple libraries)
|
|
105
|
+
- If fewer than 2 → "**Cannot proceed.** Only {count} skill(s) found in `{skills_output_folder}`. A stack requires at least 2 skills. Generate more skills with [CS] Create Skill or [QS] Quick Skill, then re-run [VS]."
|
|
106
|
+
- HALT workflow
|
|
107
|
+
|
|
108
|
+
**Check forge_data_folder:**
|
|
109
|
+
- Verify `forge_data_folder` was resolved from config.yaml and is non-empty
|
|
110
|
+
- If undefined or empty → "**Cannot proceed.** `forge_data_folder` is not configured in config.yaml. Re-run [SF] Setup Forge to initialize."
|
|
111
|
+
- HALT workflow
|
|
112
|
+
|
|
113
|
+
**Check architecture document:**
|
|
114
|
+
- Confirm it was loaded successfully in section 1
|
|
115
|
+
- If not → HALT with error (should not reach here if section 1 validation passed)
|
|
116
|
+
|
|
117
|
+
### 4. Create Feasibility Report
|
|
118
|
+
|
|
119
|
+
Load `{reportTemplate}` and create the output file at `{outputFile}`.
|
|
120
|
+
|
|
121
|
+
**Populate frontmatter:**
|
|
122
|
+
- `project_name`, `date`, `architecture_doc`, `prd_doc` (or "none")
|
|
123
|
+
- `prd_available: true|false` (from section 1 validation)
|
|
124
|
+
- `previous_report: {path}` (or empty string if not provided)
|
|
125
|
+
- `skills_analyzed: {count}`
|
|
126
|
+
- `overall_verdict: "pending"`
|
|
127
|
+
- `stepsCompleted: ['step-01-init']`
|
|
128
|
+
|
|
129
|
+
### 5. Display Initialization Summary
|
|
130
|
+
|
|
131
|
+
"**Stack Verification Initialized**
|
|
132
|
+
|
|
133
|
+
| Field | Value |
|
|
134
|
+
|-------|-------|
|
|
135
|
+
| **Skills Loaded** | {count} |
|
|
136
|
+
| **Architecture Doc** | {architecture_doc} |
|
|
137
|
+
| **PRD Document** | {prd_doc or 'Not provided — requirements pass will be skipped'} |
|
|
138
|
+
| **Previous Report** | {previous_report or 'Not provided — no delta comparison'} |
|
|
139
|
+
|
|
140
|
+
**Skill Inventory:**
|
|
141
|
+
|
|
142
|
+
| Skill | Language | Tier | Exports |
|
|
143
|
+
|-------|----------|------|---------|
|
|
144
|
+
| {skill_name} | {language} | {confidence_tier} | {exports_documented} |
|
|
145
|
+
|
|
146
|
+
**Proceeding to coverage analysis...**"
|
|
147
|
+
|
|
148
|
+
### 6. Auto-Proceed to Next Step
|
|
149
|
+
|
|
150
|
+
Load, read the full file and then execute `{nextStepFile}`.
|
|
151
|
+
|
|
152
|
+
---
|
|
153
|
+
|
|
154
|
+
## 🚨 SYSTEM SUCCESS/FAILURE METRICS
|
|
155
|
+
|
|
156
|
+
### ✅ SUCCESS:
|
|
157
|
+
|
|
158
|
+
- Architecture document loaded and validated
|
|
159
|
+
- PRD document loaded or absence recorded
|
|
160
|
+
- Skills folder scanned with SKILL.md and metadata.json validation per skill
|
|
161
|
+
- At least 2 valid skills in inventory
|
|
162
|
+
- Feasibility report created from template with populated frontmatter
|
|
163
|
+
- Initialization summary displayed with skill inventory table
|
|
164
|
+
- Auto-proceeded to step 02
|
|
165
|
+
|
|
166
|
+
### ❌ SYSTEM FAILURE:
|
|
167
|
+
|
|
168
|
+
- Proceeding with fewer than 2 skills
|
|
169
|
+
- Proceeding without a valid architecture document
|
|
170
|
+
- Not validating SKILL.md and metadata.json existence per skill directory
|
|
171
|
+
- Performing coverage or integration analysis in this step
|
|
172
|
+
- Hardcoded paths instead of frontmatter variables
|
|
173
|
+
|
|
174
|
+
**Master Rule:** This step validates inputs and initializes state. No analysis, no comparison, no verdicts.
|
|
@@ -0,0 +1,181 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: 'step-02-coverage'
|
|
3
|
+
description: 'Pass 1 — check that a generated skill exists for every technology referenced in the architecture document'
|
|
4
|
+
|
|
5
|
+
nextStepFile: './step-03-integrations.md'
|
|
6
|
+
coveragePatternsData: '../data/coverage-patterns.md'
|
|
7
|
+
outputFile: '{forge_data_folder}/feasibility-report-{project_name}.md'
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
# Step 2: Technology Coverage Analysis
|
|
11
|
+
|
|
12
|
+
## STEP GOAL:
|
|
13
|
+
|
|
14
|
+
Verify that a generated skill exists for every technology, library, or framework referenced in the architecture document. Produce a coverage matrix showing which technologies are covered and which are missing. Detect extra skills not referenced in the architecture.
|
|
15
|
+
|
|
16
|
+
## MANDATORY EXECUTION RULES (READ FIRST):
|
|
17
|
+
|
|
18
|
+
### Universal Rules:
|
|
19
|
+
|
|
20
|
+
- 📖 CRITICAL: Read the complete step file before taking any action
|
|
21
|
+
- 🔄 CRITICAL: When loading next step with 'C', ensure entire file is read
|
|
22
|
+
- ⚙️ TOOL/SUBPROCESS FALLBACK: If any instruction references a subprocess, subagent, or tool you do not have access to, you MUST still achieve the outcome in your main context thread
|
|
23
|
+
- ✅ YOU MUST ALWAYS SPEAK OUTPUT in your Agent communication style with the config `{communication_language}`
|
|
24
|
+
|
|
25
|
+
### Role Reinforcement:
|
|
26
|
+
|
|
27
|
+
- ✅ You are a stack verification analyst performing coverage analysis
|
|
28
|
+
- ✅ Every technology reference must trace to actual text in the architecture document
|
|
29
|
+
- ✅ Matching must be precise — do not guess or infer technologies not explicitly mentioned
|
|
30
|
+
|
|
31
|
+
### Step-Specific Rules:
|
|
32
|
+
|
|
33
|
+
- 🎯 Focus ONLY on technology-to-skill coverage mapping
|
|
34
|
+
- 🚫 FORBIDDEN to analyze API surfaces or integration compatibility — that is Step 03
|
|
35
|
+
- 🚫 FORBIDDEN to evaluate requirements — that is Step 04
|
|
36
|
+
- 💬 Coverage verdicts must be binary: Covered or Missing — no ambiguity
|
|
37
|
+
|
|
38
|
+
## EXECUTION PROTOCOLS:
|
|
39
|
+
|
|
40
|
+
- 🎯 Extract technology references from architecture document using {coveragePatternsData}
|
|
41
|
+
- 💾 Build and display coverage matrix with Covered/Missing verdicts
|
|
42
|
+
- 📖 Append Coverage Matrix section to {outputFile}
|
|
43
|
+
- 🚫 Only coverage mapping — no integration analysis, no requirements checking
|
|
44
|
+
|
|
45
|
+
## CONTEXT BOUNDARIES:
|
|
46
|
+
|
|
47
|
+
- Available: Architecture document content, skill inventory from Step 01, coverage patterns data
|
|
48
|
+
- Focus: Technology-to-skill matching only
|
|
49
|
+
- Limits: Do not read SKILL.md in detail — use metadata.json for name and source_repo matching only
|
|
50
|
+
- Dependencies: Step 01 must have loaded skill inventory and validated architecture document
|
|
51
|
+
|
|
52
|
+
## MANDATORY SEQUENCE
|
|
53
|
+
|
|
54
|
+
**CRITICAL:** Follow this sequence exactly. Do not skip, reorder, or improvise.
|
|
55
|
+
|
|
56
|
+
### 1. Load Coverage Patterns
|
|
57
|
+
|
|
58
|
+
Load `{coveragePatternsData}` for detection rules.
|
|
59
|
+
|
|
60
|
+
Extract: technology name patterns, section heading indicators, common aliases, and framework-to-library mappings.
|
|
61
|
+
|
|
62
|
+
### 2. Extract Technology References
|
|
63
|
+
|
|
64
|
+
Parse the architecture document for technology, library, and framework names.
|
|
65
|
+
|
|
66
|
+
**Detection methods (apply in order):**
|
|
67
|
+
|
|
68
|
+
**Section-based detection:**
|
|
69
|
+
- Identify section headings that indicate technology listings (e.g., "Tech Stack", "Dependencies", "Technologies", "Libraries", layer-specific headings)
|
|
70
|
+
- Extract technology names listed under these headings
|
|
71
|
+
|
|
72
|
+
**Direct name matching:**
|
|
73
|
+
- Scan the full document for names that match loaded skill names (case-insensitive)
|
|
74
|
+
- Apply alias resolution from {coveragePatternsData} (e.g., "React" matches "react", "PostgreSQL" matches "postgres")
|
|
75
|
+
|
|
76
|
+
**Contextual detection:**
|
|
77
|
+
- Identify technology names mentioned in prose alongside architectural descriptions
|
|
78
|
+
- Look for version-pinned references (e.g., "Express v4", "Tailwind CSS 3.x")
|
|
79
|
+
|
|
80
|
+
**Build a deduplicated list** of all referenced technologies with the document section where each was found.
|
|
81
|
+
|
|
82
|
+
### 3. Cross-Reference Against Skills
|
|
83
|
+
|
|
84
|
+
For each referenced technology in the list:
|
|
85
|
+
|
|
86
|
+
**Check if a matching skill exists** in the skill inventory from Step 01.
|
|
87
|
+
- Match by skill name (case-insensitive)
|
|
88
|
+
- Match by alias from {coveragePatternsData}
|
|
89
|
+
- Match by `source_repo` or `source_root` field in metadata.json if skill name differs from technology name
|
|
90
|
+
|
|
91
|
+
**Assign verdict:**
|
|
92
|
+
- **Covered** — a matching skill exists in the inventory
|
|
93
|
+
- **Missing** — no matching skill found
|
|
94
|
+
|
|
95
|
+
Build the coverage matrix as a structured table.
|
|
96
|
+
|
|
97
|
+
### 4. Detect Extra Skills
|
|
98
|
+
|
|
99
|
+
Check if any skills in the inventory are NOT referenced in the architecture document.
|
|
100
|
+
|
|
101
|
+
**For each extra skill:**
|
|
102
|
+
- Mark as **Extra** (informational — not an error)
|
|
103
|
+
- Note: "Skill `{skill_name}` exists but is not referenced in the architecture document"
|
|
104
|
+
|
|
105
|
+
Extra skills are informational only. They do not affect the coverage verdict.
|
|
106
|
+
|
|
107
|
+
### 5. Display Coverage Results
|
|
108
|
+
|
|
109
|
+
"**Pass 1: Technology Coverage**
|
|
110
|
+
|
|
111
|
+
| Technology | Source Section | Skill Match | Verdict |
|
|
112
|
+
|------------|---------------|-------------|---------|
|
|
113
|
+
| {tech_name} | {section_heading} | {skill_name or '—'} | {Covered / Missing} |
|
|
114
|
+
|
|
115
|
+
**Coverage: {covered_count}/{total_count} ({percentage}%)**
|
|
116
|
+
|
|
117
|
+
{IF 100% coverage AND no Extra skills:}
|
|
118
|
+
**All referenced technologies have a matching skill. No extra skills detected.**
|
|
119
|
+
|
|
120
|
+
{IF any Missing:}
|
|
121
|
+
**Missing Skills — Action Required:**
|
|
122
|
+
{For each missing technology:}
|
|
123
|
+
- `{tech_name}` → Run **[CS] Create Skill** or **[QS] Quick Skill** for `{tech_name}`, then re-run **[VS]**
|
|
124
|
+
|
|
125
|
+
{IF any Extra:}
|
|
126
|
+
**Extra Skills (informational):**
|
|
127
|
+
{For each extra skill:}
|
|
128
|
+
- `{skill_name}` — not referenced in architecture document"
|
|
129
|
+
|
|
130
|
+
### 6. Append to Report
|
|
131
|
+
|
|
132
|
+
Write the **Coverage Matrix** section to `{outputFile}`:
|
|
133
|
+
- Include the full coverage table
|
|
134
|
+
- Include coverage percentage
|
|
135
|
+
- Include missing skill recommendations
|
|
136
|
+
- Include extra skills list
|
|
137
|
+
- Update frontmatter: append `'step-02-coverage'` to `stepsCompleted`, set `coverage_percentage`
|
|
138
|
+
|
|
139
|
+
### 7. Auto-Proceed to Next Step
|
|
140
|
+
|
|
141
|
+
{IF coverage_percentage is 0%:}
|
|
142
|
+
"**⚠️ 0% coverage — no matching skills found for any referenced technology.** All subsequent analysis (integration, requirements) will be vacuous and produce empty tables.
|
|
143
|
+
|
|
144
|
+
**Recommended:** Generate skills with [CS] or [QS] for your architecture technologies, then re-run [VS].
|
|
145
|
+
|
|
146
|
+
**Select:** [X] Halt workflow (recommended) | [C] Continue anyway"
|
|
147
|
+
|
|
148
|
+
- IF X: "**Workflow halted.** Generate skills and re-run [VS] when ready." — END workflow
|
|
149
|
+
- IF C: "**Continuing with 0% coverage — results will be limited.**"
|
|
150
|
+
|
|
151
|
+
Load, read the full file and then execute `{nextStepFile}`.
|
|
152
|
+
|
|
153
|
+
{IF coverage_percentage is NOT 0%:}
|
|
154
|
+
"**Proceeding to integration analysis...**"
|
|
155
|
+
|
|
156
|
+
Load, read the full file and then execute `{nextStepFile}`.
|
|
157
|
+
|
|
158
|
+
---
|
|
159
|
+
|
|
160
|
+
## 🚨 SYSTEM SUCCESS/FAILURE METRICS
|
|
161
|
+
|
|
162
|
+
### ✅ SUCCESS:
|
|
163
|
+
|
|
164
|
+
- Coverage patterns loaded from {coveragePatternsData}
|
|
165
|
+
- All technology references extracted from architecture document with section citations
|
|
166
|
+
- Every referenced technology cross-referenced against skill inventory
|
|
167
|
+
- Coverage matrix displayed with binary Covered/Missing verdicts
|
|
168
|
+
- Extra skills detected and reported as informational
|
|
169
|
+
- Missing skills have actionable recommendations (run [CS] or [QS])
|
|
170
|
+
- Coverage Matrix section appended to {outputFile}
|
|
171
|
+
- Auto-proceeded to step 03
|
|
172
|
+
|
|
173
|
+
### ❌ SYSTEM FAILURE:
|
|
174
|
+
|
|
175
|
+
- Inventing technologies not mentioned in the architecture document
|
|
176
|
+
- Ambiguous verdicts (anything other than Covered or Missing)
|
|
177
|
+
- Analyzing API surfaces or skill content in detail (that is Step 03)
|
|
178
|
+
- Not providing actionable recommendations for missing skills
|
|
179
|
+
- Hardcoded paths instead of frontmatter variables
|
|
180
|
+
|
|
181
|
+
**Master Rule:** Skipping steps, optimizing sequences, or not following exact instructions is FORBIDDEN and constitutes SYSTEM FAILURE.
|
|
@@ -0,0 +1,195 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: 'step-03-integrations'
|
|
3
|
+
description: 'Pass 2 — cross-reference API surfaces between library pairs based on integration claims in the architecture document'
|
|
4
|
+
|
|
5
|
+
nextStepFile: './step-04-requirements.md'
|
|
6
|
+
integrationRulesData: '../data/integration-verification-rules.md'
|
|
7
|
+
outputFile: '{forge_data_folder}/feasibility-report-{project_name}.md'
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
# Step 3: Integration Verification
|
|
11
|
+
|
|
12
|
+
## STEP GOAL:
|
|
13
|
+
|
|
14
|
+
Cross-reference API surfaces between library pairs that the architecture document claims work together. For each integration pair, verify language compatibility, protocol alignment, type compatibility, and documentation cross-references. Produce an evidence-backed verdict for each integration.
|
|
15
|
+
|
|
16
|
+
## MANDATORY EXECUTION RULES (READ FIRST):
|
|
17
|
+
|
|
18
|
+
### Universal Rules:
|
|
19
|
+
|
|
20
|
+
- 📖 CRITICAL: Read the complete step file before taking any action
|
|
21
|
+
- 🔄 CRITICAL: When loading next step with 'C', ensure entire file is read
|
|
22
|
+
- ⚙️ TOOL/SUBPROCESS FALLBACK: If any instruction references a subprocess, subagent, or tool you do not have access to, you MUST still achieve the outcome in your main context thread
|
|
23
|
+
- ✅ YOU MUST ALWAYS SPEAK OUTPUT in your Agent communication style with the config `{communication_language}`
|
|
24
|
+
|
|
25
|
+
### Role Reinforcement:
|
|
26
|
+
|
|
27
|
+
- ✅ You are a stack verification analyst performing integration feasibility analysis
|
|
28
|
+
- ✅ Every verdict must cite evidence from the actual skill content — no speculation
|
|
29
|
+
- ✅ Apply the verification protocol strictly — do not skip compatibility checks
|
|
30
|
+
|
|
31
|
+
### Step-Specific Rules:
|
|
32
|
+
|
|
33
|
+
- 🎯 Focus ONLY on integration pair verification using skill API surfaces
|
|
34
|
+
- 🚫 FORBIDDEN to evaluate requirements coverage — that is Step 04
|
|
35
|
+
- 🚫 FORBIDDEN to parse Mermaid diagrams — use prose-based co-mention analysis only
|
|
36
|
+
- 💬 Every verdict MUST include evidence citations from the skills
|
|
37
|
+
|
|
38
|
+
## EXECUTION PROTOCOLS:
|
|
39
|
+
|
|
40
|
+
- 🎯 Extract integration claims from architecture document prose
|
|
41
|
+
- 💾 Load skill API surfaces and cross-reference each integration pair
|
|
42
|
+
- 📖 Append Integration Verdicts section to {outputFile}
|
|
43
|
+
- 🚫 Only integration analysis — no requirements checking, no synthesis
|
|
44
|
+
|
|
45
|
+
## CONTEXT BOUNDARIES:
|
|
46
|
+
|
|
47
|
+
- Available: Architecture document content, skill SKILL.md and metadata.json files, integration verification rules
|
|
48
|
+
- Focus: Pairwise integration compatibility between skills
|
|
49
|
+
- Limits: Only verify pairs explicitly claimed in the architecture document — do not invent integration relationships
|
|
50
|
+
- Dependencies: Step 01 (skill inventory), Step 02 (coverage matrix — only verify skills that exist)
|
|
51
|
+
|
|
52
|
+
## MANDATORY SEQUENCE
|
|
53
|
+
|
|
54
|
+
**CRITICAL:** Follow this sequence exactly. Do not skip, reorder, or improvise.
|
|
55
|
+
|
|
56
|
+
### 1. Load Integration Verification Rules
|
|
57
|
+
|
|
58
|
+
Load `{integrationRulesData}` for the cross-reference verification protocol.
|
|
59
|
+
|
|
60
|
+
Extract: verification checks (language boundary, protocol compatibility, type compatibility, documentation cross-reference), verdict criteria, and evidence requirements.
|
|
61
|
+
|
|
62
|
+
### 2. Extract Integration Claims
|
|
63
|
+
|
|
64
|
+
Parse the architecture document for statements describing two or more technologies working together.
|
|
65
|
+
|
|
66
|
+
**Detection method — prose-based co-mention analysis:**
|
|
67
|
+
- Identify sentences or paragraphs where two or more technology names appear together
|
|
68
|
+
- Look for integration verbs: "connects to", "communicates with", "wraps", "extends", "consumes", "produces", "bridges", "integrates with", "sits between"
|
|
69
|
+
- Look for data flow descriptions: "{A} sends data to {B}", "{A} results are consumed by {B}"
|
|
70
|
+
- Look for layer boundary descriptions: "{A} at the API layer connects to {B} at the data layer"
|
|
71
|
+
|
|
72
|
+
**CRITICAL:** Do NOT parse Mermaid diagram syntax. Use only prose text for co-mention detection.
|
|
73
|
+
|
|
74
|
+
**Build integration pairs list:**
|
|
75
|
+
- Each pair: `{library_a, library_b, architectural_context}`
|
|
76
|
+
- `architectural_context`: the quoted text or paraphrased description of their relationship
|
|
77
|
+
|
|
78
|
+
**Filter:** Only include pairs where BOTH libraries have a corresponding skill (Covered in Step 02). Skip pairs involving Missing skills — they cannot be verified.
|
|
79
|
+
|
|
80
|
+
### 3. Load Skill API Surfaces
|
|
81
|
+
|
|
82
|
+
For each library in an integration pair, load the skill artifacts:
|
|
83
|
+
|
|
84
|
+
**From SKILL.md, extract:**
|
|
85
|
+
- Exported functions and their signatures
|
|
86
|
+
- Exported types, interfaces, and classes
|
|
87
|
+
- Protocol indicators (HTTP, gRPC, WebSocket, message queue, file I/O, IPC)
|
|
88
|
+
- Data format indicators (JSON, protobuf, CSV, binary, streaming)
|
|
89
|
+
|
|
90
|
+
**From metadata.json, extract:**
|
|
91
|
+
- `language` — primary programming language
|
|
92
|
+
- `exports` — export names array (populated for individual skills; empty for stack skills)
|
|
93
|
+
- `stats.exports_documented` — export count
|
|
94
|
+
- `confidence_tier` — extraction confidence level
|
|
95
|
+
|
|
96
|
+
Store loaded API surfaces for cross-referencing.
|
|
97
|
+
|
|
98
|
+
### 4. Cross-Reference Each Integration Pair
|
|
99
|
+
|
|
100
|
+
For each integration pair `{library_a, library_b}`, apply the verification protocol from `{integrationRulesData}`:
|
|
101
|
+
|
|
102
|
+
**Check 1 — Language Boundary:**
|
|
103
|
+
- Same language → compatible
|
|
104
|
+
- Different languages → check for FFI, IPC, or network protocol bridge
|
|
105
|
+
- If no bridge mechanism documented → flag as risk
|
|
106
|
+
|
|
107
|
+
**Check 2 — Protocol Compatibility:**
|
|
108
|
+
- Both use same protocol (e.g., both HTTP) → compatible
|
|
109
|
+
- Complementary protocols (e.g., HTTP client + HTTP server) → compatible
|
|
110
|
+
- Incompatible protocols with no adapter → flag as risk
|
|
111
|
+
|
|
112
|
+
**Check 3 — Type Compatibility:**
|
|
113
|
+
- Shared types or compatible serialization formats → compatible
|
|
114
|
+
- Incompatible type systems with no conversion layer → flag as risk
|
|
115
|
+
|
|
116
|
+
**Check 4 — Documentation Cross-Reference:**
|
|
117
|
+
- Skill A mentions skill B's library (or vice versa) → strong evidence
|
|
118
|
+
- Neither skill mentions the other → weak evidence (plausible but unverified)
|
|
119
|
+
|
|
120
|
+
**Assign verdict per pair:**
|
|
121
|
+
- **Verified** — all checks pass with evidence from both skills
|
|
122
|
+
- **Plausible** — checks pass but evidence is indirect or incomplete
|
|
123
|
+
- **Risky** — one or more checks flag compatibility concerns
|
|
124
|
+
- **Blocked** — fundamental incompatibility detected (language barrier with no bridge, incompatible protocols)
|
|
125
|
+
|
|
126
|
+
**Each verdict MUST include:**
|
|
127
|
+
- Which checks passed and which flagged
|
|
128
|
+
- Evidence citations: specific exports, types, or protocol references from the skills
|
|
129
|
+
|
|
130
|
+
### 5. Display Integration Results
|
|
131
|
+
|
|
132
|
+
"**Pass 2: Integration Verification**
|
|
133
|
+
|
|
134
|
+
| Library A | Library B | Context | Verdict | Evidence |
|
|
135
|
+
|-----------|-----------|---------|---------|----------|
|
|
136
|
+
| {lib_a} | {lib_b} | {brief context} | {Verified/Plausible/Risky/Blocked} | {key evidence} |
|
|
137
|
+
|
|
138
|
+
**Summary:** {verified_count} Verified, {plausible_count} Plausible, {risky_count} Risky, {blocked_count} Blocked
|
|
139
|
+
|
|
140
|
+
{IF zero integration pairs found:}
|
|
141
|
+
**No integration claims detected in the architecture document prose.** Ensure your architecture document describes relationships between technologies in text form (not exclusively in Mermaid diagrams). Coverage-only analysis was performed.
|
|
142
|
+
|
|
143
|
+
{IF any Risky:}
|
|
144
|
+
**Risky Integrations — Recommendations:**
|
|
145
|
+
{For each risky pair:}
|
|
146
|
+
- `{lib_a}` ↔ `{lib_b}`: {specific concern}. **Recommendation:** {prescriptive action}
|
|
147
|
+
|
|
148
|
+
{IF any Blocked:}
|
|
149
|
+
**Blocked Integrations — Action Required:**
|
|
150
|
+
{For each blocked pair:}
|
|
151
|
+
- `{lib_a}` ↔ `{lib_b}`: {fundamental incompatibility}. **Recommendation:** {prescriptive action}"
|
|
152
|
+
|
|
153
|
+
### 6. Append to Report
|
|
154
|
+
|
|
155
|
+
Write the **Integration Verdicts** section to `{outputFile}`:
|
|
156
|
+
- Include the full integration verdicts table with evidence
|
|
157
|
+
- Include recommendations for Risky and Blocked pairs
|
|
158
|
+
- Update frontmatter: append `'step-03-integrations'` to `stepsCompleted`
|
|
159
|
+
- Set `integrations_verified`, `integrations_plausible`, `integrations_risky`, `integrations_blocked` counts
|
|
160
|
+
|
|
161
|
+
### 7. Auto-Proceed to Next Step
|
|
162
|
+
|
|
163
|
+
**Early halt guard:** If ALL integration pairs are Blocked, present: "**All integrations are Blocked** — fundamental incompatibilities detected across all library pairs. Remaining analysis will produce limited value. **[X] Halt workflow (recommended)** | **[C] Continue anyway**" — wait for user input. If X: halt with: "**Workflow halted — all integrations blocked.** Integration Verdicts saved to `{outputFile}`. Run **[VS]** after applying architectural changes. **Blocked integrations:** {list each blocked pair with reason}." If C: continue.
|
|
164
|
+
|
|
165
|
+
{IF NOT halted (user selected C, or early halt guard did not trigger):}
|
|
166
|
+
|
|
167
|
+
"**Proceeding to requirements verification...**"
|
|
168
|
+
|
|
169
|
+
Load, read the full file and then execute `{nextStepFile}`.
|
|
170
|
+
|
|
171
|
+
---
|
|
172
|
+
|
|
173
|
+
## 🚨 SYSTEM SUCCESS/FAILURE METRICS
|
|
174
|
+
|
|
175
|
+
### ✅ SUCCESS:
|
|
176
|
+
|
|
177
|
+
- Integration rules loaded from {integrationRulesData}
|
|
178
|
+
- Integration claims extracted from architecture document prose (not Mermaid diagrams)
|
|
179
|
+
- Skill API surfaces loaded for each library in integration pairs
|
|
180
|
+
- All four verification checks applied to each pair
|
|
181
|
+
- Every verdict includes evidence citations from actual skill content
|
|
182
|
+
- Recommendations provided for every Risky and Blocked integration
|
|
183
|
+
- Integration Verdicts section appended to {outputFile}
|
|
184
|
+
- Auto-proceeded to step 04
|
|
185
|
+
|
|
186
|
+
### ❌ SYSTEM FAILURE:
|
|
187
|
+
|
|
188
|
+
- Parsing Mermaid diagrams instead of using prose-based co-mention analysis
|
|
189
|
+
- Verdicts without evidence citations from actual skills
|
|
190
|
+
- Inventing integration relationships not described in the architecture document
|
|
191
|
+
- Skipping any of the four verification checks
|
|
192
|
+
- Evaluating requirements coverage (that is Step 04)
|
|
193
|
+
- Hardcoded paths instead of frontmatter variables
|
|
194
|
+
|
|
195
|
+
**Master Rule:** Skipping steps, optimizing sequences, or not following exact instructions is FORBIDDEN and constitutes SYSTEM FAILURE.
|