@neonwatty/limner 0.1.1 → 0.1.3
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 +25 -26
- package/dist/cli.js +3 -1
- package/dist/cli.js.map +1 -1
- package/dist/commands/compare-image-reference.d.ts +3 -0
- package/dist/commands/compare-image-reference.js +26 -3
- package/dist/commands/compare-image-reference.js.map +1 -1
- package/dist/commands/compare.d.ts +4 -1
- package/dist/commands/compare.js +72 -45
- package/dist/commands/compare.js.map +1 -1
- package/dist/core/agent-comparison-fingerprint.d.ts +12 -0
- package/dist/core/agent-comparison-fingerprint.js +27 -0
- package/dist/core/agent-comparison-fingerprint.js.map +1 -0
- package/dist/core/agent-comparison-pack.d.ts +30 -0
- package/dist/core/agent-comparison-pack.js +148 -0
- package/dist/core/agent-comparison-pack.js.map +1 -0
- package/dist/core/agent-comparison-profiles.d.ts +9 -0
- package/dist/core/agent-comparison-profiles.js +19 -0
- package/dist/core/agent-comparison-profiles.js.map +1 -0
- package/dist/core/agent-comparison-prompts.d.ts +22 -0
- package/dist/core/agent-comparison-prompts.js +84 -0
- package/dist/core/agent-comparison-prompts.js.map +1 -0
- package/dist/core/agent-comparison-report.d.ts +3 -0
- package/dist/core/agent-comparison-report.js +56 -0
- package/dist/core/agent-comparison-report.js.map +1 -0
- package/dist/core/agent-comparison-validation.d.ts +2 -0
- package/dist/core/agent-comparison-validation.js +8 -0
- package/dist/core/agent-comparison-validation.js.map +1 -0
- package/dist/core/playwright-capture.js +1 -1
- package/dist/core/playwright-capture.js.map +1 -1
- package/dist/core/report-writer.d.ts +7 -11
- package/dist/core/report-writer.js +20 -42
- package/dist/core/report-writer.js.map +1 -1
- package/dist/core/workspace.d.ts +1 -0
- package/dist/core/workspace.js +13 -2
- package/dist/core/workspace.js.map +1 -1
- package/dist/index.d.ts +4 -2
- package/dist/index.js +3 -2
- package/dist/index.js.map +1 -1
- package/dist/schemas/comparison.d.ts +349 -0
- package/dist/schemas/comparison.js +211 -0
- package/dist/schemas/comparison.js.map +1 -0
- package/dist/schemas/visual-spec.d.ts +8 -8
- package/dist/schemas/visual-spec.js +2 -2
- package/dist/schemas/visual-spec.js.map +1 -1
- package/docs/agent-workflow.md +18 -31
- package/docs/superpowers/plans/2026-06-12-agent-comparison-scores.md +209 -0
- package/package.json +1 -1
- package/skills/limner/SKILL.md +15 -18
- package/templates/target/AGENT_GUIDE.md +12 -8
- package/dist/commands/compare-image-app.d.ts +0 -12
- package/dist/commands/compare-image-app.js +0 -45
- package/dist/commands/compare-image-app.js.map +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"comparison.js","sourceRoot":"","sources":["../../src/schemas/comparison.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,MAAM,aAAa,GAAG,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;AAE/C,MAAM,qBAAqB,GAAG,CAAC,CAAC,MAAM,CAAC;IACrC,OAAO,EAAE,aAAa;IACtB,MAAM,EAAE,aAAa,CAAC,QAAQ,EAAE;IAChC,SAAS,EAAE,aAAa,CAAC,QAAQ,EAAE;IACnC,UAAU,EAAE,aAAa,CAAC,QAAQ,EAAE;IACpC,KAAK,EAAE,aAAa,CAAC,QAAQ,EAAE;IAC/B,OAAO,EAAE,aAAa,CAAC,QAAQ,EAAE;IACjC,SAAS,EAAE,aAAa,CAAC,QAAQ,EAAE;IACnC,SAAS,EAAE,aAAa,CAAC,QAAQ,EAAE;CACpC,CAAC,CAAC;AAEH,MAAM,UAAU,GAAG,CAAC,CAAC,MAAM,EAAE,CAAC,KAAK,CAAC,gBAAgB,CAAC,CAAC;AAEtD,MAAM,sBAAsB,GAAG,CAAC,CAAC,MAAM,CAAC;IACtC,mBAAmB,EAAE,UAAU;IAC/B,iBAAiB,EAAE,UAAU;IAC7B,uBAAuB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AC,MAAM,CAAC,EAAE,CAAC;QACnC,iBAAiB,EAAE,GAAG,CAAC,MAAM,CAAC,EAAE,CAAC;KAClC,CAAC;IACF,IAAI,IAAI,KAAK,YAAY;QAAE,OAAO,KAAK,CAAC;IACxC,OAAO;QACL,GAAG,KAAK;QACR,uBAAuB,EAAE,GAAG,CAAC,MAAM,CAAC,EAAE,CAAC;QACvC,qBAAqB,EAAE,GAAG,CAAC,MAAM,CAAC,EAAE,CAAC;KACtC,CAAC;AACJ,CAAC"}
|
|
@@ -40,8 +40,8 @@ export declare const visualSpecSchema: z.ZodObject<{
|
|
|
40
40
|
role: z.ZodEnum<{
|
|
41
41
|
unknown: "unknown";
|
|
42
42
|
status: "status";
|
|
43
|
-
header: "header";
|
|
44
43
|
hero: "hero";
|
|
44
|
+
header: "header";
|
|
45
45
|
content: "content";
|
|
46
46
|
panel: "panel";
|
|
47
47
|
footer: "footer";
|
|
@@ -84,8 +84,8 @@ export declare const visualSpecSchema: z.ZodObject<{
|
|
|
84
84
|
}>;
|
|
85
85
|
weight: z.ZodEnum<{
|
|
86
86
|
bold: "bold";
|
|
87
|
-
regular: "regular";
|
|
88
87
|
medium: "medium";
|
|
88
|
+
regular: "regular";
|
|
89
89
|
semibold: "semibold";
|
|
90
90
|
}>;
|
|
91
91
|
usage: z.ZodString;
|
|
@@ -132,8 +132,8 @@ export declare const visualSpecDiffSchema: z.ZodObject<{
|
|
|
132
132
|
reference: z.ZodString;
|
|
133
133
|
impact: z.ZodString;
|
|
134
134
|
severity: z.ZodEnum<{
|
|
135
|
-
medium: "medium";
|
|
136
135
|
high: "high";
|
|
136
|
+
medium: "medium";
|
|
137
137
|
low: "low";
|
|
138
138
|
}>;
|
|
139
139
|
}, z.core.$strip>>;
|
|
@@ -180,8 +180,8 @@ export declare const visualSpecBundleSchema: z.ZodObject<{
|
|
|
180
180
|
role: z.ZodEnum<{
|
|
181
181
|
unknown: "unknown";
|
|
182
182
|
status: "status";
|
|
183
|
-
header: "header";
|
|
184
183
|
hero: "hero";
|
|
184
|
+
header: "header";
|
|
185
185
|
content: "content";
|
|
186
186
|
panel: "panel";
|
|
187
187
|
footer: "footer";
|
|
@@ -224,8 +224,8 @@ export declare const visualSpecBundleSchema: z.ZodObject<{
|
|
|
224
224
|
}>;
|
|
225
225
|
weight: z.ZodEnum<{
|
|
226
226
|
bold: "bold";
|
|
227
|
-
regular: "regular";
|
|
228
227
|
medium: "medium";
|
|
228
|
+
regular: "regular";
|
|
229
229
|
semibold: "semibold";
|
|
230
230
|
}>;
|
|
231
231
|
usage: z.ZodString;
|
|
@@ -301,8 +301,8 @@ export declare const visualSpecBundleSchema: z.ZodObject<{
|
|
|
301
301
|
role: z.ZodEnum<{
|
|
302
302
|
unknown: "unknown";
|
|
303
303
|
status: "status";
|
|
304
|
-
header: "header";
|
|
305
304
|
hero: "hero";
|
|
305
|
+
header: "header";
|
|
306
306
|
content: "content";
|
|
307
307
|
panel: "panel";
|
|
308
308
|
footer: "footer";
|
|
@@ -345,8 +345,8 @@ export declare const visualSpecBundleSchema: z.ZodObject<{
|
|
|
345
345
|
}>;
|
|
346
346
|
weight: z.ZodEnum<{
|
|
347
347
|
bold: "bold";
|
|
348
|
-
regular: "regular";
|
|
349
348
|
medium: "medium";
|
|
349
|
+
regular: "regular";
|
|
350
350
|
semibold: "semibold";
|
|
351
351
|
}>;
|
|
352
352
|
usage: z.ZodString;
|
|
@@ -394,8 +394,8 @@ export declare const visualSpecBundleSchema: z.ZodObject<{
|
|
|
394
394
|
reference: z.ZodString;
|
|
395
395
|
impact: z.ZodString;
|
|
396
396
|
severity: z.ZodEnum<{
|
|
397
|
-
medium: "medium";
|
|
398
397
|
high: "high";
|
|
398
|
+
medium: "medium";
|
|
399
399
|
low: "low";
|
|
400
400
|
}>;
|
|
401
401
|
}, z.core.$strip>>;
|
|
@@ -81,9 +81,9 @@ export const visualSpecDiffSchema = z.object({
|
|
|
81
81
|
reference: z.string().min(1),
|
|
82
82
|
impact: z.string().min(1),
|
|
83
83
|
severity: z.enum(['high', 'medium', 'low']),
|
|
84
|
-
}))
|
|
84
|
+
})),
|
|
85
85
|
openQuestions: z.array(z.string()),
|
|
86
|
-
nextFixes: z.array(z.string())
|
|
86
|
+
nextFixes: z.array(z.string()),
|
|
87
87
|
});
|
|
88
88
|
export const visualSpecBundleSchema = z.object({
|
|
89
89
|
version: z.literal(1),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"visual-spec.js","sourceRoot":"","sources":["../../src/schemas/visual-spec.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,MAAM,oBAAoB,GAAG,CAAC,CAAC,MAAM,CAAC;IACpC,CAAC,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC;IAC3B,CAAC,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC;IAC3B,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC;IAC/B,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC;CACjC,CAAC,CAAC;AAEH,MAAM,YAAY,GAAG,CAAC,CAAC,MAAM,CAAC;IAC5B,EAAE,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC;IACrB,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC;IACxB,IAAI,EAAE,CAAC,CAAC,IAAI,CAAC,CAAC,QAAQ,EAAE,MAAM,EAAE,SAAS,EAAE,OAAO,EAAE,QAAQ,EAAE,SAAS,EAAE,QAAQ,EAAE,SAAS,CAAC,CAAC;IAC9F,WAAW,EA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
2
|
|
|
3
3
|
Limner is designed for agent-in-the-loop visual fidelity work.
|
|
4
4
|
|
|
5
|
+
Prompt profiles: `ideal-to-mockup` for Phase 1, and `mockup-to-implementation` for Phase 2.
|
|
6
|
+
|
|
5
7
|
## Phase 1: Image To Reference
|
|
6
8
|
|
|
7
9
|
1. Run `limner init <image> --target <name>`.
|
|
@@ -9,37 +11,22 @@ Limner is designed for agent-in-the-loop visual fidelity work.
|
|
|
9
11
|
3. Edit `contract/regions.json`, `contract/tokens.json`, and `contract/acceptance.md`.
|
|
10
12
|
4. Rebuild `reference/index.html` and `reference/styles.css` as a faithful HTML facsimile.
|
|
11
13
|
5. Run `limner compare image-reference --target <name>`.
|
|
12
|
-
6.
|
|
13
|
-
7.
|
|
14
|
-
8.
|
|
15
|
-
9.
|
|
16
|
-
10.
|
|
17
|
-
11.
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
4. Inspect `captures/reference-app/dom-metrics.json`.
|
|
28
|
-
5. Record app repair steps in `reports/reference-app.md`.
|
|
29
|
-
6. Fix the app and rerun until the app matches the approved reference.
|
|
30
|
-
|
|
31
|
-
## Optional Grounding: Image To App
|
|
32
|
-
|
|
33
|
-
Use this when you need to confirm that the app URL, authentication state, and viewport are correct before building the HTML reference.
|
|
34
|
-
|
|
35
|
-
```bash
|
|
36
|
-
limner compare image-app --target <name> --url <app-url> --storage-state ./e2e/.auth/user.json
|
|
37
|
-
```
|
|
38
|
-
|
|
39
|
-
This is not a replacement for Phase 1. For design reconstruction work, first recreate the generated image in `reference/index.html` and compare with `image-reference`.
|
|
40
|
-
|
|
41
|
-
Capture defaults to viewport-only. Add `--full-page` only when the generated image is meant to represent the full scrollable page.
|
|
14
|
+
6. Read `captures/image-reference/agent-comparison/agent-prompt.codex.md`.
|
|
15
|
+
7. Write `captures/image-reference/agent-comparison/agent-response.json`.
|
|
16
|
+
8. Rerun the same command to validate `image-comparison.json` and `comparison-summary.json`.
|
|
17
|
+
9. Optional: run `limner compare image-reference --target <name> --spec` to generate a visual spec prompt pack.
|
|
18
|
+
10. Edit `contract/visual-spec-instructions.md` for target-specific prompt guidance, or pass `--spec-instructions <path>` for a shared prompt policy.
|
|
19
|
+
11. Iterate on one scoped mockup fix at a time until the reference is approved.
|
|
20
|
+
|
|
21
|
+
## Phase 2: Reference To Implementation
|
|
22
|
+
|
|
23
|
+
1. Add implementation selectors to `contract/regions.json` using `appSelector`.
|
|
24
|
+
2. Run `limner compare reference-implementation --target <name> --url <implementation-url>`.
|
|
25
|
+
3. Read `captures/reference-implementation/agent-comparison/agent-prompt.codex.md`.
|
|
26
|
+
4. Write `captures/reference-implementation/agent-comparison/agent-response.json`.
|
|
27
|
+
5. Rerun the same command to validate `image-comparison.json`, `structure-comparison.json`, and `comparison-summary.json`.
|
|
28
|
+
6. Fix the implementation and rerun until it matches the approved reference.
|
|
42
29
|
|
|
43
30
|
## Agent Rule
|
|
44
31
|
|
|
45
|
-
Do not treat side-by-side generation as success. It is evidence. The agent
|
|
32
|
+
Do not treat side-by-side generation as success. It is evidence. The agent must write the structured comparison response and use its next-iteration guidance for one scoped fix.
|
|
@@ -0,0 +1,209 @@
|
|
|
1
|
+
# Agent Comparison Scores Implementation Plan
|
|
2
|
+
|
|
3
|
+
> **For agentic workers:** REQUIRED SUB-SKILL: Use superpowers:subagent-driven-development (recommended) or superpowers:executing-plans to implement this plan task-by-task. Steps use checkbox (`- [ ]`) syntax for tracking.
|
|
4
|
+
|
|
5
|
+
**Goal:** Replace Limner's current comparison behavior with agent-authored UX screenshot comparisons that drive the next implementation iteration for the two primary visual fidelity loops.
|
|
6
|
+
|
|
7
|
+
**Architecture:** Comparison commands still capture screenshots and write reports, but their core output becomes validated agent comparison artifacts rather than artifact-only side-by-sides. New schemas model image comparisons, structure comparisons, scores, confidence, evidence, matches, diffs, remarks, system feedback, and next iteration guidance. Prompt profiles tell the agent which side is canonical and which surface should change.
|
|
8
|
+
|
|
9
|
+
**Tech Stack:** TypeScript, Commander, Zod, Playwright, Vitest.
|
|
10
|
+
|
|
11
|
+
---
|
|
12
|
+
|
|
13
|
+
## Decisions
|
|
14
|
+
|
|
15
|
+
- Agent comparison is the only scoring path in this plan.
|
|
16
|
+
- This is a major overhaul of the existing compare modes, not an additive scoring feature.
|
|
17
|
+
- The implementation comparison naming should be `reference-implementation`.
|
|
18
|
+
- Current reports should be reshaped around agent comparison status, scores, diffs, and next iteration guidance.
|
|
19
|
+
- Limner stays model-agnostic: it prepares prompt/schema/evidence files; an external agent writes `agent-response.json`.
|
|
20
|
+
- The prompt is tailored for UX screenshot comparison, not generic image comparison.
|
|
21
|
+
- Perfect matches are valid: `diffs`, `mismatches`, and `nextFixes` may be empty.
|
|
22
|
+
- Scores are `0..1` estimates with rationale/evidence, not final pass/fail judgments.
|
|
23
|
+
- The schema prioritizes the next implementation iteration over progress tracking.
|
|
24
|
+
|
|
25
|
+
## Prompt Profiles
|
|
26
|
+
|
|
27
|
+
- `ideal-to-mockup`: expected is the ideal image, actual is the HTML mockup screenshot, editable surface is the mockup. Used by `compare image-reference`.
|
|
28
|
+
- `mockup-to-implementation`: expected is the approved HTML mockup screenshot, actual is the implementation screenshot, editable surface is the implementation. Used by `compare reference-implementation`.
|
|
29
|
+
|
|
30
|
+
## CLI Semantics
|
|
31
|
+
|
|
32
|
+
- `limner compare image-reference --target <name>` creates or validates an `ideal-to-mockup` agent pack and emits `image-comparison.json` after validation.
|
|
33
|
+
- `limner compare reference-implementation --target <name> --url <url>` creates or validates a `mockup-to-implementation` agent pack and emits image plus DOM-metrics structure comparisons after validation.
|
|
34
|
+
- `--no-agent-comparison` skips the default agent comparison pack for quick artifact-only runs.
|
|
35
|
+
|
|
36
|
+
## Replacement Scope
|
|
37
|
+
|
|
38
|
+
- Replace the current artifact-only comparison reports with agent-comparison-centered reports.
|
|
39
|
+
- Rename the implementation comparison command to `compare reference-implementation`.
|
|
40
|
+
- Rename implementation comparison capture/report folders to reference-implementation equivalents.
|
|
41
|
+
- Keep backwards compatibility only if implementation chooses to add a deprecated alias; the new docs and agent workflow should use `reference-implementation`.
|
|
42
|
+
|
|
43
|
+
## Artifacts
|
|
44
|
+
|
|
45
|
+
```text
|
|
46
|
+
targets/<target>/captures/<mode>/
|
|
47
|
+
agent-comparison/
|
|
48
|
+
agent-prompt.md
|
|
49
|
+
agent-prompt.codex.md
|
|
50
|
+
agent-prompt.claude.md
|
|
51
|
+
agent-response.schema.json
|
|
52
|
+
agent-response.example.json
|
|
53
|
+
agent-response.json
|
|
54
|
+
image-comparison.json
|
|
55
|
+
structure-comparison.json
|
|
56
|
+
comparison-summary.json
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
## File Map
|
|
60
|
+
|
|
61
|
+
- Create `src/schemas/comparison.ts` and `src/schemas/comparison.test.ts`.
|
|
62
|
+
- Create `src/core/agent-comparison-profiles.ts`, `src/core/agent-comparison-prompts.ts`, `src/core/agent-comparison-pack.ts`, and `src/core/agent-comparison-pack.test.ts`.
|
|
63
|
+
- Modify `src/commands/compare-image-reference.ts`, `src/commands/compare.ts`, and `src/commands/compare.test.ts`.
|
|
64
|
+
- Modify `src/core/report-writer.ts`, `src/schemas/visual-spec.ts`, and `src/index.ts`.
|
|
65
|
+
- Modify `templates/target/AGENT_GUIDE.md`, `skills/limner/SKILL.md`, `docs/agent-workflow.md`, and `README.md`.
|
|
66
|
+
|
|
67
|
+
---
|
|
68
|
+
|
|
69
|
+
### Task 1: Shared Comparison Schemas
|
|
70
|
+
|
|
71
|
+
**Files:** create `src/schemas/comparison.ts`, create `src/schemas/comparison.test.ts`, modify `src/index.ts`.
|
|
72
|
+
|
|
73
|
+
- [ ] Write failing tests for image-only bundles, image-plus-structure bundles, perfect matches with empty `diffs`/`nextFixes`, and score bounds.
|
|
74
|
+
|
|
75
|
+
Use assertions shaped like:
|
|
76
|
+
|
|
77
|
+
```ts
|
|
78
|
+
expect(agentComparisonBundleSchema.parse(createAgentComparisonBundleExample('image-only')).imageComparison.kind).toBe('image-vs-image');
|
|
79
|
+
expect(agentComparisonBundleSchema.parse(createAgentComparisonBundleExample('image-and-structure')).structureComparison?.kind).toBe('structure-vs-structure');
|
|
80
|
+
example.imageComparison.diffs = [];
|
|
81
|
+
example.imageComparison.nextIteration.steps = [];
|
|
82
|
+
example.imageComparison.score.overall = 1;
|
|
83
|
+
expect(agentComparisonBundleSchema.parse(example).imageComparison.diffs).toEqual([]);
|
|
84
|
+
example.imageComparison.score.overall = 1.2;
|
|
85
|
+
expect(() => agentComparisonBundleSchema.parse(example)).toThrow();
|
|
86
|
+
```
|
|
87
|
+
|
|
88
|
+
- [ ] Run `npm test -- src/schemas/comparison.test.ts`; expect failure because the schema module is missing.
|
|
89
|
+
- [ ] Implement `score01Schema`, `imageComparisonSchema`, `structureComparisonSchema`, `agentComparisonBundleSchema`, exported types, `createAgentComparisonBundleExample(mode)`, and `createAgentComparisonJsonSchema()`.
|
|
90
|
+
- [ ] Include these top-level comparison fields: `summary`, `score`, `confidence`, `majorDiffAreas`, `matches`, `remarks`, `systemFeedback`, `nextIteration`, and `rationale`.
|
|
91
|
+
- [ ] Each diff should include `id`, `title`, `category`, `severity`, `priority`, `expected`, `actual`, `impact`, `evidence`, optional `fixTarget`, and `recommendedChange`.
|
|
92
|
+
- [ ] `fixTarget.surface` should be `mockup`, `implementation`, or `unknown`.
|
|
93
|
+
- [ ] Export schemas, helpers, and types from `src/index.ts`.
|
|
94
|
+
- [ ] Run `npm test -- src/schemas/comparison.test.ts && npm run typecheck`; expect pass.
|
|
95
|
+
|
|
96
|
+
---
|
|
97
|
+
|
|
98
|
+
### Task 2: Allow Perfect Visual Spec Diffs
|
|
99
|
+
|
|
100
|
+
**Files:** modify `src/schemas/visual-spec.ts`, modify `src/commands/compare.test.ts`.
|
|
101
|
+
|
|
102
|
+
- [ ] In the existing `compareImageReference` spec validation test, set `response.diff.mismatches = []` and `response.diff.nextFixes = []`.
|
|
103
|
+
- [ ] Assert `expect(diff.mismatches).toEqual([])`.
|
|
104
|
+
- [ ] Run `npm test -- src/commands/compare.test.ts`; expect failure because current schema requires one mismatch and one next fix.
|
|
105
|
+
- [ ] Remove `.min(1)` from `visualSpecDiffSchema.mismatches` and `visualSpecDiffSchema.nextFixes`.
|
|
106
|
+
- [ ] Run `npm test -- src/commands/compare.test.ts`; expect pass.
|
|
107
|
+
|
|
108
|
+
---
|
|
109
|
+
|
|
110
|
+
### Task 3: Agent Comparison Pack
|
|
111
|
+
|
|
112
|
+
**Files:** create `src/core/agent-comparison-profiles.ts`, create `src/core/agent-comparison-prompts.ts`, create `src/core/agent-comparison-pack.ts`, create `src/core/agent-comparison-pack.test.ts`.
|
|
113
|
+
|
|
114
|
+
- [ ] Write tests covering missing response, prompt/schema/example creation, invalid JSON, schema-invalid JSON, valid image-only response, valid image-plus-structure response, and both prompt profiles.
|
|
115
|
+
- [ ] Run `npm test -- src/core/agent-comparison-pack.test.ts`; expect failure because implementation is missing.
|
|
116
|
+
- [ ] Implement profile metadata for `ideal-to-mockup` and `mockup-to-implementation`.
|
|
117
|
+
- [ ] Implement prompt builders that include profile name, expected role, actual role, editable surface, expected/actual image paths, optional structure paths, schema path, response path, and UX-specific comparison guidance.
|
|
118
|
+
- [ ] The prompt must tell the agent to prioritize the next implementation iteration over exhaustive critique.
|
|
119
|
+
- [ ] The prompt must ask for high-signal UX diffs: layout, hierarchy, typography, color, spacing, component anatomy, copy/state, and attention flow.
|
|
120
|
+
- [ ] Implement `writeAgentComparisonPack(input)` with this contract:
|
|
121
|
+
|
|
122
|
+
```ts
|
|
123
|
+
{
|
|
124
|
+
workspaceRoot: string;
|
|
125
|
+
captureDir: string;
|
|
126
|
+
mode: 'image-reference' | 'reference-implementation';
|
|
127
|
+
profile: 'ideal-to-mockup' | 'mockup-to-implementation';
|
|
128
|
+
imageInputs: { expectedImagePath: string; actualImagePath: string };
|
|
129
|
+
structureInputs?: {
|
|
130
|
+
expectedStructurePath: string;
|
|
131
|
+
actualStructurePath: string;
|
|
132
|
+
structureKind: 'visual-spec' | 'dom-metrics' | 'html' | 'json-description';
|
|
133
|
+
};
|
|
134
|
+
}
|
|
135
|
+
```
|
|
136
|
+
|
|
137
|
+
- [ ] Return prompt paths, schema/example/response paths, status, validation errors, split artifact paths, and score highlights.
|
|
138
|
+
- [ ] On valid responses, write `image-comparison.json`, optional `structure-comparison.json`, and `comparison-summary.json`.
|
|
139
|
+
- [ ] Run `npm test -- src/core/agent-comparison-pack.test.ts && npm run typecheck`; expect pass.
|
|
140
|
+
|
|
141
|
+
---
|
|
142
|
+
|
|
143
|
+
### Task 4: Replace Current Primary Compare Modes
|
|
144
|
+
|
|
145
|
+
**Files:** modify `src/commands/compare-image-reference.ts`, `src/commands/compare.ts`, and `src/commands/compare.test.ts`.
|
|
146
|
+
|
|
147
|
+
- [ ] Extend compare tests so `image-reference` and `reference-implementation` return `agentComparison.status === 'awaiting-agent'` by default and each report mentions `agent-response.json`.
|
|
148
|
+
- [ ] For `reference-implementation`, assert the prompt includes `Structure kind: \`dom-metrics\``.
|
|
149
|
+
- [ ] Add coverage that `compare reference-implementation` is the documented command name.
|
|
150
|
+
- [ ] If a deprecated alias is retained, assert it points to the same implementation and prints a deprecation warning.
|
|
151
|
+
- [ ] Assert prompts include the expected profile names: `ideal-to-mockup` and `mockup-to-implementation`.
|
|
152
|
+
- [ ] Run `npm test -- src/commands/compare.test.ts`; expect failure.
|
|
153
|
+
- [ ] In `image-reference`, call `writeAgentComparisonPack` with profile `ideal-to-mockup`, ideal image as expected, and reference screenshot as actual.
|
|
154
|
+
- [ ] In `reference-implementation`, call it with profile `mockup-to-implementation`, reference screenshot as expected, implementation screenshot as actual, and structure inputs pointing at `${referencePath}.metrics.json` and `${implementationPath}.metrics.json`.
|
|
155
|
+
- [ ] Respect `options.agentComparison === false`.
|
|
156
|
+
- [ ] Run `npm test -- src/commands/compare.test.ts && npm run typecheck`; expect pass.
|
|
157
|
+
|
|
158
|
+
---
|
|
159
|
+
|
|
160
|
+
### Task 5: CLI Flags And Reports
|
|
161
|
+
|
|
162
|
+
**Files:** modify `src/commands/compare.ts`, modify `src/core/report-writer.ts`.
|
|
163
|
+
|
|
164
|
+
- [ ] Add to `image-reference` and `reference-implementation`:
|
|
165
|
+
|
|
166
|
+
```ts
|
|
167
|
+
.option('--no-agent-comparison', 'skip the default agent comparison prompt pack')
|
|
168
|
+
```
|
|
169
|
+
|
|
170
|
+
- [ ] Pass `agentComparison` through to command functions.
|
|
171
|
+
- [ ] Console output should include prompt paths, schema path, response target, validation status, and validated artifact paths.
|
|
172
|
+
- [ ] Reports should include `## Agent Comparison`.
|
|
173
|
+
- [ ] Awaiting reports should show prompt paths and the next step.
|
|
174
|
+
- [ ] Invalid reports should show validation errors.
|
|
175
|
+
- [ ] Validated reports should show agent image score, optional agent structure score, next iteration focus, and artifact paths.
|
|
176
|
+
- [ ] Verify help: `image-reference` and `reference-implementation` show `--no-agent-comparison`.
|
|
177
|
+
|
|
178
|
+
---
|
|
179
|
+
|
|
180
|
+
### Task 6: Teach Agents The Default Workflow
|
|
181
|
+
|
|
182
|
+
**Files:** modify `templates/target/AGENT_GUIDE.md`, `skills/limner/SKILL.md`, `docs/agent-workflow.md`, and `README.md`.
|
|
183
|
+
|
|
184
|
+
- [ ] Document that `image-reference` and `reference-implementation` create an agent comparison pack by default.
|
|
185
|
+
- [ ] Document prompt profiles: `ideal-to-mockup` and `mockup-to-implementation`.
|
|
186
|
+
- [ ] Tell agents to read `captures/<mode>/agent-comparison/agent-prompt.codex.md`.
|
|
187
|
+
- [ ] Tell agents to write `captures/<mode>/agent-comparison/agent-response.json`.
|
|
188
|
+
- [ ] Tell agents to rerun the same compare command to validate output.
|
|
189
|
+
- [ ] Update README’s product promise: Limner prepares model-agnostic agent-authored UX comparison scores, but does not make final pass/fail judgments.
|
|
190
|
+
- [ ] Run `rg -n "agent comparison|agent-response.json|ideal-to-mockup|mockup-to-implementation" README.md docs/agent-workflow.md templates/target/AGENT_GUIDE.md skills/limner/SKILL.md`; expect all files to mention the workflow.
|
|
191
|
+
|
|
192
|
+
---
|
|
193
|
+
|
|
194
|
+
### Task 7: Full Quality Gate And Handoff
|
|
195
|
+
|
|
196
|
+
**Files:** no edits.
|
|
197
|
+
|
|
198
|
+
- [ ] Run `npm run check`; expect lint, typecheck, Vitest, build, Knip, and file-size guard pass.
|
|
199
|
+
- [ ] Smoke `npm run dev -- compare image-reference --help`; expect `--no-agent-comparison`.
|
|
200
|
+
- [ ] Smoke `npm run dev -- compare reference-implementation --help`; expect `--no-agent-comparison`.
|
|
201
|
+
- [ ] PR handoff should include failure modes, commands run/results, generated artifacts, negative cases, and remaining risks.
|
|
202
|
+
- [ ] Failure modes: agents may treat scores as pass/fail; awaiting-agent loop if response is not written; agent feedback may be too broad unless the prompt enforces a focused next iteration.
|
|
203
|
+
- [ ] Negative cases: perfect match, invalid JSON, schema-invalid JSON, and `--no-agent-comparison`.
|
|
204
|
+
|
|
205
|
+
## Self-Review
|
|
206
|
+
|
|
207
|
+
- Spec coverage: Covers the comparison overhaul, `reference-implementation` naming, two prompt profiles, image-vs-image output, structure-vs-structure output, how agents know to use it, schemas, validation, docs, and tests.
|
|
208
|
+
- Placeholder scan: No TBD/TODO language remains; each task names concrete files, behavior, commands, and expected outcomes.
|
|
209
|
+
- Type consistency: `agentComparison`, `imageComparison`, `structureComparison`, `ideal-to-mockup`, and `mockup-to-implementation` are consistent across the plan.
|
package/package.json
CHANGED
package/skills/limner/SKILL.md
CHANGED
|
@@ -1,12 +1,14 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: limner
|
|
3
|
-
description: Use when turning an image into
|
|
3
|
+
description: Use when turning an image into an HTML mockup or comparing an approved mockup against an implementation.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# Limner
|
|
7
7
|
|
|
8
8
|
Use Limner for structured visual fidelity loops.
|
|
9
9
|
|
|
10
|
+
Prompt profiles: `ideal-to-mockup` for Image To Reference, and `mockup-to-implementation` for Reference To Implementation.
|
|
11
|
+
|
|
10
12
|
## Image To Reference
|
|
11
13
|
|
|
12
14
|
1. Run `limner init <image> --target <name>` if the target does not exist.
|
|
@@ -14,8 +16,10 @@ Use Limner for structured visual fidelity loops.
|
|
|
14
16
|
3. Fill `contract/regions.json`, `contract/tokens.json`, and `contract/acceptance.md`.
|
|
15
17
|
4. Edit `reference/index.html` and `reference/styles.css`.
|
|
16
18
|
5. Run `limner compare image-reference --target <name>`.
|
|
17
|
-
6.
|
|
18
|
-
7.
|
|
19
|
+
6. Read `captures/image-reference/agent-comparison/agent-prompt.codex.md`.
|
|
20
|
+
7. Write `captures/image-reference/agent-comparison/agent-response.json`.
|
|
21
|
+
8. Rerun `limner compare image-reference --target <name>` so Limner validates `image-comparison.json` and `comparison-summary.json`.
|
|
22
|
+
9. Use the validated next-iteration guidance for one scoped mockup fix.
|
|
19
23
|
|
|
20
24
|
Optional structured spec layer:
|
|
21
25
|
|
|
@@ -27,25 +31,18 @@ Optional structured spec layer:
|
|
|
27
31
|
- Have the agent write `captures/image-reference/spec/agent-response.json`.
|
|
28
32
|
- Rerun the same command so Limner can validate the response and emit the spec and diff JSON artifacts.
|
|
29
33
|
|
|
30
|
-
## Reference To
|
|
34
|
+
## Reference To Implementation
|
|
31
35
|
|
|
32
36
|
1. Confirm the reference HTML is approved.
|
|
33
|
-
2. Ensure every important region has both `referenceSelector` and `appSelector`.
|
|
34
|
-
3. Run `limner compare reference-
|
|
35
|
-
4.
|
|
36
|
-
5.
|
|
37
|
-
6. Rerun
|
|
38
|
-
|
|
39
|
-
## Image To App Grounding
|
|
40
|
-
|
|
41
|
-
Use `limner compare image-app --target <name> --url <app-url>` to compare the source image directly to an app screenshot.
|
|
42
|
-
|
|
43
|
-
Add `--storage-state <path>` for authenticated pages and `--full-page` only when a full-page screenshot is intended. The default is viewport-only.
|
|
44
|
-
|
|
45
|
-
For generated-image reconstruction work, do not skip Image To Reference. Build the HTML facsimile first, then compare the approved reference to the app.
|
|
37
|
+
2. Ensure every important region has both `referenceSelector` and an implementation selector in `appSelector`.
|
|
38
|
+
3. Run `limner compare reference-implementation --target <name> --url <implementation-url>`.
|
|
39
|
+
4. Read `captures/reference-implementation/agent-comparison/agent-prompt.codex.md`.
|
|
40
|
+
5. Write `captures/reference-implementation/agent-comparison/agent-response.json`.
|
|
41
|
+
6. Rerun the same command so Limner validates image, structure, and summary comparison artifacts.
|
|
42
|
+
7. Use the validated next-iteration guidance for one scoped implementation fix.
|
|
46
43
|
|
|
47
44
|
## Constraints
|
|
48
45
|
|
|
49
|
-
- Limner does not call an AI vision model itself.
|
|
46
|
+
- Limner does not call an AI vision model itself. Agent comparison and the `--spec` workflow require an external agent.
|
|
50
47
|
- Limner does not make final pass/fail judgments.
|
|
51
48
|
- Limner logs only local JSONL events under `.limner/runs/`.
|
|
@@ -2,23 +2,27 @@
|
|
|
2
2
|
|
|
3
3
|
Use this target folder as a structured workbench for visual fidelity.
|
|
4
4
|
|
|
5
|
+
Prompt profiles: `ideal-to-mockup` for Loop 1, and `mockup-to-implementation` for Loop 2.
|
|
6
|
+
|
|
5
7
|
## Loop 1: Image To Reference
|
|
6
8
|
|
|
7
9
|
1. Inspect `source/ideal.png`.
|
|
8
10
|
2. Fill out `contract/regions.json`, `contract/tokens.json`, and `contract/acceptance.md`.
|
|
9
11
|
3. Edit `reference/index.html` and `reference/styles.css` until the reference is a faithful HTML facsimile.
|
|
10
12
|
4. Run `limner compare image-reference --target <target>`.
|
|
11
|
-
5.
|
|
12
|
-
6.
|
|
13
|
+
5. Read `captures/image-reference/agent-comparison/agent-prompt.codex.md`.
|
|
14
|
+
6. Write `captures/image-reference/agent-comparison/agent-response.json`.
|
|
15
|
+
7. Rerun the comparison and use the validated next-iteration guidance for one scoped mockup fix.
|
|
13
16
|
|
|
14
|
-
## Loop 2: Reference To
|
|
17
|
+
## Loop 2: Reference To Implementation
|
|
15
18
|
|
|
16
19
|
1. Treat the reference HTML as the approved design.
|
|
17
|
-
2. Add
|
|
18
|
-
3. Run `limner compare reference-
|
|
19
|
-
4.
|
|
20
|
-
5.
|
|
20
|
+
2. Add implementation selectors to `contract/regions.json` using `appSelector`.
|
|
21
|
+
3. Run `limner compare reference-implementation --target <target> --url <implementation-url>`.
|
|
22
|
+
4. Read `captures/reference-implementation/agent-comparison/agent-prompt.codex.md`.
|
|
23
|
+
5. Write `captures/reference-implementation/agent-comparison/agent-response.json`.
|
|
24
|
+
6. Rerun the comparison and use the validated next-iteration guidance for one scoped implementation fix.
|
|
21
25
|
|
|
22
26
|
## Rule
|
|
23
27
|
|
|
24
|
-
Limner does not decide visual success automatically. It produces evidence
|
|
28
|
+
Limner does not decide visual success automatically. It produces evidence and validates agent-authored UX comparisons so the next implementation iteration is focused.
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
export declare function compareImageApp(options: {
|
|
2
|
-
workspaceRoot: string;
|
|
3
|
-
target: string;
|
|
4
|
-
url: string;
|
|
5
|
-
headed?: boolean;
|
|
6
|
-
storageState?: string;
|
|
7
|
-
fullPage?: boolean;
|
|
8
|
-
}): Promise<{
|
|
9
|
-
sideBySidePath: string;
|
|
10
|
-
reportPath: string;
|
|
11
|
-
appPath: string;
|
|
12
|
-
}>;
|
|
@@ -1,45 +0,0 @@
|
|
|
1
|
-
import { mkdir } from 'node:fs/promises';
|
|
2
|
-
import path from 'node:path';
|
|
3
|
-
import { capturePage } from '../core/playwright-capture.js';
|
|
4
|
-
import { writeImageAppReport } from '../core/report-writer.js';
|
|
5
|
-
import { createRunLogger } from '../core/run-logger.js';
|
|
6
|
-
import { createSideBySideImage } from '../core/side-by-side.js';
|
|
7
|
-
import { resolveTarget, resolveWorkspace } from '../core/workspace.js';
|
|
8
|
-
export async function compareImageApp(options) {
|
|
9
|
-
const workspace = resolveWorkspace(options.workspaceRoot);
|
|
10
|
-
const target = resolveTarget(options.workspaceRoot, options.target);
|
|
11
|
-
const logger = await createRunLogger(workspace, { command: 'compare', target: options.target, mode: 'image-app' });
|
|
12
|
-
const captureDir = path.join(target.capturesDir, 'image-app');
|
|
13
|
-
const appPath = path.join(captureDir, 'app.png');
|
|
14
|
-
const sideBySidePath = path.join(captureDir, 'side-by-side.png');
|
|
15
|
-
try {
|
|
16
|
-
await logger.event({ type: 'command.started' });
|
|
17
|
-
await mkdir(captureDir, { recursive: true });
|
|
18
|
-
await capturePage({
|
|
19
|
-
url: options.url,
|
|
20
|
-
outputPath: appPath,
|
|
21
|
-
headed: options.headed,
|
|
22
|
-
storageState: options.storageState,
|
|
23
|
-
fullPage: options.fullPage,
|
|
24
|
-
});
|
|
25
|
-
await createSideBySideImage({ leftPath: target.sourceImagePath, rightPath: appPath, outputPath: sideBySidePath });
|
|
26
|
-
const reportPath = await writeImageAppReport({
|
|
27
|
-
target,
|
|
28
|
-
idealPath: target.sourceImagePath,
|
|
29
|
-
appPath,
|
|
30
|
-
sideBySidePath,
|
|
31
|
-
appUrl: options.url,
|
|
32
|
-
});
|
|
33
|
-
await logger.artifact(appPath, 'screenshot');
|
|
34
|
-
await logger.artifact(sideBySidePath, 'side-by-side');
|
|
35
|
-
await logger.artifact(reportPath, 'report');
|
|
36
|
-
await logger.complete('ok');
|
|
37
|
-
return { sideBySidePath, reportPath, appPath };
|
|
38
|
-
}
|
|
39
|
-
catch (error) {
|
|
40
|
-
await logger.event({ type: 'command.failed', status: 'failed', message: error instanceof Error ? error.message : String(error) });
|
|
41
|
-
await logger.complete('failed');
|
|
42
|
-
throw error;
|
|
43
|
-
}
|
|
44
|
-
}
|
|
45
|
-
//# sourceMappingURL=compare-image-app.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"compare-image-app.js","sourceRoot":"","sources":["../../src/commands/compare-image-app.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,kBAAkB,CAAC;AACzC,OAAO,IAAI,MAAM,WAAW,CAAC;AAE7B,OAAO,EAAE,WAAW,EAAE,MAAM,+BAA+B,CA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