@event4u/agent-config 16.4.0 → 16.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.augment-plugin/marketplace.json +3 -3
- package/.augment-plugin/plugin.json +1 -1
- package/.claude-plugin/marketplace.json +1 -1
- package/CHANGELOG.md +40 -191
- package/README.md +1 -1
- package/dist/agent-src/commands/design.md +1 -1
- package/dist/agent-src/guidelines/design-antipatterns.md +1 -1
- package/dist/agent-src/rules/token-budget-discipline.md +2 -2
- package/dist/agent-src/skills/accessibility-auditor/data/aria-patterns.csv +2 -0
- package/dist/agent-src/skills/accessibility-auditor/data/manifest.json +3 -3
- package/dist/agent-src/skills/canvas-design/SKILL.md +4 -2
- package/dist/agent-src/skills/design-intelligence/references/integration-mapping.md +13 -10
- package/dist/agent-src/skills/fe-design/references/design-patterns.md +49 -2
- package/dist/agent-src/skills/frontend-render-security/SKILL.md +9 -0
- package/dist/agent-src/skills/iconography/SKILL.md +4 -2
- package/dist/agent-src/skills/image-provider-routing/SKILL.md +16 -5
- package/dist/agent-src/skills/logo-generation/SKILL.md +12 -8
- package/dist/agent-src/skills/svg-authoring/SKILL.md +318 -0
- package/dist/agent-src/skills/wireframe/SKILL.md +5 -2
- package/dist/agent-src/templates/agents/agent-project-settings.example.yml +1 -1
- package/dist/cli/commands/uiRender.js +201 -4
- package/dist/cli/commands/uiRenderAsset.js +1308 -0
- package/dist/cli/commands/uiRenderAssetCompare.js +752 -0
- package/dist/cli/commands/uiRenderAssetGrid.js +265 -0
- package/dist/cli/commands/uiRenderAssetGrounds.js +323 -0
- package/dist/cli/commands/uiRenderAssetIsolation.js +85 -0
- package/dist/cli/commands/uiRenderAssetTypes.js +145 -0
- package/dist/cli/main.js +47 -1
- package/dist/cli/registry.js +1 -1
- package/dist/cli-delegate/{chunk-MSUL5NYP.js → chunk-4DBG5K7M.js} +1 -1
- package/dist/cli-delegate/{chunk-AED2VQGM.js → chunk-TMWYUOK4.js} +10 -1
- package/dist/cli-delegate/cmd_conformance.js +395 -214
- package/dist/cli-delegate/cmd_handoff.js +2 -2
- package/dist/cli-delegate/cmd_session_recycle.js +2 -2
- package/dist/discovery/deprecation-report.md +1 -1
- package/dist/discovery/discovery-manifest.json +47 -22
- package/dist/discovery/discovery-manifest.json.sha256 +1 -1
- package/dist/discovery/discovery-manifest.summary.md +6 -6
- package/dist/discovery/dormancy-report.md +1 -1
- package/dist/discovery/orphan-report.md +1 -1
- package/dist/discovery/packs.json +19 -15
- package/dist/discovery/trust-report.md +2 -2
- package/dist/discovery/workspaces.json +13 -9
- package/dist/hooks/dispatch.js +1073 -808
- package/dist/hooks/dispatch.sha256 +1 -1
- package/dist/hooks/svg_rules.chunk.cjs +1626 -0
- package/dist/hooks/svg_rules.chunk.cjs.sha256 +1 -0
- package/dist/mcp/registry-manifest.json +3 -3
- package/dist/mcp/server.json +2 -2
- package/dist/mcp/server.mjs +931 -735
- package/dist/scripts/_lib/scan_scope.js +105 -0
- package/dist/scripts/_lib/svg_dom.js +284 -0
- package/dist/scripts/_lib/svg_geometry.js +477 -0
- package/dist/scripts/_lib/svg_motion.js +179 -0
- package/dist/scripts/_lib/svg_rules.js +1337 -0
- package/dist/scripts/_lib/svg_urls.js +67 -0
- package/dist/scripts/lint_svg_asset.js +324 -0
- package/docs/guidelines/design-antipatterns.md +1 -1
- package/package.json +4 -3
- package/src/config/gate-violation-baselines.json +3 -3
- package/src/config/routing-coverage-seed.json +9 -2
- package/src/scripts/_lib/svg_dom.ts +318 -0
- package/src/scripts/_lib/svg_geometry.ts +480 -0
- package/src/scripts/_lib/svg_motion.ts +208 -0
- package/src/scripts/_lib/svg_rules.ts +1453 -0
- package/src/scripts/_lib/svg_urls.ts +72 -0
- package/src/scripts/_lib/verification_command.ts +59 -0
- package/src/scripts/_lib/verify_clause.ts +27 -17
- package/src/scripts/hooks/block_speaking_inbox_dir.ts +16 -1
- package/src/scripts/hooks/design_pass_hook.ts +157 -3
- package/src/scripts/hooks/svg_obligation.ts +497 -0
- package/src/scripts/hooks/svg_rules_loader.ts +133 -0
- package/src/scripts/hooks/turn_end_gate_hook.ts +5 -3
- package/src/scripts/lint_consolidation_lineage.ts +6 -3
- package/src/scripts/lint_design_quality.ts +60 -12
- package/src/scripts/lint_motion_authority_drift.ts +27 -0
- package/src/scripts/lint_svg_asset.ts +365 -0
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
model_tier: inherit
|
|
3
3
|
name: iconography
|
|
4
|
-
description: "Resolve an icon request to
|
|
4
|
+
description: "Resolve an icon request to an Iconify name and emit the stack's embedding. Use when adding icons, picking an icon set, or wiring Lucide/Heroicons/Phosphor/Tabler."
|
|
5
5
|
domain: product
|
|
6
6
|
personas: []
|
|
7
7
|
workspaces:
|
|
@@ -102,7 +102,9 @@ Inspect stage of the
|
|
|
102
102
|
- **No hand-rolled icons when a set exists.** If the project has an icon library
|
|
103
103
|
or brand mark, use it — do not hand-author a one-off SVG that drifts from the
|
|
104
104
|
system. Hand-rolling is for a genuinely missing glyph, and then it matches the
|
|
105
|
-
set's grid + stroke
|
|
105
|
+
set's grid + stroke — read the grid, stroke and padding off the set's OWN
|
|
106
|
+
SVGs and author it under [`svg-authoring`](../svg-authoring/SKILL.md), which
|
|
107
|
+
checks the result instead of trusting that it matched.
|
|
106
108
|
- **Flag substitutions when the exact asset is absent.** When the needed icon or
|
|
107
109
|
brand mark does not exist in the set, pick the nearest and **state the
|
|
108
110
|
substitution** ("no exact 'sync' glyph in Heroicons; used `arrow-path`") rather
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
model_tier: inherit
|
|
3
3
|
name: image-provider-routing
|
|
4
|
-
description: "
|
|
4
|
+
description: "Pick the image provider from job shape — text-in-image to Ideogram, photoreal to Flux, illustrative vector to Recraft, general to Gemini/GPT."
|
|
5
5
|
domain: product
|
|
6
6
|
personas: []
|
|
7
7
|
workspaces:
|
|
@@ -37,13 +37,24 @@ promotion per `provider-lifecycle-discipline`.
|
|
|
37
37
|
|---|---|---|
|
|
38
38
|
| Text-in-image (logo, banner, typographic art) | **Ideogram** | Best glyph rendering; raster models garble text |
|
|
39
39
|
| Photoreal (product shot, portrait, scene) | **Flux** | Photorealism specialist; routed via fal/Replicate |
|
|
40
|
-
|
|
|
40
|
+
| Icon the set lacks | `iconography` first, then [`svg-authoring`](../svg-authoring/SKILL.md) | The incumbent set wins; a missing glyph is hand-authored against its grid and checked — no provider involved |
|
|
41
|
+
| Simple geometric mark | [`svg-authoring`](../svg-authoring/SKILL.md) | A `rect`/`circle`/`path` mark is cheaper and more editable hand-authored than generated, and it ends in a file rather than a plan |
|
|
42
|
+
| Complex illustrative vector art | **Recraft** | The only job shape left for a vector provider. State the adapter's lifecycle in the answer: `experimental — scaffold tier, dry-run plumbing only`, so the caller knows no asset is produced |
|
|
41
43
|
| General art / edit / multimodal | **Gemini-image** or **GPT Image 2** | Broad capability; natural-language prompts |
|
|
42
44
|
| Budget-conscious 4K upscale | Flux via Replicate | Cost-competitive at high resolution |
|
|
43
45
|
|
|
44
|
-
Decision order:
|
|
45
|
-
|
|
46
|
-
|
|
46
|
+
Decision order: an icon → the incumbent set, then `svg-authoring` for a missing
|
|
47
|
+
glyph; a simple geometric mark → `svg-authoring`; text-in-image → Ideogram;
|
|
48
|
+
complex illustrative vector art → Recraft, with its scaffold-tier lifecycle
|
|
49
|
+
stated; photoreal → Flux; everything else → Gemini-image (default) or GPT
|
|
50
|
+
Image 2 (when an OpenAI key is available and an existing image is being edited).
|
|
51
|
+
|
|
52
|
+
The split exists because the single "Vector / SVG logo or icon" row sent every
|
|
53
|
+
icon and every geometric mark to an adapter whose header reads `experimental —
|
|
54
|
+
scaffold tier. dry-run plumbing only` and whose live calls exit at
|
|
55
|
+
the adapter's own live-call guard. The routed path ended in a plan;
|
|
56
|
+
the icon floor meanwhile sent icons to the set. Neither produced an asset for
|
|
57
|
+
the one case that needs one — a glyph the set does not have.
|
|
47
58
|
|
|
48
59
|
## Procedure
|
|
49
60
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
model_tier: inherit
|
|
3
3
|
name: logo-generation
|
|
4
|
-
description: "Generate a logo or brand mark — structured prompt
|
|
4
|
+
description: "Generate a logo or brand mark — structured prompt, provider routing, and a true-vector path. Use for logo or brand mark generation."
|
|
5
5
|
domain: product
|
|
6
6
|
personas:
|
|
7
7
|
- design-director
|
|
@@ -40,9 +40,10 @@ governance. All adapters are scaffold-tier (dry-run) until promoted to `stable`.
|
|
|
40
40
|
icon mark / combination), colour palette, do/don't constraints (e.g. "no gradients",
|
|
41
41
|
"must be legible at 16 px").
|
|
42
42
|
2. **Choose the path** — raster concept (text-in-mark → Ideogram for legible type)
|
|
43
|
-
vs. **true vector** (vector-native provider
|
|
44
|
-
|
|
45
|
-
|
|
43
|
+
vs. **true vector** (a vector-native provider for editable marks, or a
|
|
44
|
+
hand-authored one for simple geometric marks — authored under
|
|
45
|
+
[`svg-authoring`](../svg-authoring/SKILL.md), never free-hand). Raster output
|
|
46
|
+
is a concept only — not a shippable logo asset.
|
|
46
47
|
3. **Inject brand tokens when a brand layer is present** (`pack-brand`) — pull the
|
|
47
48
|
registered palette, typeface, and spacing tokens. When no brand layer exists,
|
|
48
49
|
use the brief's palette and type choices directly.
|
|
@@ -51,8 +52,11 @@ governance. All adapters are scaffold-tier (dry-run) until promoted to `stable`.
|
|
|
51
52
|
provider-specific grammar (text-literal first for Ideogram, `style: vector` param
|
|
52
53
|
for a vector-native provider, direct SVG authoring for simple geometric shapes).
|
|
53
54
|
5. **Dry-run + validate** — invoke the adapter (scaffold-tier; returns a dry-run
|
|
54
|
-
plan). If the vector path is taken,
|
|
55
|
-
|
|
55
|
+
plan). If the vector path is taken, the vector verdict comes from
|
|
56
|
+
`lint_svg_asset`'s vector-honesty family plus the render witness, not from
|
|
57
|
+
counting `<path>` elements: a raster embedded beside one dummy path passes
|
|
58
|
+
that count and is not a vector, and a mark built from `rect`/`circle` fails
|
|
59
|
+
it and is one. See [`svg-authoring`](../svg-authoring/SKILL.md).
|
|
56
60
|
6. **Rights check** — never reproduce a mark that resembles an existing trademarked
|
|
57
61
|
logo. Run [`image-likeness-and-rights`](../../rules/image-likeness-and-rights.md)
|
|
58
62
|
when the brief names a brand, references a known mark style, or targets a
|
|
@@ -78,8 +82,8 @@ governance. All adapters are scaffold-tier (dry-run) until promoted to `stable`.
|
|
|
78
82
|
is `stable` misleads the caller.
|
|
79
83
|
|
|
80
84
|
**Good example:** Brief for a wordmark → route to a vector-native provider with
|
|
81
|
-
`style: vector`,
|
|
82
|
-
dry-run plan only."
|
|
85
|
+
`style: vector`, run `lint_svg_asset` over the output and confirm it carries no
|
|
86
|
+
embedded raster, note "experimental — dry-run plan only."
|
|
83
87
|
|
|
84
88
|
**Bad example:** Routing a logo brief to a photoreal raster model and delivering the
|
|
85
89
|
PNG as the final logo file.
|
|
@@ -0,0 +1,318 @@
|
|
|
1
|
+
---
|
|
2
|
+
model_tier: inherit
|
|
3
|
+
name: svg-authoring
|
|
4
|
+
description: "Hand-author or edit an SVG — icon, mark, illustration, diagram, animation, raster-to-vector — checked and rendered."
|
|
5
|
+
domain: product
|
|
6
|
+
personas:
|
|
7
|
+
- design-director
|
|
8
|
+
workspaces:
|
|
9
|
+
- engineering
|
|
10
|
+
packs:
|
|
11
|
+
- frontend-design
|
|
12
|
+
- ai-image
|
|
13
|
+
- ai-video
|
|
14
|
+
- engineering-base
|
|
15
|
+
trust:
|
|
16
|
+
level: professional
|
|
17
|
+
install:
|
|
18
|
+
removable: true
|
|
19
|
+
scope:
|
|
20
|
+
write: []
|
|
21
|
+
verification_reason: "execution declares no handler, so this skill runs nothing of its own — every write is the calling agent's, under the rules that govern it. No command can prove a scope the skill never executes."
|
|
22
|
+
execution:
|
|
23
|
+
type: manual
|
|
24
|
+
---
|
|
25
|
+
|
|
26
|
+
# svg-authoring
|
|
27
|
+
|
|
28
|
+
> The one owner for SVG an agent writes by hand. Six lanes produce one — a
|
|
29
|
+
> missing icon glyph, a geometric mark, an illustration, a diagram, an animated
|
|
30
|
+
> asset, a wireframe canvas — and until this skill existed none of them had a
|
|
31
|
+
> procedure or a check beyond the agent's own belief that the file looked right.
|
|
32
|
+
|
|
33
|
+
## When to use
|
|
34
|
+
|
|
35
|
+
- A glyph the incumbent icon set does not have (`iconography` first — the set wins).
|
|
36
|
+
- A simple geometric mark, when `logo-generation` takes the true-vector path.
|
|
37
|
+
- An illustration or a diagram authored as SVG rather than generated.
|
|
38
|
+
- An animated asset: SMIL, CSS or WAAPI inside an `.svg` or an inline graphic.
|
|
39
|
+
- A **surgical edit** to an existing SVG — "change only the hat", "remove the face".
|
|
40
|
+
- A **raster converted to a vector** — "turn the logo in this PNG into a real vector".
|
|
41
|
+
|
|
42
|
+
## When NOT to use
|
|
43
|
+
|
|
44
|
+
- The icon exists in the set → `iconography`, and stop there.
|
|
45
|
+
- A photoreal or illustrative raster → `image-generation`.
|
|
46
|
+
- A full brand pipeline → `logo-generation` (which routes back here for the mark).
|
|
47
|
+
- Motion design for video → `motion-choreographer`.
|
|
48
|
+
|
|
49
|
+
## Procedure
|
|
50
|
+
|
|
51
|
+
1. **Read the delivery mode first — it decides everything after it.** `inline`
|
|
52
|
+
in a host page, a standalone `document` opened directly, `img`, a CSS
|
|
53
|
+
background, or a deck. It decides what can animate, what can execute, and how
|
|
54
|
+
the graphic gets its accessible name. An **undeclared** mode is treated as
|
|
55
|
+
`inline`, the strictest.
|
|
56
|
+
2. **Classify the asset** — `icon`, `mark`, `illustration`, `diagram`,
|
|
57
|
+
`animated`. The class picks the fill-ratio threshold and the geometry
|
|
58
|
+
tolerance; there is no global threshold, because a 24-grid icon's designed
|
|
59
|
+
padding reads as an under-filled viewBox against one.
|
|
60
|
+
3. **Plan before attributes** — concept, then layout, then attributes.
|
|
61
|
+
Primitives before detail: a mark built from `rect`/`circle`/`polygon` is a
|
|
62
|
+
true vector and is often the right answer, not a lesser one.
|
|
63
|
+
4. **Write with the invariants.**
|
|
64
|
+
- ids namespaced to the graphic — a bare `id="title"` names the second
|
|
65
|
+
inline graphic on the page after the first.
|
|
66
|
+
- the accessible name comes from the ARIA corpus, not from here: ground
|
|
67
|
+
`meaningful standalone svg chart graphic accessible name` against
|
|
68
|
+
`accessibility-auditor`'s `aria-patterns.csv` and follow the
|
|
69
|
+
**Meaningful standalone graphic** or **Decorative graphic** row.
|
|
70
|
+
- colour from the project's tokens or `currentColor`, never a loose hex.
|
|
71
|
+
- an explicit `font-family` with a fallback the target actually ships; a
|
|
72
|
+
`<text>` with none resolves to the platform serif.
|
|
73
|
+
- no `<script>`, no `on*`, no `javascript:`, no `foreignObject`, no external
|
|
74
|
+
`href` or `url()`, no internal DTD subset or `<!ENTITY` (a bare public
|
|
75
|
+
DOCTYPE is fine).
|
|
76
|
+
5. **Run the static check** — `lint_svg_asset`, with the delivery mode declared:
|
|
77
|
+
```bash
|
|
78
|
+
npx tsx node_modules/@event4u/agent-config/src/scripts/lint_svg_asset.ts \
|
|
79
|
+
--file path/to/asset.svg --delivery inline
|
|
80
|
+
```
|
|
81
|
+
6. **Run the witness** — the asset profile, which opens the file in a real engine:
|
|
82
|
+
```bash
|
|
83
|
+
agent-config ui:render path/to/asset.svg --profile asset --class icon
|
|
84
|
+
```
|
|
85
|
+
7. **Look at the render.** Looking stays mandatory for *meaning*; it is never the
|
|
86
|
+
pass for *geometry*. Fix what both the checks and the look found.
|
|
87
|
+
8. **Stop** at a clean witness or after three render passes, whichever comes
|
|
88
|
+
first. A stop **at the cap with error findings still open** reports
|
|
89
|
+
`unverified` with the reason `pass-cap-reached` and lists what is open —
|
|
90
|
+
never `verified`, and never done. That reason is yours to report: the render
|
|
91
|
+
manifest never carries it, because one invocation of `ui:render` cannot see
|
|
92
|
+
how many passes you have made.
|
|
93
|
+
9. **Report** the renderer and the checks that actually ran — `verified`,
|
|
94
|
+
`static-only` or `unverified` — plus `goal: unassessed`, and name only
|
|
95
|
+
output files read back from disk. Where the renderer is **absent**, run the
|
|
96
|
+
static witness, report `static-only`, and name the missing capability in one
|
|
97
|
+
line; opening the file in a browser is never a step of this procedure or of
|
|
98
|
+
the user's.
|
|
99
|
+
|
|
100
|
+
## Status — what each word is allowed to mean
|
|
101
|
+
|
|
102
|
+
| Status | Allowed only when |
|
|
103
|
+
|---|---|
|
|
104
|
+
| `verified` | a render manifest from the asset profile exists **whose recorded file digest equals the delivered file's digest on disk**. A manifest from an earlier pass does not count. |
|
|
105
|
+
| `static-only` | the static check ran and no render did. A parser pass (`xmllint --noout`) is this, never `verified` — a file can parse and still be the wrong picture. |
|
|
106
|
+
| `unverified` | no browser resolved, or the pass cap was reached with error findings open (`pass-cap-reached`). Never a pass; never silently upgraded. |
|
|
107
|
+
|
|
108
|
+
**A second axis, and it is not this table's.** Every status above is about
|
|
109
|
+
whether a CHECK ran and what it found. Whether the graphic is *right* is a
|
|
110
|
+
different question, and `verified` was being read as an answer to it. So every
|
|
111
|
+
report carries `goal:` beside the status, and this skill writes exactly one
|
|
112
|
+
value into it:
|
|
113
|
+
|
|
114
|
+
| Goal | Written by |
|
|
115
|
+
|---|---|
|
|
116
|
+
| `unassessed` | **always, by this skill and by the renderer.** The default, and the only value either may write. |
|
|
117
|
+
| `accepted` / `rejected` | an owner statement, or a pre-registered scenario witness. Never derived from a digest match, a clean witness, or a score. |
|
|
118
|
+
|
|
119
|
+
## Editing an existing SVG — the baseline replaces the look
|
|
120
|
+
|
|
121
|
+
Declare the ids the edit is allowed to touch, then let the readout decide:
|
|
122
|
+
|
|
123
|
+
```bash
|
|
124
|
+
npx tsx node_modules/@event4u/agent-config/src/scripts/lint_svg_asset.ts \
|
|
125
|
+
--file after.svg --baseline before.svg --allow hat,hat-band
|
|
126
|
+
```
|
|
127
|
+
|
|
128
|
+
Every element outside the allowed set that changed is reported with the attribute
|
|
129
|
+
that changed, after number and whitespace canonicalisation. **No pixel diff
|
|
130
|
+
decides this** — anti-aliasing and font metrics would make it a per-machine
|
|
131
|
+
verdict.
|
|
132
|
+
|
|
133
|
+
This applies **between the owner's own passes** too. A part the user already
|
|
134
|
+
accepted joins the baseline and may not move by hand. A conversion pass that
|
|
135
|
+
re-derives that part from the source instead **re-measures** it and re-checks
|
|
136
|
+
the accepted property — a hole that was accepted as a hole stays a hole through
|
|
137
|
+
a full re-trace.
|
|
138
|
+
|
|
139
|
+
## Converting a raster to a vector — its own branch
|
|
140
|
+
|
|
141
|
+
Drawing it from a look fails, and it fails the same way every time: the outlines
|
|
142
|
+
"coincide within a few pixels" by eye and read 0.883 silhouette IoU when
|
|
143
|
+
measured. The procedure below reached 0.984 with the same tools.
|
|
144
|
+
|
|
145
|
+
### Trace to measure, construct to deliver
|
|
146
|
+
|
|
147
|
+
**The trace is the underlay by default, not the deliverable.** Trace the source
|
|
148
|
+
to measure and to align; then construct the deliverable over that underlay from
|
|
149
|
+
few points, palette colours and named shapes. Keep a trace AS the deliverable
|
|
150
|
+
only when the owner asks for maximum fidelity over editability, and say that is
|
|
151
|
+
what they are getting.
|
|
152
|
+
|
|
153
|
+
The reason is measured, not stylistic. In one session the traced mark scored
|
|
154
|
+
0.989 region IoU against the constructed one's 0.935 — and the trace was sent
|
|
155
|
+
back fifteen minutes after it was accepted, on criteria no score sees: a crown
|
|
156
|
+
cut at the crop edge, hairlines between segments, an off-palette spot, jagged
|
|
157
|
+
edges, 49 KB of edit-hostile points, and a face unreadable at 32 px. The
|
|
158
|
+
rebuild was 4.5 KB with 14 shapes and about 180 points. **The score is the
|
|
159
|
+
alignment check. It is never the acceptance.**
|
|
160
|
+
|
|
161
|
+
**When the score stops applying.** Once the owner's goal becomes a redesign
|
|
162
|
+
rather than a reproduction — different fingers, depth taken from a style
|
|
163
|
+
reference — the source-fidelity number measures agreement with something
|
|
164
|
+
nobody is still trying to match. Stop reporting it as progress and say why.
|
|
165
|
+
|
|
166
|
+
1. **Crop the source region with a margin, and make that crop the coordinate
|
|
167
|
+
system.** Write every vector coordinate in the crop's pixel units; fit the
|
|
168
|
+
viewBox to the content at the end, not at the start. **Widen the crop
|
|
169
|
+
whenever source content touches its edge** — a trace takes the crop border
|
|
170
|
+
for a contour, and a comparison against that same crop cannot see the cut.
|
|
171
|
+
One session lost a crown that way: the crop started five pixels below it.
|
|
172
|
+
The engine's `geometry/source-cut-by-frame` reading is the check.
|
|
173
|
+
2. **Derive geometry from the pixels, never by eye — then build over it.** One
|
|
174
|
+
traced silhouette that clips everything, then named regions split along an
|
|
175
|
+
edge map; smooth, resample and simplify each contour. The outer edge comes
|
|
176
|
+
from one contour and the holes come from the source. That trace is the
|
|
177
|
+
underlay; the shapes you ship are constructed on top of it.
|
|
178
|
+
3. **Fit colour, do not pick it.** Least-squares per region against that region's
|
|
179
|
+
own pixels; swap a linear gradient for a radial one only when the residual
|
|
180
|
+
actually drops.
|
|
181
|
+
4. **Classify near-white inside the mark as hole or paint from the source**, and
|
|
182
|
+
check it on a dark background **before** the first report. Near-white paint
|
|
183
|
+
where the source shows a hole is invisible on white and obvious on black.
|
|
184
|
+
5. **Keep text, wordmark and slogan out** unless they were asked for.
|
|
185
|
+
6. **Score every pass and every candidate change**, and keep a change only when
|
|
186
|
+
the score improves — a tried-and-worse idea is dropped by the number, not by
|
|
187
|
+
taste. Use the two readings the geometry comparison produces: silhouette IoU
|
|
188
|
+
over saturated regions, and mean colour error plus the share of pixels off by
|
|
189
|
+
more than 40/255 — broken down per region, so the worst region is named. The
|
|
190
|
+
score ranks passes against the source; it does not decide acceptance, and it
|
|
191
|
+
stops meaning anything once the goal becomes a redesign.
|
|
192
|
+
7. **Stop** at the declared tolerance, at the user's pass budget, or **on a
|
|
193
|
+
plateau** — whichever comes first. A plateau is two consecutive passes each
|
|
194
|
+
improving the score by less than 5 % relative: stop, report the residual's
|
|
195
|
+
cause, and offer the construct-or-redesign option instead of starting
|
|
196
|
+
another pass. An explicit pass budget from the user still wins when it is
|
|
197
|
+
smaller. Measured: twelve further scored passes took mean error 16.78 to
|
|
198
|
+
6.12 and the share off by 40 from 9.1 % to 1.5 %, and the owner said "still
|
|
199
|
+
unclean" twice; the plateau was named only after they brought a reference.
|
|
200
|
+
8. **Snapshot every delivered pass** as `<name>.pass-<n>.svg`, and diff the next
|
|
201
|
+
pass against the last accepted snapshot with `lint_svg_asset --baseline`.
|
|
202
|
+
Report which accepted properties carried forward. Restoring "version 4" is
|
|
203
|
+
then a copy, not a reconstruction — one session lost the same accepted
|
|
204
|
+
detail twice between hand edits, and the owner had to supply the file back
|
|
205
|
+
from their own downloads.
|
|
206
|
+
9. **Report the per-pass numbers, the cause of the remaining residual, and the
|
|
207
|
+
file size.** Fidelity costs bytes — one accepted conversion went 5.3 KB →
|
|
208
|
+
49.5 KB and nothing measured it. Each number carries the **registration**
|
|
209
|
+
it was taken against as `x,y,w,h` in the source's pixel frame, the
|
|
210
|
+
**scorer** that produced it (`ui:render`, or a named script) and the sample
|
|
211
|
+
resolution. Two scorers disagreed on one file by a factor of four and
|
|
212
|
+
neither number could be told from the other afterwards; a wordmark's frame
|
|
213
|
+
could not be recovered at all, and three plausible ones moved its IoU from
|
|
214
|
+
0.56 to 0.81.
|
|
215
|
+
|
|
216
|
+
Any tracing tool the host has may do the deriving, and a host with none can
|
|
217
|
+
write one. **The measurement is the procedure, not the tool.**
|
|
218
|
+
|
|
219
|
+
## Deliver, re-open, re-render
|
|
220
|
+
|
|
221
|
+
The last step reads every delivered file back **from its final path** in a fresh
|
|
222
|
+
browser context (`file://`, every other request aborted) and re-renders it from
|
|
223
|
+
there — not from the source text the agent wrote. Report path, byte size and
|
|
224
|
+
digest. An `img` delivery is additionally loaded through a host `<img>` and must
|
|
225
|
+
report a non-zero natural width.
|
|
226
|
+
|
|
227
|
+
**A file that does not re-open is not delivered.**
|
|
228
|
+
|
|
229
|
+
## Output format
|
|
230
|
+
|
|
231
|
+
1. **Delivery mode and asset class** — declared, not assumed.
|
|
232
|
+
2. **The file** — path, byte size, digest.
|
|
233
|
+
3. **Checks that ran** — the static check's finding count, the witness's
|
|
234
|
+
readings, and the status word from the table above.
|
|
235
|
+
4. **For a conversion** — the per-pass score table and the residual's cause,
|
|
236
|
+
each number carrying its **registration** (`x,y,w,h` in the source's pixel
|
|
237
|
+
frame), the scorer that produced it and the sample resolution, so a later
|
|
238
|
+
run can repeat the reading and no second scorer's number is quoted as the
|
|
239
|
+
first's.
|
|
240
|
+
5. **Variants** — for a `mark`, the small-size variant when the 16 and 32 px
|
|
241
|
+
captures lose the detail, and a light-on-dark variant when the contrast
|
|
242
|
+
reading is low on a capture's ground. Built, or named as missing. Never
|
|
243
|
+
silent: one wordmark shipped in a dark violet that is unreadable on a dark
|
|
244
|
+
ground, and the dark variant was simply not mentioned.
|
|
245
|
+
6. **Outlined lettering** — a word set from an installed font and converted to
|
|
246
|
+
outlines is reported with the font's name and whether its license allows
|
|
247
|
+
outlining into a distributed asset. An unknown license is reported as
|
|
248
|
+
unknown, never as permitted.
|
|
249
|
+
7. **Cost** — the reading the manifest carries (`bytes`, `elements`, `paths`,
|
|
250
|
+
`gradients`, `coordinates`), beside the fidelity numbers. No threshold: none
|
|
251
|
+
was measured, and a gate on bytes would have refused a 195 KB trace and a
|
|
252
|
+
59 KB accepted figure alike.
|
|
253
|
+
8. **What was looked at** — honestly, or nothing.
|
|
254
|
+
|
|
255
|
+
## Gotcha
|
|
256
|
+
|
|
257
|
+
- **A `<path>` is not evidence of a vector.** A raster embedded beside one dummy
|
|
258
|
+
path passes a presence-of-`<path>` check and is not a vector; a mark built
|
|
259
|
+
from `rect`/`circle` fails that check and is one.
|
|
260
|
+
- **CSS cannot stop SMIL.** `svg * { animation: none !important }` under an
|
|
261
|
+
emulated `reduce` leaves an `<animate>` running. Route the animation itself.
|
|
262
|
+
- **An `<img>`-delivered SVG never sees the OS motion preference.** The host
|
|
263
|
+
needs a `<picture>` with a `media="(prefers-reduced-motion: reduce)"` source
|
|
264
|
+
pointing at a static file.
|
|
265
|
+
- **`screenshot({ animations: 'disabled' })` does not freeze SMIL.** Use
|
|
266
|
+
`pauseAnimations()` + `setCurrentTime()`.
|
|
267
|
+
- **`transform-origin` without `transform-box` pivots against the view box**, not
|
|
268
|
+
the element — per element, so a correct sibling proves nothing about it.
|
|
269
|
+
- **`keySplines` outside [0,1] stops the animation outright** rather than
|
|
270
|
+
clamping it.
|
|
271
|
+
|
|
272
|
+
## Do NOT
|
|
273
|
+
|
|
274
|
+
- Do NOT report `verified` on a look, a parser pass, or a render of an earlier
|
|
275
|
+
draft.
|
|
276
|
+
- Do NOT say "matches" or "100 %" about a conversion without the two numbers and
|
|
277
|
+
the registration they were measured against.
|
|
278
|
+
- Do NOT rename ids or simplify paths as a side effect of a surgical edit.
|
|
279
|
+
- Do NOT restate motion, ARIA or render-security mechanism here — point at the
|
|
280
|
+
authority and let it own the rule.
|
|
281
|
+
- Do NOT add a rasteriser, a tracing dependency, or an optimiser to the write path.
|
|
282
|
+
|
|
283
|
+
## See also
|
|
284
|
+
|
|
285
|
+
> Named rather than linked, and that is a correctness property rather than a
|
|
286
|
+
> style one: this skill ships in four packs, so a relative link to an artifact
|
|
287
|
+
> that lives in only one of them resolves for a consumer who installed that pack
|
|
288
|
+
> and is dead for the other three. The names are stable; the paths are not
|
|
289
|
+
> promises this skill can keep.
|
|
290
|
+
|
|
291
|
+
- `iconography` — the set comes first; this skill is
|
|
292
|
+
for the glyph it lacks.
|
|
293
|
+
- `logo-generation` — the brand pipeline that
|
|
294
|
+
routes a geometric mark here.
|
|
295
|
+
- `image-provider-routing` — illustrative
|
|
296
|
+
vector art goes to a provider, not here.
|
|
297
|
+
- `fe-design` § Motion — the motion authority, in
|
|
298
|
+
`references/design-patterns.md` § *Motion — decision-tree and rationale*. The
|
|
299
|
+
SVG mechanism lines are step **6b, "Which mechanism carries it inside an
|
|
300
|
+
SVG?"** — `transform-box`, `pathLength`, the `keySplines` range, path-morph
|
|
301
|
+
command equality, and delivery mode picking the reduced-motion route. Cited
|
|
302
|
+
here and never restated.
|
|
303
|
+
- `frontend-render-security` § *The
|
|
304
|
+
patterns AI ships by default*, row **Untrusted SVG markup into an HTML sink**
|
|
305
|
+
— the sinks an SVG carries into a host origin, and what each delivery mode
|
|
306
|
+
can execute. Its § *Backstop greps* carries the grep that finds them.
|
|
307
|
+
- `design-intelligence` — diagram layout; its
|
|
308
|
+
geometric pre-checks are witnessed by the asset profile now.
|
|
309
|
+
- `accessibility-auditor` — the ARIA
|
|
310
|
+
corpus that answers what a graphic's accessible name has to be; its
|
|
311
|
+
`data/aria-patterns.csv` carries the **Meaningful standalone graphic** and
|
|
312
|
+
**Decorative graphic** rows this skill grounds against rather than copies.
|
|
313
|
+
- `canvas-design`, `wireframe`
|
|
314
|
+
— the two lanes that use SVG as an execution surface.
|
|
315
|
+
- `design-fidelity` — a provided artifact is
|
|
316
|
+
the spec; the baseline readout above is its surgical-edit witness.
|
|
317
|
+
- `docs/contracts/design-artifact-verification.md` — `frame_seek` and the other
|
|
318
|
+
primitives the witness depends on.
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
model_tier: inherit
|
|
3
3
|
name: wireframe
|
|
4
|
-
description: "Explore a flow or layout with 3+ disposable lo-fi greyscale wireframes on a named axis
|
|
4
|
+
description: "Explore a flow or layout with 3+ disposable lo-fi greyscale wireframes on a named axis. Use when the user wants to sketch directions or explore structure."
|
|
5
5
|
domain: product
|
|
6
6
|
personas: []
|
|
7
7
|
workspaces:
|
|
@@ -80,7 +80,10 @@ branded, recommendation-bearing). A single refined implementation →
|
|
|
80
80
|
|
|
81
81
|
1. **One file** (HTML or annotated markdown/SVG canvas) with ≥3 greyscale
|
|
82
82
|
variations side-by-side — flows as small storyboards (3–5 screens each);
|
|
83
|
-
no brand color, no styled typography, no real imagery.
|
|
83
|
+
no brand color, no styled typography, no real imagery. An SVG canvas is
|
|
84
|
+
authored under [`svg-authoring`](../svg-authoring/SKILL.md); its grays are
|
|
85
|
+
the wireframe's own non-decisions, so the fidelity floor does not reproduce
|
|
86
|
+
them as choices.
|
|
84
87
|
2. **Per-variation annotations** — 2–4 callouts naming the structural bet and
|
|
85
88
|
its trade-off, inline next to the variation.
|
|
86
89
|
3. **Decision-capture block** (after user pick) — chosen direction,
|
|
@@ -39,7 +39,7 @@ schema_version: 1
|
|
|
39
39
|
# CI guard: a release bump of `package.json` must update this value
|
|
40
40
|
# in lockstep — see scripts/check_template_pin_drift.ts (road-to-
|
|
41
41
|
# portable-runtime-and-update-check P3.3).
|
|
42
|
-
agent_config_version: "16.
|
|
42
|
+
agent_config_version: "16.5.0"
|
|
43
43
|
|
|
44
44
|
# --- Project identity ---
|
|
45
45
|
project:
|