heygen

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese
Install the belt CLI skill:
npx skills add belt-sh/cli
安装 belt CLI skill:
npx skills add belt-sh/cli

HeyGen

HeyGen

Create avatar videos, animate photos, translate and lipsync videos, and generate or clone voices with HeyGen via inference.sh CLI.
通过 inference.sh CLI 使用 HeyGen 创建数字人视频、让照片动起来、翻译并同步口型,以及生成或克隆声音。

Quick Start

快速开始

Requires inference.sh CLI (
belt
). Install instructions
bash
belt login
需要 inference.sh CLI(
belt
)。安装说明
bash
belt login

Animate a portrait photo into a talking video

将一张人像照片制作成会说话的视频

belt app run heygen/photo-video --input '{ "image": "https://portrait.jpg", "audio_url": "https://speech.mp3" }'
undefined
belt app run heygen/photo-video --input '{ "image": "https://portrait.jpg", "audio_url": "https://speech.mp3" }'
undefined

Apps

应用列表

AppApp IDWhat It DoesPricing
Avatar Video
heygen/avatar-video
Talking video from a HeyGen avatar ID + script, Avatar IV or V engine, 720p/1080p/4KPhoto avatar $0.05/s (720p/1080p), $0.067/s (4K); digital twin $0.067/s (720p/1080p), $0.083/s (4K)
Create Avatar
heygen/create-avatar
New avatar from video (digital twin), photo, or text prompt; returns a look ID$1.00/call
Photo Video
heygen/photo-video
Animate a portrait photo with script+voice or an audio file$0.05/s (720p/1080p), $0.067/s (4K)
Lip Sync
heygen/lipsync
Re-sync an existing video's lips to new audio$0.033/s speed, $0.067/s precision
Video Agent
heygen/video-agent
Full video from a natural language prompt; agent picks avatar, script, production$0.033/s
Video Translate
heygen/video-translate
Translate a video into 30+ languages with voice cloning and lip-sync$0.033/s speed or audio-only, $0.067/s precision
Text to Speech
heygen/text-to-speech
Starfish TTS, plain text or SSML, speed and language control$0.0007/s
Voice Clone
heygen/voice-clone
Instant clone from one short recording, optionally speak text in it$0.0007/s of audio; clone-only runs free
应用App ID功能说明定价
数字人视频
heygen/avatar-video
通过 HeyGen 数字人 ID + 脚本生成说话视频,支持 Avatar IV 或 V 引擎,720p/1080p/4K照片数字人 $0.05/秒(720p/1080p),$0.067/秒(4K);数字孪生 $0.067/秒(720p/1080p),$0.083/秒(4K)
创建数字人
heygen/create-avatar
通过视频(数字孪生)、照片或文本提示词创建新数字人;返回 look ID$1.00/次
照片视频
heygen/photo-video
用脚本+声音或音频文件让一张人像照片动起来$0.05/秒(720p/1080p),$0.067/秒(4K)
唇形同步
heygen/lipsync
将已有视频的嘴型重新对齐到新音频speed 模式 $0.033/秒,precision 模式 $0.067/秒
视频 Agent
heygen/video-agent
从自然语言提示词生成完整视频;Agent 自动选择数字人、脚本和制作方式$0.033/秒
视频翻译
heygen/video-translate
将视频翻译成 30+ 种语言,含声音克隆与唇形同步speed 模式或仅音频 $0.033/秒,precision 模式 $0.067/秒
文本转语音
heygen/text-to-speech
Starfish TTS,支持纯文本或 SSML,可控制语速与语言$0.0007/秒
声音克隆
heygen/voice-clone
从一段短录音即时克隆,可选择用克隆声音朗读文本音频 $0.0007/秒;仅克隆操作免费

Choosing an App

如何选择应用

You haveYou wantUse
A portrait photoA one-off talking video
heygen/photo-video
Footage, a photo, or a descriptionA reusable avatar
heygen/create-avatar
, then
heygen/avatar-video
A HeyGen avatar IDA scripted video
heygen/avatar-video
Only an ideaA finished video
heygen/video-agent
A video in one languageThe same video in another
heygen/video-translate
A video and new audioLips matching the new audio
heygen/lipsync
TextSpeech audio
heygen/text-to-speech
A voice recordingA reusable voice ID
heygen/voice-clone
你拥有的你想要的使用
一张人像照片一段一次性的说话视频
heygen/photo-video
视频素材、一张照片或一段描述一个可复用的数字人
heygen/create-avatar
,然后
heygen/avatar-video
一个 HeyGen 数字人 ID一段按脚本录制的视频
heygen/avatar-video
只有一个想法一段成片
heygen/video-agent
一段某种语言的视频同一视频的其他语言版本
heygen/video-translate
一段视频和一段新音频嘴型与新音频匹配
heygen/lipsync
文本语音音频
heygen/text-to-speech
一段声音录音一个可复用的 voice ID
heygen/voice-clone

Examples

示例

Avatar Video

数字人视频

bash
belt app run heygen/avatar-video --input '{
  "avatar_id": "<avatar-look-id>",
  "script": "Welcome to our quarterly update. Here are three things that changed.",
  "engine": "avatar_iv",
  "resolution": "1080p",
  "aspect_ratio": "16:9"
}'
  • engine
    :
    avatar_iv
    (default) or
    avatar_v
    . Avatar V gives more natural motion and lip-sync but needs an eligible avatar look.
  • resolution
    :
    720p
    ,
    1080p
    ,
    4k
    .
    aspect_ratio
    :
    16:9
    ,
    9:16
    .
  • voice_id
    is optional; the avatar's default voice is used when omitted.
  • expressiveness
    (
    high
    ,
    medium
    ,
    low
    ) and
    motion_prompt
    only apply to photo avatars.
  • remove_background
    and
    output_format
    (
    mp4
    ,
    webm
    ) are also available.
List available avatars and voices with the
list_resources
function:
bash
belt app run heygen/avatar-video --function list_resources --input '{
  "resource_type": "both",
  "limit": 10
}'
resource_type
is
avatars
,
voices
, or
both
.
bash
belt app run heygen/avatar-video --input '{
  "avatar_id": "<avatar-look-id>",
  "script": "Welcome to our quarterly update. Here are three things that changed.",
  "engine": "avatar_iv",
  "resolution": "1080p",
  "aspect_ratio": "16:9"
}'
  • engine
    :
    avatar_iv
    (默认)或
    avatar_v
    。Avatar V 的动作和唇形同步更自然,但需要符合资格的数字人 look。
  • resolution
    :
    720p
    、
    1080p
    、
    4k
    。
    aspect_ratio
    :
    16:9
    、
    9:16
    。
  • voice_id
    为可选;省略时使用数字人的默认声音。
  • expressiveness
    (
    high
    、
    medium
    、
    low
    )和
    motion_prompt
    仅适用于照片数字人。
  • 还可用
    remove_background
    和
    output_format
    (
    mp4
    、
    webm
    )。
使用
list_resources
函数列出可用的数字人和声音:
bash
belt app run heygen/avatar-video --function list_resources --input '{
  "resource_type": "both",
  "limit": 10
}'
resource_type
可选
avatars
、
voices
或
both
。

Photo Video (Talking Photo)

照片视频(会说话的照片)

With a script and voice:
bash
belt app run heygen/photo-video --input '{
  "image": "https://portrait.jpg",
  "script": "Hi, I am excited to show you what we built.",
  "voice_id": "<voice-id>",
  "expressiveness": "medium",
  "motion_prompt": "nodding slowly",
  "aspect_ratio": "9:16"
}'
voice_id
is required when
script
is set. Pass
audio_url
instead of
script
+
voice_id
to lip-sync to your own audio.
使用脚本和声音:
bash
belt app run heygen/photo-video --input '{
  "image": "https://portrait.jpg",
  "script": "Hi, I am excited to show you what we built.",
  "voice_id": "<voice-id>",
  "expressiveness": "medium",
  "motion_prompt": "nodding slowly",
  "aspect_ratio": "9:16"
}'
设置
script
时必须提供
voice_id
。若希望对齐自己的音频,请传入
audio_url
而非
script
+
voice_id
。

Create an Avatar

创建数字人

bash
undefined
bash
undefined

From a photo

通过照片创建

belt app run heygen/create-avatar --input '{ "type": "photo", "name": "Product Presenter", "file": "https://portrait.jpg" }'
belt app run heygen/create-avatar --input '{ "type": "photo", "name": "Product Presenter", "file": "https://portrait.jpg" }'

From a text prompt

通过文本提示词创建

belt app run heygen/create-avatar --input '{ "type": "prompt", "name": "Friendly Teacher", "prompt": "a friendly middle-aged teacher in a bright classroom, warm smile" }'
belt app run heygen/create-avatar --input '{ "type": "prompt", "name": "Friendly Teacher", "prompt": "a friendly middle-aged teacher in a bright classroom, warm smile" }'

Digital twin from video footage

通过视频素材创建数字孪生

belt app run heygen/create-avatar --input '{ "type": "digital_twin", "name": "My Twin", "file": "https://footage-of-me.mp4" }'

The output has `avatar.id` (the look ID to pass as `avatar_id` in `heygen/avatar-video`), `avatar.supported_engines`, and `group.id`. Pass `avatar_group_id` to attach a new look to an existing character. Digital twins can return `group.consent_status` and `group.consent_url` when consent is pending.
belt app run heygen/create-avatar --input '{ "type": "digital_twin", "name": "My Twin", "file": "https://footage-of-me.mp4" }'

输出包含 `avatar.id`(作为 `avatar_id` 传给 `heygen/avatar-video` 的 look ID)、`avatar.supported_engines` 和 `group.id`。传入 `avatar_group_id` 可将新的 look 附加到已有角色上。当授权待确认时,数字孪生可能返回 `group.consent_status` 和 `group.consent_url`。

Video Agent (Prompt to Video)

视频 Agent(提示词转视频)

bash
belt app run heygen/video-agent --input '{
  "prompt": "A 45-second explainer about how solar panels convert sunlight into electricity, friendly presenter, simple diagrams",
  "orientation": "landscape"
}'
orientation
is
landscape
or
portrait
(auto-detected if omitted). Optional
avatar_id
,
voice_id
, and
style_id
pin specific choices.
bash
belt app run heygen/video-agent --input '{
  "prompt": "A 45-second explainer about how solar panels convert sunlight into electricity, friendly presenter, simple diagrams",
  "orientation": "landscape"
}'
orientation
为
landscape
或
portrait
(省略时自动检测)。可选的
avatar_id
、
voice_id
和
style_id
可指定具体选择。

Lip Sync

唇形同步

bash
belt app run heygen/lipsync --input '{
  "video": "https://original.mp4",
  "audio": "https://new-voiceover.mp3",
  "mode": "precision"
}'
mode
is
speed
(default) or
precision
. Optional:
enable_caption
,
enable_dynamic_duration
(default true),
disable_music_track
,
start_time
/
end_time
for a partial sync. Inputs must be publicly accessible URLs.
bash
belt app run heygen/lipsync --input '{
  "video": "https://original.mp4",
  "audio": "https://new-voiceover.mp3",
  "mode": "precision"
}'
mode
为
speed
(默认)或
precision
。可选参数:
enable_caption
、
enable_dynamic_duration
(默认 true)、
disable_music_track
、用于局部同步的
start_time
/
end_time
。输入必须是公开可访问的 URL。

Text to Speech

文本转语音

bash
belt app run heygen/text-to-speech --input '{
  "text": "Thanks for watching. See you next week.",
  "voice_id": "<voice-id>",
  "speed": 1.1,
  "locale": "en-US"
}'
  • text
    : 1-5000 characters.
    input_type
    :
    text
    or
    ssml
    .
  • speed
    : 0.5-2.0.
    language
    (ISO code, e.g.
    es
    ) or
    locale
    (BCP-47, e.g.
    pt-BR
    ).
  • The voice must support the Starfish engine.
bash
belt app run heygen/text-to-speech --input '{
  "text": "Thanks for watching. See you next week.",
  "voice_id": "<voice-id>",
  "speed": 1.1,
  "locale": "en-US"
}'
  • text
    :1-5000 个字符。
    input_type
    :
    text
    或
    ssml
    。
  • speed
    :0.5-2.0。
    language
    (ISO 代码,如
    es
    )或
    locale
    (BCP-47,如
    pt-BR
    )。
  • 声音必须支持 Starfish 引擎。

Voice Clone

声音克隆

bash
belt app run heygen/voice-clone --input '{
  "audio": "https://my-voice-60s.mp3",
  "text": "This sentence is spoken in my cloned voice.",
  "voice_name": "My Voice",
  "keep_voice": true
}'
  • 30-60 seconds of clean, single-speaker speech works best.
    remove_background_noise
    defaults to true.
  • keep_voice
    defaults to false: the clone is deleted after generating audio because the HeyGen account has limited clone slots. It is forced on when no
    text
    is given.
  • Output:
    audio
    ,
    voice_id
    ,
    kept
    ,
    preview_audio_url
    . A kept
    voice_id
    works with
    heygen/text-to-speech
    and avatar videos.
Manage cloned voices:
bash
belt app run heygen/voice-clone --function list_voices --input '{"voice_type": "private", "limit": 20}'
belt app run heygen/voice-clone --function delete_voice --input '{"voice_id": "<voice-id>"}'
voice_type
:
private
(this workspace's clones) or
public
(HeyGen catalog).
bash
belt app run heygen/voice-clone --input '{
  "audio": "https://my-voice-60s.mp3",
  "text": "This sentence is spoken in my cloned voice.",
  "voice_name": "My Voice",
  "keep_voice": true
}'
  • 30-60 秒干净的单人语音效果最佳。
    remove_background_noise
    默认为 true。
  • keep_voice
    默认为 false:由于 HeyGen 账号的克隆槽位有限,生成音频后克隆会被删除。当未提供
    text
    时会强制为 true。
  • 输出:
    audio
    、
    voice_id
    、
    kept
    、
    preview_audio_url
    。保留的
    voice_id
    可用于
    heygen/text-to-speech
    和数字人视频。
管理已克隆的声音:
bash
belt app run heygen/voice-clone --function list_voices --input '{"voice_type": "private", "limit": 20}'
belt app run heygen/voice-clone --function delete_voice --input '{"voice_id": "<voice-id>"}'
voice_type
:
private
(当前工作区的克隆)或
public
(HeyGen 目录)。

Workflows

工作流

Create an Avatar, Then Make Videos With It

先创建数字人,再用它制作视频

bash
undefined
bash
undefined

1. Create a photo avatar (one-time, $1.00)

1. 创建照片数字人(一次性,$1.00)

belt app run heygen/create-avatar --input '{ "type": "photo", "name": "Brand Host", "file": "https://host-portrait.jpg" }' -o avatar.json
belt app run heygen/create-avatar --input '{ "type": "photo", "name": "Brand Host", "file": "https://host-portrait.jpg" }' -o avatar.json

2. Use avatar.id from step 1 as avatar_id

2. 将第 1 步的 avatar.id 作为 avatar_id 使用

belt app run heygen/avatar-video --input '{ "avatar_id": "<avatar.id-from-step-1>", "script": "Here is what is new this week.", "aspect_ratio": "9:16", "resolution": "1080p" }'

Reuse the same `avatar_id` for every future video. Check `avatar.supported_engines` before setting `"engine": "avatar_v"`.
belt app run heygen/avatar-video --input '{ "avatar_id": "<avatar.id-from-step-1>", "script": "Here is what is new this week.", "aspect_ratio": "9:16", "resolution": "1080p" }'

之后每个视频都可复用同一个 `avatar_id`。设置 `"engine": "avatar_v"` 前请先检查 `avatar.supported_engines`。

Translate a Video

翻译视频

bash
belt app run heygen/video-translate --input '{
  "video": "https://original-english.mp4",
  "output_language": "Spanish (Spain)",
  "mode": "precision",
  "speaker_num": 2,
  "enable_caption": true
}'
  • output_language
    takes names like
    Spanish (Spain)
    ,
    Chinese (Mandarin, Simplified)
    ,
    French
    .
  • input_language
    is auto-detected if omitted.
  • translate_audio_only: true
    translates the audio track and keeps the original frames.
  • speaker_num
    improves speaker separation in multi-speaker videos.
  • start_time
    /
    end_time
    translate only part of the video.
bash
belt app run heygen/video-translate --input '{
  "video": "https://original-english.mp4",
  "output_language": "Spanish (Spain)",
  "mode": "precision",
  "speaker_num": 2,
  "enable_caption": true
}'
  • output_language
    填写如
    Spanish (Spain)
    、
    Chinese (Mandarin, Simplified)
    、
    French
    这样的语言名称。
  • 省略
    input_language
    时会自动检测。
  • translate_audio_only: true
    只翻译音轨并保留原始画面。
  • speaker_num
    可改善多说话人视频中的说话人分离效果。
  • start_time
    /
    end_time
    可只翻译视频的一部分。

Your Own Voice on an Avatar

在数字人上使用自己的声音

bash
undefined
bash
undefined

1. Clone and keep the voice

1. 克隆并保留声音

belt app run heygen/voice-clone --input '{ "audio": "https://my-voice-60s.mp3", "voice_name": "Founder Voice" }' -o voice.json
belt app run heygen/voice-clone --input '{ "audio": "https://my-voice-60s.mp3", "voice_name": "Founder Voice" }' -o voice.json

2. Use voice_id from step 1 in an avatar video

2. 在数字人视频中使用第 1 步的 voice_id

belt app run heygen/avatar-video --input '{ "avatar_id": "<avatar-look-id>", "voice_id": "<voice_id-from-step-1>", "script": "A quick message from our founder." }'

With no `text`, the clone is kept automatically and only the `voice_id` is returned.
belt app run heygen/avatar-video --input '{ "avatar_id": "<avatar-look-id>", "voice_id": "<voice_id-from-step-1>", "script": "A quick message from our founder." }'

不提供 `text` 时,克隆会被自动保留,并且只返回 `voice_id`。

Replace the Voiceover on Existing Footage

替换已有素材的配音

bash
undefined
bash
undefined

1. Generate new speech

1. 生成新的语音

belt app run heygen/text-to-speech --input '{ "text": "Our new pricing starts today.", "voice_id": "<voice-id>" }' -o speech.json
belt app run heygen/text-to-speech --input '{ "text": "Our new pricing starts today.", "voice_id": "<voice-id>" }' -o speech.json

2. Re-sync the presenter's lips to the new audio

2. 将主播的嘴型重新对齐到新音频

belt app run heygen/lipsync --input '{ "video": "https://presenter.mp4", "audio": "<audio-url-from-step-1>", "mode": "precision" }'
undefined
belt app run heygen/lipsync --input '{ "video": "https://presenter.mp4", "audio": "<audio-url-from-step-1>", "mode": "precision" }'
undefined

Tips

小贴士

  • Check pricing with
    belt app pricing heygen/<app>
    ; use
    --estimate
    before long or 4K renders.
  • precision
    mode in lipsync and video-translate costs about twice
    speed
    mode.
  • 使用
    belt app pricing heygen/<app>
    查看价格;在长时间或 4K 渲染前先使用
    --estimate
    预估。
  • lipsync 和 video-translate 中的
    precision
    模式成本约为
    speed
    模式的两倍。

Related Skills

相关 Skills

bash
undefined
bash
undefined

Full platform skill (all apps)

完整平台 skill(所有应用)

npx skills add inference-sh/skills@infsh-cli
npx skills add inference-sh/skills@infsh-cli

Other avatar and lipsync models (P-Video-Avatar, OmniHuman, Fabric)

其他数字人与唇形同步模型(P-Video-Avatar、OmniHuman、Fabric)

npx skills add inference-sh/skills@ai-avatar-video
npx skills add inference-sh/skills@ai-avatar-video

Talking head production workflows

数字人视频制作工作流

npx skills add inference-sh/skills@talking-head-production
npx skills add inference-sh/skills@talking-head-production

ElevenLabs dubbing (alternative to video-translate)

ElevenLabs 配音(video-translate 的替代方案)

npx skills add inference-sh/skills@elevenlabs-dubbing
npx skills add inference-sh/skills@elevenlabs-dubbing

Voice cloning with other providers

使用其他服务商的声音克隆

npx skills add inference-sh/skills@ai-voice-cloning
npx skills add inference-sh/skills@ai-voice-cloning

Video generation

视频生成

npx skills add inference-sh/skills@ai-video-generation

Browse all HeyGen apps: `belt app search "heygen"`
npx skills add inference-sh/skills@ai-video-generation

浏览全部 HeyGen 应用:`belt app search "heygen"`

Documentation

文档