$npx -y skills add indranilbanerjee/socialforge --skill compose-creativeCore creative engine. Generates images and video using 4 modes with brand assets, AI compositing, and platform resizing.
| 1 | # /socialforge:compose-creative — Creative Production Engine |
| 2 | |
| 3 | The core production skill. Takes asset matching results and produces visual and video assets for each post according to its assigned creative mode, using a staged human-in-the-loop approval flow. |
| 4 | |
| 5 | ## Context efficiency |
| 6 | |
| 7 | Asset-heavy skill. **Grep before Read** the asset catalog (`${CLAUDE_PLUGIN_DATA}/<brand>/assets/index.json`) — never list the asset directory. Reference generated images / videos by path, not by loading metadata. Brand profile loads once per session. |
| 8 | |
| 9 | ## The 4 Creative Modes |
| 10 | |
| 11 | ### MODE 1: ANCHOR_COMPOSE |
| 12 | Brand asset is the untouchable center. AI generates scene around it. |
| 13 | 1. Remove background from brand asset (rembg) |
| 14 | 2. Generate surrounding scene via AI using brand style references |
| 15 | 3. Composite asset onto generated scene (Pillow) |
| 16 | 4. Add shadow/reflection for natural placement |
| 17 | 5. Add text overlay + logo |
| 18 | 6. Resize per platform |
| 19 | |
| 20 | ### MODE 2: ENHANCE_EXTEND |
| 21 | Brand asset is the foundation. AI modifies periphery only. |
| 22 | 1. Feed real image to AI edit endpoint |
| 23 | 2. AI extends/enhances while preserving core subject |
| 24 | 3. Verify core subject preservation |
| 25 | 4. Add overlay + resize |
| 26 | |
| 27 | ### MODE 3: STYLE_REFERENCED |
| 28 | No brand asset composited. Style reference photos guide AI generation. |
| 29 | 1. Load 2-8 brand style reference images |
| 30 | 2. Construct 5-layer prompt (brand identity, post context, creative direction, image rules, technical) |
| 31 | 3. Feed references + prompt to AI generation |
| 32 | 4. Quality review — does output match brand DNA? |
| 33 | 5. Add overlay + resize |
| 34 | |
| 35 | ### MODE 4: PURE_CREATIVE |
| 36 | Full AI generation with only text prompt + brand colors/mood. |
| 37 | 1. Construct prompt from brief + brand-config visual style |
| 38 | 2. Generate (text-only, no reference images) |
| 39 | 3. Quality review |
| 40 | 4. Add overlay + resize |
| 41 | |
| 42 | ## Prerequisites |
| 43 | |
| 44 | - `asset-matches.json` must exist (generated by `/socialforge:match-assets` -> match_assets.py) |
| 45 | - `calendar-data.json` must exist (generated by `/socialforge:parse-calendar`) |
| 46 | - `brand-config.json` must exist for active brand |
| 47 | - `cost-log.json` initialized (via status_manager.py --action init-month) |
| 48 | - Valid credentials for Gemini via Vertex AI (images) and WaveSpeed / Kling v3.0 (video) via credential_manager.py |
| 49 | |
| 50 | If any prerequisite is missing: "Run `/socialforge:match-assets` first — creative production needs asset matching results." |
| 51 | |
| 52 | ## Process (For Each IMAGE Post) — 4-Stage Approval Flow |
| 53 | |
| 54 | ### Stage 1: Creative Direction (No API Call) |
| 55 | Present 2-3 creative direction options to the user. Each option includes: |
| 56 | - A description of the visual concept |
| 57 | - Mood, color palette, and composition approach |
| 58 | - How the brand asset will be used (per the assigned creative mode) |
| 59 | - Rough reference to style/tone |
| 60 | |
| 61 | No image generation happens here. The user picks a direction before any credits are spent. |
| 62 | |
| 63 | ### Stage 2: Confirm Details |
| 64 | Once the user selects a direction, confirm the specifics before generating: |
| 65 | - Final prompt details and any refinements the user wants |
| 66 | - Aspect ratio and platform targets |
| 67 | - Text overlay copy and placement preferences |
| 68 | - Any special instructions (e.g., "warmer tones", "more negative space") |
| 69 | |
| 70 | User explicitly approves to proceed to generation. |
| 71 | |
| 72 | ### Stage 3: Generate and Select (Gemini via Vertex AI) |
| 73 | - Generate 2-3 image versions based on the confirmed direction |
| 74 | - Show all versions inline via the Read tool so the user can compare |
| 75 | - User picks their preferred version (or requests another round with adjustments) |
| 76 | - Max 3 generation rounds per post before escalating |
| 77 | |
| 78 | ### Stage 4: Post-Process and Save |
| 79 | After the user selects their preferred image: |
| 80 | 1. Apply text overlay via compose_text_overlay.py |
| 81 | 2. Apply logo per brand-config.json (position, opacity, size, platform exclusions) |
| 82 | 3. Resize per platform via resize_image.py |
| 83 | 4. Save final assets to the post-specific folder: `{post_folder}/final/` |
| 84 | 5. Update status-tracker.json |
| 85 | 6. Log prompt to `shared/prompt-logs/` |
| 86 | 7. Track API cost in cost-log.json |
| 87 | |
| 88 | ## Process (For Each VIDEO Post) — 5-Stage Approval Flow |
| 89 | |
| 90 | ### Stage 1: Video Concept (No API Call) |
| 91 | Present 2-3 video concept ideas to the user. Each option includes: |
| 92 | - A narrative arc or visual concept for the short-form video |
| 93 | - Description of the opening frame, motion/transition, and closing frame |
| 94 | - Mood, pacing, and style notes |
| 95 | - How brand assets or style references will be incorporated |
| 96 | |
| 97 | User picks a concept before any generation begins. |
| 98 | |
| 99 | ### Stage 2: First Frame Generation (Gemini via Vertex AI) |
| 100 | - Generate 2 first-frame options based on the selected concept |
| 101 | - Show both inline via the Read tool |
| 102 | - User picks their preferred first frame (or requests adjustments) |
| 103 | |
| 104 | ### Stage 3: Last Frame Generation (Gemini via Vertex AI) |
| 105 | - Generate 2 last-frame options that complement the approved first frame |
| 106 | - Show both inline via the Read tool |
| 107 | - User pick |