human2ai 0.1.3 → 0.1.4
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.en.md +36 -4
- package/README.md +36 -4
- package/dist/cli/main.js +26 -0
- package/dist/cli/main.js.map +1 -1
- package/dist/database/style-library-repository.d.ts +14 -1
- package/dist/database/style-library-repository.js +59 -0
- package/dist/database/style-library-repository.js.map +1 -1
- package/dist/domain/composition/analysis.d.ts +3 -0
- package/dist/domain/composition/analysis.js +4 -0
- package/dist/domain/composition/analysis.js.map +1 -1
- package/dist/domain/composition/draft.d.ts +1 -0
- package/dist/domain/composition/draft.js +73 -2
- package/dist/domain/composition/draft.js.map +1 -1
- package/dist/domain/composition/frame.d.ts +1 -0
- package/dist/domain/composition/frame.js +6 -0
- package/dist/domain/composition/frame.js.map +1 -1
- package/dist/domain/composition/index.d.ts +4 -1
- package/dist/domain/composition/index.js +4 -1
- package/dist/domain/composition/index.js.map +1 -1
- package/dist/domain/composition/planning-intersections.d.ts +20 -0
- package/dist/domain/composition/planning-intersections.js +119 -0
- package/dist/domain/composition/planning-intersections.js.map +1 -0
- package/dist/domain/composition/planning.d.ts +25 -0
- package/dist/domain/composition/planning.js +152 -0
- package/dist/domain/composition/planning.js.map +1 -0
- package/dist/domain/composition/render.js +8 -0
- package/dist/domain/composition/render.js.map +1 -1
- package/dist/domain/composition/states.js +4 -1
- package/dist/domain/composition/states.js.map +1 -1
- package/dist/domain/composition/types.d.ts +46 -0
- package/dist/domain/spatial/camera-render-key.d.ts +7 -0
- package/dist/domain/spatial/camera-render-key.js +63 -0
- package/dist/domain/spatial/camera-render-key.js.map +1 -0
- package/dist/domain/spatial/lighting.js +3 -2
- package/dist/domain/spatial/lighting.js.map +1 -1
- package/dist/domain/spatial/model.d.ts +2 -0
- package/dist/domain/spatial/model.js +82 -27
- package/dist/domain/spatial/model.js.map +1 -1
- package/dist/domain/spatial/preview.d.ts +4 -0
- package/dist/domain/spatial/preview.js +23 -0
- package/dist/domain/spatial/preview.js.map +1 -0
- package/dist/domain/spatial/reference-lines.d.ts +12 -3
- package/dist/domain/spatial/reference-lines.js +37 -16
- package/dist/domain/spatial/reference-lines.js.map +1 -1
- package/dist/domain/spatial/render-inputs.d.ts +1 -1
- package/dist/domain/spatial/render-inputs.js +10 -2
- package/dist/domain/spatial/render-inputs.js.map +1 -1
- package/dist/domain/spatial/scene-cache.d.ts +13 -1
- package/dist/domain/spatial/scene-cache.js +88 -10
- package/dist/domain/spatial/scene-cache.js.map +1 -1
- package/dist/domain/spatial/scene-update.d.ts +6 -0
- package/dist/domain/spatial/scene-update.js +52 -0
- package/dist/domain/spatial/scene-update.js.map +1 -0
- package/dist/domain/spatial/scene.d.ts +3 -1
- package/dist/domain/spatial/scene.js +78 -20
- package/dist/domain/spatial/scene.js.map +1 -1
- package/dist/domain/style/model-input.d.ts +3 -0
- package/dist/domain/style/model-input.js +36 -0
- package/dist/domain/style/model-input.js.map +1 -0
- package/dist/domain/style/types.d.ts +7 -0
- package/dist/server/routes/spatial-sessions.js +28 -12
- package/dist/server/routes/spatial-sessions.js.map +1 -1
- package/dist/server/routes/style-library.js +39 -0
- package/dist/server/routes/style-library.js.map +1 -1
- package/dist/server/spatial-render-service.d.ts +21 -0
- package/dist/server/spatial-render-service.js +67 -0
- package/dist/server/spatial-render-service.js.map +1 -0
- package/dist/server/spatial-render-worker.d.ts +1 -0
- package/dist/server/spatial-render-worker.js +15 -0
- package/dist/server/spatial-render-worker.js.map +1 -0
- package/dist/server/spatial-render.d.ts +14 -2
- package/dist/server/spatial-render.js +38 -7
- package/dist/server/spatial-render.js.map +1 -1
- package/locales/en/common.json +60 -4
- package/migrations/0010_style_preview_models.sql +8 -0
- package/package.json +1 -1
- package/schemas/composition-draft.schema.json +457 -0
- package/skills/human2ai/SKILL.md +12 -4
- package/skills/human2ai/references/composition.md +192 -1
- package/skills/human2ai/references/spatial-modeling.md +20 -0
- package/web/out/404/index.html +1 -1
- package/web/out/404.html +1 -1
- package/web/out/__next.__PAGE__.txt +6 -6
- package/web/out/__next._full.txt +6 -6
- package/web/out/__next._tree.txt +3 -3
- package/web/out/_next/static/chunks/101.6ef34adad3e9815b.js +1 -0
- package/web/out/_next/static/chunks/130-7e9e715a084569bb.js +1 -0
- package/web/out/_next/static/chunks/166-96a8c6ae1e9aed59.js +1 -0
- package/web/out/_next/static/chunks/218.7b89674409b344b8.js +1 -0
- package/web/out/_next/static/chunks/484.92b016222d6749f2.js +1 -0
- package/web/out/_next/static/chunks/{773-24ba65074da7fa71.js → 635-611c009924b842be.js} +50 -50
- package/web/out/_next/static/chunks/653-6dfb97fec9a2d91b.js +1 -0
- package/web/out/_next/static/chunks/678-32d3aa1859450d63.js +1 -0
- package/web/out/_next/static/chunks/83607670-fd2f339702a222e4.js +1 -0
- package/web/out/_next/static/chunks/app/_not-found/page-b92817fdc4609975.js +1 -0
- package/web/out/_next/static/chunks/app/composition/page-6c12ee8472715448.js +1 -0
- package/web/out/_next/static/chunks/app/{layout-3b5f82ced220ef42.js → layout-1dd9196cde94389c.js} +1 -1
- package/web/out/_next/static/chunks/app/{page-d41d1cdb1d6ed018.js → page-741ecaf9ee8c3c07.js} +1 -1
- package/web/out/_next/static/chunks/app/spatial/page-5ba0940650df6c7f.js +1 -0
- package/web/out/_next/static/chunks/app/styles/page-1ccfc2c5fbc1e646.js +1 -0
- package/web/out/_next/static/chunks/app/ui-sketch/page-ef4f2e531583e684.js +1 -0
- package/web/out/_next/static/chunks/{c3f2cda1-9e279dab137b7272.js → c3f2cda1-ef85a0897724e46b.js} +1 -1
- package/web/out/_next/static/chunks/{main-app-ec9e35d71481270a.js → main-app-cf37a257d91ce62e.js} +1 -1
- package/web/out/_next/static/chunks/next/dist/client/components/builtin/global-error-33b4f58f02e82215.js +1 -0
- package/web/out/_next/static/chunks/webpack-d16ce1f994e98178.js +1 -0
- package/web/out/_next/static/css/06743b5635914999.css +5 -0
- package/web/out/_next/static/css/0b43ff4a0439c97e.css +1 -0
- package/web/out/_next/static/css/39e8cace36461a15.css +1 -0
- package/web/out/_not-found/__next._full.txt +3 -3
- package/web/out/_not-found/__next._not-found.__PAGE__.txt +3 -3
- package/web/out/_not-found/__next._tree.txt +1 -1
- package/web/out/_not-found/index.html +1 -1
- package/web/out/_not-found/index.txt +3 -3
- package/web/out/composition/__next._full.txt +6 -6
- package/web/out/composition/__next._tree.txt +3 -3
- package/web/out/composition/__next.composition.__PAGE__.txt +6 -6
- package/web/out/composition/index.html +1 -1
- package/web/out/composition/index.txt +6 -6
- package/web/out/index.html +1 -1
- package/web/out/index.txt +6 -6
- package/web/out/spatial/__next._full.txt +6 -6
- package/web/out/spatial/__next._tree.txt +3 -3
- package/web/out/spatial/__next.spatial.__PAGE__.txt +6 -6
- package/web/out/spatial/index.html +1 -1
- package/web/out/spatial/index.txt +6 -6
- package/web/out/styles/__next._full.txt +6 -6
- package/web/out/styles/__next._tree.txt +3 -3
- package/web/out/styles/__next.styles.__PAGE__.txt +6 -6
- package/web/out/styles/index.html +1 -1
- package/web/out/styles/index.txt +6 -6
- package/web/out/ui-sketch/__next._full.txt +6 -6
- package/web/out/ui-sketch/__next._tree.txt +3 -3
- package/web/out/ui-sketch/__next.ui-sketch.__PAGE__.txt +6 -6
- package/web/out/ui-sketch/index.html +1 -1
- package/web/out/ui-sketch/index.txt +6 -6
- package/web/out/_next/static/chunks/130-027b022c82d30077.js +0 -1
- package/web/out/_next/static/chunks/678-6f33e7277564a5df.js +0 -1
- package/web/out/_next/static/chunks/728-7597352c3a7eeaf9.js +0 -1
- package/web/out/_next/static/chunks/83607670-bc1279370476e59f.js +0 -1
- package/web/out/_next/static/chunks/app/_not-found/page-58bf95050b473956.js +0 -1
- package/web/out/_next/static/chunks/app/composition/page-30184e9c21352991.js +0 -1
- package/web/out/_next/static/chunks/app/spatial/page-fc3c66e1f94ed210.js +0 -1
- package/web/out/_next/static/chunks/app/styles/page-194a16109270e08d.js +0 -1
- package/web/out/_next/static/chunks/app/ui-sketch/page-c28eeab67fea766e.js +0 -1
- package/web/out/_next/static/chunks/next/dist/client/components/builtin/global-error-f62e60e5a6e74304.js +0 -1
- package/web/out/_next/static/chunks/webpack-fdd377b620f7ea99.js +0 -1
- package/web/out/_next/static/css/2ed56cbf8f662d23.css +0 -5
- package/web/out/_next/static/css/96839f63fcc5e50d.css +0 -1
- /package/web/out/_next/static/{Wakl9xK54qWYuP4Hpi0W9 → n4UcxqMmr_2CBmSxBp52z}/_buildManifest.js +0 -0
- /package/web/out/_next/static/{Wakl9xK54qWYuP4Hpi0W9 → n4UcxqMmr_2CBmSxBp52z}/_ssgManifest.js +0 -0
package/locales/en/common.json
CHANGED
|
@@ -72,7 +72,7 @@
|
|
|
72
72
|
},
|
|
73
73
|
"searchPlaceholder": "Search styles",
|
|
74
74
|
"deleteTitle": "Delete this style?",
|
|
75
|
-
"deleteDescription": "The style and all of its reference images will be permanently deleted.",
|
|
75
|
+
"deleteDescription": "The style and all of its reference images and models will be permanently deleted.",
|
|
76
76
|
"empty": "No styles yet",
|
|
77
77
|
"noMatches": "No matching styles",
|
|
78
78
|
"loading": "Loading styles",
|
|
@@ -84,6 +84,13 @@
|
|
|
84
84
|
"promptSummary": {
|
|
85
85
|
"label": "Style summary",
|
|
86
86
|
"placeholder": "Summarize the defining visual traits in one sentence."
|
|
87
|
+
},
|
|
88
|
+
"model": {
|
|
89
|
+
"label": "Model example",
|
|
90
|
+
"loading": "Loading model",
|
|
91
|
+
"failed": "Could not preview the model",
|
|
92
|
+
"reset": "Reset model view",
|
|
93
|
+
"controls": "Drag to rotate, scroll to zoom. When focused, use arrow keys to rotate, + / − to zoom, and Home to reset."
|
|
87
94
|
}
|
|
88
95
|
},
|
|
89
96
|
"notes": {
|
|
@@ -256,8 +263,6 @@
|
|
|
256
263
|
"quadrilateral": "Rectangle",
|
|
257
264
|
"textRegion": "Text region"
|
|
258
265
|
},
|
|
259
|
-
"showGuideGrid": "Show grid",
|
|
260
|
-
"hideGuideGrid": "Hide grid",
|
|
261
266
|
"canvasZoom": "Current zoom",
|
|
262
267
|
"zoomOut": "Zoom out",
|
|
263
268
|
"zoomIn": "Zoom in",
|
|
@@ -302,7 +307,16 @@
|
|
|
302
307
|
"left": "left",
|
|
303
308
|
"lightSourceNumber": "Light source {{index}}",
|
|
304
309
|
"lightSourceGuidance": "- Like ordinary shape regions, light markers describe approximate visual intent and spatial relationships. Pale yellow identifies lighting, not color temperature. A source is distinct from the area it illuminates: interpret its origin and contribution in the scene. Rectangles suggest band-shaped or extended illumination; circles suggest localized illumination. Retain the broad lighting placement, extension trend and contribution to subject and space, while freely adapting width, length, curvature, continuity, edges and strength to the scene. User instructions and node notes take precedence; otherwise the Agent chooses. Do not infer fixed width, straight constant-width strips, full-frame coverage, medium-strong contrast or thumbnail prominence from the reference. Consider sources individually while allowing their visible effects to split, overlap or blend. Review whether the overall lighting broadly echoes the composition rather than comparing edges, segments or widths; tighten a constraint only when the user explicitly requests it, and do not ignore the authored lighting intent entirely.",
|
|
305
|
-
"lightBandGuidance": "Light-band intent: broadly retain the extended or band-like illumination and its spatial role here. Its realization may narrow, widen, curve, break up or blend with the scene; a complete, straight, constant-width or conspicuous stripe is not required. User instructions and this node’s notes take precedence for width, length, edges and strength; otherwise the Agent interprets them freely. An approximate overall correspondence is sufficient."
|
|
310
|
+
"lightBandGuidance": "Light-band intent: broadly retain the extended or band-like illumination and its spatial role here. Its realization may narrow, widen, curve, break up or blend with the scene; a complete, straight, constant-width or conspicuous stripe is not required. User instructions and this node’s notes take precedence for width, length, edges and strength; otherwise the Agent interprets them freely. An approximate overall correspondence is sufficient.",
|
|
311
|
+
"planningGuidance": "Use the following plans as composition intent alongside the overall requirements and notes. Do not draw the guide lines, axes, spiral or triangle outline in the artwork. Positions are relative to the top-left of the image; angles run clockwise from the rightward horizontal.",
|
|
312
|
+
"planningGrid": "- {{type}}: {{axes}} divisions.",
|
|
313
|
+
"planningSymmetry": "- Symmetrical composition: axis through the image center ({{x}}%, {{y}}%), direction {{rotation}}°.",
|
|
314
|
+
"planningSpiral": "- Golden spiral: pole at ({{x}}%, {{y}}%), outer radius directed at {{rotation}}°, radius {{scale}}% of the shorter image side, {{winding}}.",
|
|
315
|
+
"planningClockwise": "expanding clockwise",
|
|
316
|
+
"planningCounterclockwise": "expanding counterclockwise",
|
|
317
|
+
"planningTriangle": "- Triangular composition: isosceles triangle with vertices at {{points}}.",
|
|
318
|
+
"planningRadial": "- Radial composition: convergence point ({{x}}%, {{y}}%), {{rayCount}} evenly spaced rays starting at {{rotation}}° and spanning {{spread}}° clockwise.",
|
|
319
|
+
"planningRadialFree": "- Free radial composition: convergence point ({{x}}%, {{y}}%), {{rayCount}} rays with independent directions: {{angles}} (clockwise from the rightward horizontal)."
|
|
306
320
|
},
|
|
307
321
|
"depth": {
|
|
308
322
|
"label": "Depth",
|
|
@@ -352,6 +366,48 @@
|
|
|
352
366
|
"textRegion": {
|
|
353
367
|
"cornerLabel": "Text outline corner {{index}}",
|
|
354
368
|
"cornerHelp": "Select a text region and hold Ctrl to drag its corners. Focus a corner and use the arrow keys for fine adjustments."
|
|
369
|
+
},
|
|
370
|
+
"planning": {
|
|
371
|
+
"title": "Composition planning",
|
|
372
|
+
"add": "Add plan",
|
|
373
|
+
"empty": "No composition plans",
|
|
374
|
+
"types": {
|
|
375
|
+
"thirds": "Rule of thirds",
|
|
376
|
+
"golden-section": "Golden section",
|
|
377
|
+
"symmetry": "Symmetrical composition",
|
|
378
|
+
"golden-spiral": "Golden spiral",
|
|
379
|
+
"triangle": "Triangular composition",
|
|
380
|
+
"radial": "Radial composition"
|
|
381
|
+
},
|
|
382
|
+
"visible": "Show plan",
|
|
383
|
+
"axes": "Grid directions",
|
|
384
|
+
"both": "Horizontal and vertical",
|
|
385
|
+
"horizontal": "Horizontal",
|
|
386
|
+
"vertical": "Vertical",
|
|
387
|
+
"x": "Horizontal (%)",
|
|
388
|
+
"y": "Vertical (%)",
|
|
389
|
+
"rotation": "Rotation (°)",
|
|
390
|
+
"scale": "Spiral size (%)",
|
|
391
|
+
"mirrored": "Mirror spiral",
|
|
392
|
+
"handle": "Plan control {{index}}",
|
|
393
|
+
"help": "Shift-click to select multiple plans and drag a selected guide to move them together. Thirds, golden-section and symmetry guides stay fixed. Select thirds and golden-section plans in the sidebar. Arrow keys nudge; Delete removes a plan.",
|
|
394
|
+
"width": "Base width (%)",
|
|
395
|
+
"height": "Triangle height (%)",
|
|
396
|
+
"triangleHelp": "Drag the apex to rotate and adjust height. Drag a base corner to resize; both sides stay symmetric.",
|
|
397
|
+
"symmetryHelp": "The center stays fixed. Drag the other dot to one of eight regular directions or four frame-corner directions. Corner directions follow the frame ratio; duplicate positions merge for a square. Arrow keys step between positions.",
|
|
398
|
+
"spiralHelp": "Click the center dot to switch clockwise/counterclockwise. Drag it to move the spiral; drag the outer dot to rotate and resize.",
|
|
399
|
+
"spiralDirection": "Switch spiral direction (clockwise/counterclockwise)",
|
|
400
|
+
"rayCount": "Ray count",
|
|
401
|
+
"spread": "Spread (°)",
|
|
402
|
+
"radialHelp": "Uniform mode uses a starting direction and spread. In Free mode, drag each ray’s dot to adjust its direction; drag the center to move the convergence point. Switching to Free preserves directions; switching back to Uniform redistributes the current rays around a full circle.",
|
|
403
|
+
"lock": "Lock composition planning",
|
|
404
|
+
"unlock": "Unlock composition planning",
|
|
405
|
+
"showAll": "Show composition guides",
|
|
406
|
+
"hideAll": "Hide composition guides",
|
|
407
|
+
"radialMode": "Radial mode",
|
|
408
|
+
"radialUniform": "Uniform",
|
|
409
|
+
"radialFree": "Free",
|
|
410
|
+
"rayHandle": "Ray {{index}} direction"
|
|
355
411
|
}
|
|
356
412
|
},
|
|
357
413
|
"uiSketch": {
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
CREATE TABLE style_preview_models (
|
|
2
|
+
style_id TEXT PRIMARY KEY REFERENCES style_entries(id) ON DELETE CASCADE,
|
|
3
|
+
id TEXT NOT NULL UNIQUE,
|
|
4
|
+
relative_path TEXT NOT NULL,
|
|
5
|
+
original_filename TEXT NOT NULL,
|
|
6
|
+
byte_size INTEGER NOT NULL CHECK (byte_size > 0),
|
|
7
|
+
created_at TEXT NOT NULL
|
|
8
|
+
) STRICT;
|
package/package.json
CHANGED
|
@@ -10,6 +10,7 @@
|
|
|
10
10
|
{ "if": { "required": ["activeStateId"] }, "then": { "required": ["states"] } }
|
|
11
11
|
],
|
|
12
12
|
"properties": {
|
|
13
|
+
"plans": { "type": "array", "items": { "$ref": "#/$defs/compositionPlan" } },
|
|
13
14
|
"activeStateId": { "type": "string", "minLength": 1 },
|
|
14
15
|
"states": { "type": "array", "minItems": 1, "items": { "$ref": "#/$defs/state" } },
|
|
15
16
|
"layerOrder": { "type": "array", "uniqueItems": true, "items": { "type": "string", "minLength": 1 } },
|
|
@@ -152,6 +153,461 @@
|
|
|
152
153
|
}
|
|
153
154
|
},
|
|
154
155
|
"$defs": {
|
|
156
|
+
"compositionPlan": {
|
|
157
|
+
"type": "object",
|
|
158
|
+
"additionalProperties": false,
|
|
159
|
+
"required": [
|
|
160
|
+
"id",
|
|
161
|
+
"visible",
|
|
162
|
+
"type"
|
|
163
|
+
],
|
|
164
|
+
"properties": {
|
|
165
|
+
"id": {
|
|
166
|
+
"type": "string",
|
|
167
|
+
"pattern": "^plan-[a-zA-Z0-9-]+$"
|
|
168
|
+
},
|
|
169
|
+
"visible": {
|
|
170
|
+
"type": "boolean"
|
|
171
|
+
},
|
|
172
|
+
"axes": {
|
|
173
|
+
"enum": [
|
|
174
|
+
"both",
|
|
175
|
+
"horizontal",
|
|
176
|
+
"vertical"
|
|
177
|
+
]
|
|
178
|
+
},
|
|
179
|
+
"x": {
|
|
180
|
+
"type": "number"
|
|
181
|
+
},
|
|
182
|
+
"y": {
|
|
183
|
+
"type": "number"
|
|
184
|
+
},
|
|
185
|
+
"rotation": {
|
|
186
|
+
"type": "number"
|
|
187
|
+
},
|
|
188
|
+
"scale": {
|
|
189
|
+
"type": "number",
|
|
190
|
+
"exclusiveMinimum": 0
|
|
191
|
+
},
|
|
192
|
+
"mirrored": {
|
|
193
|
+
"type": "boolean"
|
|
194
|
+
},
|
|
195
|
+
"type": {
|
|
196
|
+
"enum": [
|
|
197
|
+
"thirds",
|
|
198
|
+
"golden-section",
|
|
199
|
+
"symmetry",
|
|
200
|
+
"golden-spiral",
|
|
201
|
+
"triangle",
|
|
202
|
+
"radial"
|
|
203
|
+
]
|
|
204
|
+
},
|
|
205
|
+
"width": {
|
|
206
|
+
"type": "number",
|
|
207
|
+
"exclusiveMinimum": 0
|
|
208
|
+
},
|
|
209
|
+
"height": {
|
|
210
|
+
"type": "number",
|
|
211
|
+
"exclusiveMinimum": 0
|
|
212
|
+
},
|
|
213
|
+
"rayCount": {
|
|
214
|
+
"type": "integer",
|
|
215
|
+
"minimum": 2,
|
|
216
|
+
"maximum": 36
|
|
217
|
+
},
|
|
218
|
+
"spread": {
|
|
219
|
+
"type": "number",
|
|
220
|
+
"minimum": 1,
|
|
221
|
+
"maximum": 360
|
|
222
|
+
},
|
|
223
|
+
"mode": {
|
|
224
|
+
"enum": [
|
|
225
|
+
"uniform",
|
|
226
|
+
"free"
|
|
227
|
+
]
|
|
228
|
+
},
|
|
229
|
+
"angles": {
|
|
230
|
+
"type": "array",
|
|
231
|
+
"minItems": 2,
|
|
232
|
+
"maxItems": 36,
|
|
233
|
+
"items": {
|
|
234
|
+
"type": "number"
|
|
235
|
+
}
|
|
236
|
+
}
|
|
237
|
+
},
|
|
238
|
+
"oneOf": [
|
|
239
|
+
{
|
|
240
|
+
"type": "object",
|
|
241
|
+
"properties": {
|
|
242
|
+
"type": {
|
|
243
|
+
"enum": [
|
|
244
|
+
"thirds",
|
|
245
|
+
"golden-section"
|
|
246
|
+
]
|
|
247
|
+
}
|
|
248
|
+
},
|
|
249
|
+
"required": [
|
|
250
|
+
"axes"
|
|
251
|
+
],
|
|
252
|
+
"not": {
|
|
253
|
+
"anyOf": [
|
|
254
|
+
{
|
|
255
|
+
"required": [
|
|
256
|
+
"x"
|
|
257
|
+
]
|
|
258
|
+
},
|
|
259
|
+
{
|
|
260
|
+
"required": [
|
|
261
|
+
"y"
|
|
262
|
+
]
|
|
263
|
+
},
|
|
264
|
+
{
|
|
265
|
+
"required": [
|
|
266
|
+
"rotation"
|
|
267
|
+
]
|
|
268
|
+
},
|
|
269
|
+
{
|
|
270
|
+
"required": [
|
|
271
|
+
"scale"
|
|
272
|
+
]
|
|
273
|
+
},
|
|
274
|
+
{
|
|
275
|
+
"required": [
|
|
276
|
+
"mirrored"
|
|
277
|
+
]
|
|
278
|
+
},
|
|
279
|
+
{
|
|
280
|
+
"required": [
|
|
281
|
+
"width"
|
|
282
|
+
]
|
|
283
|
+
},
|
|
284
|
+
{
|
|
285
|
+
"required": [
|
|
286
|
+
"height"
|
|
287
|
+
]
|
|
288
|
+
},
|
|
289
|
+
{
|
|
290
|
+
"required": [
|
|
291
|
+
"rayCount"
|
|
292
|
+
]
|
|
293
|
+
},
|
|
294
|
+
{
|
|
295
|
+
"required": [
|
|
296
|
+
"spread"
|
|
297
|
+
]
|
|
298
|
+
},
|
|
299
|
+
{
|
|
300
|
+
"required": [
|
|
301
|
+
"mode"
|
|
302
|
+
]
|
|
303
|
+
},
|
|
304
|
+
{
|
|
305
|
+
"required": [
|
|
306
|
+
"angles"
|
|
307
|
+
]
|
|
308
|
+
}
|
|
309
|
+
]
|
|
310
|
+
}
|
|
311
|
+
},
|
|
312
|
+
{
|
|
313
|
+
"type": "object",
|
|
314
|
+
"properties": {
|
|
315
|
+
"type": {
|
|
316
|
+
"enum": [
|
|
317
|
+
"symmetry"
|
|
318
|
+
]
|
|
319
|
+
}
|
|
320
|
+
},
|
|
321
|
+
"required": [
|
|
322
|
+
"x",
|
|
323
|
+
"y",
|
|
324
|
+
"rotation"
|
|
325
|
+
],
|
|
326
|
+
"not": {
|
|
327
|
+
"anyOf": [
|
|
328
|
+
{
|
|
329
|
+
"required": [
|
|
330
|
+
"axes"
|
|
331
|
+
]
|
|
332
|
+
},
|
|
333
|
+
{
|
|
334
|
+
"required": [
|
|
335
|
+
"scale"
|
|
336
|
+
]
|
|
337
|
+
},
|
|
338
|
+
{
|
|
339
|
+
"required": [
|
|
340
|
+
"mirrored"
|
|
341
|
+
]
|
|
342
|
+
},
|
|
343
|
+
{
|
|
344
|
+
"required": [
|
|
345
|
+
"width"
|
|
346
|
+
]
|
|
347
|
+
},
|
|
348
|
+
{
|
|
349
|
+
"required": [
|
|
350
|
+
"height"
|
|
351
|
+
]
|
|
352
|
+
},
|
|
353
|
+
{
|
|
354
|
+
"required": [
|
|
355
|
+
"rayCount"
|
|
356
|
+
]
|
|
357
|
+
},
|
|
358
|
+
{
|
|
359
|
+
"required": [
|
|
360
|
+
"spread"
|
|
361
|
+
]
|
|
362
|
+
},
|
|
363
|
+
{
|
|
364
|
+
"required": [
|
|
365
|
+
"mode"
|
|
366
|
+
]
|
|
367
|
+
},
|
|
368
|
+
{
|
|
369
|
+
"required": [
|
|
370
|
+
"angles"
|
|
371
|
+
]
|
|
372
|
+
}
|
|
373
|
+
]
|
|
374
|
+
}
|
|
375
|
+
},
|
|
376
|
+
{
|
|
377
|
+
"type": "object",
|
|
378
|
+
"properties": {
|
|
379
|
+
"type": {
|
|
380
|
+
"enum": [
|
|
381
|
+
"golden-spiral"
|
|
382
|
+
]
|
|
383
|
+
}
|
|
384
|
+
},
|
|
385
|
+
"required": [
|
|
386
|
+
"x",
|
|
387
|
+
"y",
|
|
388
|
+
"rotation",
|
|
389
|
+
"scale",
|
|
390
|
+
"mirrored"
|
|
391
|
+
],
|
|
392
|
+
"not": {
|
|
393
|
+
"anyOf": [
|
|
394
|
+
{
|
|
395
|
+
"required": [
|
|
396
|
+
"axes"
|
|
397
|
+
]
|
|
398
|
+
},
|
|
399
|
+
{
|
|
400
|
+
"required": [
|
|
401
|
+
"width"
|
|
402
|
+
]
|
|
403
|
+
},
|
|
404
|
+
{
|
|
405
|
+
"required": [
|
|
406
|
+
"height"
|
|
407
|
+
]
|
|
408
|
+
},
|
|
409
|
+
{
|
|
410
|
+
"required": [
|
|
411
|
+
"rayCount"
|
|
412
|
+
]
|
|
413
|
+
},
|
|
414
|
+
{
|
|
415
|
+
"required": [
|
|
416
|
+
"spread"
|
|
417
|
+
]
|
|
418
|
+
},
|
|
419
|
+
{
|
|
420
|
+
"required": [
|
|
421
|
+
"mode"
|
|
422
|
+
]
|
|
423
|
+
},
|
|
424
|
+
{
|
|
425
|
+
"required": [
|
|
426
|
+
"angles"
|
|
427
|
+
]
|
|
428
|
+
}
|
|
429
|
+
]
|
|
430
|
+
}
|
|
431
|
+
},
|
|
432
|
+
{
|
|
433
|
+
"type": "object",
|
|
434
|
+
"properties": {
|
|
435
|
+
"type": {
|
|
436
|
+
"enum": [
|
|
437
|
+
"triangle"
|
|
438
|
+
]
|
|
439
|
+
}
|
|
440
|
+
},
|
|
441
|
+
"required": [
|
|
442
|
+
"x",
|
|
443
|
+
"y",
|
|
444
|
+
"rotation",
|
|
445
|
+
"width",
|
|
446
|
+
"height"
|
|
447
|
+
],
|
|
448
|
+
"not": {
|
|
449
|
+
"anyOf": [
|
|
450
|
+
{
|
|
451
|
+
"required": [
|
|
452
|
+
"axes"
|
|
453
|
+
]
|
|
454
|
+
},
|
|
455
|
+
{
|
|
456
|
+
"required": [
|
|
457
|
+
"scale"
|
|
458
|
+
]
|
|
459
|
+
},
|
|
460
|
+
{
|
|
461
|
+
"required": [
|
|
462
|
+
"mirrored"
|
|
463
|
+
]
|
|
464
|
+
},
|
|
465
|
+
{
|
|
466
|
+
"required": [
|
|
467
|
+
"rayCount"
|
|
468
|
+
]
|
|
469
|
+
},
|
|
470
|
+
{
|
|
471
|
+
"required": [
|
|
472
|
+
"spread"
|
|
473
|
+
]
|
|
474
|
+
},
|
|
475
|
+
{
|
|
476
|
+
"required": [
|
|
477
|
+
"mode"
|
|
478
|
+
]
|
|
479
|
+
},
|
|
480
|
+
{
|
|
481
|
+
"required": [
|
|
482
|
+
"angles"
|
|
483
|
+
]
|
|
484
|
+
}
|
|
485
|
+
]
|
|
486
|
+
}
|
|
487
|
+
},
|
|
488
|
+
{
|
|
489
|
+
"type": "object",
|
|
490
|
+
"properties": {
|
|
491
|
+
"type": {
|
|
492
|
+
"enum": [
|
|
493
|
+
"radial"
|
|
494
|
+
]
|
|
495
|
+
},
|
|
496
|
+
"mode": {
|
|
497
|
+
"enum": [
|
|
498
|
+
"uniform"
|
|
499
|
+
]
|
|
500
|
+
}
|
|
501
|
+
},
|
|
502
|
+
"required": [
|
|
503
|
+
"x",
|
|
504
|
+
"y",
|
|
505
|
+
"rotation",
|
|
506
|
+
"rayCount",
|
|
507
|
+
"spread"
|
|
508
|
+
],
|
|
509
|
+
"not": {
|
|
510
|
+
"anyOf": [
|
|
511
|
+
{
|
|
512
|
+
"required": [
|
|
513
|
+
"axes"
|
|
514
|
+
]
|
|
515
|
+
},
|
|
516
|
+
{
|
|
517
|
+
"required": [
|
|
518
|
+
"scale"
|
|
519
|
+
]
|
|
520
|
+
},
|
|
521
|
+
{
|
|
522
|
+
"required": [
|
|
523
|
+
"mirrored"
|
|
524
|
+
]
|
|
525
|
+
},
|
|
526
|
+
{
|
|
527
|
+
"required": [
|
|
528
|
+
"width"
|
|
529
|
+
]
|
|
530
|
+
},
|
|
531
|
+
{
|
|
532
|
+
"required": [
|
|
533
|
+
"height"
|
|
534
|
+
]
|
|
535
|
+
},
|
|
536
|
+
{
|
|
537
|
+
"required": [
|
|
538
|
+
"angles"
|
|
539
|
+
]
|
|
540
|
+
}
|
|
541
|
+
]
|
|
542
|
+
}
|
|
543
|
+
},
|
|
544
|
+
{
|
|
545
|
+
"type": "object",
|
|
546
|
+
"properties": {
|
|
547
|
+
"type": {
|
|
548
|
+
"enum": [
|
|
549
|
+
"radial"
|
|
550
|
+
]
|
|
551
|
+
},
|
|
552
|
+
"mode": {
|
|
553
|
+
"enum": [
|
|
554
|
+
"free"
|
|
555
|
+
]
|
|
556
|
+
}
|
|
557
|
+
},
|
|
558
|
+
"required": [
|
|
559
|
+
"x",
|
|
560
|
+
"y",
|
|
561
|
+
"mode",
|
|
562
|
+
"angles"
|
|
563
|
+
],
|
|
564
|
+
"not": {
|
|
565
|
+
"anyOf": [
|
|
566
|
+
{
|
|
567
|
+
"required": [
|
|
568
|
+
"axes"
|
|
569
|
+
]
|
|
570
|
+
},
|
|
571
|
+
{
|
|
572
|
+
"required": [
|
|
573
|
+
"rotation"
|
|
574
|
+
]
|
|
575
|
+
},
|
|
576
|
+
{
|
|
577
|
+
"required": [
|
|
578
|
+
"scale"
|
|
579
|
+
]
|
|
580
|
+
},
|
|
581
|
+
{
|
|
582
|
+
"required": [
|
|
583
|
+
"mirrored"
|
|
584
|
+
]
|
|
585
|
+
},
|
|
586
|
+
{
|
|
587
|
+
"required": [
|
|
588
|
+
"width"
|
|
589
|
+
]
|
|
590
|
+
},
|
|
591
|
+
{
|
|
592
|
+
"required": [
|
|
593
|
+
"height"
|
|
594
|
+
]
|
|
595
|
+
},
|
|
596
|
+
{
|
|
597
|
+
"required": [
|
|
598
|
+
"rayCount"
|
|
599
|
+
]
|
|
600
|
+
},
|
|
601
|
+
{
|
|
602
|
+
"required": [
|
|
603
|
+
"spread"
|
|
604
|
+
]
|
|
605
|
+
}
|
|
606
|
+
]
|
|
607
|
+
}
|
|
608
|
+
}
|
|
609
|
+
]
|
|
610
|
+
},
|
|
155
611
|
"state": {
|
|
156
612
|
"type": "object", "additionalProperties": false,
|
|
157
613
|
"required": ["id", "number", "layout"],
|
|
@@ -163,6 +619,7 @@
|
|
|
163
619
|
"type": "object", "additionalProperties": false,
|
|
164
620
|
"required": ["frame", "layerOrder", "focusPoints", "directionLine", "areas", "images"],
|
|
165
621
|
"properties": {
|
|
622
|
+
"plans": { "type": "array", "items": { "$ref": "#/$defs/compositionPlan" } },
|
|
166
623
|
"frame": { "allOf": [{ "$ref": "#/properties/frame" }, { "type": "object", "required": ["bounds"] }] },
|
|
167
624
|
"layerOrder": { "$ref": "#/properties/layerOrder" },
|
|
168
625
|
"focusPoints": { "type": "array", "maxItems": 3, "items": { "$ref": "#/$defs/layoutPoint" } },
|
package/skills/human2ai/SKILL.md
CHANGED
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: human2ai
|
|
3
3
|
description: Collaborate through local Human2AI design sessions, its style library, and its CLI. Use in a consumer project containing .human2ai/integration.json to inspect, edit, refine, review, or undo design work; to draw a reference picture as editable scene or editorial composition (“把这张图的构图画到画布上”); to project existing UI into a layout canvas (“把 UI 放到画布上让我修改”); to model in the consumer project using a style and 3D spatial guidance; or to reuse a visual style. The consumer project's Agent owns downstream implementation.
|
|
4
|
+
metadata:
|
|
5
|
+
version: "0.1.4"
|
|
4
6
|
---
|
|
5
7
|
|
|
6
8
|
# Human2AI
|
|
@@ -37,7 +39,7 @@ The style library is global to the local Human2AI service. Each composition, UI
|
|
|
37
39
|
<runner> style get --style <style-id>
|
|
38
40
|
```
|
|
39
41
|
|
|
40
|
-
`style get` returns reference image URLs and the full description. Treat that description as an actionable design specification: layout, proportions, hierarchy, spacing, typography, palette, materials, and decorative treatment as applicable. Inspect available reference images to resolve the visual characteristics. The user's explicit content, functions, and placement requirements take precedence over the style specification.
|
|
42
|
+
`style get` returns reference image URLs, an optional `previewModel.url`, and the full description. Treat that description as an actionable design specification: layout, proportions, hierarchy, spacing, typography, palette, materials, and decorative treatment as applicable. Inspect available reference images to resolve the visual characteristics. The user's explicit content, functions, and placement requirements take precedence over the style specification.
|
|
41
43
|
|
|
42
44
|
When a style encountered during Agent work is worth keeping, save it directly as an Agent-created entry; there is no proposal or pending-review state:
|
|
43
45
|
|
|
@@ -46,6 +48,8 @@ When a style encountered during Agent work is worth keeping, save it directly as
|
|
|
46
48
|
<runner> style add-reference --style <style-id> --input <image> --expected-revision <n>
|
|
47
49
|
```
|
|
48
50
|
|
|
51
|
+
For a program-generated 3D model example, follow the model-preview instructions in [spatial modeling](references/spatial-modeling.md#save-a-generated-style-example).
|
|
52
|
+
|
|
49
53
|
A style may have no reference image, but its design specification must be non-empty. Supply a separate concise sentence capturing its distinctive visual traits (typically 30–60 Chinese characters, maximum 240 characters). Browser prompt copying adds only this sentence, without a model call or the full specification. Keep the sentence consistent when editing the specification. Older entries without a sentence fall back to their first description sentence until edited. The creation entrypoint permanently marks these entries as `agent`; entries created in the browser remain `user` even after Agent edits. Update or permanently delete only when the user requests it or it is otherwise clearly part of the current task:
|
|
50
54
|
|
|
51
55
|
```text
|
|
@@ -110,9 +114,13 @@ When generating an image from a spatial camera, follow that reference's **Camera
|
|
|
110
114
|
|
|
111
115
|
When the user asks for final 3D models or a scene in their project, read [references/spatial-modeling.md](references/spatial-modeling.md). Combine the full style specification and reference images with the Human2AI spatial session's layout, scale, pose and camera guidance. Build and review the result using the consumer project's existing tools. A style binding does not alter the guide scene or record completion of external modeling. Use the spatial authoring workflow above only when the guide scene itself needs edits.
|
|
112
116
|
|
|
113
|
-
## Choose refinement or style processing
|
|
117
|
+
## Choose design, planning, refinement or style processing
|
|
118
|
+
|
|
119
|
+
For requests to design or redesign composition content from focuses or planning guides, follow [Design content from composition planning](references/composition.md#design-content-from-composition-planning). Apply the same interpretation and visual checks when styling, refining or generating from an existing planned composition. With complex guides, especially radial fans, spirals or interacting plans, explicitly map their relationships to visible content before choosing shapes. Check focal placement and directional structure separately; preserving guide data or placing subjects at focuses alone does not fulfill the composition.
|
|
120
|
+
|
|
121
|
+
For requests to add, inspect or adjust composition planning guides, follow [Shared composition planning](references/composition.md#shared-composition-planning). Read and edit the draft's `plans` through the CLI and save through `capture.commands.save`. Use `composition inspect` and its `planningIntersections` to locate guide crossings and read coordinates for requested placement. Editing guides alone leaves content nodes unchanged.
|
|
114
122
|
|
|
115
|
-
A request for
|
|
123
|
+
A request for 精修 or for applying mathematical proportions, symmetry or focal relationships to canvas elements calls for the independent refinement workflow in [references/composition.md](references/composition.md). Do not infer a style request from these terms or bind a library style. Refinement may preserve the source without changes when the Agent finds no justified improvement. Use style processing below only when style application is part of the user’s intent.
|
|
116
124
|
|
|
117
125
|
## Process a canvas with its style
|
|
118
126
|
|
|
@@ -148,7 +156,7 @@ Reconnect after binding to obtain the current specification and save command. Bi
|
|
|
148
156
|
|
|
149
157
|
For SVG icons, decorations, or outlines requested as image-node content, read [references/svg-images.md](references/svg-images.md). Both session types use their existing image nodes for SVG; the user describes the result in language and the Agent authors the source.
|
|
150
158
|
|
|
151
|
-
- For `image-composition`, read [references/composition.md](references/composition.md) before drawing a reference picture, canvas processing, refinement or generation-reference work. Interpret light markers as approximately as ordinary shape regions: retain their broad lighting contribution while freely adapting width, length, continuity, edges and strength. User instructions and node notes take precedence. Approximate overall correspondence is sufficient; do not infer fixed-width stripes, strong contrast or exact coverage from the canvas.
|
|
159
|
+
- For `image-composition`, read [references/composition.md](references/composition.md) before designing from focuses or planning guides, editing composition planning, drawing a reference picture, canvas processing, refinement or generation-reference work. Interpret light markers as approximately as ordinary shape regions: retain their broad lighting contribution while freely adapting width, length, continuity, edges and strength. User instructions and node notes take precedence. Approximate overall correspondence is sufficient; do not infer fixed-width stripes, strong contrast or exact coverage from the canvas.
|
|
152
160
|
- For `ui-layout`, read [references/ui-layout.md](references/ui-layout.md) before modifying the layout document or implementing UI from a capture. Group multi-node controls during projection, and execute its standardization workflow before changing consumer components from canvas geometry.
|
|
153
161
|
- For a future session type, use only the capture kind and operations returned by `session connect`. If no reference or operation supports the requested action, report that boundary instead of inventing a command.
|
|
154
162
|
|