generate-image

Use when user asks to generate, create, draw, or make an image or picture. Triggers on phrases like "generate an image of", "make a picture of", "create an image", "draw me a".

install
source · Clone the upstream repo
git clone https://github.com/nicolasagardoy/flux-klein-image-gen
manifest: skill.md
source content

Generate Image with FLUX.2 Klein

Use this skill to generate images locally using the FLUX.2 Klein 4B model.

Workflow

  1. Craft a rich prompt using the FLUX formula:

    [Subject] + [Action/Pose] + [Style/Medium] + [Setting] + [Lighting] + [Camera]

    • Preserve all specific details the user mentioned
    • Add lighting if not specified: golden hour, soft diffused, dramatic rim, studio three-point
    • Add camera if not specified: "shot on Hasselblad 85mm f/2.8, shallow depth of field"
    • Use hex codes for specific colors (e.g. "#1A2B3C deep navy")
    • Describe what you WANT — negative prompts don't work with this model
  2. Run the script:

source ~/venvs/flux/bin/activate && python3.11 ~/Documents/gen-images/claude-cli/flux_klein.py --prompt "<your prompt here>"
  1. Parse the output path from the last line of stdout (

    Saved to <path>
    )

  2. Auto-open in Preview:

open <path>
  1. Report the path to the user.

Prompt Formula Example

User: "a fisherman at sunset"

Good prompt:

A weathered fisherman in his 70s, navy cable-knit sweater, standing at the helm of a wooden boat. Golden hour light from the left, dramatic rim lighting. Shot on Hasselblad 85mm f/2.8, shallow depth of field, Kodak Portra 400 color science.

Notes

  • Output saved to
    ~/Documents/gen-images/claude-cli/<timestamp>.png
  • Model: FLUX.2 Klein 4B at
    ~/models/flux2-klein-4b
    on MPS
  • Generation takes ~30-60 seconds on Apple Silicon