chinese-ink-poster

Community@sumino/chinese-ink-poster
Community skill — not reviewed. It was shared by Jagulus and has not been checked by Neta. Read SKILL.md below before letting an agent use it.
Installation
npx -y @neta-art/neta-search-cli@latest skills add @sumino/chinese-ink-poster
Summary

Turn your world's place and season into a vertical ink-wash poster with a brush-calligraphy title and a small poem.

  • Makes one tall poster: an ink landscape on the left, clean paper for text on the right, and a dark ink block at the top.
  • A four-character brush-calligraphy title runs down the ink block, with a two-line poem beside it and a small red seal.
  • The upper right carries a small English title, a subtitle, a short verse and made-up coordinates, like a magazine cover.
  • Your character never appears. The place, the season and a few small objects tell the story.
  • Works best for a world with a distinct place, weather or season. You can switch the season, ink colour, paper tone and seal.
SKILL.md
# Chinese Ink Editorial Poster

A vertical 3:4 art poster in the language of new-Chinese ink wash and modern magazine layout. The left two-thirds carry an ink landscape; the right third stays clean paper for type; a large feathered ink block sits at the top-left with a thin gilded edge. A four-character brush title runs vertically over the block, a two-column poem sits beside it, and the upper-right carries a small English title, a kicker, a verse, coordinates and a red seal.

The character never appears. The landscape, the season, the settlement and a few small objects carry the story. The method is one mechanism with parameters — season, ink colour, paper tone, seal character — not a different skill per skin.

## What you get

- A 1086×1448 (3:4) PNG poster, ready to import as a Work.
- A generated, textless ink-wash background with a controlled text zone.
- Typeset Chinese calligraphy, poem, English annotations and seal, composited in HTML/CSS and screenshotted through headless Chrome.
- A deterministic layout with a probe report, so you can verify the title sits inside the ink block before shipping.

## When to use

Use when the user wants a poetic, restrained, typographic poster of a **place or world**, not a character portrait:

- "Chinese ink poster", "new Chinese style poster", "ink wash editorial";
- "水墨海报", "新中式海报", "国风海报", "书法标题海报";
- a travel-poster or magazine-cover layout with a large calligraphy title and a small poem.

Do not use for:

- a character portrait or a scene with the OC in frame;
- a colorful illustration with no typography;
- a Western editorial layout with photos — use an editorial poster skill;
- a multi-panel storyboard — use a storyboard skill.

## Hard rules

0. **Use the sandbox CLI path.** Every `neta` command is `node /mods/neta/neta …` (`neta` may not be on PATH).
1. **Read the character and the world first.** Extract a place, a season, 3–5 motifs, a palette, and one small narrative object. Do not invent a generic Chinese village if the world has its own architecture.
2. **No character in the picture.** No face, silhouette, portrait, reflection or recognizable costume. Distant generic figures with umbrellas are scene dressing, not the OC.
3. **Title = scenery, not a label.** Four Chinese characters distilled from the place/season. Never use the character's name, species, faction or a location label. The title must read as a place or a mood.
4. **Text zones are fixed.** The ink block must contain the title; the right 30–32% stays clean paper; the English block sits in the upper right. Nothing crosses those zones.
5. **No text in the generated background.** No letters, numbers, seal, watermark or pseudo-text. All type is composited.
6. **Low saturation, one pure colour block.** Ink layers are transparent; only the big block uses a pure colour. One small accent (vermilion seal or a single autumn leaf).
7. **One mechanism, parameters.** Season, block colour, paper tone and seal character are config values. Do not fork the skill per season or palette.
8. **Verify before shipping.** Render once, read the JSON probe, and confirm the title box is inside the measured ink block. A title on paper is a fail unless the block was intentionally removed.
9. **Deliver the image Work and its card.** No web page unless the user asks.
10. **Self-contained.** All prompts and configs use placeholders (`[character]`, `[place]`, `[season]`, `[motif]`, `[theme]`, `[palette]`). No private world names, no account names, no keys.

## Inputs

A JSON config (see `templates/config.example.json`):

```json
{
  "title_zh": "四字标题",
  "verses": ["七字上句占位文", "七字下句占位文"],
  "title_en": ["TWO-LINE", "ENGLISH TITLE"],
  "kicker": ["A STUDY OF [THEME]", "AND [MOTIF]"],
  "verse_en": ["The [element] remembers", "what the [element] forgets."],
  "coords": "00°00′N · 00°00′E",
  "plate": "PLATE 01",
  "seal": "印",
  "background": "path/to/background.png",
  "out": "path/to/poster.png",
  "width": 1086,
  "height": 1448
}
```

Rules:

- `title_zh`: exactly 4 characters for the default block. Five needs a taller block (≥ 48% of canvas height) or a smaller title (96 px).
- `verses`: two lines, 5–9 characters each, original, poetic, no character names.
- `title_en`: one or two lines, 2–4 words each, title case or caps.
- `kicker`: one or two short lines, an editorial subtitle.
- `verse_en`: one or two short lines, an English poem.
- `coords`, `plate`: decorative metadata; keep them plausible but fictional.
- `seal`: one character, a mood or virtue — not the character's name.
- `width`/`height`: must be 1086×1448 for this template. For a larger raster, render here and upscale with Lanczos.

## Pipeline

### 1. Read the world and choose the scene

```bash
node /mods/neta/neta atom list --type character
node /mods/neta/neta atom get "world/characters/<Name>.md"
node /mods/neta/neta find images "<Name>"
```

Write five lines before prompting:

- **Place:** the settlement or landmark that belongs to this world.
- **Season / weather:** e.g. late autumn rain, spring mist, first snow.
- **Motifs:** 3–5 shapes that can be drawn as landscape details.
- **Palette:** one ink colour, one paper tone, one accent.
- **Narrative object:** one small object that hints at the character's story without naming it.

### 2. Generate the textless background

Read `references/background-prompt.md` for the full template and parameter table.

```bash
NETA_DEFAULT_IMAGE_MODEL=gpt-image-2 node /mods/neta/neta generate image \
  --work-title "<Place> · ink background" \
  --work-description "<one sentence>" \
  --param size=1536x2048 --param quality=high --param output_format=png \
  --prompt "$(cat /tmp/<slug>-ink-bg.txt)"
```

The background must satisfy:

- 3:4 vertical, warm ivory paper, fine fibre texture;
- a large ink block from the top-left edge to ~52% width and ~37% height, feathered, mottled, thin gilded rim;
- right 30–32% clean paper, no ink;
- lower-left/centre landscape with 3–5 depth layers;
- no text, no seal, no character.

Save the image. `neta generate` creates a Work automatically; that Work is an ingredient, not the deliverable.

### 3. Measure the block

```bash
bash scripts/measure-block.sh /path/to/background.png
```

It prints `block=<w>x<h>+<x>+<y>` measured in the top-left 60%×45%.

The title box for four characters is **115×466 px at (70, 22)**. The block must contain it with ≥ 20 px margin:

- block width ≥ 185 px;
- block height ≥ 510 px.

If the block is smaller, either regenerate with "extend the ink block to 52% width and 37% height", or reduce the title to 96 px and re-check. Do not ship a cream title on paper.

### 4. Write the text

- Four-character title: two concrete nouns/verbs, no character label. Example shapes: `[season]+[water]`, `[place]+[weather]`, `[mountain]+[silence]`.
- Two seven-character lines: a couplet, image first, feeling second. Avoid the character's name, species or faction.
- English title: a translation of the Chinese title, not a character name.
- Kicker: "A STUDY OF [THEME] AND [MOTIF]".
- English verse: two short lines, parallel structure.
- Seal: one virtue character (e.g. 静, 隐, 寒, 清) — not a name.

### 5. Render

```bash
node scripts/render.mjs --config /path/to/config.json --probe
```

The script:

- copies the templates and fonts into a temp build;
- fetches a brush-calligraphy subset for only the characters used (`Ma Shan Zheng` via Google Fonts);
- starts a local static server;
- screenshots at 1086×1448 with headless Chrome;
- optionally dumps a layout probe;
- returns JSON with `width`, `height`, `calligraphy` and `layout`.

If the calligraphy fetch fails, the title falls back to a system serif and `"calligraphy": false`. Re-run when the network is available, or install a Chinese brush font and point `@font-face` at it.

### 6. QA

Follow `references/qa.md`. At minimum:

- output is 1086×1448;
- `scroll` is `[1086, 1448]`, no overflow;
- `calligraphy` is `true`;
- title box `[70,22,115,466]` sits inside the measured block;
- English block is inside the right paper, no overlap with the landscape;
- seal does not touch the English title;
- no text in the background; no character.

Regenerate the background if a hard check fails. Do not paint type over a busy area.

### 7. Deliver

Import the final PNG as an image Work:

```bash
node /mods/neta/neta work import image \
  --file uploads/<slug>.png \
  --work-title "<English Title>" \
  --prompt "<one sentence describing the poster>" \
  --work-description "<one sentence>"
```

Place the image card:

```bash
node /mods/neta/.agents/skills/board-ops/scripts/place.mjs \
  --title "<English Title>" \
  --work "works/work_<id>.json"
```

For a chat embed, upload the final PNG to a public asset and use the returned HTTPS URL. Verify the Work page returns 200.

## Layout geometry (1086×1448)

| Element | Position / size |
| --- | --- |
| Canvas | 1086×1448, warm ivory paper |
| Ink block | top-left, ~52% width × ~37% height, gilded right edge |
| Title | 4 chars, 112 px, vertical, left 70, top 22, cream `#f2e8d4` |
| Poem | 19 px, vertical, 7 chars per column, left 294 / 252, top 92 |
| Seal | 47×47, right 64, top 52, red `#a32a2f`, one white character |
| English block | right 64, top 126, width 286, right-aligned |
| English title | 12 px Bodoni, letter-spacing .2em, 2 lines |
| Kicker | 7.5 px, letter-spacing .24em, 2 lines |
| Rule | 148×1, right-aligned |
| English verse | 9 px, line-height 1.95 |
| Meta | 7 px, coordinates + plate |

The title and poem are cream on the ink block; the English block is ink on paper. Do not invert that relationship.

## Parameters (one mechanism, many skins)

| Parameter | Options | Effect |
| --- | --- | --- |
| `season` | spring mist / summer rain / autumn maple / winter snow | prompt palette and motifs |
| `block_color` | indigo / ink black / moss / ochre | the big pure colour block |
| `paper` | warm ivory / cool white | background base |
| `accent` | vermilion / ochre / celadon | seal, one leaf, one lantern |
| `seal` | one virtue character | seal engraving |
| `title_zh` | four characters | calligraphy title |
| `title_en` | two short lines | English title |

Do not create separate skills for each season or colour. Change the config and the background prompt only.

## Failure fallbacks

- **Block too small:** regenerate with an explicit 52%×37% block; or drop the title to 96 px and re-measure. Never put cream type on paper.
- **Calligraphy fetch fails:** `calligraphy:false`; the title uses Noto Serif. Re-run, or install a brush font and update the `@font-face` source.
- **Title overflows the block:** shorten to four characters, reduce to 96 px, or raise the block height.
- **English text overlaps the landscape:** confirm the right 30–32% is clean; if not, regenerate. Do not add a white box.
- **Seal collides:** move the seal up 8 px or reduce to 42 px; keep it off the English title.
- **Chrome missing:** set `CHROME_BIN` to a Chrome/Chromium executable. The renderer has no npm dependencies.
- **Chrome times out:** the renderer serves files from the same Node process, so it uses async `spawn`; if it still hangs, close other Chrome instances and re-run.
- **Wrong output size:** the template is tuned to 1086×1448 and rejects other sizes. Render here, then upscale with `magick final.png -resize 2172x2896 [email protected]`.

## Files

```
chinese-ink-poster/
  SKILL.md
  templates/poster.html, poster.css, config.example.json
  scripts/render.mjs, fetch-calligraphy.sh, measure-block.sh
  references/background-prompt.md, layout.md, qa.md, publishing.md
  assets/demo-cover.webp, assets/fonts/*.woff2
```

`assets/demo-cover.webp` is a textless example background; it contains no names or story text.