grimoire-wizard 0.3.1 → 0.4.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.
Files changed (37) hide show
  1. package/README.md +173 -18
  2. package/dist/cli.js +503 -97
  3. package/dist/cli.js.map +1 -1
  4. package/dist/index.d.ts +107 -3
  5. package/dist/index.js +832 -367
  6. package/dist/index.js.map +1 -1
  7. package/examples/json/all-features.json +66 -0
  8. package/examples/json/appstore-screenshot-wizard.json +362 -0
  9. package/examples/json/appstore-upload.json +104 -0
  10. package/examples/json/basic.json +72 -0
  11. package/examples/json/batch-generate.json +186 -0
  12. package/examples/json/brief-builder.json +519 -0
  13. package/examples/json/conditional.json +155 -0
  14. package/examples/json/cost-analyzer.json +83 -0
  15. package/examples/json/demo.json +130 -0
  16. package/examples/json/scraper-selector.json +63 -0
  17. package/examples/json/themed-catppuccin.json +39 -0
  18. package/examples/json/themed.json +103 -0
  19. package/examples/json/with-checks.json +47 -0
  20. package/examples/yaml/appstore-screenshot-wizard.yaml +321 -0
  21. package/examples/yaml/appstore-upload.yaml +84 -0
  22. package/examples/yaml/batch-generate.yaml +156 -0
  23. package/examples/yaml/brief-builder.yaml +429 -0
  24. package/examples/yaml/cost-analyzer.yaml +69 -0
  25. package/examples/yaml/pipeline.yaml +35 -0
  26. package/examples/yaml/scraper-selector.yaml +52 -0
  27. package/examples/yaml/themed-catppuccin.yaml +31 -0
  28. package/package.json +1 -1
  29. /package/examples/{all-features.yaml → yaml/all-features.yaml} +0 -0
  30. /package/examples/{base.yaml → yaml/base.yaml} +0 -0
  31. /package/examples/{basic.yaml → yaml/basic.yaml} +0 -0
  32. /package/examples/{conditional.yaml → yaml/conditional.yaml} +0 -0
  33. /package/examples/{demo.yaml → yaml/demo.yaml} +0 -0
  34. /package/examples/{ebay-mcp-setup.yaml → yaml/ebay-mcp-setup.yaml} +0 -0
  35. /package/examples/{extended.yaml → yaml/extended.yaml} +0 -0
  36. /package/examples/{themed.yaml → yaml/themed.yaml} +0 -0
  37. /package/examples/{with-checks.yaml → yaml/with-checks.yaml} +0 -0
@@ -0,0 +1,321 @@
1
+ meta:
2
+ name: "App Store Screenshot Wizard"
3
+ description: "Generate beautiful AI-powered app store screenshots"
4
+ version: "1.0.0"
5
+ review: true
6
+
7
+ theme:
8
+ preset: catppuccin
9
+
10
+ steps:
11
+ # ── Generation Setup ──────────────────────────────────────────────
12
+
13
+ - id: generation-mode
14
+ type: select
15
+ group: "Generation Setup"
16
+ message: "What would you like to generate?"
17
+ default: app_store_screenshots
18
+ options:
19
+ - { value: app_store_screenshots, label: "App Store Screenshots", hint: "Device-framed marketing screenshots with store-specific dimensions" }
20
+ - { value: app_ui, label: "App UI Screens", hint: "Consistent app UI screens driven by a concept brief design system" }
21
+ - { value: web_ui, label: "Web UI Screens", hint: "SaaS dashboards, landing pages, and web application screens" }
22
+ - { value: design_system, label: "Design System Preview", hint: "Component and token showcase for visual consistency review" }
23
+
24
+ - id: platform-preset
25
+ type: select
26
+ group: "Generation Setup"
27
+ message: "Target platform"
28
+ when:
29
+ field: generation-mode
30
+ equals: app_store_screenshots
31
+ default: custom
32
+ options:
33
+ - { value: app_store, label: "Apple App Store", hint: "iPhone + iPad" }
34
+ - { value: google_play, label: "Google Play Store", hint: "Phone + Tablet" }
35
+ - { value: both, label: "Both Platforms", hint: "App Store + Google Play" }
36
+ - { value: custom, label: "Custom Selection", hint: "Choose devices manually" }
37
+
38
+ - id: providers
39
+ type: multiselect
40
+ group: "Generation Setup"
41
+ message: "Select AI providers"
42
+ min: 1
43
+ default: ["gemini"]
44
+ options:
45
+ - { value: gemini, label: "Gemini" }
46
+ - { value: openai, label: "OpenAI" }
47
+
48
+ # ── App Details ────────────────────────────────────────────────────
49
+
50
+ - id: app-name
51
+ type: text
52
+ group: "App Details"
53
+ message: "App name"
54
+ validate:
55
+ - rule: required
56
+ - rule: minLength
57
+ value: 1
58
+
59
+ - id: app-description
60
+ type: text
61
+ group: "App Details"
62
+ message: "Describe your app"
63
+ validate:
64
+ - rule: required
65
+ - rule: minLength
66
+ value: 10
67
+
68
+ # ── Visual Style ───────────────────────────────────────────────────
69
+
70
+ - id: visual-style
71
+ type: select
72
+ group: "Visual Style"
73
+ message: "Visual style"
74
+ default: auto
75
+ options:
76
+ - { value: auto, label: "Auto (AI picks best style)", hint: "Let the Creative Director choose" }
77
+ - { value: photorealistic, label: "Photorealistic" }
78
+ - { value: 3d-cartoon, label: "3D Cartoon" }
79
+ - { value: isometric, label: "Isometric" }
80
+ - { value: claymorphism, label: "Claymorphism" }
81
+ - { value: flat-2d, label: "Flat 2D" }
82
+ - { value: illustration, label: "Illustration" }
83
+ - { value: freestyle, label: "Freestyle (AI-selected)", hint: "AI picks the most distinctive style" }
84
+
85
+ # ── Content Settings ───────────────────────────────────────────────
86
+
87
+ - id: screenshot-count
88
+ type: number
89
+ group: "Content Settings"
90
+ message: "How many screenshots?"
91
+ default: 10
92
+ min: 1
93
+ max: 20
94
+
95
+ - id: reference-images
96
+ type: select
97
+ group: "Content Settings"
98
+ message: "Reference images for UI matching"
99
+ default: none
100
+ options:
101
+ - { value: none, label: "None", hint: "Generate UI from description only" }
102
+ - { value: single, label: "Single screenshot", hint: "Provide one reference image" }
103
+ - { value: folder, label: "Folder of screenshots", hint: "Multiple UI screenshots for 1:1 matching" }
104
+
105
+ - id: reference-image-path
106
+ type: text
107
+ group: "Content Settings"
108
+ message: "Path to screenshot image"
109
+ when:
110
+ field: reference-images
111
+ equals: single
112
+ placeholder: "/path/to/screenshot.png"
113
+ validate:
114
+ - rule: required
115
+
116
+ - id: reference-folder-path
117
+ type: text
118
+ group: "Content Settings"
119
+ message: "Path to folder with UI screenshots"
120
+ when:
121
+ field: reference-images
122
+ equals: folder
123
+ placeholder: "/path/to/screenshots/"
124
+ validate:
125
+ - rule: required
126
+
127
+ - id: design-reference
128
+ type: select
129
+ group: "Content Settings"
130
+ message: "Design reference"
131
+ default: none
132
+ options:
133
+ - { value: none, label: "None", hint: "AI picks its own creative direction" }
134
+ - { value: dribbble, label: "From dribbble-inspirations", hint: "Pick a professional design to match" }
135
+ - { value: custom, label: "Custom image path", hint: "Provide any image file as reference" }
136
+
137
+ - id: design-reference-path
138
+ type: text
139
+ group: "Content Settings"
140
+ message: "Path to design reference image"
141
+ when:
142
+ field: design-reference
143
+ equals: custom
144
+ placeholder: "/path/to/design-reference.png"
145
+ validate:
146
+ - rule: required
147
+
148
+ # ── Device Targets ─────────────────────────────────────────────────
149
+
150
+ - id: device-targets
151
+ type: multiselect
152
+ group: "Device Targets"
153
+ message: "Target devices"
154
+ when:
155
+ any:
156
+ - { field: platform-preset, equals: custom }
157
+ - { field: generation-mode, notEquals: app_store_screenshots }
158
+ min: 1
159
+ default: ["iphone"]
160
+ options:
161
+ - { value: iphone, label: "iPhone" }
162
+ - { value: ipad, label: "iPad" }
163
+ - { value: watch, label: "Apple Watch" }
164
+ - { value: android-phone, label: "Android Phone" }
165
+ - { value: android-tablet, label: "Android Tablet" }
166
+
167
+ # ── AI Models ──────────────────────────────────────────────────────
168
+
169
+ - id: gemini-image-model
170
+ type: select
171
+ group: "AI Models"
172
+ message: "Gemini image generation model"
173
+ when:
174
+ field: providers
175
+ includes: gemini
176
+ default: gemini-3.1-flash-image-preview
177
+ options:
178
+ - { value: gemini-3.1-flash-image-preview, label: "Flash (Fast & Cheap)", hint: "Near-Pro quality at ~$0.067/img" }
179
+ - { value: gemini-3-pro-image-preview, label: "Pro (Best Quality)", hint: "Top quality, 94% text accuracy — $0.134/img" }
180
+
181
+ - id: gemini-text-model
182
+ type: select
183
+ group: "AI Models"
184
+ message: "Gemini pipeline text model"
185
+ when:
186
+ field: providers
187
+ includes: gemini
188
+ default: gemini-2.5-flash
189
+ options:
190
+ - { value: gemini-2.5-flash, label: "Gemini Flash (Fast)", hint: "Fast pipeline stages, good quality" }
191
+ - { value: gemini-2.5-pro, label: "Gemini Pro (Best Prompts)", hint: "Higher quality prompt refinement" }
192
+ - { value: claude-sonnet-4-20250514, label: "Claude Sonnet 4 (Scoring)", hint: "Excellent visual judgment" }
193
+ - { value: claude-haiku-4-20250414, label: "Claude Haiku 4 (Fast Scoring)", hint: "Fast and cheap visual scoring" }
194
+
195
+ - id: openai-image-model
196
+ type: select
197
+ group: "AI Models"
198
+ message: "OpenAI image generation model"
199
+ when:
200
+ field: providers
201
+ includes: openai
202
+ default: gpt-image-1
203
+ options:
204
+ - { value: gpt-image-1, label: "GPT Image 1", hint: "OpenAI image generation model" }
205
+
206
+ - id: openai-text-model
207
+ type: select
208
+ group: "AI Models"
209
+ message: "OpenAI pipeline text model"
210
+ when:
211
+ field: providers
212
+ includes: openai
213
+ default: gpt-4o-mini
214
+ options:
215
+ - { value: gpt-4o, label: "GPT-4o", hint: "Advanced reasoning and generation" }
216
+ - { value: gpt-4o-mini, label: "GPT-4o Mini", hint: "Fast and efficient generation" }
217
+
218
+ # ── Marketing Copy ─────────────────────────────────────────────────
219
+
220
+ - id: headline-prefix
221
+ type: text
222
+ group: "Marketing Copy"
223
+ message: "Headline prefix above device"
224
+ placeholder: "Leave empty to omit"
225
+ default: ""
226
+ required: false
227
+
228
+ - id: cta-badge
229
+ type: text
230
+ group: "Marketing Copy"
231
+ message: "CTA badge text"
232
+ placeholder: "Leave empty for no badge"
233
+ default: ""
234
+ required: false
235
+
236
+ - id: badge-position
237
+ type: select
238
+ group: "Marketing Copy"
239
+ message: "Badge position"
240
+ when:
241
+ field: cta-badge
242
+ isNotEmpty: true
243
+ default: bottom-right
244
+ options:
245
+ - { value: bottom-right, label: "Bottom-right" }
246
+ - { value: bottom-left, label: "Bottom-left" }
247
+ - { value: top-right, label: "Top-right" }
248
+
249
+ # ── Localization ───────────────────────────────────────────────────
250
+
251
+ - id: want-locales
252
+ type: confirm
253
+ group: "Localization"
254
+ message: "Generate for multiple languages?"
255
+ default: false
256
+
257
+ - id: locales
258
+ type: multiselect
259
+ group: "Localization"
260
+ message: "Select target locales"
261
+ when:
262
+ field: want-locales
263
+ equals: true
264
+ min: 1
265
+ options:
266
+ - { value: en, label: "English" }
267
+ - { value: ja, label: "Japanese" }
268
+ - { value: de, label: "German" }
269
+ - { value: es, label: "Spanish" }
270
+ - { value: fr, label: "French" }
271
+ - { value: pt-BR, label: "Portuguese (Brazil)" }
272
+ - { value: ko, label: "Korean" }
273
+ - { value: zh-CN, label: "Chinese (Simplified)" }
274
+ - { value: it, label: "Italian" }
275
+ - { value: ar, label: "Arabic" }
276
+
277
+ # ── Advanced Options ───────────────────────────────────────────────
278
+
279
+ - id: advanced-options
280
+ type: multiselect
281
+ group: "Advanced Options"
282
+ message: "Advanced options"
283
+ required: false
284
+ options:
285
+ - { value: variations, label: "Style variations", hint: "Generate multiple style sets" }
286
+ - { value: mixed, label: "Mixed prompts", hint: "Different style per image" }
287
+ - { value: landscape, label: "Landscape orientation", hint: "2778x1284 instead of portrait" }
288
+
289
+ - id: variation-styles
290
+ type: multiselect
291
+ group: "Advanced Options"
292
+ message: "Select styles for variations"
293
+ when:
294
+ field: advanced-options
295
+ includes: variations
296
+ min: 1
297
+ options:
298
+ - { value: photorealistic, label: "Photorealistic" }
299
+ - { value: 3d-cartoon, label: "3D Cartoon" }
300
+ - { value: isometric, label: "Isometric" }
301
+ - { value: claymorphism, label: "Claymorphism" }
302
+ - { value: flat-2d, label: "Flat 2D" }
303
+ - { value: illustration, label: "Illustration" }
304
+
305
+ # ── Confirmation ───────────────────────────────────────────────────
306
+
307
+ - id: confirm-generate
308
+ type: confirm
309
+ group: "Confirmation"
310
+ message: "Start generation?"
311
+ default: true
312
+
313
+ - id: save-template-name
314
+ type: text
315
+ group: "Confirmation"
316
+ message: "Save as template? (enter name or leave empty to skip)"
317
+ default: ""
318
+ required: false
319
+
320
+ output:
321
+ format: json
@@ -0,0 +1,84 @@
1
+ meta:
2
+ name: "App Store Connect Upload"
3
+ description: "Upload screenshots to App Store Connect"
4
+ version: "1.0.0"
5
+
6
+ theme:
7
+ preset: monokai
8
+
9
+ steps:
10
+ - id: run-id
11
+ type: text
12
+ group: "Run Selection"
13
+ message: "Run ID (from generation results)"
14
+ validate:
15
+ - rule: required
16
+ placeholder: "e.g., 2024-01-15T10-30-00"
17
+
18
+ - id: asc-info-note
19
+ type: note
20
+ group: "ASC Credentials"
21
+ message: "App Store Connect API Key"
22
+ description: "You need an App Store Connect API key. Create one at https://appstoreconnect.apple.com/access/api"
23
+
24
+ - id: issuer-id
25
+ type: text
26
+ group: "ASC Credentials"
27
+ message: "Issuer ID"
28
+ validate:
29
+ - rule: required
30
+ placeholder: "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
31
+
32
+ - id: key-id
33
+ type: text
34
+ group: "ASC Credentials"
35
+ message: "Key ID"
36
+ validate:
37
+ - rule: required
38
+ placeholder: "XXXXXXXXXX"
39
+
40
+ - id: key-path
41
+ type: path
42
+ group: "ASC Credentials"
43
+ message: "Path to API key (.p8 file)"
44
+ validate:
45
+ - rule: required
46
+ placeholder: "~/.appstoreconnect/AuthKey_XXXXXXXXXX.p8"
47
+
48
+ - id: app-id
49
+ type: text
50
+ group: "App Details"
51
+ message: "App ID"
52
+ validate:
53
+ - rule: required
54
+ placeholder: "e.g., 1234567890"
55
+
56
+ - id: localization-id
57
+ type: text
58
+ group: "App Details"
59
+ message: "Localization ID"
60
+ validate:
61
+ - rule: required
62
+ placeholder: "e.g., en-US"
63
+
64
+ - id: display-type
65
+ type: select
66
+ group: "App Details"
67
+ message: "Display type"
68
+ options:
69
+ - { value: APP_IPHONE_67, label: 'iPhone 6.7"' }
70
+ - { value: APP_IPHONE_65, label: 'iPhone 6.5"' }
71
+ - { value: APP_IPAD_PRO_129, label: 'iPad Pro 12.9"' }
72
+ - { value: APP_IPAD_PRO_3GEN_129, label: 'iPad Pro 12.9" (3rd Gen)' }
73
+ - { value: APP_APPLE_WATCH_ULTRA, label: "Apple Watch Ultra" }
74
+ - { value: APP_APPLE_WATCH_SERIES_7, label: "Apple Watch Series 7" }
75
+ default: APP_IPHONE_67
76
+
77
+ - id: confirm-upload
78
+ type: confirm
79
+ group: "Confirmation"
80
+ message: "Upload screenshots to App Store Connect?"
81
+ default: true
82
+
83
+ output:
84
+ format: json
@@ -0,0 +1,156 @@
1
+ meta:
2
+ name: "Batch Generation Setup"
3
+ description: "Configure batch generation for multiple apps"
4
+ version: "1.0.0"
5
+
6
+ theme:
7
+ preset: nord
8
+
9
+ steps:
10
+ - id: shared-image-model
11
+ type: select
12
+ group: "Shared Settings"
13
+ message: "Default image generation model"
14
+ options:
15
+ - { value: gemini-3.1-flash-image-preview, label: "Flash (Fast & Cheap)", hint: "Near-Pro quality at ~$0.067/img" }
16
+ - { value: gemini-3-pro-image-preview, label: "Pro (Best Quality)", hint: "Top quality, 94% text accuracy" }
17
+ default: gemini-3.1-flash-image-preview
18
+
19
+ - id: shared-text-model
20
+ type: select
21
+ group: "Shared Settings"
22
+ message: "Default text model"
23
+ options:
24
+ - { value: gemini-2.5-flash, label: "Gemini Flash (Fast)" }
25
+ - { value: gemini-2.5-pro, label: "Gemini Pro (Best Prompts)" }
26
+ default: gemini-2.5-flash
27
+
28
+ - id: shared-count
29
+ type: number
30
+ group: "Shared Settings"
31
+ message: "Default screenshot count per app"
32
+ default: 10
33
+ min: 1
34
+ max: 50
35
+
36
+ - id: shared-providers
37
+ type: multiselect
38
+ group: "Shared Settings"
39
+ message: "Default providers"
40
+ options:
41
+ - { value: gemini, label: "Gemini" }
42
+ - { value: openai, label: "OpenAI" }
43
+ default: ["gemini"]
44
+ min: 1
45
+
46
+ - id: shared-device-targets
47
+ type: multiselect
48
+ group: "Shared Settings"
49
+ message: "Default device targets"
50
+ options:
51
+ - { value: iphone, label: "iPhone" }
52
+ - { value: ipad, label: "iPad" }
53
+ - { value: watch, label: "Apple Watch" }
54
+ - { value: android-phone, label: "Android Phone" }
55
+ - { value: android-tablet, label: "Android Tablet" }
56
+ default: ["iphone"]
57
+ min: 1
58
+
59
+ - id: app-1-note
60
+ type: note
61
+ group: "App 1"
62
+ message: "First App Configuration"
63
+ description: "Configure the first app in the batch"
64
+
65
+ - id: app-1-name
66
+ type: text
67
+ group: "App 1"
68
+ message: "App 1 name"
69
+ validate:
70
+ - rule: required
71
+
72
+ - id: app-1-description
73
+ type: text
74
+ group: "App 1"
75
+ message: "App 1 description"
76
+ validate:
77
+ - rule: required
78
+ - rule: minLength
79
+ value: 10
80
+
81
+ - id: app-1-visual-style
82
+ type: select
83
+ group: "App 1"
84
+ message: "App 1 visual style"
85
+ options:
86
+ - { value: auto, label: "Auto (AI picks)" }
87
+ - { value: photorealistic, label: "Photorealistic" }
88
+ - { value: 3d-cartoon, label: "3D Cartoon" }
89
+ - { value: isometric, label: "Isometric" }
90
+ - { value: claymorphism, label: "Claymorphism" }
91
+ - { value: flat-2d, label: "Flat 2D" }
92
+ - { value: illustration, label: "Illustration" }
93
+ default: auto
94
+
95
+ - id: app-1-count
96
+ type: number
97
+ group: "App 1"
98
+ message: "App 1 screenshot count (leave default to use shared)"
99
+ default: 10
100
+ min: 1
101
+ max: 50
102
+
103
+ - id: add-app-2
104
+ type: confirm
105
+ group: "App 2"
106
+ message: "Add a second app to the batch?"
107
+ default: false
108
+
109
+ - id: app-2-name
110
+ type: text
111
+ group: "App 2"
112
+ message: "App 2 name"
113
+ when:
114
+ field: add-app-2
115
+ equals: true
116
+ validate:
117
+ - rule: required
118
+
119
+ - id: app-2-description
120
+ type: text
121
+ group: "App 2"
122
+ message: "App 2 description"
123
+ when:
124
+ field: add-app-2
125
+ equals: true
126
+ validate:
127
+ - rule: required
128
+ - rule: minLength
129
+ value: 10
130
+
131
+ - id: app-2-visual-style
132
+ type: select
133
+ group: "App 2"
134
+ message: "App 2 visual style"
135
+ when:
136
+ field: add-app-2
137
+ equals: true
138
+ options:
139
+ - { value: auto, label: "Auto (AI picks)" }
140
+ - { value: photorealistic, label: "Photorealistic" }
141
+ - { value: 3d-cartoon, label: "3D Cartoon" }
142
+ - { value: isometric, label: "Isometric" }
143
+ - { value: claymorphism, label: "Claymorphism" }
144
+ - { value: flat-2d, label: "Flat 2D" }
145
+ - { value: illustration, label: "Illustration" }
146
+ default: auto
147
+
148
+ - id: confirm-batch
149
+ type: confirm
150
+ group: "Confirmation"
151
+ message: "Generate batch config file?"
152
+ default: true
153
+
154
+ output:
155
+ format: json
156
+ path: batch-config.json