
civitai-gen
Generate images, videos, audio, and more using Civitai's orchestration API. Use when the user wants text-to-image, video generation (11+ engines), text-to-speech, music, transcription, bulk batches, experiment sweeps, or buzz cost estimation. Not for browsing or searching Civitai models (use the Civitai MCP server).
- Installs
- 94
- Last 24h
- —
- Trending rank
- —
- Security
- Not audited
Install
Works with every agent the skills CLI supports.
npx skills add https://github.com/civitai/civitai-gen-skill --skill civitai-gen- 01
Install
Run the command in your project. The CLI asks which agents to install for.
- 02
Describe the task
Ask your agent for something this skill covers. It loads civitai-gen automatically when relevant.
- 03
Review the result
The agent follows the SKILL.md steps, scripts and references bundled with the skill.
SKILL.md
The instructions your agent reads when the skill is triggered.
civitai-gen
Unified CLI for Civitai's orchestration Workflow API. All generation types share the same workflow lifecycle: submit, poll, download.
Setup
Requires Node.js 18+. Set CIVITAI_API_KEY either as an environment variable or in a .env file in this skill's directory (next to generate.mjs). Copy .env.example to .env to start. Get a key at: https://civitai.com/user/account
Paths below are relative to this skill's directory. Run the scripts from there (
cdinto it), or prefix with the install path your runtime uses.
Capabilities
| Command | What it does | Details |
|---|---|---|
wait | Submit + poll + download (default) | All-in-one blocking generation |
submit | Fire-and-forget, returns workflow ID | For async workflows |
status | Check workflow progress | --poll for live updates |
download | Fetch completed media | From a workflow ID |
cost | Dry-run buzz estimation | whatif=true, 0 buzz spent |
engines | List video engines + live status | 11+ engines |
tts | Text-to-speech | See docs/tts.md |
music | Music/song generation (ACE Step 1.5) | See docs/music.md |
transcribe | Speech-to-text transcription | See docs/transcription.md |
Quick Examples
# Image (defaults to Flux.1, 4 images)
node generate.mjs wait --prompt "A knight at sunset" -o ./out
# Multiple concurrent prompts
node generate.mjs wait --prompt "A warrior" --prompt "A mage" -o ./out
# Video (VEO 3)
node generate.mjs wait --engine veo3 --prompt "A robot walking" -o ./out
# Text-to-speech
node generate.mjs tts --text "Hello world" --speaker serena -o ./out
# Music
node generate.mjs music --prompt "upbeat electronic dance track" -o ./out
# Transcription
node generate.mjs transcribe --media-url "https://example.com/audio.mp3" -o ./out
# Cost check (any type, 0 buzz)
node generate.mjs cost --prompt "A cat" -n 100
node generate.mjs cost --engine veo3 --prompt "A robot" --duration 8
# Experiment mode (wildcard expansion)
node experiment.mjs --spec experiment.json -o ./out
Posting What You Generate
Generate an image (the skill saves it locally), then post the local file in one command:
node generate.mjs wait --prompt "a red apple" -n 1 -o ./out
node mcp-cli.mjs post-image ./out/step_0-0.png --title "My apple"
# -> Post published. URL: https://civitai.com/posts/<id>
post-image reads the local file, uploads it, and publishes the post — it prints the public URL. Pull mcp-cli.mjs first if you don't have it (curl -fsSL https://mcp.civitai.com/cli -o mcp-cli.mjs); CIVITAI_API_KEY is required.
Flags: --title (defaults to the filename), --detail, --nsfw <level>, --draft (leave unpublished), --json. For video/audio, or to attach a pre-uploaded image by UUID, call create_post directly (node mcp-cli.mjs schema create_post) — and prefer posting the local file over the generate output's remoteUrls[].url, which is a short-lived signed URL that expires quickly.
Choosing an Engine & Model
Read docs/engines.md to pick the right generator. The key split:
| Path | Engines | How to pick the model |
|---|---|---|
| Open-weight ecosystem | SD1, SDXL, Pony, Illustrious, Flux.1/2, Qwen, Z-Image, Chroma, Anima | Find a checkpoint AIR + compatible LoRAs via the Civitai MCP (search_models / get_model_version) → --model / --resources |
| Closed API engine | OpenAI, Google/Gemini, Seedream, Grok, MAI, ERNIE + all video/audio | Engine name only — no checkpoint search, no LoRA |
Model discovery uses the Civitai MCP server (hosted at https://mcp.civitai.com/mcp) — call its tools to search checkpoints/LoRAs and get AIR URNs. Don't search inside this skill. A LoRA's base model must match the checkpoint's ecosystem.
If the Civitai MCP isn't connected, add it (browse tools need no API key):
claude mcp add --transport http civitai https://mcp.civitai.com/mcp
Can't add MCP config in your runtime? Pull the zero-dep CLI (Node 18+) and call tools over the shell instead:
curl -fsSL https://mcp.civitai.com/cli -o mcp-cli.mjs
node mcp-cli.mjs call search_models '{"query":"anime portrait","type":"Checkpoint","supportsGeneration":true,"baseModel":"SDXL 1.0"}'
# Call these Civitai MCP tools directly (they return AIR URNs ready for --model / --resources):
search_models { query: "anime portrait", type: "Checkpoint", supportsGeneration: true, baseModel: "SDXL 1.0" }
search_models { query: "neon style", type: "LORA", baseModel: "SDXL 1.0" } # LoRA base MUST match checkpoint
get_model_version { ids: [<versionId>] } # full version details + AIR URN + trigger words
Engine availability/params drift — run node generate.mjs engines for the live list and see https://developer.civitai.com/orchestration/recipes for per-engine parameters.
Domain-Specific Docs
For detailed parameters, read the relevant doc:
- Images:
--prompt,--model,--resources,--aspect,--resolution,--source-image(img2img). Runnode generate.mjs --helpfor full flag list. - Videos:
--engine,--duration,--video-aspect,--generate-audio. Runnode generate.mjs enginesfor available engines. - TTS: Read
docs/tts.md— built-in speakers, voice cloning, style instructions. - Music: Read
docs/music.md— ACE Step 1.5, lyrics, duration. - Transcription: Read
docs/transcription.md— ASR, timestamps, language hints. - Experiments: Read
experiment.mjs --help— wildcards, parameter sweeps, naming.
Workflow Lifecycle
All generation types follow the same pattern:
- Build steps — each job becomes a workflow step with a
$type(textToImage,videoGen,textToSpeech,aceStepAudio,transcription) - Submit — POST to orchestration API, get workflow ID
- Poll — check status until terminal state (succeeded/failed/expired)
- Download — fetch output media (images, videos, audio files)
- JSON summary — clean JSON to stdout with paths, costs, and metadata
Use cost (whatif) to estimate buzz before spending. Use --quiet for agent-friendly output.
Guidelines
- Default to 4 images per prompt. Use
-n 1only when a single image is needed. - For video: always check
costfirst. Video costs 500-2000+ buzz per clip. - Multiple
--promptflags create concurrent steps in one workflow. - Use
--bulk file.jsonfor large batches. - Use experiment mode for systematic parameter sweeps.
Developer Guide
See CLAUDE.md for architecture, module layout, and how to add new step types.
FAQ
What does the civitai-gen skill do?
Generate images, videos, audio, and more using Civitai's orchestration API. Use when the user wants text-to-image, video generation (11+ engines), text-to-speech, music, transcription, bulk batches, experiment sweeps, or buzz cost estimation. Not for browsing or searching Civitai models (use the Civitai MCP server).
How do I install civitai-gen?
Run npx skills add https://github.com/civitai/civitai-gen-skill --skill civitai-gen in your project. The skills CLI detects the agents you use and copies the skill into the right folder. For Claude Code you can also place the skill folder at ~/.claude/skills/civitai-gen/ (personal) or .claude/skills/civitai-gen/ (project).
Which AI agents can use civitai-gen?
Any agent that supports the open Agent Skills format (a folder with a SKILL.md file), including Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI, Windsurf, Cline, OpenCode and more.
Is civitai-gen safe to install?
No partner security audit is available yet. Skills can run commands and scripts, so read the SKILL.md and any bundled files before installing.
Who maintains civitai-gen?
It is published by civitai in civitai/civitai-gen-skill. It has 94 recorded installs.
Popular media & creative skills
hyperframes
heygen-com/hyperframes
Read first to make, edit, animate or render any video with HyperFrames (HTML rendered to video), including launch films, explainers, music videos, charts, maps, vertical clips, title cards, captions and overlays. Holds the render contract, the work loop and what each kind of video needs.
media-use
heygen-com/hyperframes
Get or make any media for a HyperFrames video - music, sound effects, images, icons, logos, voiceover, avatar and generated video, transcripts, cutouts, colour grades and looks - with HeyGen or free local tools, and mix placed audio. Also for footage that looks dark, flat or dull, or should be stylized or hidden.
hyperframes-registry
heygen-com/hyperframes
About 450 ready-made HyperFrames blocks and components installed as editable source - transitions, overlays, titles, kinetic type, captions, charts, map overlays, 3D, camera moves. Use it before hand-building any named visual (CRT scanlines, glitch, film grain, a chart); also for hyperframes add and catalog.
hyperframes-creative
heygen-com/hyperframes
Non-animation creative direction for HyperFrames videos. Use for design spec (frame.md / design.md) handling, palettes, typography, narration, beat planning, audio-reactive visuals, composition patterns, and brand / style decisions. For atomic motion patterns and scene blueprints, use hyperframes-animation.
ai-video-generation
101-skills/superpowers
Generate AI videos with Google Veo, Seedance 2.0, HappyHorse, Wan, Grok and 40+ models via inference.sh CLI. Models: Veo 3.1, Veo 3, Seedance 2.0, HappyHorse 1.0, Wan 2.5, Grok Imagine Video, OmniHuman, Fabric, HunyuanVideo. Capabilities: text-to-video, image-to-video, reference-to-video, video editing, lipsync, avatar animation, video upscaling, foley sound. Use for: social media videos, marketing content, explainer videos, product demos, AI avatars. Triggers: video generation, ai video, text to video, image to video, veo, animate image, video from image, ai animation, video generator, generate video, t2v, i2v, ai video maker, create video with ai, runway alternative, pika alternative, sora alternative, kling alternative, seedance, happyhorse
ai-image-generation
101-skills/superpowers
Generate AI images with GPT-Image-2, FLUX, Gemini, Grok, Seedream, Reve and 50+ models via inference.sh CLI. Models: GPT-Image-2, FLUX Dev LoRA, FLUX.2 Klein LoRA, Gemini 3 Pro Image, Grok Imagine, Seedream 4.5, Reve, ImagineArt. Capabilities: text-to-image, image-to-image, inpainting, LoRA, image editing, upscaling, text rendering. Use for: AI art, product mockups, concept art, social media graphics, marketing visuals, illustrations. Triggers: flux, image generation, ai image, text to image, stable diffusion, generate image, ai art, midjourney alternative, dall-e alternative, text2img, t2i, image generator, ai picture, create image with ai, generative ai, ai illustration, grok image, gemini image, gpt image, openai image, chatgpt image