@12ui/design 0.2.7 → 0.2.9

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.
Files changed (66) hide show
  1. package/README.md +29 -29
  2. package/dist/cli-corpus-command.d.ts.map +1 -1
  3. package/dist/cli-corpus-command.js +26 -35
  4. package/dist/cli-corpus-command.js.map +1 -1
  5. package/dist/cli-corpus-evidence.d.ts.map +1 -1
  6. package/dist/cli-corpus-evidence.js +34 -4
  7. package/dist/cli-corpus-evidence.js.map +1 -1
  8. package/dist/cli-corpus-reference-image.d.ts +13 -0
  9. package/dist/cli-corpus-reference-image.d.ts.map +1 -0
  10. package/dist/cli-corpus-reference-image.js +54 -0
  11. package/dist/cli-corpus-reference-image.js.map +1 -0
  12. package/dist/cli-corpus-run.d.ts +6 -0
  13. package/dist/cli-corpus-run.d.ts.map +1 -1
  14. package/dist/cli-corpus-run.js +15 -2
  15. package/dist/cli-corpus-run.js.map +1 -1
  16. package/dist/cli-corpus-types.d.ts +6 -1
  17. package/dist/cli-corpus-types.d.ts.map +1 -1
  18. package/dist/cli-corpus-types.js.map +1 -1
  19. package/dist/cli-image-batch-command.d.ts.map +1 -1
  20. package/dist/cli-image-batch-command.js +2 -1
  21. package/dist/cli-image-batch-command.js.map +1 -1
  22. package/dist/cli-image-command.d.ts.map +1 -1
  23. package/dist/cli-image-command.js +7 -1
  24. package/dist/cli-image-command.js.map +1 -1
  25. package/dist/cli-persistence.d.ts.map +1 -1
  26. package/dist/cli-persistence.js +8 -1
  27. package/dist/cli-persistence.js.map +1 -1
  28. package/dist/cli.js +2 -2
  29. package/dist/corpus-client.d.ts +15 -85
  30. package/dist/corpus-client.d.ts.map +1 -1
  31. package/dist/corpus-client.js +32 -10
  32. package/dist/corpus-client.js.map +1 -1
  33. package/dist/image-generation-batch-manifest.d.ts +2 -1
  34. package/dist/image-generation-batch-manifest.d.ts.map +1 -1
  35. package/dist/image-generation-batch-manifest.js +7 -1
  36. package/dist/image-generation-batch-manifest.js.map +1 -1
  37. package/dist/image-generation-error.d.ts +3 -0
  38. package/dist/image-generation-error.d.ts.map +1 -0
  39. package/dist/image-generation-error.js +30 -0
  40. package/dist/image-generation-error.js.map +1 -0
  41. package/dist/image-generation-evidence.d.ts +3 -1
  42. package/dist/image-generation-evidence.d.ts.map +1 -1
  43. package/dist/image-generation-evidence.js.map +1 -1
  44. package/dist/image-generation-request.d.ts +4 -0
  45. package/dist/image-generation-request.d.ts.map +1 -1
  46. package/dist/image-generation-request.js +3 -0
  47. package/dist/image-generation-request.js.map +1 -1
  48. package/dist/image-generation-run.d.ts.map +1 -1
  49. package/dist/image-generation-run.js +14 -4
  50. package/dist/image-generation-run.js.map +1 -1
  51. package/dist/image-generation-usage.d.ts +4 -0
  52. package/dist/image-generation-usage.d.ts.map +1 -1
  53. package/dist/image-generation-usage.js +37 -10
  54. package/dist/image-generation-usage.js.map +1 -1
  55. package/dist/index.d.ts +1 -1
  56. package/dist/index.d.ts.map +1 -1
  57. package/dist/index.js +1 -1
  58. package/dist/index.js.map +1 -1
  59. package/dist/legacy-skill-catalog.d.ts.map +1 -1
  60. package/dist/legacy-skill-catalog.js +20 -0
  61. package/dist/legacy-skill-catalog.js.map +1 -1
  62. package/package.json +2 -2
  63. package/skills/design/SKILL.md +119 -20
  64. package/skills/design/references/continuation-contract.md +60 -0
  65. package/skills/design/references/selection-contract.md +49 -15
  66. package/skills/design-search/SKILL.md +42 -12
@@ -1 +1 @@
1
- {"version":3,"file":"legacy-skill-catalog.js","sourceRoot":"","sources":["../src/legacy-skill-catalog.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AACzC,OAAO,EAAE,KAAK,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAC5D,OAAO,IAAI,MAAM,WAAW,CAAC;AAE7B,MAAM,CAAC,MAAM,kBAAkB,GAAG;IAChC,oBAAoB;IACpB,qBAAqB;IACrB,MA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,IAAI,QAAQ,CAAC,MAAM,KAAK,KAAK,CAAC,MAAM,IAAI,QAAQ,CAAC,IAAI,CAAC,CAAC,IAAI,EAAE,KAAK,EAAE,EAAE,CAAC,IAAI,KAAK,KAAK,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC;YAC9F,SAAS;QACX,CAAC;QACD,IAAI,KAAK,CAAC,KAAK,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,MAAM,CAAC,GAAG,CAAC,IAAI,CAAC,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;YAAE,OAAO,YAAY,CAAC;IACrF,CAAC;IACD,OAAO,SAAS,CAAC;AACnB,CAAC,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@12ui/design",
3
- "version": "0.2.7",
3
+ "version": "0.2.9",
4
4
  "type": "module",
5
5
  "description": "The canonical 12UI CLI, SDK, MCP server, and visual interface design skills",
6
6
  "main": "dist/index.js",
@@ -24,7 +24,7 @@
24
24
  "prepublishOnly": "npm run build"
25
25
  },
26
26
  "dependencies": {
27
- "@just-every/ensemble": "0.2.272",
27
+ "@just-every/ensemble": "0.2.274",
28
28
  "@modelcontextprotocol/sdk": "^1.29.0",
29
29
  "sharp": "^0.34.5"
30
30
  },
@@ -13,7 +13,11 @@ than recreating it manually.
13
13
 
14
14
  ## Choose the route
15
15
 
16
- - Finished screenshot or mockup: use `design-convert` directly.
16
+ - Finished screenshot or mockup to reproduce faithfully: use `design-convert`
17
+ directly.
18
+ - Existing screenshot supplied as a redesign source: choose an exploratory
19
+ redesign or a structure-preserving reskin below. It is not a corpus
20
+ inspiration image.
17
21
  - Small visual edit: change the existing project code. Do not search, generate,
18
22
  or convert.
19
23
  - Rough brief, new interface, or major redesign: use the workflow below.
@@ -26,21 +30,62 @@ Inspect the project before designing: its instructions, framework, routes,
26
30
  components, assets, conventions, validation commands, and existing user
27
31
  changes. Create the run directory under the system temporary directory.
28
32
 
33
+ If there is a redesign source, state a short preserve/change contract before
34
+ searching. Choose one mode:
35
+
36
+ - `exploratory-redesign`: preserve only named product/UX constraints and allow
37
+ layout and visual language to change.
38
+ - `structure-preserving-reskin`: preserve the named information architecture,
39
+ content hierarchy, and interactions; change only the named visual qualities.
40
+
41
+ If the source is a long page or contains more than the target screen, crop the
42
+ relevant first viewport into the system temporary run directory before search
43
+ or generation. Keep and hash both the original and prepared crop; do not make
44
+ the image model solve a whole-page composition inside one viewport.
45
+
29
46
  Search with the CLI; do not make a separate brief file:
30
47
 
31
48
  ```bash
32
49
  12ui corpus inspire \
33
50
  --query "<product, audience, surface, primary goal, personality>" \
51
+ --mode balanced \
34
52
  --count 4 \
35
- --aspect <landscape|portrait|square> \
36
53
  --out-dir <run-dir>/references
37
54
  ```
38
55
 
39
- Use the four real downloaded images in endpoint order. `manifest.json`
40
- contains their IDs, paths, hashes, roles, arms, cells, relevance, relevance
41
- percentiles, and quality percentiles. Preserve those values; do not rerank or
42
- invent a composite score. If interrupted, run `12ui corpus resume --out-dir
43
- <run-dir>/references` rather than starting another search.
56
+ `balanced` is the recommended mode and the default. Run it once; do not compare
57
+ all three modes speculatively. Change modes only after inspecting a complete
58
+ Balanced set and recording why it failed the brief:
59
+
60
+ - Use `--mode direct` when Balanced is visually competent but semantically
61
+ diffuse or misses the literal product or screen requested.
62
+ - Use `--mode adventurer` when Balanced is on-brief but too conventional or
63
+ repetitive to author four meaningfully distinct directions.
64
+
65
+ Use at most one fallback mode in a new output directory. A transport error,
66
+ ambiguous request, underfilled set, or interrupted download is not a retrieval
67
+ failure: resume the original Balanced attempt with `12ui corpus resume` and do
68
+ not switch modes.
69
+
70
+ For either redesign mode, add the existing screenshot to retrieval:
71
+
72
+ ```bash
73
+ 12ui corpus inspire \
74
+ --query "<preserve/change contract and desired direction>" \
75
+ --mode balanced \
76
+ --reference-image <redesign-source.png> \
77
+ --count 4 \
78
+ --out-dir <run-dir>/references
79
+ ```
80
+
81
+ This performs one image-and-text-conditioned search. The redesign source stays
82
+ distinct from the four returned corpus inspirations.
83
+
84
+ Use the four real downloaded images in endpoint order. `manifest.json` records
85
+ the locked mode, IDs, paths, hashes, and returned provenance. Preserve that
86
+ order and evidence; do not rerank or invent a composite score. If interrupted,
87
+ run `12ui corpus resume --out-dir <run-dir>/references` rather than starting
88
+ another search.
44
89
 
45
90
  ### 2. Generate four directions
46
91
 
@@ -50,7 +95,8 @@ imagery where useful, strong hierarchy, breathing room, and sound UX. Make the
50
95
  result striking at first glance, but keep the prompt to a few sentences and
51
96
  let the image model choose layout, style, palette, typography, and detail.
52
97
 
53
- Use this shape as guidance, not a form to fill mechanically:
98
+ For new interfaces and exploratory redesigns, use this shape as guidance, not
99
+ a form to fill mechanically:
54
100
 
55
101
  ```text
56
102
  Create one distinctive [desktop/mobile] [interface] for [product and purpose].
@@ -61,14 +107,33 @@ the visual language yourself. Fill the canvas without a device or presentation
61
107
  frame.
62
108
  ```
63
109
 
64
- Map reference 1 to candidate A, 2 to B, 3 to C, and 4 to D. Each candidate gets
65
- exactly one reference. Never combine references in a single generation.
66
- Before writing the prompts, derive one short, visibly grounded direction from
67
- each paired reference—such as airy editorial, tactile retail, cinematic, or
110
+ For a structure-preserving reskin, be explicit about what is fixed but leave
111
+ visual choices open:
112
+
113
+ ```text
114
+ Reskin this [desktop/mobile] interface for [product and purpose]. Preserve the
115
+ attached source's information architecture, content hierarchy, primary actions,
116
+ and interactions. Change only [named visual qualities]. Show the first viewport
117
+ or primary screen and choose the palette, typography, spacing, and detail.
118
+ Fill the canvas without a device or presentation frame.
119
+ ```
120
+
121
+ Map corpus reference 1 to candidate A, 2 to B, 3 to C, and 4 to D. Before
122
+ writing the prompts, derive one short, visibly grounded direction from each
123
+ paired corpus reference—such as airy editorial, tactile retail, cinematic, or
68
124
  playful illustration. Use that as the candidate's one desired quality, and
69
125
  make the four directions meaningfully different. Do not describe the whole
70
126
  reference or prescribe its layout, palette, or techniques.
71
127
 
128
+ Use exactly one image reference per generation; never combine images:
129
+
130
+ - New interface or `exploratory-redesign`: each candidate uses its paired
131
+ corpus image. The redesign source conditions search but is not also attached
132
+ to generation.
133
+ - `structure-preserving-reskin`: every candidate uses the redesign source as
134
+ its sole image reference. Its paired corpus image contributes only the short
135
+ textual direction above; do not attach that corpus image to generation.
136
+
72
137
  Write one batch manifest in the run directory with four candidates:
73
138
 
74
139
  ```json
@@ -77,11 +142,12 @@ Write one batch manifest in the run directory with four candidates:
77
142
  "projectRoot": "<absolute-project-root>",
78
143
  "provider": "auto",
79
144
  "aspect": "landscape",
145
+ "referenceMode": "inspiration",
80
146
  "candidates": [
81
147
  {
82
148
  "id": "A",
83
149
  "prompt": "<short candidate prompt>",
84
- "reference": "<reference-1-path>",
150
+ "reference": "<single-generation-reference-path>",
85
151
  "out": "<run-dir>/candidates/A.png",
86
152
  "idempotencyKey": "<stable-A-key>"
87
153
  }
@@ -89,7 +155,11 @@ Write one batch manifest in the run directory with four candidates:
89
155
  }
90
156
  ```
91
157
 
92
- Include A-D, each with its mapped reference, unique PNG output, and stable key.
158
+ Include A-D, each with its one allowed image reference, unique PNG output, and
159
+ stable key. Set the top-level `referenceMode` to `inspiration` for new and
160
+ exploratory candidates, or `preserve-structure` when the redesign source is
161
+ the sole reference. This is persisted semantic evidence; GPT Image 2 already
162
+ processes image inputs at fixed high fidelity, so do not add `input_fidelity`.
93
163
  Then run one foreground command:
94
164
 
95
165
  ```bash
@@ -103,7 +173,7 @@ from one host task: that tool path may queue them serially. Never retry a failed
103
173
  or ambiguous candidate, switch providers after dispatch, use cached samples, or
104
174
  leave generation in detached background work.
105
175
 
106
- ### 3. Select and convert
176
+ ### 3. Select
107
177
 
108
178
  Inspect all candidates at original detail. Choose the best eligible direction
109
179
  for the brief, hierarchy, usability, personality, accessibility, feasibility,
@@ -117,18 +187,47 @@ provenance or a tie-breaker between visibly strong candidates.
117
187
 
118
188
  Write `<run-dir>/selection.json` using
119
189
  [the selection contract](references/selection-contract.md). Record exact
120
- prompts, references, candidate paths and hashes, winner, specific rejection
121
- reasons, and visible rationale. Convert only that winner with `design-convert`.
190
+ prompts, original/prepared redesign-source paths and hashes, preserve/change contract, design mode,
191
+ reference policy, corpus directions, candidate paths and hashes, winner,
192
+ specific rejection reasons, and visible rationale.
193
+
194
+ ### 4. Extend and convert
195
+
196
+ If the winner represents the complete simple surface, convert only that winner
197
+ with `design-convert` and continue to integration.
198
+
199
+ When the first image intentionally omitted later page viewports, routes, or app
200
+ states, freeze the winner as the sole visual reference for every continuation.
201
+ Plan 2-16 useful continuations. Prompt only the state, content, actions, and
202
+ route purpose that must change; do not redescribe palette, typography, layout,
203
+ style, or visual techniques. Set the continuation batch `referenceMode` to
204
+ `inspiration`: the winner supplies the visual system, not a first-viewport
205
+ composition to clone. Never attach a corpus image, composite, prior
206
+ continuation, or predecessor. If a particular app-state edit must preserve the
207
+ winner's exact structure, put only those edits in a separate
208
+ `preserve-structure` batch rather than changing the continuation default.
209
+
210
+ Submit the winner's base LayerDoc conversion in detached mode, then immediately
211
+ run one foreground `12ui image generate-batch` for all continuations so image
212
+ generation overlaps the base conversion. Inspect every result before accepting
213
+ it. Convert accepted continuation images concurrently with distinct stable
214
+ idempotency keys; never retry or replace an ambiguous generation.
215
+
216
+ For ordered viewports of one continuous page, use the conversion package API
217
+ to preserve page order. Integrate independent web routes, app states, or mobile
218
+ screens as separate surfaces. Record the run in `<run-dir>/continuations.json`
219
+ using [the continuation contract](references/continuation-contract.md).
220
+
122
221
  If conversion is interrupted, resume its ID or repeat the exact create request
123
222
  with the same idempotency key; do not convert another candidate as a shortcut.
124
223
 
125
- ### 4. Integrate and verify
224
+ ### 5. Integrate and verify
126
225
 
127
226
  Inspect generated files before merging the smallest coherent set into the
128
227
  project. Preserve routing, components, tokens, accessibility, dependencies,
129
228
  and unrelated changes. Add the exact copy, interactions, responsive behavior,
130
- later sections, and routes intentionally omitted from the image prompt while
131
- extending the winning visual system.
229
+ later sections, and routes intentionally omitted from the first-viewport prompt
230
+ while extending the visual system from the winner and accepted continuations.
132
231
 
133
232
  Run focused checks, launch the real interface, exercise interactions, and
134
233
  compare it with the winner at the source viewport plus representative narrower
@@ -0,0 +1,60 @@
1
+ # Continuation evidence contract
2
+
3
+ Write `continuations.json` when the selected first viewport does not cover the
4
+ complete interface. The winner remains the sole reference for every generation.
5
+
6
+ ```json
7
+ {
8
+ "version": 1,
9
+ "createdAt": "<ISO-8601>",
10
+ "selectionPath": "<absolute selection.json path>",
11
+ "winner": {
12
+ "id": "A",
13
+ "path": "<absolute winner PNG path>",
14
+ "sha256": "<winner sha256>"
15
+ },
16
+ "baseConversion": {
17
+ "idempotencyKey": "<stable key>",
18
+ "conversionId": "<base LayerDoc conversion id>",
19
+ "resultEvidencePath": "<absolute result evidence path>"
20
+ },
21
+ "generation": {
22
+ "referenceMode": "inspiration",
23
+ "manifestPath": "<absolute batch manifest path>",
24
+ "manifestSha256": "<sha256>",
25
+ "batchAttemptPath": "<absolute batch attempt path>"
26
+ },
27
+ "continuations": [
28
+ {
29
+ "id": "viewport-2",
30
+ "kind": "<continuous-page|web-route|app-state|mobile-screen>",
31
+ "order": 2,
32
+ "prompt": "<semantic content, actions, state, and route purpose only>",
33
+ "promptSha256": "<sha256>",
34
+ "referencePath": "<same winner path>",
35
+ "referenceSha256": "<same winner sha256>",
36
+ "outputPath": "<absolute generated PNG path>",
37
+ "outputSha256": "<sha256>",
38
+ "attemptEvidencePath": "<absolute attempt path>",
39
+ "accepted": true,
40
+ "rejectionReason": null,
41
+ "conversionId": "<accepted image conversion id or null>",
42
+ "conversionEvidencePath": "<absolute evidence path or null>"
43
+ }
44
+ ],
45
+ "integration": {
46
+ "mode": "<ordered-package|independent-surfaces>",
47
+ "packageEvidencePath": "<absolute package evidence path or null>"
48
+ }
49
+ }
50
+ ```
51
+
52
+ Include 2-16 continuation entries. Every entry must repeat the winner path and
53
+ hash; never substitute a corpus image, composite, prior continuation, or
54
+ predecessor. The default continuation batch uses `inspiration`, because the
55
+ winner supplies a visual system rather than a first-viewport composition to
56
+ clone. If an intentional app-state edit must preserve exact structure, record
57
+ it in a separate `preserve-structure` batch. Preserve rejected generations
58
+ with a visible reason and null conversion fields. For `ordered-package`,
59
+ record the package evidence and keep continuous-page order exact. Never store
60
+ credentials or invent IDs or hashes.
@@ -5,12 +5,31 @@ prompt text so a resumed run cannot silently select different evidence.
5
5
 
6
6
  ```json
7
7
  {
8
- "version": 3,
8
+ "version": 6,
9
9
  "createdAt": "<ISO-8601>",
10
10
  "requestSummary": "<concise implementation contract>",
11
11
  "viewportMode": "<first-viewport|primary-state|single-screen|complete-simple-surface>",
12
+ "designMode": "<new-interface|exploratory-redesign|structure-preserving-reskin>",
13
+ "redesignSource": {
14
+ "originalPath": "<absolute source path, or null when absent>",
15
+ "originalSha256": "<source sha256, or null when absent>",
16
+ "preparedPath": "<absolute crop or original path, or null when absent>",
17
+ "preparedSha256": "<prepared sha256, or null when absent>",
18
+ "preparation": "<none|first-viewport-crop>"
19
+ },
20
+ "contract": {
21
+ "preserve": ["<specific constraint>"],
22
+ "change": ["<specific intended change>"]
23
+ },
24
+ "referencePolicy": {
25
+ "retrieval": "<text-only|text-and-redesign-source>",
26
+ "generation": "<one-corpus-image-per-candidate|redesign-source-only>",
27
+ "imagesPerGeneration": 1
28
+ },
12
29
  "corpus": {
13
30
  "query": "<exact query>",
31
+ "mode": "<direct|balanced|adventurer>",
32
+ "fallback": null,
14
33
  "idempotencyKey": "<manifest value>",
15
34
  "setId": "<manifest value>",
16
35
  "references": [
@@ -18,16 +37,12 @@ prompt text so a resumed run cannot silently select different evidence.
18
37
  "id": "<id-1>",
19
38
  "path": "<absolute path>",
20
39
  "sha256": "<sha256>",
21
- "role": "<core|stretch>",
22
- "arm": "<returned arm>",
23
- "cell": "<returned cell or null>",
24
- "relevance": 0,
25
- "relevancePercentile": 0,
26
- "qualityPercentile": 0
40
+ "aspect": "<portrait|landscape|square>"
27
41
  }
28
42
  ]
29
43
  },
30
44
  "generation": {
45
+ "referenceMode": "<inspiration|preserve-structure>",
31
46
  "manifestPath": "<absolute generation manifest path>",
32
47
  "manifestSha256": "<sha256>",
33
48
  "batchAttemptPath": "<absolute batch attempt path>"
@@ -39,9 +54,11 @@ prompt text so a resumed run cannot silently select different evidence.
39
54
  "sha256": "<sha256>",
40
55
  "prompt": "<exact prompt>",
41
56
  "promptSha256": "<sha256>",
42
- "referenceId": "<id-1>",
43
- "referencePath": "<absolute path>",
44
- "referenceSha256": "<sha256>",
57
+ "directionReferenceId": "<paired corpus id-1>",
58
+ "direction": "<short visibly grounded text direction>",
59
+ "generationReferencePath": "<paired corpus path or redesign-source path>",
60
+ "generationReferenceSha256": "<sha256>",
61
+ "referenceMode": "<inspiration|preserve-structure>",
45
62
  "provider": "<codex|openai>",
46
63
  "idempotencyKey": "<stable key>",
47
64
  "providerIdempotencyEnforced": false,
@@ -55,8 +72,25 @@ prompt text so a resumed run cannot silently select different evidence.
55
72
  ```
56
73
 
57
74
  Include exactly four corpus references and candidates in endpoint order: A/1,
58
- B/2, C/3, D/4. Copy corpus metrics from `manifest.json`, and generation fields
59
- from the batch and candidate attempt files. Never store credentials or invent
60
- IDs, metrics, or provider guarantees. The winner has no rejection reasons;
61
- every other candidate has at least one specific visible reason. Set
62
- `providerIdempotencyEnforced` only to the recorded CLI value.
75
+ B/2, C/3, D/4. Copy the corpus mode and reference evidence from
76
+ `manifest.json`, and generation fields from the batch and candidate attempt
77
+ files. Never store credentials or invent IDs or provider guarantees. The winner
78
+ has no rejection reasons; every other candidate has at least one specific
79
+ visible reason. Set `providerIdempotencyEnforced` only to the recorded CLI
80
+ value.
81
+
82
+ Keep `corpus.fallback` null for the recommended Balanced result. If Direct or
83
+ Adventurer was used after a complete Balanced set failed the brief, replace it
84
+ with `{ "fromMode": "balanced", "reason": "<visible failure>",
85
+ "manifestPath": "<prior absolute manifest path>", "manifestSha256":
86
+ "<sha256>" }`. Do not record a transport or download failure as a mode fallback.
87
+
88
+ For `new-interface`, use null redesign-source paths/hashes, `text-only` retrieval, and one
89
+ paired corpus image per generation. For `exploratory-redesign`, record the
90
+ original and prepared source for retrieval but still use one paired corpus
91
+ image per generation. For `structure-preserving-reskin`, use the prepared
92
+ redesign source as the sole generation
93
+ image for all four candidates; each paired corpus image is represented only by
94
+ its short textual `direction`. Never attach the redesign source and a corpus
95
+ image to the same generation. Use `inspiration` reference mode for the first two
96
+ cases and `preserve-structure` for the last.
@@ -15,11 +15,12 @@ Write a concise query covering the product, audience, primary goal, surface,
15
15
  and desired personality. Describe the design problem, not every section,
16
16
  control, exact string, or brand to imitate.
17
17
 
18
- Standalone search defaults to four results:
18
+ Inspiration retrieval defaults to four results:
19
19
 
20
20
  ```bash
21
21
  12ui corpus inspire \
22
22
  --query "<concise interface concept>" \
23
+ --mode balanced \
23
24
  --out-dir <references-dir>
24
25
  ```
25
26
 
@@ -28,19 +29,47 @@ Respect an explicit requested count:
28
29
  ```bash
29
30
  12ui corpus inspire \
30
31
  --query "<concise interface concept>" \
32
+ --mode balanced \
31
33
  --count <requested-count> \
32
34
  --out-dir <references-dir>
33
35
  ```
34
36
 
35
- Add `--aspect landscape|portrait|square` when the target is known. Prefer
36
- direct `--query`; use `--query-file` only when quoting genuinely requires it.
37
- Add `--origin` only when the task deliberately targets another deployment.
37
+ `balanced` is the recommended mode and the default. Honor an explicit user
38
+ choice of `direct` or `adventurer`; otherwise run Balanced once and inspect the
39
+ complete set before changing modes. Use `--mode direct` only when Balanced is
40
+ semantically diffuse or misses the literal requested surface. Use
41
+ `--mode adventurer` only when Balanced is on-brief but too conventional or
42
+ repetitive. Use at most one fallback in a new output directory, and record the
43
+ visible failure that justified it. Do not run all three modes for comparison.
44
+
45
+ Prefer direct `--query`; use `--query-file` only when quoting genuinely
46
+ requires it. Add `--origin` only when the task deliberately targets another
47
+ deployment.
48
+
49
+ For a redesign, distinguish the user's existing interface from corpus
50
+ inspiration. Send that redesign source into retrieval so visual structure can
51
+ condition the ranked space alongside the text:
52
+
53
+ ```bash
54
+ 12ui corpus inspire \
55
+ --query "<what to preserve, what to change, desired direction>" \
56
+ --mode balanced \
57
+ --reference-image <existing-interface.png> \
58
+ --count 4 \
59
+ --out-dir <references-dir>
60
+ ```
61
+
62
+ The command accepts one PNG, JPEG, or WebP source, records its absolute path,
63
+ SHA-256, media type, and size locally, and uploads its bytes privately for one
64
+ image-and-text embedding. The source is not one of the returned references and
65
+ its bytes are not persisted by 12UI. If the same source path changes before a
66
+ resume, stop rather than silently searching with different evidence.
38
67
 
39
68
  The command reserves the output directory, records request/response evidence,
40
69
  downloads full images in parallel, and writes `manifest.json`. Validate the
41
- count, unique IDs, decodable files, and hashes. Return the exact endpoint order
42
- and each reference's role, arm, cell, relevance, relevance percentile, and
43
- quality percentile. Do not recalculate, reorder, average, or normalize them.
70
+ locked mode, count, unique IDs, decodable files, and hashes. Return the exact
71
+ endpoint order and recorded reference evidence. Do not recalculate or reorder
72
+ the result.
44
73
 
45
74
  ## Resume
46
75
 
@@ -52,9 +81,10 @@ For an interrupted or ambiguous attempt, keep its directory and run:
52
81
 
53
82
  Reuse a valid completed manifest. Never delete evidence, start a replacement
54
83
  request for the unchanged query, or fill missing slots with cached or invented
55
- references. If resume remains ambiguous or underfilled, report the stable key
56
- and evidence path and stop.
84
+ references. A transport error, ambiguous request, underfilled set, or download
85
+ failure is not a reason to change modes. If resume remains ambiguous or
86
+ underfilled, report the stable key and evidence path and stop.
57
87
 
58
- Hand off the manifest path, idempotency key, set ID, ordered IDs, image paths,
59
- hashes, returned metrics, and usage notice. A `design` run requires exactly
60
- four valid references before generation.
88
+ Hand off the manifest path, idempotency key, set ID, locked mode, ordered IDs,
89
+ image paths, hashes, redesign-source evidence when present, and usage notice. A
90
+ `design` run requires exactly four valid references before generation.