@easysociable/cli 0.1.20 → 0.1.22

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@easysociable/cli",
3
- "version": "0.1.20",
3
+ "version": "0.1.22",
4
4
  "description": "Agent-first CLI for EasySociable: Content Engine, Template, Slideshow, and MCP",
5
5
  "type": "module",
6
6
  "license": "MIT",
@@ -49,12 +49,38 @@ Ask only for what only the user knows:
49
49
  palette goes in `theme.json` (without a Brand or theme Studio falls back to
50
50
  its dark default).
51
51
 
52
- ### 2. Facts
52
+ ### 2. Facts and evidence
53
53
 
54
54
  Research the topic from primary sources (official announcement, docs,
55
55
  reputable press). Keep a source URL for every fact. Drop claims you can only
56
56
  find in secondary blogs. Never invent numbers, dates, quotes or features.
57
57
 
58
+ While you read those sources, collect **evidence images**: real pictures that
59
+ can be a page's focal point (a product screenshot, a chart, a figure from the
60
+ paper). Aim for 2–4 per Run, the cover first. A page built around a real image
61
+ reads as proof and looks different from its neighbours; a text-only deck does
62
+ neither.
63
+
64
+ - Sources: only the topic's own primary sources — the product's site, docs,
65
+ blog, press kit or GitHub README; the paper itself (arXiv HTML has each
66
+ figure as its own file); openly licensed images (Wikimedia Commons, CC0/CC BY).
67
+ Never image search, stock sites, news-site photos, other creators' posts or
68
+ anything watermarked.
69
+ - Take image URLs from pages you already opened (`og:image`, images in the
70
+ body) and download them: `curl -sL -o assets/<name>.png <url>`. PNG, JPEG or
71
+ WebP only (convert anything else to PNG), ≤ 20 MB.
72
+ - Launch posts often show the product only in demo videos: download the video
73
+ and pull frames of the real UI (`ffmpeg -ss <seconds> -i demo.mp4 -frames:v 1
74
+ frame.png`), then crop to the phone or window. A frame where the key moment is
75
+ on screen (an approval prompt, a result) beats a generic screen.
76
+ - **Look at every file** before keeping it. Drop it when it is off-topic,
77
+ unreadable at phone size, would need more than 1.25× upscaling to fill its
78
+ area, carries a watermark, or shows a recognisable person who is not the
79
+ subject.
80
+ - Keep each kept image's source URL for the final message.
81
+ - Found nothing usable → fine, step 5 handles it. Don't spend more than a few
82
+ fetches looking.
83
+
58
84
  When the user started from a Content Engine run, facts come from its knowledge
59
85
  pages instead (see `easysociable-content`).
60
86
 
@@ -110,8 +136,9 @@ Structure (step 3) and look are chosen separately. The look comes from a
110
136
  (results are shuffled) and take the first that fits the content. Its
111
137
  `style` is the deck's style; for each other page ask for that page's roles
112
138
  with `--style <style>`. A number → `metric,proof`; a list item →
113
- `point,value,steps`; a comparison → `compare`; a real product →
114
- `screenshot`. No match in that style → any style, keeping the cover's chrome.
139
+ `point,value,steps`; a comparison → `compare`; a page with an evidence
140
+ image (step 2) or a real product → `screenshot`. No match in that style →
141
+ any style, keeping the cover's chrome.
115
142
 
116
143
  Don't filter out references that need an image just because you have none:
117
144
  most covers in the library have an image area. Use one and fill that area
@@ -140,17 +167,26 @@ Say 'same as this'. Want another look? Say 'different look'."
140
167
  an AI-generated picture of a real product UI.
141
168
  - Concept / mood / background → generate one if this environment has an
142
169
  image-generation tool; otherwise leave the page text-only.
143
- - Images never contain text: all words stay in editable text layers.
144
- - **Every page whose content needs a real image you don't have gets a
145
- placeholder slot** (as many pages as need one), never a text-only layout. Size it into the composition (usually the
146
- lower half of the page) and label it with exactly what belongs there, e.g.
147
- "Add: Grok Bot app screenshot". The user selects it in Studio and clicks
148
- the upload button to replace it. Markup and SVG in `references/REFERENCES.md`
149
- ("Image placeholder").
150
- - An image you do have: upload it
151
- (`easysociable images upload --file body.json` with
152
- `{ "file": "data:image/png;base64,…", "filename": "x.png" }`) and use the
153
- returned `asset.url` as `src`.
170
+ - Generated images never contain text: all words stay in editable text layers.
171
+ (A real screenshot or figure keeps its own text.)
172
+ - Fill each image area in this order:
173
+ 1. The user's own image, when they gave one.
174
+ 2. An evidence image from step 2. Upload it
175
+ (`easysociable images upload --file body.json` with
176
+ `{ "file": "data:image/png;base64,…", "filename": "x.png" }`; build it with
177
+ `node -e "const f=process.argv[1],t=f.match(/\.(jpe?g|webp)$/i)?(/webp/i.test(f)?'webp':'jpeg'):'png';console.log(JSON.stringify({file:'data:image/'+t+';base64,'+require('fs').readFileSync(f,'base64'),filename:require('path').basename(f)}))" assets/x.png > body.json`)
178
+ and use the returned `asset.url` as `src`.
179
+ Crop and scale it (`objectFit: 'cover'`, `objectPosition`), never alter
180
+ what it shows. To point at something in it, add a separate element on top
181
+ (a red ellipse border, an underline bar) so the user can move or delete it.
182
+ 3. Something only the user has (their app, their dashboard, their results)
183
+ → a **placeholder slot**, never a text-only layout. Size it into the
184
+ composition (usually the lower half of the page) and label it with
185
+ exactly what belongs there, e.g. "Add: Grok Bot app screenshot". The user
186
+ selects it in Studio and clicks the upload button to replace it. Markup
187
+ and SVG in `references/REFERENCES.md` ("Image placeholder").
188
+ 4. Anything else → fill the area from the content or delete it
189
+ (`references/REFERENCES.md`, "A reference's image area").
154
190
  - List every placeholder in the final message ("page 2: app screenshot").
155
191
 
156
192
  ### 6. Check (hard gate)
@@ -176,8 +212,8 @@ easysociable slideshows create --file pack.json --brand-id <brandId> --json
176
212
  # no Brand: --theme theme.json instead of --brand-id
177
213
  ```
178
214
 
179
- Reply once with: the `studioUrl`, the arc in one line, the sources, and each
180
- image placeholder to replace (page + what to upload). Tell them to edit in
215
+ Reply once with: the `studioUrl`, the arc in one line, the sources (facts and
216
+ each evidence image: "p1 image: <url>"), and each image placeholder to replace (page + what to upload). Tell them to edit in
181
217
  Studio and click **Download** for the PNG ZIP.
182
218
 
183
219
  ### 8. Revise (same Run, never a copy)
@@ -244,7 +280,7 @@ Template steps:
244
280
  roles the new content has none of.
245
281
  4. Change only text inside `data-variable` elements and send matching
246
282
  `slots`. Too long → rewrite shorter; never resize boxes or move elements.
247
- Every source image becomes a placeholder for the new topic (step 5);
283
+ Every source image is replaced for the new topic (step 5 order);
248
284
  Brand avatar/logo stay.
249
285
  5. Step 6 check, then create (step 7). In the reply, say in one line what
250
286
  differs from the source ("6 tips, so 6 point pages instead of 4") and that