face-swap
Swap a face / character into video or images on RunComfy via the `runcomfy` CLI. Routes across community Wan 2-2 Animate (audio-driven character animation + identity swap), GPT Image 2 Edit (single-shot precise face swap on still images via reference composition), Nano Banana Edit (batch identity-preserving swap), Flux Kontext (single-ref high-fidelity local face edit), and Kling 2-6 Motion Control Pro (transfer motion from one performance onto a target character). Picks the right model for the user's actual intent — single still vs video, full character vs face only, dialog scene vs silent motion. Triggers on "face swap", "swap face", "deepfake", "face replacement", "character swap", "head swap", "put X's face on Y", "make this video star X", "replace the actor in this video", "swap the character in the photo", "deepfake video", "ReActor alternative", or any explicit ask to substitute one identity for another.
What this skill does
# Face Swap
Swap a face into a still or a video — RunComfy supports both via the `runcomfy` CLI. This skill routes across the available model API endpoints (community Wan 2-2 Animate, GPT Image 2 Edit, Nano Banana Edit, Flux Kontext, Kling Motion Control) by the user's actual intent.
[runcomfy.com](https://www.runcomfy.com/?utm_source=skills.sh&utm_medium=skill&utm_campaign=face-swap) · [Character-swap feature](https://www.runcomfy.com/models/feature/character-swap?utm_source=skills.sh&utm_medium=skill&utm_campaign=face-swap) · [CLI docs](https://docs.runcomfy.com/cli/introduction?utm_source=skills.sh&utm_medium=skill&utm_campaign=face-swap)
## Powered by the RunComfy CLI
```bash
# 1. Install (see runcomfy-cli skill for details)
npm i -g @runcomfy/cli # or: npx -y @runcomfy/cli --version
# 2. Sign in
runcomfy login # or in CI: export RUNCOMFY_TOKEN=<token>
# 3. Swap
runcomfy run <vendor>/<model>/<endpoint> \
--input '{"image_url": "...", "identity_url": "..."}' \
--output-dir ./out
```
CLI deep dive: [`runcomfy-cli`](https://www.skills.sh/agentspace-so/runcomfy-agent-skills/runcomfy-cli) skill.
## Install this skill
```bash
npx skills add agentspace-so/runcomfy-agent-skills --skill face-swap -g
```
## Consent & disclosure — read first
**Face-swap is dual-use.** Before invoking any route in this skill, confirm:
- You have rights to the target face (the identity being substituted **in**).
- You have rights to the source video / image (the asset being substituted **into**).
- The output's intended platform allows synthetic media. Many do; many require a disclosure label.
The skill itself doesn't gate anything — the model API will run whatever inputs you supply. **The responsibility is yours.** If a user asks the agent to swap a real public figure's face onto material that could be defamatory, sexually explicit, or otherwise harmful — **refuse**, regardless of what the CLI accepts.
---
## Pick the right model for the user's intent
Listed newest first within each subtype. The agent picks one route based on: still vs video, single-shot vs batch, photoreal vs stylized, motion-preserving vs identity-preserving.
### Video face / character swap
**Wan 2-2 Animate** — `community/wan-2-2-animate/api` *(default for video)*
> Featured RunComfy endpoint under `/feature/character-swap`. Audio-driven full-body character animation: one reference image of the new identity + audio → video where the character drives.
> Pick for: replacing a character in a scene with a new identity, dubbed clips, stylized + photoreal both work.
> Avoid for: preserving the **motion** of a specific source video — use **Kling Motion Control**.
**Kling 2-6 Motion Control Pro** — `kling/kling-2-6/motion-control-pro`
> Takes a reference performance video + target character image, produces the target performing the reference motion. Face-swap is the byproduct.
> Pick for: preserving exact source motion / blocking onto a new character; stylized characters handled cleanly.
> Avoid for: simple "swap face in an existing video" without motion preservation — use **Wan 2-2 Animate**.
### Still image face swap — newest first
**Nano Banana 2 Edit** — `google/nano-banana-2/edit`
> Identity-preserving by default, 1–20 input images per call, spatial-language honored.
> Pick for: same identity across multiple frames consistently (SKU shots, A/B variants, narrative panels). Identity reference as `image_urls[0]`, scenes after.
> Avoid for: precise multi-ref compositional ("face from img 1 onto body in img 2") — use **GPT Image 2 Edit**.
**GPT Image 2 Edit** — `openai/gpt-image-2/edit`
> Up to 10 reference images, multilingual in-image text rewrite, layout-precise compositional instructions.
> Pick for: hero still where exact face from a portrait must land in a scene, with explicit role assignment ("image 1", "image 2"); preserve pose + lighting + background while swapping only face.
> Avoid for: 1-20 batch — use **Nano Banana 2 Edit**.
**FLUX Kontext Pro** — `blackforestlabs/flux-1-kontext/pro/edit`
> Single source image, single declarative instruction, maximum fidelity preservation of everything except the targeted edit.
> Pick for: "keep pose / clothing / hair / lighting / background, change only the face to [prose description]" — works without a reference image of the new identity.
> Avoid for: batch, multi-ref, or when you have a target face image to swap in — use **Nano Banana 2 Edit** or **GPT Image 2 Edit**.
> **Audio-driven talking-head identity swap (face + voice in one pass)?** → use the [`ai-avatar-video`](https://www.skills.sh/agentspace-so/runcomfy-agent-skills/ai-avatar-video) skill — OmniHuman handles face + audio together.
---
## Route 1: Wan 2-2 Animate — video character swap with audio
**Model**: `community/wan-2-2-animate/api`
**Catalog**: [wan-2-2-animate](https://www.runcomfy.com/models/community/wan-2-2-animate/api?utm_source=skills.sh&utm_medium=skill&utm_campaign=face-swap) · [`/feature/character-swap`](https://www.runcomfy.com/models/feature/character-swap?utm_source=skills.sh&utm_medium=skill&utm_campaign=face-swap)
The featured RunComfy endpoint for character swap — supply a reference image of the new identity + the audio track the character should speak, and the model produces a video where the character drives.
### Invoke
```bash
runcomfy run community/wan-2-2-animate/api \
--input '{
"image_url": "https://your-cdn.example/new-character.png",
"audio_url": "https://your-cdn.example/voiceover.mp3"
}' \
--output-dir ./out
```
### Tips
- **Single reference image** drives the swap. Pick a clean, well-lit portrait of the target identity — front-facing if possible.
- **Audio drives the mouth and rhythm.** Without audio the character won't speak; without good audio sync degrades.
- Schema details: [model page](https://www.runcomfy.com/models/community/wan-2-2-animate/api?utm_source=skills.sh&utm_medium=skill&utm_campaign=face-swap).
---
## Route 2: Kling 2-6 Motion Control Pro — motion transfer
**Model**: `kling/kling-2-6/motion-control-pro`
**Catalog**: [motion-control-pro](https://www.runcomfy.com/models/kling/kling-2-6/motion-control-pro?utm_source=skills.sh&utm_medium=skill&utm_campaign=face-swap) · [`kling` collection](https://www.runcomfy.com/models/collections/kling?utm_source=skills.sh&utm_medium=skill&utm_campaign=face-swap)
Different from a pure face-swap: Motion Control takes a **reference performance video** (the motion you want) and a **target character image** (the identity you want), and produces a video of the target performing the reference motion. The face-swap effect is a byproduct.
### Invoke
```bash
runcomfy run kling/kling-2-6/motion-control-pro \
--input '{
"reference_video_url": "https://your-cdn.example/source-performance.mp4",
"character_image_url": "https://your-cdn.example/target-character.png"
}' \
--output-dir ./out
```
### When to pick this over Route 1
- You have a **source video whose motion / blocking you want preserved**, not just the audio.
- The target is a stylized character rather than a photoreal portrait — motion-control handles stylized identities cleanly.
---
## Route 3: GPT Image 2 Edit — still face swap with multi-ref
**Model**: `openai/gpt-image-2/edit`
**Catalog**: [gpt-image-2/edit](https://www.runcomfy.com/models/openai/gpt-image-2/edit?utm_source=skills.sh&utm_medium=skill&utm_campaign=face-swap)
For **still images**, GPT Image 2 Edit accepts up to **10 reference images** and follows precise compositional instructions — making it the strongest path for multi-ref face swap on a single output frame.
### Schema (relevant fields)
| Field | Type | Required | Default | Notes |
|---|---|---|---|---|
| `prompt` | string | yes | — | Compositional instruction; quote roles explicitly |
| `images` | string[] | yes | — | Up to **10** HTTPS reference URLs. Image 1 is primary |
| `size` | enum | no | `auto` | `auto` (preserve input ratio), `1024_1024`, `1024Related in Image & Video
watch
IncludedWatch a video (URL or local path). Downloads with yt-dlp, extracts auto-scaled frames with ffmpeg, pulls the transcript from captions (or Whisper API fallback), and hands the result to Claude so it can answer questions about what's in the video.
physical-ai-defect-image-generation
IncludedUse when the user wants to orchestrate defect image generation, run associated setup, or handle outputs on OSMO. The Day 0 path handles cold-start with USD-to-ROI, image-edit augmentation, and AnomalyGen to create initial PCBA datasets. The Day 1 path performs inference and labeling on real images. This skill helps with first-time asset setup, creation of finetuning checkpoints, and configuring deployment. Trigger keywords: defect image generation, dig workflow, dig pipeline, defect image detection workflow, aoi pipeline, aoi anomalygen, usd2roi anomalygen, day 0 pcba, day 1 pcba, day 1 real-photo alignment, day 1 manual roi, metal surface anomaly, glass defect, anomalygen finetune, setup_pcb, setup_metal, setup_glass, setup_pretrained, dig setup, dig datasets, dig pretrained checkpoint, dig image-edit endpoint.
accelint-react-best-practices
IncludedReact performance optimization and best practices. ALWAYS use this skill when working with any React code - writing components, hooks, JSX; refactoring; optimizing re-renders, memoization, state management; reviewing for performance; fixing hydration mismatches; debugging infinite re-renders, stale closures, input focus loss, animations restarting; preventing remounting; implementing transitions, lazy initialization, effect dependencies. Even simple React tasks benefit from these patterns. Covers React 19+ (useEffectEvent, Activity, ref props). Triggers - useEffect, useState, useMemo, useCallback, memo, inline components, nested components, components inside components, re-render, performance, hydration, SSR, Next.js, useDeferredValue, combined hooks.
elevenlabs-agents
IncludedBuild conversational AI voice agents with ElevenLabs Platform using React, JavaScript, React Native, or Swift SDKs. Configure agents, tools (client/server/MCP), RAG knowledge bases, multi-voice, and Scribe real-time STT. Use when: building voice chat interfaces, implementing AI phone agents with Twilio, configuring agent workflows or tools, adding RAG knowledge bases, testing with CLI "agents as code", or troubleshooting deprecated @11labs packages, Android audio cutoff, CSP violations, dynamic variables, or WebRTC config. Keywords: ElevenLabs Agents, ElevenLabs voice agents, AI voice agents, conversational AI, @elevenlabs/react, @elevenlabs/client, @elevenlabs/react-native, @elevenlabs/elevenlabs-js, @elevenlabs/agents-cli, elevenlabs SDK, voice AI, TTS, text-to-speech, ASR, speech recognition, turn-taking model, WebRTC voice, WebSocket voice, ElevenLabs conversation, agent system prompt, agent tools, agent knowledge base, RAG voice agents, multi-voice agents, pronunciation dictionary, voice speed control, elevenlabs scribe, @11labs deprecated, Android audio cutoff, CSP violation elevenlabs, dynamic variables elevenlabs, case-sensitive tool names, webhook authentication
humanizer
IncludedHumanize AI-generated text by detecting and removing patterns typical of LLM output. Rewrites text to sound natural, specific, and human. Uses 28 pattern detectors, 560+ AI vocabulary terms across 3 tiers, and statistical analysis (burstiness, type-token ratio, readability) for comprehensive detection. Use when asked to humanize text, de-AI writing, make content sound more natural/human, review writing for AI patterns, score text for AI detection, or improve AI-generated drafts. Covers content, language, style, communication, and filler categories.
generating-mermaid-diagrams
IncludedSalesforce architecture diagrams using Mermaid with ASCII fallback. Use this skill when generating text-based diagrams for Salesforce architecture, OAuth flows, ERDs, integration sequences, or Agentforce structure. TRIGGER when: user says "diagram", "visualize", "ERD", or asks for sequence diagrams, flowcharts, class diagrams, or architecture visualizations in Mermaid. DO NOT TRIGGER when: user wants PNG/SVG image output (use generating-visual-diagrams), or asks about non-Salesforce systems.