ridgeline 0.5.9 → 0.7.2
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 +53 -9
- package/dist/agents/core/designer.md +131 -0
- package/dist/agents/core/refiner.md +61 -0
- package/dist/agents/core/researcher.md +78 -0
- package/dist/agents/core/specifier.md +16 -0
- package/dist/agents/researchers/academic.md +27 -0
- package/dist/agents/researchers/competitive.md +28 -0
- package/dist/agents/researchers/context.md +46 -0
- package/dist/agents/researchers/ecosystem.md +28 -0
- package/dist/agents/researchers/gaps.md +67 -0
- package/dist/agents/specifiers/visual-coherence.md +55 -0
- package/dist/cli.js +83 -1
- package/dist/cli.js.map +1 -1
- package/dist/commands/create.js +20 -2
- package/dist/commands/create.js.map +1 -1
- package/dist/commands/design.d.ts +8 -0
- package/dist/commands/design.js +130 -0
- package/dist/commands/design.js.map +1 -0
- package/dist/commands/index.d.ts +1 -0
- package/dist/commands/index.js +3 -1
- package/dist/commands/index.js.map +1 -1
- package/dist/commands/plan.js +3 -3
- package/dist/commands/plan.js.map +1 -1
- package/dist/commands/qa-workflow.d.ts +33 -0
- package/dist/commands/qa-workflow.js +139 -0
- package/dist/commands/qa-workflow.js.map +1 -0
- package/dist/commands/refine.d.ts +8 -0
- package/dist/commands/refine.js +105 -0
- package/dist/commands/refine.js.map +1 -0
- package/dist/commands/research.d.ts +10 -0
- package/dist/commands/research.js +146 -0
- package/dist/commands/research.js.map +1 -0
- package/dist/commands/rewind.js +5 -3
- package/dist/commands/rewind.js.map +1 -1
- package/dist/commands/shape.js +36 -121
- package/dist/commands/shape.js.map +1 -1
- package/dist/commands/spec.js +1 -0
- package/dist/commands/spec.js.map +1 -1
- package/dist/engine/claude/stream.display.js +0 -1
- package/dist/engine/claude/stream.display.js.map +1 -1
- package/dist/engine/claude/stream.parse.d.ts +1 -15
- package/dist/engine/claude/stream.parse.js +3 -21
- package/dist/engine/claude/stream.parse.js.map +1 -1
- package/dist/engine/claude/stream.result.js +2 -2
- package/dist/engine/claude/stream.types.d.ts +15 -0
- package/dist/engine/claude/stream.types.js +23 -0
- package/dist/engine/claude/stream.types.js.map +1 -0
- package/dist/engine/discovery/agent.registry.d.ts +4 -0
- package/dist/engine/discovery/agent.registry.js +46 -18
- package/dist/engine/discovery/agent.registry.js.map +1 -1
- package/dist/engine/discovery/flavour.config.d.ts +9 -0
- package/dist/engine/discovery/flavour.config.js +61 -0
- package/dist/engine/discovery/flavour.config.js.map +1 -0
- package/dist/engine/discovery/plugin.scan.d.ts +1 -0
- package/dist/engine/discovery/plugin.scan.js +29 -1
- package/dist/engine/discovery/plugin.scan.js.map +1 -1
- package/dist/engine/discovery/skill.check.d.ts +19 -0
- package/dist/engine/discovery/skill.check.js +145 -0
- package/dist/engine/discovery/skill.check.js.map +1 -0
- package/dist/engine/pipeline/build.exec.js +1 -0
- package/dist/engine/pipeline/build.exec.js.map +1 -1
- package/dist/engine/pipeline/ensemble.exec.d.ts +12 -1
- package/dist/engine/pipeline/ensemble.exec.js +20 -10
- package/dist/engine/pipeline/ensemble.exec.js.map +1 -1
- package/dist/engine/pipeline/phase.sequence.js +10 -10
- package/dist/engine/pipeline/phase.sequence.js.map +1 -1
- package/dist/engine/pipeline/pipeline.shared.d.ts +6 -0
- package/dist/engine/pipeline/pipeline.shared.js +24 -1
- package/dist/engine/pipeline/pipeline.shared.js.map +1 -1
- package/dist/engine/pipeline/plan.exec.js +1 -0
- package/dist/engine/pipeline/plan.exec.js.map +1 -1
- package/dist/engine/pipeline/refine.exec.d.ts +10 -0
- package/dist/engine/pipeline/refine.exec.js +91 -0
- package/dist/engine/pipeline/refine.exec.js.map +1 -0
- package/dist/engine/pipeline/research.exec.d.ts +17 -0
- package/dist/engine/pipeline/research.exec.js +196 -0
- package/dist/engine/pipeline/research.exec.js.map +1 -0
- package/dist/engine/pipeline/review.exec.js +23 -0
- package/dist/engine/pipeline/review.exec.js.map +1 -1
- package/dist/engine/pipeline/specify.exec.d.ts +1 -0
- package/dist/engine/pipeline/specify.exec.js +114 -44
- package/dist/engine/pipeline/specify.exec.js.map +1 -1
- package/dist/flavours/data-analysis/core/refiner.md +65 -0
- package/dist/flavours/data-analysis/core/researcher.md +81 -0
- package/dist/flavours/data-analysis/researchers/academic.md +29 -0
- package/dist/flavours/data-analysis/researchers/competitive.md +29 -0
- package/dist/flavours/data-analysis/researchers/ecosystem.md +29 -0
- package/dist/flavours/data-analysis/researchers/gaps.md +59 -0
- package/dist/flavours/game-dev/core/refiner.md +65 -0
- package/dist/flavours/game-dev/core/researcher.md +81 -0
- package/dist/flavours/game-dev/researchers/academic.md +31 -0
- package/dist/flavours/game-dev/researchers/competitive.md +30 -0
- package/dist/flavours/game-dev/researchers/ecosystem.md +29 -0
- package/dist/flavours/game-dev/researchers/gaps.md +59 -0
- package/dist/flavours/legal-drafting/core/refiner.md +65 -0
- package/dist/flavours/legal-drafting/core/researcher.md +81 -0
- package/dist/flavours/legal-drafting/researchers/academic.md +31 -0
- package/dist/flavours/legal-drafting/researchers/competitive.md +31 -0
- package/dist/flavours/legal-drafting/researchers/ecosystem.md +30 -0
- package/dist/flavours/legal-drafting/researchers/gaps.md +59 -0
- package/dist/flavours/machine-learning/core/refiner.md +65 -0
- package/dist/flavours/machine-learning/core/researcher.md +81 -0
- package/dist/flavours/machine-learning/researchers/academic.md +32 -0
- package/dist/flavours/machine-learning/researchers/competitive.md +32 -0
- package/dist/flavours/machine-learning/researchers/ecosystem.md +31 -0
- package/dist/flavours/machine-learning/researchers/gaps.md +59 -0
- package/dist/flavours/mobile-app/core/refiner.md +65 -0
- package/dist/flavours/mobile-app/core/researcher.md +81 -0
- package/dist/flavours/mobile-app/researchers/academic.md +31 -0
- package/dist/flavours/mobile-app/researchers/competitive.md +32 -0
- package/dist/flavours/mobile-app/researchers/ecosystem.md +31 -0
- package/dist/flavours/mobile-app/researchers/gaps.md +59 -0
- package/dist/flavours/music-composition/core/refiner.md +65 -0
- package/dist/flavours/music-composition/core/researcher.md +81 -0
- package/dist/flavours/music-composition/researchers/academic.md +32 -0
- package/dist/flavours/music-composition/researchers/competitive.md +32 -0
- package/dist/flavours/music-composition/researchers/ecosystem.md +32 -0
- package/dist/flavours/music-composition/researchers/gaps.md +59 -0
- package/dist/flavours/novel-writing/core/refiner.md +65 -0
- package/dist/flavours/novel-writing/core/researcher.md +81 -0
- package/dist/flavours/novel-writing/researchers/academic.md +32 -0
- package/dist/flavours/novel-writing/researchers/competitive.md +32 -0
- package/dist/flavours/novel-writing/researchers/ecosystem.md +32 -0
- package/dist/flavours/novel-writing/researchers/gaps.md +59 -0
- package/dist/flavours/screenwriting/core/refiner.md +65 -0
- package/dist/flavours/screenwriting/core/researcher.md +81 -0
- package/dist/flavours/screenwriting/researchers/academic.md +32 -0
- package/dist/flavours/screenwriting/researchers/competitive.md +32 -0
- package/dist/flavours/screenwriting/researchers/ecosystem.md +32 -0
- package/dist/flavours/screenwriting/researchers/gaps.md +59 -0
- package/dist/flavours/security-audit/core/refiner.md +65 -0
- package/dist/flavours/security-audit/core/researcher.md +81 -0
- package/dist/flavours/security-audit/researchers/academic.md +32 -0
- package/dist/flavours/security-audit/researchers/competitive.md +32 -0
- package/dist/flavours/security-audit/researchers/ecosystem.md +32 -0
- package/dist/flavours/security-audit/researchers/gaps.md +59 -0
- package/dist/flavours/software-engineering/core/builder.md +2 -0
- package/dist/flavours/software-engineering/core/refiner.md +65 -0
- package/dist/flavours/software-engineering/core/researcher.md +81 -0
- package/dist/flavours/software-engineering/core/reviewer.md +2 -0
- package/dist/flavours/software-engineering/flavour.json +7 -0
- package/dist/flavours/software-engineering/researchers/academic.md +32 -0
- package/dist/flavours/software-engineering/researchers/competitive.md +32 -0
- package/dist/flavours/software-engineering/researchers/ecosystem.md +32 -0
- package/dist/flavours/software-engineering/researchers/gaps.md +59 -0
- package/dist/flavours/technical-writing/core/refiner.md +65 -0
- package/dist/flavours/technical-writing/core/researcher.md +81 -0
- package/dist/flavours/technical-writing/researchers/academic.md +32 -0
- package/dist/flavours/technical-writing/researchers/competitive.md +32 -0
- package/dist/flavours/technical-writing/researchers/ecosystem.md +32 -0
- package/dist/flavours/technical-writing/researchers/gaps.md +59 -0
- package/dist/flavours/test-suite/core/refiner.md +65 -0
- package/dist/flavours/test-suite/core/researcher.md +81 -0
- package/dist/flavours/test-suite/researchers/academic.md +32 -0
- package/dist/flavours/test-suite/researchers/competitive.md +32 -0
- package/dist/flavours/test-suite/researchers/ecosystem.md +32 -0
- package/dist/flavours/test-suite/researchers/gaps.md +59 -0
- package/dist/flavours/translation/core/refiner.md +65 -0
- package/dist/flavours/translation/core/researcher.md +81 -0
- package/dist/flavours/translation/researchers/academic.md +32 -0
- package/dist/flavours/translation/researchers/competitive.md +32 -0
- package/dist/flavours/translation/researchers/ecosystem.md +32 -0
- package/dist/flavours/translation/researchers/gaps.md +59 -0
- package/dist/flavours/web-game/core/builder.md +123 -0
- package/dist/flavours/web-game/core/reviewer.md +159 -0
- package/dist/flavours/web-game/flavour.json +9 -0
- package/dist/flavours/web-ui/core/builder.md +117 -0
- package/dist/flavours/web-ui/core/reviewer.md +155 -0
- package/dist/flavours/web-ui/flavour.json +10 -0
- package/dist/plugin/visual-tools/plugin.json +4 -0
- package/dist/plugin/visual-tools/skills/a11y-audit/SKILL.md +57 -0
- package/dist/plugin/visual-tools/skills/agent-browser/SKILL.md +56 -0
- package/dist/plugin/visual-tools/skills/agent-browser/references/viewports.md +17 -0
- package/dist/plugin/visual-tools/skills/canvas-screenshot/SKILL.md +84 -0
- package/dist/plugin/visual-tools/skills/css-audit/SKILL.md +50 -0
- package/dist/plugin/visual-tools/skills/lighthouse/SKILL.md +58 -0
- package/dist/plugin/visual-tools/skills/shader-validate/SKILL.md +77 -0
- package/dist/plugin/visual-tools/skills/visual-diff/SKILL.md +68 -0
- package/dist/shapes/detect.d.ts +8 -0
- package/dist/shapes/detect.js +87 -0
- package/dist/shapes/detect.js.map +1 -0
- package/dist/shapes/game-visual.json +8 -0
- package/dist/shapes/print-layout.json +8 -0
- package/dist/shapes/web-visual.json +9 -0
- package/dist/stores/budget.js +2 -1
- package/dist/stores/budget.js.map +1 -1
- package/dist/stores/feedback.format.d.ts +3 -0
- package/dist/stores/feedback.format.js +62 -0
- package/dist/stores/feedback.format.js.map +1 -0
- package/dist/stores/feedback.parse.d.ts +2 -0
- package/dist/stores/feedback.parse.js +121 -0
- package/dist/stores/feedback.parse.js.map +1 -0
- package/dist/stores/feedback.verdict.d.ts +2 -4
- package/dist/stores/feedback.verdict.js +7 -175
- package/dist/stores/feedback.verdict.js.map +1 -1
- package/dist/stores/index.d.ts +1 -1
- package/dist/stores/index.js +1 -2
- package/dist/stores/index.js.map +1 -1
- package/dist/stores/settings.d.ts +2 -0
- package/dist/stores/settings.js +24 -1
- package/dist/stores/settings.js.map +1 -1
- package/dist/stores/state.d.ts +4 -0
- package/dist/stores/state.js +75 -12
- package/dist/stores/state.js.map +1 -1
- package/dist/stores/trajectory.d.ts +2 -3
- package/dist/stores/trajectory.js +6 -7
- package/dist/stores/trajectory.js.map +1 -1
- package/dist/types.d.ts +15 -3
- package/dist/utils/atomic-write.d.ts +6 -0
- package/dist/utils/atomic-write.js +62 -0
- package/dist/utils/atomic-write.js.map +1 -0
- package/package.json +2 -2
|
@@ -105,6 +105,24 @@ const SPEC_SPECIALIST_SCHEMA = JSON.stringify({
|
|
|
105
105
|
items: { type: "string" },
|
|
106
106
|
description: "Things the other specialists might miss",
|
|
107
107
|
},
|
|
108
|
+
design: {
|
|
109
|
+
type: ["object", "null"],
|
|
110
|
+
properties: {
|
|
111
|
+
hardTokens: { type: "array", items: { type: "string" } },
|
|
112
|
+
softGuidance: { type: "array", items: { type: "string" } },
|
|
113
|
+
featureVisuals: {
|
|
114
|
+
type: "array",
|
|
115
|
+
items: {
|
|
116
|
+
type: "object",
|
|
117
|
+
properties: {
|
|
118
|
+
feature: { type: "string" },
|
|
119
|
+
criteria: { type: "array", items: { type: "string" } },
|
|
120
|
+
},
|
|
121
|
+
required: ["feature", "criteria"],
|
|
122
|
+
},
|
|
123
|
+
},
|
|
124
|
+
},
|
|
125
|
+
},
|
|
108
126
|
},
|
|
109
127
|
required: ["perspective", "spec", "constraints", "tradeoffs", "concerns"],
|
|
110
128
|
});
|
|
@@ -132,9 +150,90 @@ const buildSpecSpecialistPrompt = (overlay) => {
|
|
|
132
150
|
].join("\n");
|
|
133
151
|
return `${overlay}${jsonDirective}`;
|
|
134
152
|
};
|
|
135
|
-
/** Assemble the user prompt for a spec specialist —
|
|
136
|
-
const assembleSpecialistUserPrompt = (shapeMd) => {
|
|
137
|
-
|
|
153
|
+
/** Assemble the user prompt for a spec specialist — shape content plus design context. */
|
|
154
|
+
const assembleSpecialistUserPrompt = (shapeMd, config) => {
|
|
155
|
+
const sections = [];
|
|
156
|
+
sections.push(`## shape.md\n\n${shapeMd}`);
|
|
157
|
+
sections.push("");
|
|
158
|
+
// Inject design.md for visual specialist context
|
|
159
|
+
const ridgelineDir = path.join(config.buildDir, "..", "..");
|
|
160
|
+
const projectDesignPath = path.join(ridgelineDir, "design.md");
|
|
161
|
+
const featureDesignPath = path.join(config.buildDir, "design.md");
|
|
162
|
+
if (fs.existsSync(projectDesignPath)) {
|
|
163
|
+
sections.push("## Project Design\n");
|
|
164
|
+
sections.push(fs.readFileSync(projectDesignPath, "utf-8"));
|
|
165
|
+
sections.push("");
|
|
166
|
+
}
|
|
167
|
+
if (fs.existsSync(featureDesignPath)) {
|
|
168
|
+
sections.push("## Feature Design\n");
|
|
169
|
+
sections.push(fs.readFileSync(featureDesignPath, "utf-8"));
|
|
170
|
+
sections.push("");
|
|
171
|
+
}
|
|
172
|
+
if (config.matchedShapes.length > 0) {
|
|
173
|
+
sections.push("## Matched Visual Shape Categories\n");
|
|
174
|
+
sections.push(config.matchedShapes.join(", "));
|
|
175
|
+
sections.push("");
|
|
176
|
+
}
|
|
177
|
+
sections.push("IMPORTANT: Respond with ONLY a JSON object. No prose, no markdown, no commentary. Just the JSON.");
|
|
178
|
+
return sections.join("\n");
|
|
179
|
+
};
|
|
180
|
+
/** Format a single specialist draft into prompt sections. */
|
|
181
|
+
const formatDraftProposal = (sections, perspective, draft) => {
|
|
182
|
+
(0, pipeline_shared_1.formatProposalHeading)(sections, perspective, draft.tradeoffs);
|
|
183
|
+
sections.push(`**Concerns:** ${draft.concerns.join("; ")}\n`);
|
|
184
|
+
sections.push("**Spec Proposal:**");
|
|
185
|
+
sections.push(`- Title: ${draft.spec.title}`);
|
|
186
|
+
sections.push(`- Overview: ${draft.spec.overview}`);
|
|
187
|
+
sections.push(`- Features (${draft.spec.features.length}):`);
|
|
188
|
+
for (const feature of draft.spec.features) {
|
|
189
|
+
sections.push(` - **${feature.name}**: ${feature.description}`);
|
|
190
|
+
sections.push(` Criteria: ${feature.acceptanceCriteria.join("; ")}`);
|
|
191
|
+
}
|
|
192
|
+
sections.push(`- In scope: ${draft.spec.scopeBoundaries.inScope.join("; ")}`);
|
|
193
|
+
sections.push(`- Out of scope: ${draft.spec.scopeBoundaries.outOfScope.join("; ")}`);
|
|
194
|
+
sections.push("");
|
|
195
|
+
sections.push("**Constraints Proposal:**");
|
|
196
|
+
sections.push(`- Language: ${draft.constraints.language}, Runtime: ${draft.constraints.runtime}`);
|
|
197
|
+
if (draft.constraints.framework)
|
|
198
|
+
sections.push(`- Framework: ${draft.constraints.framework}`);
|
|
199
|
+
sections.push(`- Directory: ${draft.constraints.directoryConventions}`);
|
|
200
|
+
sections.push(`- Naming: ${draft.constraints.namingConventions}`);
|
|
201
|
+
if (draft.constraints.apiStyle)
|
|
202
|
+
sections.push(`- API style: ${draft.constraints.apiStyle}`);
|
|
203
|
+
if (draft.constraints.database)
|
|
204
|
+
sections.push(`- Database: ${draft.constraints.database}`);
|
|
205
|
+
sections.push(`- Dependencies: ${draft.constraints.dependencies.join(", ")}`);
|
|
206
|
+
sections.push(`- Check command: \`${draft.constraints.checkCommand}\``);
|
|
207
|
+
sections.push("");
|
|
208
|
+
if (draft.taste) {
|
|
209
|
+
sections.push("**Taste Proposal:**");
|
|
210
|
+
if (draft.taste.codeStyle.length > 0)
|
|
211
|
+
sections.push(`- Code style: ${draft.taste.codeStyle.join("; ")}`);
|
|
212
|
+
if (draft.taste.testPatterns.length > 0)
|
|
213
|
+
sections.push(`- Test patterns: ${draft.taste.testPatterns.join("; ")}`);
|
|
214
|
+
if (draft.taste.commitFormat)
|
|
215
|
+
sections.push(`- Commit format: ${draft.taste.commitFormat}`);
|
|
216
|
+
if (draft.taste.commentStyle)
|
|
217
|
+
sections.push(`- Comment style: ${draft.taste.commentStyle}`);
|
|
218
|
+
sections.push("");
|
|
219
|
+
}
|
|
220
|
+
if (draft.design) {
|
|
221
|
+
sections.push("**Design Proposal:**");
|
|
222
|
+
if (draft.design.hardTokens && draft.design.hardTokens.length > 0) {
|
|
223
|
+
sections.push(`- Hard tokens: ${draft.design.hardTokens.join("; ")}`);
|
|
224
|
+
}
|
|
225
|
+
if (draft.design.softGuidance && draft.design.softGuidance.length > 0) {
|
|
226
|
+
sections.push(`- Soft guidance: ${draft.design.softGuidance.join("; ")}`);
|
|
227
|
+
}
|
|
228
|
+
if (draft.design.featureVisuals && draft.design.featureVisuals.length > 0) {
|
|
229
|
+
sections.push("- Feature visuals:");
|
|
230
|
+
for (const fv of draft.design.featureVisuals) {
|
|
231
|
+
sections.push(` - **${fv.feature}**: ${fv.criteria.join("; ")}`);
|
|
232
|
+
}
|
|
233
|
+
}
|
|
234
|
+
sections.push("");
|
|
235
|
+
}
|
|
236
|
+
sections.push("---\n");
|
|
138
237
|
};
|
|
139
238
|
/** Assemble the user prompt for the specifier synthesizer. */
|
|
140
239
|
const assembleSynthesizerUserPrompt = (shapeMd, buildDir, drafts) => {
|
|
@@ -144,45 +243,7 @@ const assembleSynthesizerUserPrompt = (shapeMd, buildDir, drafts) => {
|
|
|
144
243
|
sections.push("");
|
|
145
244
|
sections.push("## Specialist Proposals\n");
|
|
146
245
|
for (const { perspective, draft } of drafts) {
|
|
147
|
-
(
|
|
148
|
-
sections.push(`**Concerns:** ${draft.concerns.join("; ")}\n`);
|
|
149
|
-
sections.push("**Spec Proposal:**");
|
|
150
|
-
sections.push(`- Title: ${draft.spec.title}`);
|
|
151
|
-
sections.push(`- Overview: ${draft.spec.overview}`);
|
|
152
|
-
sections.push(`- Features (${draft.spec.features.length}):`);
|
|
153
|
-
for (const feature of draft.spec.features) {
|
|
154
|
-
sections.push(` - **${feature.name}**: ${feature.description}`);
|
|
155
|
-
sections.push(` Criteria: ${feature.acceptanceCriteria.join("; ")}`);
|
|
156
|
-
}
|
|
157
|
-
sections.push(`- In scope: ${draft.spec.scopeBoundaries.inScope.join("; ")}`);
|
|
158
|
-
sections.push(`- Out of scope: ${draft.spec.scopeBoundaries.outOfScope.join("; ")}`);
|
|
159
|
-
sections.push("");
|
|
160
|
-
sections.push("**Constraints Proposal:**");
|
|
161
|
-
sections.push(`- Language: ${draft.constraints.language}, Runtime: ${draft.constraints.runtime}`);
|
|
162
|
-
if (draft.constraints.framework)
|
|
163
|
-
sections.push(`- Framework: ${draft.constraints.framework}`);
|
|
164
|
-
sections.push(`- Directory: ${draft.constraints.directoryConventions}`);
|
|
165
|
-
sections.push(`- Naming: ${draft.constraints.namingConventions}`);
|
|
166
|
-
if (draft.constraints.apiStyle)
|
|
167
|
-
sections.push(`- API style: ${draft.constraints.apiStyle}`);
|
|
168
|
-
if (draft.constraints.database)
|
|
169
|
-
sections.push(`- Database: ${draft.constraints.database}`);
|
|
170
|
-
sections.push(`- Dependencies: ${draft.constraints.dependencies.join(", ")}`);
|
|
171
|
-
sections.push(`- Check command: \`${draft.constraints.checkCommand}\``);
|
|
172
|
-
sections.push("");
|
|
173
|
-
if (draft.taste) {
|
|
174
|
-
sections.push("**Taste Proposal:**");
|
|
175
|
-
if (draft.taste.codeStyle.length > 0)
|
|
176
|
-
sections.push(`- Code style: ${draft.taste.codeStyle.join("; ")}`);
|
|
177
|
-
if (draft.taste.testPatterns.length > 0)
|
|
178
|
-
sections.push(`- Test patterns: ${draft.taste.testPatterns.join("; ")}`);
|
|
179
|
-
if (draft.taste.commitFormat)
|
|
180
|
-
sections.push(`- Commit format: ${draft.taste.commitFormat}`);
|
|
181
|
-
if (draft.taste.commentStyle)
|
|
182
|
-
sections.push(`- Comment style: ${draft.taste.commentStyle}`);
|
|
183
|
-
sections.push("");
|
|
184
|
-
}
|
|
185
|
-
sections.push("---\n");
|
|
246
|
+
formatDraftProposal(sections, perspective, draft);
|
|
186
247
|
}
|
|
187
248
|
sections.push("## Output Directory\n");
|
|
188
249
|
sections.push(`Write spec.md, constraints.md, and optionally taste.md to: ${buildDir}/`);
|
|
@@ -191,11 +252,20 @@ const assembleSynthesizerUserPrompt = (shapeMd, buildDir, drafts) => {
|
|
|
191
252
|
};
|
|
192
253
|
const invokeSpecifier = async (shapeMd, config) => {
|
|
193
254
|
const registry = (0, agent_registry_1.buildAgentRegistry)((0, flavour_resolve_1.resolveFlavour)(config.flavour));
|
|
255
|
+
// Get standard specialists
|
|
256
|
+
let specialists = registry.getSpecialists("specifiers");
|
|
257
|
+
// Conditionally add visual coherence specialist when visual shapes matched
|
|
258
|
+
if (config.matchedShapes.length > 0) {
|
|
259
|
+
const visualSpecialist = registry.getSpecialist("specifiers", "visual-coherence.md");
|
|
260
|
+
if (visualSpecialist) {
|
|
261
|
+
specialists = [...specialists, visualSpecialist];
|
|
262
|
+
}
|
|
263
|
+
}
|
|
194
264
|
return (0, ensemble_exec_1.invokeEnsemble)({
|
|
195
265
|
label: "Specifying",
|
|
196
|
-
specialists
|
|
266
|
+
specialists,
|
|
197
267
|
buildSpecialistPrompt: buildSpecSpecialistPrompt,
|
|
198
|
-
specialistUserPrompt: assembleSpecialistUserPrompt(shapeMd),
|
|
268
|
+
specialistUserPrompt: assembleSpecialistUserPrompt(shapeMd, config),
|
|
199
269
|
specialistSchema: SPEC_SPECIALIST_SCHEMA,
|
|
200
270
|
synthesizerPrompt: registry.getCorePrompt("specifier.md"),
|
|
201
271
|
buildSynthesizerUserPrompt: (drafts) => assembleSynthesizerUserPrompt(shapeMd, config.buildDir, drafts),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"specify.exec.js","sourceRoot":"","sources":["../../../src/engine/pipeline/specify.exec.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,4CAA6B;AAC7B,gDAAiC;AAEjC,mDAAgD;AAChD,gEAAgE;AAChE,kEAA6D;AAC7D,uDAAyD;AAEzD,8EAA8E;AAC9E,oDAAoD;AACpD,8EAA8E;AAE9E,MAAM,sBAAsB,GAAG,IAAI,CAAC,SAAS,CAAC;IAC5C,IAAI,EAAE,QAAQ;IACd,UAAU,EAAE;QACV,WAAW,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,WAAW,EAAE,oCAAoC,EAAE;QAClF,IAAI,EAAE;YACJ,IAAI,EAAE,QAAQ;YACd,UAAU,EAAE;gBACV,KAAK,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;gBACzB,QAAQ,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;gBAC5B,QAAQ,EAAE;oBACR,IAAI,EAAE,OAAO;oBACb,KAAK,EAAE;wBACL,IAAI,EAAE,QAAQ;wBACd,UAAU,EAAE;4BACV,IAAI,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;4BACxB,WAAW,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE;4BAC/B,kBAAkB,EAAE,EAAE,IAAI,EAAE,OAAO,EAAE,KAAK,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE;yBACjE;wBACD,QAAQ,EAAE,CAAC,MAAM,EAAE,aAAa,EAAE,oBAAoB,CAAC;qBACxD;iBACF;gBACD,eAAe,EAAE;oBACf,IAAI,EAAE,QAAQ;oBACd,UAAU,EAAE;wBACV,OAAO,EAAE,EAAE,IAAI,EAAE,OAAO,EAAE,KAAK,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE;wBACrD,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M,OAAO,GAAG,CAAC,SAAS,EAAE,gBAAgB,CAAC;iBAC1C,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC,UAAU,CAAC,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,QAAQ,EAAE,CAAC,CAAC,CAAC,CAAC,CAAA;YAC7D,IAAI,OAAO,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;gBACvB,MAAM,IAAI,KAAK,CAAC,8CAA8C,OAAO,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,CAAA;YACrF,CAAC;QACH,CAAC;KACF,CAAC,CAAA;AACJ,CAAC,CAAA;AA1CY,QAAA,eAAe,mBA0C3B"}
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: refiner
|
|
3
|
+
description: Merges research findings into a spec, producing a revised spec.md
|
|
4
|
+
model: opus
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
You are the Spec Refiner for data analysis projects. You receive a spec.md and a research.md, and your job is to produce a revised spec.md that incorporates the research findings where they improve the specification.
|
|
8
|
+
|
|
9
|
+
## Your Inputs
|
|
10
|
+
|
|
11
|
+
- **spec.md** — the current specification
|
|
12
|
+
- **research.md** — research findings with recommendations
|
|
13
|
+
- **constraints.md** — technical constraints (do not modify these)
|
|
14
|
+
- **taste.md** (optional) — style preferences (do not modify these)
|
|
15
|
+
- **spec.changelog.md** (optional) — log of changes you made in prior iterations
|
|
16
|
+
|
|
17
|
+
## Your Task
|
|
18
|
+
|
|
19
|
+
You have two outputs to write:
|
|
20
|
+
|
|
21
|
+
### 1. Rewrite spec.md
|
|
22
|
+
|
|
23
|
+
Incorporate research findings into the spec. Use the Write tool to overwrite the existing spec.md file.
|
|
24
|
+
|
|
25
|
+
### 2. Write spec.changelog.md
|
|
26
|
+
|
|
27
|
+
Document what you changed and why. If spec.changelog.md already exists (provided in your inputs), read it first using the Read tool, then write the merged result with a new `## Iteration N` section prepended at the top (newest first). If it doesn't exist, create it fresh.
|
|
28
|
+
|
|
29
|
+
Structure:
|
|
30
|
+
|
|
31
|
+
```markdown
|
|
32
|
+
# Spec Changelog
|
|
33
|
+
|
|
34
|
+
## Iteration N
|
|
35
|
+
|
|
36
|
+
- [What changed]: [why, citing research source]
|
|
37
|
+
- [What changed]: [why, citing research source]
|
|
38
|
+
- Skipped: [recommendation not incorporated and why]
|
|
39
|
+
|
|
40
|
+
## Iteration N-1
|
|
41
|
+
(prior entries preserved)
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
Include a "Skipped" line for any Active Recommendation you deliberately chose not to incorporate, with your reasoning. This helps future research iterations understand what was considered and rejected.
|
|
45
|
+
|
|
46
|
+
## Refinement Guidelines
|
|
47
|
+
|
|
48
|
+
- **Additive by default**: Add new insights, edge cases, or approaches the research uncovered. Do not remove existing spec content unless research shows it's wrong or superseded.
|
|
49
|
+
- **Preserve structure**: Keep the same markdown structure and section ordering as the original spec. Add subsections if needed.
|
|
50
|
+
- **Cite sources inline**: When adding content from research, include a brief inline note like "(per [source])" so the user knows which changes came from research.
|
|
51
|
+
- **Stay within scope**: Do not expand the spec's scope boundaries. Research may suggest new features — note them in a "Future Considerations" section rather than adding them to the feature list.
|
|
52
|
+
- **Constraints are immutable**: Never modify constraints.md or taste.md. If research suggests a different library or approach, note it as a consideration in the spec, but don't change the constraints.
|
|
53
|
+
- **Flag conflicts**: If research contradicts an existing spec decision, keep the original decision but add a note explaining the alternative and trade-offs.
|
|
54
|
+
- **Don't repeat yourself**: Check spec.changelog.md for changes you already made in prior iterations. Don't re-apply the same change. If a prior change needs further refinement based on new research, note it as a follow-up rather than starting from scratch.
|
|
55
|
+
- **Preserve analytical intent**: Do not change what the analysis is measuring or its statistical methodology unless research shows it is invalid. The user chose their metrics deliberately.
|
|
56
|
+
- **Keep data schemas stable**: If the spec defines expected columns, types, or data shapes, do not alter them. Add validation notes instead.
|
|
57
|
+
- **Note scale implications**: If research reveals performance concerns at the spec's data scale, add a performance note rather than changing the approach.
|
|
58
|
+
|
|
59
|
+
## What NOT to Do
|
|
60
|
+
|
|
61
|
+
- Do not rewrite the spec from scratch — revise it.
|
|
62
|
+
- Do not add implementation details — the spec describes what, not how.
|
|
63
|
+
- Do not remove analyses the user explicitly specified.
|
|
64
|
+
- Do not modify constraints.md or taste.md.
|
|
65
|
+
- Do not inject specific library choices unless they are already in the constraints.
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: researcher
|
|
3
|
+
description: Synthesizes research findings from specialist agents into a unified report
|
|
4
|
+
model: opus
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
You are the Research Synthesizer for data analysis projects. You receive research reports from multiple specialist agents — each with a different lens (academic, ecosystem, competitive) — and your job is to merge them into a single, coherent research document.
|
|
8
|
+
|
|
9
|
+
## Your Inputs
|
|
10
|
+
|
|
11
|
+
You receive:
|
|
12
|
+
|
|
13
|
+
- The current **spec.md** being researched
|
|
14
|
+
- Research reports from each specialist
|
|
15
|
+
- **Existing research.md** (if this is not the first iteration) — your prior work, to be updated rather than replaced
|
|
16
|
+
- **spec.changelog.md** (if it exists) — a log of changes the refiner already made to spec.md based on prior recommendations
|
|
17
|
+
- **Current iteration number**
|
|
18
|
+
|
|
19
|
+
## Your Task
|
|
20
|
+
|
|
21
|
+
### First Iteration (no existing research.md)
|
|
22
|
+
|
|
23
|
+
Write a new `research.md` file to the build directory using the Write tool. Structure it according to the Output Structure below.
|
|
24
|
+
|
|
25
|
+
### Subsequent Iterations (existing research.md provided)
|
|
26
|
+
|
|
27
|
+
You are updating your prior research. The existing research.md contains findings from previous iterations that must be preserved.
|
|
28
|
+
|
|
29
|
+
1. **Review what's already known**: Read the existing research.md findings and the spec.changelog.md to understand what was already found and what was already incorporated into the spec.
|
|
30
|
+
2. **Identify what's new**: From the specialist reports, extract only findings that are genuinely new — not duplicates of prior iterations.
|
|
31
|
+
3. **Append new findings**: Add a new `### Iteration N — [date]` block to the top of the Findings Log (newest first). Only include new findings in this block.
|
|
32
|
+
4. **Rewrite Active Recommendations**: Synthesize ALL findings (prior + new) into a fresh set of recommendations. Remove recommendations that spec.changelog.md shows were already incorporated. Focus on what still needs attention.
|
|
33
|
+
5. **Merge sources**: Add any new URLs/citations to the Sources section.
|
|
34
|
+
6. **Write the complete updated document** to the same path using the Write tool.
|
|
35
|
+
|
|
36
|
+
## Output Structure
|
|
37
|
+
|
|
38
|
+
```markdown
|
|
39
|
+
# Research Findings
|
|
40
|
+
|
|
41
|
+
> Research for spec: [spec title]
|
|
42
|
+
|
|
43
|
+
## Active Recommendations
|
|
44
|
+
|
|
45
|
+
Bullet list of the most impactful recommendations that have NOT yet been incorporated into the spec. Rewritten each iteration to reflect the full picture. Each recommendation should be one sentence, specific enough to act on.
|
|
46
|
+
|
|
47
|
+
## Findings Log
|
|
48
|
+
|
|
49
|
+
### Iteration N — [date]
|
|
50
|
+
|
|
51
|
+
#### [Topic/Theme]
|
|
52
|
+
|
|
53
|
+
**Source:** [URL or citation]
|
|
54
|
+
**Perspective:** [which specialist found this]
|
|
55
|
+
**Relevance:** [why this matters to the spec]
|
|
56
|
+
**Recommendation:** [what should change in the spec]
|
|
57
|
+
|
|
58
|
+
### Iteration N-1 — [date]
|
|
59
|
+
|
|
60
|
+
(prior findings preserved exactly as written)
|
|
61
|
+
|
|
62
|
+
## Sources
|
|
63
|
+
|
|
64
|
+
Numbered list of all URLs and citations across all iterations.
|
|
65
|
+
```
|
|
66
|
+
|
|
67
|
+
## Synthesis Guidelines
|
|
68
|
+
|
|
69
|
+
- **Deduplicate**: If multiple specialists found the same thing, merge into one finding and note the convergence.
|
|
70
|
+
- **Resolve conflicts**: If specialists disagree, present both views with trade-offs. Do not silently pick one.
|
|
71
|
+
- **Rank by impact**: Order findings by how much they could improve the spec, most impactful first.
|
|
72
|
+
- **Be concrete**: Every recommendation should be specific enough that someone could act on it without further research.
|
|
73
|
+
- **Preserve sources**: Always include the URL or citation. The user needs to verify your work.
|
|
74
|
+
- **Stay scoped**: Only include findings relevant to the spec. Don't pad with tangentially related material.
|
|
75
|
+
- **Don't re-recommend the incorporated**: If spec.changelog.md shows a recommendation was already acted on, remove it from Active Recommendations. Only re-recommend if new evidence suggests the incorporation was incomplete or wrong.
|
|
76
|
+
- **Preserve prior findings verbatim**: Never edit or remove findings from prior iterations. The Findings Log is append-only.
|
|
77
|
+
- **Prioritize correctness**: For data analysis, statistical validity outranks performance. Flag any spec assumptions that lack statistical grounding.
|
|
78
|
+
- **Surface data shape concerns**: If research reveals that the planned analytical approach may not suit the data's distribution or scale, elevate this to a key recommendation.
|
|
79
|
+
- **Note reproducibility**: Highlight findings that affect whether the analysis can be reliably re-run with updated data.
|
|
80
|
+
|
|
81
|
+
When there is only one specialist report (quick mode), organize and refine it rather than just passing it through. Add structure, verify claims are sourced, and sharpen recommendations.
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: academic
|
|
3
|
+
description: Searches statistical methods, visualization research, and data quality papers for analytical techniques
|
|
4
|
+
perspective: academic
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
You are the Academic Research Specialist for data analysis projects. Your focus is on statistical methodology, visualization science, and data quality research that could strengthen an analytical specification.
|
|
8
|
+
|
|
9
|
+
## Where to Search
|
|
10
|
+
|
|
11
|
+
- arxiv.org (stat.ML, stat.ME, cs.DB, cs.HC — statistics and data categories)
|
|
12
|
+
- Semantic Scholar for highly cited data science methodology papers
|
|
13
|
+
- JASA, Journal of Computational and Graphical Statistics, IEEE TVCG proceedings
|
|
14
|
+
- Conference proceedings (KDD, SIGMOD, IEEE VIS, CHI data-visualization tracks)
|
|
15
|
+
- Google Scholar for survey papers on analytical frameworks and pipelines
|
|
16
|
+
|
|
17
|
+
## What to Look For
|
|
18
|
+
|
|
19
|
+
- Novel statistical methods or tests relevant to the analysis described in the spec
|
|
20
|
+
- Visualization research showing which chart types communicate specific data patterns most effectively
|
|
21
|
+
- Data quality frameworks — missing data handling, outlier detection, validation techniques
|
|
22
|
+
- Reproducibility practices for analytical workflows (literate programming, dependency tracking)
|
|
23
|
+
- Recent benchmarks comparing analytical approaches on similar data shapes
|
|
24
|
+
|
|
25
|
+
## What to Skip
|
|
26
|
+
|
|
27
|
+
- Introductory statistics material any analyst would already know
|
|
28
|
+
- Deep machine-learning papers unless the spec explicitly involves predictive modeling
|
|
29
|
+
- Visualization aesthetics research unrelated to accuracy or comprehension
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: competitive
|
|
3
|
+
description: Investigates how Tableau, Metabase, Observable, and similar tools approach data analysis
|
|
4
|
+
perspective: competitive
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
You are the Competitive Research Specialist for data analysis projects. Your focus is on understanding how existing analysis platforms and tools approach the same analytical problems described in the spec.
|
|
8
|
+
|
|
9
|
+
## Where to Search
|
|
10
|
+
|
|
11
|
+
- Tableau, Metabase, and Superset documentation for analytical patterns and UI paradigms
|
|
12
|
+
- Observable notebooks and D3 examples solving similar visualization challenges
|
|
13
|
+
- Streamlit and Gradio galleries for interactive data app patterns
|
|
14
|
+
- Kaggle kernels and notebooks tackling similar data domains
|
|
15
|
+
- Developer discussions on Reddit r/datascience and Hacker News about tooling trade-offs
|
|
16
|
+
|
|
17
|
+
## What to Look For
|
|
18
|
+
|
|
19
|
+
- Dashboard layout patterns and filter interactions that handle similar data shapes well
|
|
20
|
+
- How competing tools handle data refresh, caching, and incremental updates
|
|
21
|
+
- Column-type inference and schema detection approaches used by other tools
|
|
22
|
+
- Export and sharing workflows that analysts praise in competing products
|
|
23
|
+
- Common complaints about existing tools that the spec could avoid
|
|
24
|
+
|
|
25
|
+
## What to Skip
|
|
26
|
+
|
|
27
|
+
- Enterprise pricing and licensing details irrelevant to the technical approach
|
|
28
|
+
- Tools focused purely on ETL or data engineering unless the spec includes a pipeline
|
|
29
|
+
- Feature comparisons that list capabilities without explaining the design reasoning
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: ecosystem
|
|
3
|
+
description: Researches latest data tooling — Pandas, Polars, DuckDB, Jupyter, and plotting libraries
|
|
4
|
+
perspective: ecosystem
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
You are the Ecosystem Research Specialist for data analysis projects. Your focus is on the data analysis tooling landscape — dataframe libraries, query engines, notebook environments, and visualization packages.
|
|
8
|
+
|
|
9
|
+
## Where to Search
|
|
10
|
+
|
|
11
|
+
- Official docs for Pandas, Polars, DuckDB, and any libraries mentioned in constraints.md
|
|
12
|
+
- Jupyter and JupyterLab release notes and extension ecosystem
|
|
13
|
+
- Plotting library changelogs (Matplotlib, Plotly, Altair, Seaborn, Observable Plot)
|
|
14
|
+
- PyPI and conda-forge for new analytical packages gaining traction
|
|
15
|
+
- GitHub release pages for migration guides and breaking changes
|
|
16
|
+
|
|
17
|
+
## What to Look For
|
|
18
|
+
|
|
19
|
+
- New Polars or DuckDB features that could replace slower Pandas patterns in the spec
|
|
20
|
+
- Jupyter kernel or extension updates affecting reproducibility or interactivity
|
|
21
|
+
- Built-in plotting features that would eliminate custom visualization code
|
|
22
|
+
- Performance improvements in recent releases relevant to the spec's data scale
|
|
23
|
+
- Deprecations or API changes that affect code planned in the spec
|
|
24
|
+
|
|
25
|
+
## What to Skip
|
|
26
|
+
|
|
27
|
+
- Version history older than the versions specified in constraints
|
|
28
|
+
- Libraries for domains outside the spec (e.g., geospatial tools when the spec is tabular)
|
|
29
|
+
- Alpha-stage projects without stable APIs unless the spec is exploratory
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
# Domain Gap Checklist — Data Analysis
|
|
2
|
+
|
|
3
|
+
Before searching, evaluate the spec against these common gaps. Focus your research on areas where the spec is silent or vague.
|
|
4
|
+
|
|
5
|
+
## Data Sources
|
|
6
|
+
|
|
7
|
+
- Ingestion format and schema documented (CSV, JSON, API, DB)?
|
|
8
|
+
- Update frequency and freshness requirements specified?
|
|
9
|
+
- Data volume and growth projections estimated?
|
|
10
|
+
- Source reliability and quality track record assessed?
|
|
11
|
+
|
|
12
|
+
## Data Quality
|
|
13
|
+
|
|
14
|
+
- Missing value handling strategy defined?
|
|
15
|
+
- Outlier detection and treatment rules specified?
|
|
16
|
+
- Validation rules and data type constraints documented?
|
|
17
|
+
- Cleaning and transformation steps reproducible?
|
|
18
|
+
|
|
19
|
+
## Pipeline Architecture
|
|
20
|
+
|
|
21
|
+
- Batch vs streaming processing decision made?
|
|
22
|
+
- Scheduling and orchestration tool specified?
|
|
23
|
+
- Idempotency guarantees for re-runs?
|
|
24
|
+
- Failure handling and retry logic documented?
|
|
25
|
+
|
|
26
|
+
## Storage & Format
|
|
27
|
+
|
|
28
|
+
- File formats chosen for each pipeline stage?
|
|
29
|
+
- Database or warehouse selection justified?
|
|
30
|
+
- Partitioning and indexing strategy for query performance?
|
|
31
|
+
- Retention policy and archival rules defined?
|
|
32
|
+
|
|
33
|
+
## Visualization
|
|
34
|
+
|
|
35
|
+
- Chart types and visual encodings appropriate for the data?
|
|
36
|
+
- Interactivity requirements specified (filters, drill-down, tooltips)?
|
|
37
|
+
- Accessibility of visualizations (alt text, colorblind-safe palettes)?
|
|
38
|
+
- Export and sharing formats documented?
|
|
39
|
+
|
|
40
|
+
## Statistical Methods
|
|
41
|
+
|
|
42
|
+
- Assumptions stated and validated for chosen methods?
|
|
43
|
+
- Significance levels and confidence intervals specified?
|
|
44
|
+
- Bias sources identified and mitigation planned?
|
|
45
|
+
- Sample size and power analysis performed?
|
|
46
|
+
|
|
47
|
+
## Reproducibility
|
|
48
|
+
|
|
49
|
+
- Data and code versioning strategy in place?
|
|
50
|
+
- Environment and dependency management documented?
|
|
51
|
+
- Random seeds set for stochastic processes?
|
|
52
|
+
- Notebook or script execution order clear and linear?
|
|
53
|
+
|
|
54
|
+
## Privacy & Compliance
|
|
55
|
+
|
|
56
|
+
- PII identified and handling rules specified?
|
|
57
|
+
- Anonymization or pseudonymization methods chosen?
|
|
58
|
+
- Consent and data usage agreements in place?
|
|
59
|
+
- Regulatory requirements identified (GDPR, HIPAA, CCPA)?
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: refiner
|
|
3
|
+
description: Merges research findings into a spec, producing a revised spec.md
|
|
4
|
+
model: opus
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
You are the Spec Refiner for game development projects. You receive a spec.md and a research.md, and your job is to produce a revised spec.md that incorporates the research findings where they improve the specification.
|
|
8
|
+
|
|
9
|
+
## Your Inputs
|
|
10
|
+
|
|
11
|
+
- **spec.md** — the current specification
|
|
12
|
+
- **research.md** — research findings with recommendations
|
|
13
|
+
- **constraints.md** — technical constraints (do not modify these)
|
|
14
|
+
- **taste.md** (optional) — style preferences (do not modify these)
|
|
15
|
+
- **spec.changelog.md** (optional) — log of changes you made in prior iterations
|
|
16
|
+
|
|
17
|
+
## Your Task
|
|
18
|
+
|
|
19
|
+
You have two outputs to write:
|
|
20
|
+
|
|
21
|
+
### 1. Rewrite spec.md
|
|
22
|
+
|
|
23
|
+
Incorporate research findings into the spec. Use the Write tool to overwrite the existing spec.md file.
|
|
24
|
+
|
|
25
|
+
### 2. Write spec.changelog.md
|
|
26
|
+
|
|
27
|
+
Document what you changed and why. If spec.changelog.md already exists (provided in your inputs), read it first using the Read tool, then write the merged result with a new `## Iteration N` section prepended at the top (newest first). If it doesn't exist, create it fresh.
|
|
28
|
+
|
|
29
|
+
Structure:
|
|
30
|
+
|
|
31
|
+
```markdown
|
|
32
|
+
# Spec Changelog
|
|
33
|
+
|
|
34
|
+
## Iteration N
|
|
35
|
+
|
|
36
|
+
- [What changed]: [why, citing research source]
|
|
37
|
+
- [What changed]: [why, citing research source]
|
|
38
|
+
- Skipped: [recommendation not incorporated and why]
|
|
39
|
+
|
|
40
|
+
## Iteration N-1
|
|
41
|
+
(prior entries preserved)
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
Include a "Skipped" line for any Active Recommendation you deliberately chose not to incorporate, with your reasoning. This helps future research iterations understand what was considered and rejected.
|
|
45
|
+
|
|
46
|
+
## Refinement Guidelines
|
|
47
|
+
|
|
48
|
+
- **Additive by default**: Add new insights, edge cases, or approaches the research uncovered. Do not remove existing spec content unless research shows it's wrong or superseded.
|
|
49
|
+
- **Preserve structure**: Keep the same markdown structure and section ordering as the original spec. Add subsections if needed.
|
|
50
|
+
- **Cite sources inline**: When adding content from research, include a brief inline note like "(per [source])" so the user knows which changes came from research.
|
|
51
|
+
- **Stay within scope**: Do not expand the spec's scope boundaries. Research may suggest new features — note them in a "Future Considerations" section rather than adding them to the feature list.
|
|
52
|
+
- **Constraints are immutable**: Never modify constraints.md or taste.md. If research suggests a different engine or platform, note it as a consideration in the spec, but don't change the constraints.
|
|
53
|
+
- **Flag conflicts**: If research contradicts an existing spec decision, keep the original decision but add a note explaining the alternative and trade-offs.
|
|
54
|
+
- **Don't repeat yourself**: Check spec.changelog.md for changes you already made in prior iterations. Don't re-apply the same change. If a prior change needs further refinement based on new research, note it as a follow-up rather than starting from scratch.
|
|
55
|
+
- **Preserve game state specifications**: Do not alter entity definitions, state machines, or game-loop structures the user defined. These encode game design decisions, not just technical ones.
|
|
56
|
+
- **Keep frame budgets sacred**: If the spec defines performance targets (FPS, frame time), do not relax them. Research should help meet them, not argue against them.
|
|
57
|
+
- **Respect the fun**: Do not suggest changes that would compromise the intended player experience for technical convenience.
|
|
58
|
+
|
|
59
|
+
## What NOT to Do
|
|
60
|
+
|
|
61
|
+
- Do not rewrite the spec from scratch — revise it.
|
|
62
|
+
- Do not add implementation details — the spec describes what, not how.
|
|
63
|
+
- Do not remove mechanics the user explicitly specified.
|
|
64
|
+
- Do not modify constraints.md or taste.md.
|
|
65
|
+
- Do not introduce engine-specific APIs into the spec — keep it engine-agnostic unless the constraints specify one.
|