Skip to content
Skills Library
Marketing & content · Conversion & formats

video-content-replace

/video-content-replace

使用 meitu-cli 替换视频中的内容元素(人物/场景/服装/衣物),保留原始运镜和动作,支持文本指令和参考图驱动。当用户提到视频替换、改视频内容、把视频里的 xx 改成、把视频背景换成、用这张图替换视频里的人、参考图替换时触发。

Author
meitu ↗
Licence
MIT
Last repository change
28.08.2026

Assessment and security

100/ 100Class: good
Format25 / 25
Frontmatter with name and description, valid name, description up to 1,024 characters, name matching the folder.
Discoverability25 / 25
Description explains when to use the skill, has a reasonable length and uses third person.
Content35 / 35
At least 150 words and at most 500 lines, headings, step lists, examples or code.
Hygiene15 / 15
No placeholders such as TODO, no Windows paths, with a licence.
Riskno signals detected in the scan
Files in this package
1
Scripts
0
HTML comments
0
URLs in SKILL.md
0
Deprecation

No signals detected. Repository changed on 28.08.2026, without references to retired models or APIs.

Licence

MIT, open: use and modify while retaining author attribution.

What it does and when to use it

使用 meitu-cli 替换视频中的内容元素(人物/场景/服装/衣物),保留原始运镜和动作,支持文本指令和参考图驱动。当用户提到视频替换、改视频内容、把视频里的 xx 改成、把视频背景换成、用这张图替换视频里的人、参考图替换时触发。

Original author description

使用 meitu-cli 替换视频中的内容元素(人物/场景/服装/衣物),保留原始运镜和动作,支持文本指令和参考图驱动。当用户提到视频替换、改视频内容、把视频里的 xx 改成、把视频背景换成、用这张图替换视频里的人、参考图替换时触发。

How it works

  1. Overview
  2. API Mapping
  3. Dependencies
  4. Core Workflow
  5. Output
  6. 基线 Task ID
Original SKILL.md headings · 115 lines, 361 words
SKILL.md preview
---
name: video-content-replace
description: "使用 meitu-cli 替换视频中的内容元素(人物/场景/服装/衣物),保留原始运镜和动作,支持文本指令和参考图驱动。当用户提到视频替换、改视频内容、把视频里的 xx 改成、把视频背景换成、用这张图替换视频里的人、参考图替换时触发。"
version: "1.0.0"
metadata: {"openclaw":{"requires":{"bins":["meitu"],"env":["MEITU_OPENAPI_ACCESS_KEY","MEITU_OPENAPI_SECRET_KEY","MEITU_OPENAPI_TOOL_TASK_MODE"],"paths":{"read":["~/.meitu/credentials.json","~/.meitu/tool-registry.json","~/.openclaw/workspace/visual/"],"write":["~/.openclaw/workspace/visual/","./output/"]}},"primaryEnv":"MEITU_OPENAPI_ACCESS_KEY"}}
requirements:
  credentials:
    - name: MEITU_OPENAPI_ACCESS_KEY
      source: env | ~/.meitu/credentials.json
    - name: MEITU_OPENAPI_SECRET_KEY
      source: env | ~/.meitu/credentials.json
  env:
    MEITU_OPENAPI_TOOL_TASK_MODE: command
  permissions:
    - type: file_read
      paths:
        - ~/.meitu/credentials.json
        - ~/.meitu/tool-registry.json
        - ~/.openclaw/workspace/visual/
    - type: file_write
      paths:
        - ~/.openclaw/workspace/visual/
        - ./output/
    - type: exec
      commands:
        - meitu
---

# Video Content Replace

## Overview

对**已有视频**做内容元素替换(人物/场景/服装/衣物/穿着),保留原始运镜和动作,覆盖 2 类场景:

1. **文本指令替换**:文本指令驱动视频内容修改,无需额外参考图。
2. **参考图驱动替换**:用户提供参考图 + 视频,按参考图替换视频中对应元素。

不处理:视频生成、去水印/去字幕、整体风格变换、音频修改、视频拼接。

## API Mapping

| 场景 | API name | model |
|---|---|---|
| 文本指令替换 | `video_molasses_edit` | `molasses` |
| 参考图驱动替换 | `video_molasses_vidimgs2vid` | `molasses` |

`model` 可选:`auto`(默认,按是否有参考图自动路由)/ `molasses`(显式指定)。

## Dependencies

- **meitu-cli**: `>=2.0.6`
- **凭证**:CONFIG AKSK → `meitu tools update`;EXEC AKSK → 跑命令
- **环境变量**:`MEITU_OPENAPI_TOOL_TASK_MODE=command`

> **路径别名:** `$VISUAL` = `{OPENCLAW_HOME}/workspace/visual/`

## Core Workflow

```
Preflight → Execute → Deliver
```

### Preflight

1. `meitu --version` 与 `meitu auth verify --json`
2. 检测 `MEITU_OPENAPI_TOOL_TASK_MODE=command`
3. output_dir:项目 → `./output/`;一次性 → `$VISUAL/output/video-content-replace/`;`mkdir -p`

### Execute

**触发信号与路由**

核心判断维度:**是否提供参考图**。

| 场景 | 判定 | 路由 |
|---|---|---|
| 有参考图 + 替换元素 | 有 `image_url` | `video_molasses_vidimgs2vid` |
| 无参考图 + 文本指令 | 无 `image_url` | `video_molasses_edit`(默认) |

路由原则:`image_url` 存在时优先走参考图模式,即使用户说"用文字描述修改"也走 `vidimgs2vid`。

**参数定义**

| 参数 | 类型 | 必填 | 范围 | 默认 | 说明 |
|---|---|---|---|---|---|
| `video_url` | STRING | 是 | 见下方约束 | — | 原视频地址 |
| `prompt` | STRING | 是 | — | — | 修改描述 |
| `image_url` | STRING | 否 | — | — | 参考图 URL;存在时路由至 `vidimgs2vid` |
| `model` | STRING | 否 | `auto`/`molasses` | `auto` | 模型选择 |

其余参数(`duration`/`ratio`/`character_orientation` 等)由 combo-tool 内部管理,不对外暴露。

**`video_url` 约束(参考图驱动模式专用)**:

- 格式:`.mp4` / `.mov`;大小:≤ 100MB
- 边长:340px ~ 3850px;时长:3 ~ 30 秒
- 画面:漏出清晰的上半身/全身,1 人动作,一镜到底,动作平稳

`video_molasses_edit`(文本指令模式)对 `video_url` 限制较宽松,主要是格式和大小。

**工具调用**

```bash
# 文本指令
meitu video-content-replace --video_url {url} --prompt "{修改描述}" --json --download-dir {output_dir} --skill_name skill_video-content-replace
```

```bash
# 参考图驱动
meitu video-content-replace --video_url {url} --prompt "{修改描述}" --image_url {ref} --json --download-dir {output_dir} --skill_name skill_video-content-replace
```

**错误降级**

| 场景 | 处理 |
|---|---|
| `video_url` 缺失 | 提示"请提供视频链接",不调用 |
| `video_url` 不可访问 | 直接返回错误,不重试 |
| `prompt` 缺失 | 提示"请描述你想修改的内容" |
| `image_url` 不可访问 | 降级至 `video_molasses_edit`(仅用 prompt) |
| `video_url` 非 mp4/mov | 提示格式要求,不调用 |
| `video_url` >100MB 或边长越界 | 提示具体超限项 |
| `video_url` 时长 <3s / >30s(vidimgs2vid)| 提示时长要求 |
| 返回 "Video duration can not longer than" | **识别为参考视频时长超限(非生成时长)**,提示用户裁剪视频而非重试 |
| API 调用失败 / 超时 | 重试 1 次,仍失败返回错误 |
| 内容合规拦截 | 直接返回合规提示,不重试 |

### Deliver

`mv {file} {output_dir}/{date}_{name}_content-replace.mp4`

## Output

- **格式**:MP4
- **命名**:`{YYYY-MM-DD}_{descriptive-name}_content-replace.mp4`
- **位置**:项目 → `./output/`;一次性 → `$VISUAL/output/video-content-replace/`

## 基线 Task ID

`t_mt1a3i5n7b82954cc9-d2cb-44cd-a786-cb9fd37244f9`

Versions

The database has no other skills named video-content-replace.

Identical content appears in 1 other GitHub folders. We show one copy with the highest score.

Database snapshot: 13.11.2026 · package version b2acb1bd1dc9 (SHA-256 digest of the entire package)

Downloads in the last 30 days: 0 · ranking

Report a problem with this skill: harmful content, incorrect descriptions or an author’s removal request.

Similar skills

  • 100video-motion-transfer
    使用 meitu-cli 做视频动作姿态迁移,把参考视频动作迁移到图片人物上并保留外貌。仅在用户明确提供人物图片和动作参考视频,并表达动作迁移、姿态驱动、模仿动作或让图中人物跟着视频做动作时触发。
  • 100video-resolution-upscale
    使用 meitu-cli 做视频专项分辨率超分(720P/1080P/2K/4K),仅像素级重建不修复画质。当用户说放大到 4K、转成 1080P、超分、升清、提升分辨率时触发。
  • 100p-video-replace
    Use when someone wants to swap a person, outfit, or product inside existing footage while keeping the camera move and audio.
  • 100recast
    Put the user's own characters, people or things into a video of theirs with Recast - each picture replaces one person or thing in the video, and the motion, the place and the sound stay as filmed - on a board that checks the video, offers each video model with its price and…
  • 95magic-hour-character-replace
    Replace a subject in an existing video or transfer its performance onto a reference character with Magic Hour. Use for whole-character recasting and motion transfer; not face-only swaps or generating unrelated scenes with a recurring character.
  • 90video-inpaint-remove
    Remove or replace an object in a video using a mask, with open-weights Wan 2.1 VACE or LTX-2.3 in-painting in ComfyUI (tracked mask, feathering, original pixels kept outside the mask). Use to clean props, logos, rigs or artifacts from a take.

Feedback and reports

Your message goes to Bartosz Sokoliński. An email address is needed only for a reply. See the privacy policy.