$npx -y skills add freestylefly/canghe-skills --skill canghe-article-illustratorAnalyzes article structure, identifies positions requiring visual aids, generates illustrations with Type × Style two-dimension approach. Use when user asks to "illustrate article", "add images", "generate images for article", or "为文章配图".
| 1 | # Article Illustrator |
| 2 | |
| 3 | Analyze articles, identify illustration positions, generate images with Type × Style consistency. |
| 4 | |
| 5 | ## Two Dimensions |
| 6 | |
| 7 | | Dimension | Controls | Examples | |
| 8 | |-----------|----------|----------| |
| 9 | | **Type** | Information structure | infographic, scene, flowchart, comparison, framework, timeline | |
| 10 | | **Style** | Visual aesthetics | notion, warm, minimal, blueprint, watercolor, elegant | |
| 11 | |
| 12 | Combine freely: `--type infographic --style blueprint` |
| 13 | |
| 14 | ## Types |
| 15 | |
| 16 | | Type | Best For | |
| 17 | |------|----------| |
| 18 | | `infographic` | Data, metrics, technical | |
| 19 | | `scene` | Narratives, emotional | |
| 20 | | `flowchart` | Processes, workflows | |
| 21 | | `comparison` | Side-by-side, options | |
| 22 | | `framework` | Models, architecture | |
| 23 | | `timeline` | History, evolution | |
| 24 | |
| 25 | ## Styles |
| 26 | |
| 27 | See [references/styles.md](references/styles.md) for Core Styles, full gallery, and Type × Style compatibility. |
| 28 | |
| 29 | ## Workflow |
| 30 | |
| 31 | ``` |
| 32 | - [ ] Step 1: Pre-check (EXTEND.md, references, config) |
| 33 | - [ ] Step 2: Analyze content |
| 34 | - [ ] Step 3: Confirm settings (AskUserQuestion) |
| 35 | - [ ] Step 4: Generate outline |
| 36 | - [ ] Step 5: Generate images |
| 37 | - [ ] Step 6: Finalize |
| 38 | ``` |
| 39 | |
| 40 | ### Step 1: Pre-check |
| 41 | |
| 42 | **1.5 Load Preferences (EXTEND.md) ⛔ BLOCKING** |
| 43 | |
| 44 | ```bash |
| 45 | test -f .canghe-skills/canghe-article-illustrator/EXTEND.md && echo "project" |
| 46 | test -f "$HOME/.canghe-skills/canghe-article-illustrator/EXTEND.md" && echo "user" |
| 47 | ``` |
| 48 | |
| 49 | | Result | Action | |
| 50 | |--------|--------| |
| 51 | | Found | Read, parse, display summary | |
| 52 | | Not found | ⛔ Run [first-time-setup](references/config/first-time-setup.md) | |
| 53 | |
| 54 | Full procedures: [references/workflow.md](references/workflow.md#step-1-pre-check) |
| 55 | |
| 56 | ### Step 2: Analyze |
| 57 | |
| 58 | | Analysis | Output | |
| 59 | |----------|--------| |
| 60 | | Content type | Technical / Tutorial / Methodology / Narrative | |
| 61 | | Purpose | information / visualization / imagination | |
| 62 | | Core arguments | 2-5 main points | |
| 63 | | Positions | Where illustrations add value | |
| 64 | |
| 65 | **CRITICAL**: Metaphors → visualize underlying concept, NOT literal image. |
| 66 | |
| 67 | Full procedures: [references/workflow.md](references/workflow.md#step-2-setup--analyze) |
| 68 | |
| 69 | ### Step 3: Confirm Settings ⚠️ |
| 70 | |
| 71 | **ONE AskUserQuestion, max 4 Qs. Q1-Q3 REQUIRED.** |
| 72 | |
| 73 | | Q | Options | |
| 74 | |---|---------| |
| 75 | | **Q1: Type** | [Recommended], infographic, scene, flowchart, comparison, framework, timeline, mixed | |
| 76 | | **Q2: Density** | minimal (1-2), balanced (3-5), per-section (Recommended), rich (6+) | |
| 77 | | **Q3: Style** | [Recommended], minimal-flat, sci-fi, hand-drawn, editorial, scene, Other | |
| 78 | | Q4: Language | When article language ≠ EXTEND.md setting | |
| 79 | |
| 80 | Full procedures: [references/workflow.md](references/workflow.md#step-3-confirm-settings-) |
| 81 | |
| 82 | ### Step 4: Generate Outline |
| 83 | |
| 84 | Save `outline.md` with frontmatter (type, density, style, image_count) and entries: |
| 85 | |
| 86 | ```yaml |
| 87 | ## Illustration 1 |
| 88 | **Position**: [section/paragraph] |
| 89 | **Purpose**: [why] |
| 90 | **Visual Content**: [what] |
| 91 | **Filename**: 01-infographic-concept-name.png |
| 92 | ``` |
| 93 | |
| 94 | Full template: [references/workflow.md](references/workflow.md#step-4-generate-outline) |
| 95 | |
| 96 | ### Step 5: Generate Images |
| 97 | |
| 98 | ⛔ **BLOCKING: Prompt files MUST be saved before ANY image generation.** |
| 99 | |
| 100 | 1. For each illustration, create a prompt file per [references/prompt-construction.md](references/prompt-construction.md) |
| 101 | 2. Save to `prompts/NN-{type}-{slug}.md` with YAML frontmatter |
| 102 | 3. Prompts **MUST** use type-specific templates with structured sections (ZONES / LABELS / COLORS / STYLE / ASPECT) |
| 103 | 4. LABELS **MUST** include article-specific data: actual numbers, terms, metrics, quotes |
| 104 | 5. **DO NOT** pass ad-hoc inline prompts to `--prompt` without saving prompt files first |
| 105 | 6. Select generation skill, process references (`direct`/`style`/`palette`) |
| 106 | 7. Apply watermark if EXTEND.md enabled |
| 107 | 8. Generate from saved prompt files; retry once on failure |
| 108 | |
| 109 | Full procedures: [references/workflow.md](references/workflow.md#step-5-generate-images) |
| 110 | |
| 111 | ### Step 6: Finalize |
| 112 | |
| 113 | Insert `` after paragraphs. |
| 114 | |
| 115 | ``` |
| 116 | Article Illustration Complete! |
| 117 | Article: [path] | Type: [type] | Density: [level] | Style: [style] |
| 118 | Images: X/N generated |
| 119 | ``` |
| 120 | |
| 121 | ## Output Directory |
| 122 | |
| 123 | ``` |
| 124 | illustrations/{topic-slug}/ |
| 125 | ├── source-{slug}.{ext} |
| 126 | ├── references/ # if provided |
| 127 | ├── outline.md |
| 128 | ├── prompts/ |
| 129 | └── NN-{type}-{slug}.png |
| 130 | ``` |
| 131 | |
| 132 | **Slug**: 2-4 words, kebab-case. **Conflict**: append `-YYYYMMDD-HHMMSS`. |
| 133 | |
| 134 | ## Modification |
| 135 | |
| 136 | | Action | Steps | |
| 137 | |--------|-------| |
| 138 | | Edit | Update prompt → Regenerate → Update reference | |
| 139 | | Add | Position → Prompt → Generate → Update outline → Insert | |
| 140 | | Delete | Delete files → Remove reference → Update outline | |
| 141 | |
| 142 | ## References |
| 143 | |
| 144 | | File | Content | |
| 145 | |------|---------| |
| 146 | | [references/workflow.md](references/workflow.md) | Detailed procedures | |
| 147 | | [references/usage.md](references/usage.md) | Command synt |