Communitygithub.com

9018/mychat

使用HeyGen v2 API创建AI虚拟主播视频,精确控制虚拟人、语音、脚本、场景和背景。

mychat 是什么?

该技能(即9018/mychat,原名Avatar Video)允许开发者通过HeyGen的`/v2/video/generate` API创建AI虚拟主播视频,提供对虚拟人、语音、脚本、场景和背景的全面控制。它适用于需要精确指定虚拟人形象和语音的场景,例如选择特定的虚拟人和语音、编写精确的脚本、构建包含不同背景的多场景视频、创建用于合成的透明WebM视频、使用照片生成虚拟人,以及集成Remotion进行批量视频生成。技能文档详细说明了认证方式(通过`HEYGEN_API_KEY`环境变量),并建议优先使用HeyGen MCP工具(`mcp__heygen__*`)进行视频状态查询、列表和删除操作,而视频生成及虚拟人/语音列表查询则通过直接API调用完成。工作流程包括列出并预览虚拟人、选择语音、编写脚本、生成视频并轮询状态直至完成。此外,技能还提供了丰富的参考文件,涵盖背景、字幕、文本叠加、模板、照片虚拟人、Webhook集成等多个方面,并强调了最佳实践,如预览虚拟人、使用默认语音、启用测试模式以节省积分等。

兼容平台~Claude Code~Codex CLI~Cursor
npx skills add https://github.com/9018/mychat/tree/HEAD/OpenMontage/.agents/skills/avatar-video

在你喜欢的 AI 中提问

打开一个已预加载此 Agent Skill 的新对话。

文档

虚拟主播视频

使用 HeyGen 的 /v2/video/generate API 创建 AI 虚拟主播视频,可全面控制虚拟人、语音、脚本、场景和背景。支持构建单场景或多场景视频,并精确配置各项参数。

认证

所有请求都需要 X-Api-Key 头信息。请设置 HEYGEN_API_KEY 环境变量。

curl -X GET "https://api.heygen.com/v2/avatars" \
  -H "X-Api-Key: $HEYGEN_API_KEY"

工具选择

如果 HeyGen MCP 工具可用(mcp__heygen__*),优先使用它们,而不是直接调用 HTTP API——它们会自动处理认证和请求格式化。

任务MCP 工具备用方案(直接 API)
检查视频状态 / 获取URLmcp__heygen__get_videoGET /v2/videos/{video_id}
列出账户视频mcp__heygen__list_videosGET /v2/videos
删除视频mcp__heygen__delete_videoDELETE /v2/videos/{video_id}

视频生成(POST /v2/video/generate)以及虚拟人/语音列表查询通过直接 API 调用完成——请参阅下方参考文件。

默认工作流程

  1. 列出虚拟人 — GET /v2/avatars → 选择一个虚拟人,预览它,记下 avatar_id 和 default_voice_id。详见 avatars.md
  2. 列出语音(如果需要) — GET /v2/voices → 选择一个与虚拟人性别/语言匹配的语音。详见 voices.md
  3. 编写脚本 — 每个场景只包含一个概念。详见 scripts.md
  4. 生成视频 — POST /v2/video/generate,为每个场景指定虚拟人、语音、脚本和背景。详见 video-generation.md
  5. 轮询直至完成 — GET /v2/videos/{video_id} 直到状态变为 completed。详见 video-status.md

快速参考

任务参考文件
列出并预览虚拟人avatars.md
列出并选择语音voices.md
编写和结构化脚本scripts.md
生成视频(单场景或多场景)video-generation.md
添加自定义背景backgrounds.md
添加字幕/副标题captions.md
添加文字叠加text-overlays.md
创建透明 WebM 视频video-generation.md(WebM 部分)
使用模板templates.md
从照片创建虚拟人photo-avatars.md
检查视频状态 / 下载video-status.md
上传资源(图片、音频)assets.md
与 Remotion 集成remotion-integration.md
设置 Webhookswebhooks.md

何时使用此技能 vs 创建视频

此技能适用于精确控制——您需要选择虚拟人、编写精确的脚本并配置每个场景。

如果用户只是想描述一个视频创意,让 AI 处理其余部分(脚本、虚拟人、视觉效果),请改用 create-video 技能。

用户说创建视频技能此技能
“帮我做一个关于 X 的视频”✓
“创建一个产品演示”✓
“我想要虚拟人 Y 准确说出 Z”✓
“不同背景的多场景视频”✓
“用于合成的透明 WebM”✓
“为我的脚本使用这个特定语音”✓
“按精确规格批量生成视频”✓

参考文件

核心视频创建

视频自定义

高级功能

集成

基础

最佳实践

  1. 在生成前预览虚拟人 — 下载 preview_image_url,以便用户在提交前看到虚拟人
  2. 使用虚拟人的默认语音 — 大多数虚拟人具有预先匹配的 default_voice_id,可获得自然效果
  3. 备用方案:手动匹配性别 — 如果没有默认语音,确保虚拟人和语音的性别匹配
  4. 开发时使用测试模式 — 设置 test: true 以避免消耗积分(输出将带有水印)
  5. 设置较长的超时时间 — 视频生成通常需要 5-15 分钟,有时更长
  6. 验证输入 — 在生成前检查虚拟人和语音 ID 是否存在

Individual skills in this repo

This repo contains 20 individual skills — each has its own dedicated page.

9018/mychat

Generate AI videos from text prompts using multiple provider gateways. Use when: (1) Generating videos from text descriptions, (2) Creating AI-generated video clips for content production, (3) Image-to-video generation with a reference image, (4) Choosing between video generation providers (VEO, Kling, Sora, Runway, Seedance, MiniMax, Gemini Omni). Supports gateways: HeyGen API, fal.ai API, Kling official direct API, and the Gemini API (Gemini Omni Flash).

9018/mychat

Use p5.js/canvas for local procedural character effects: particles, weather, squash/stretch, walk cycles, and environmental motion.

9018/mychat

Review local character animation with schema checks, Playwright browser previews, frame sampling, and FFmpeg/ffprobe final output checks.

9018/mychat

Create videos from a text prompt using HeyGen's Video Agent. Use when: (1) Creating a video from a description or idea, (2) Generating explainer, demo, or marketing videos from a prompt, (3) Making a video without specifying exact avatars, voices, or scenes, (4) Quick video prototyping or drafts, (5) One-shot prompt-to-video generation, (6) User says "make me a video" or "create a video about X".

9018/mychat

Generate Mandarin and multilingual narration with Volcengine Doubao Speech 2.0. Use when creating Chinese voiceovers, when the user prefers Doubao/Volcengine/火山引擎/豆包 TTS, or when narration needs character-level timestamp metadata for subtitles.

9018/mychat

Video and audio processing with FFmpeg. Use for format conversion, resizing, compression, audio extraction, and preparing assets for Remotion. Triggers include converting GIF to MP4, resizing video, extracting audio, compressing files, or any media transformation task.

9018/mychat

Use when implementing Disney's 12 animation principles with Framer Motion in React applications

9018/mychat

All animation knowledge for HyperFrames — atomic motion rules, multi-phase scene blueprints, scene transitions, broader motion-design techniques, AND the seven runtime adapters (GSAP default, plus Lottie, Three.js, Anime.js, CSS keyframes, Web Animations API, TypeGPU). Use for any motion or animation task: pick 2-4 rules and compose, or load a blueprint, or look up runtime-specific API (e.g. GSAP eases / Lottie player / Three.js mixer). HyperFrames-native: single paused timeline, seek-safe, deterministic.

9018/mychat

HyperFrames CLI dev loop. Use when running npx hyperframes init, add, catalog, capture, lint, validate, inspect, layout, snapshot, preview, play, render, publish, lambda, doctor, browser, info, upgrade, skills, compositions, docs, benchmark, telemetry, transcribe, tts, or remove-background, or when troubleshooting the HyperFrames build/render environment. Entry point for AWS Lambda cloud rendering (`hyperframes lambda deploy / render / progress / destroy / policies`).

9018/mychat

The HyperFrames composition contract — build one renderable project. Use for composition structure, the `data-*` timing attributes, `class="clip"`, tracks, sub-compositions, variables, framework-owned media playback, deterministic-render rules, and validation. Read before writing composition HTML.

9018/mychat

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`.

9018/mychat

Audio and media assets for HyperFrames compositions, produced by one shared audio engine (`scripts/audio.mjs`) — multi-provider TTS (HeyGen / ElevenLabs / Kokoro local), background music + sound effects (HeyGen audio-library retrieval by default, with local Lyria / MusicGen BGM generation and a bundled SFX library as the no-credential fallback), Whisper transcription, background removal, and caption authoring. Use for voiceover / TTS, BGM, SFX / sound effects, transcription, captions / subtitles / lyrics / karaoke / per-word styling, voice + provider selection, and music-mood prompting.

9018/mychat

Install and wire registry blocks and components into HyperFrames compositions. Use when running hyperframes add, installing a block or component, wiring an installed item into index.html, or working with hyperframes.json. Covers the add command, install locations, block sub-composition wiring, component snippet merging, registry discovery, and authoring a new block or component to contribute upstream (idea → scaffold → validate → PR).

9018/mychat

Use when the user wants a short, design-led motion graphic where motion is the message: kinetic typography, stat or number count-up, chart/data-viz hit, logo sting, brand lockup, lower-third, callout, social overlay, animated headline/tweet/news item, motion poster, or quick captured-page highlight. Usually under 10s and up to ~30s, with no narration arc, voice-over, or live-action subject. Can render to MP4 or transparent overlay. Not for longer, multi-scene, narrated, or brand-reel pieces (use general-video), narrated website videos (website-to-video), topic explainers (faceless-explainer), product promos (product-launch-video), PR videos (pr-to-video), or captions on existing footage (embedded-captions). When unsure whether it's a quick motion-first piece or a longer / narrated treatment, see /hyperframes.

9018/mychat

Use when the user has a music track (an audio file, or a video to pull audio from) and wants a beat-synced HyperFrames video, calm to hard-hitting. The music drives everything: one analyzer reads it once, the orchestrator lays out the frames and fills a per-frame plan, and one sub-agent builds each frame. Typography and templates are the floor — a complete video needs zero assets — but any images or videos the user supplies are cut into the frames on the same beat grid (beat-cut / ken-burns). The genre (lyric video, slideshow, kinetic promo) falls out of the per-frame choices; the pipeline never branches on it.

9018/mychat

Toolkit-specific Remotion patterns — custom transitions, shared components, and project conventions. For core Remotion framework knowledge (hooks, animations, rendering, etc.), see the `remotion-official` skill.

9018/mychat

Port an existing Remotion (React) composition to HyperFrames HTML. Use ONLY when the user explicitly asks to port/convert/migrate/translate a Remotion source. Do NOT use: (a) authoring a new HyperFrames composition; (b) Remotion mentioned in passing; (c) Remotion code shared as reference only; (d) "same video as my Remotion one" without explicit migrate request — treat as fresh build. Doubt → `/general-video`. One-way, Remotion-only: no reverse export (HyperFrames→Remotion or any framework), no non-Remotion source (After Effects, Framer Motion, plain React/CSS) → out of scope, re-create via `/general-video`. Flags unsupported patterns (useState, useEffect, async calculateMetadata, third-party React libs, `@remotion/lambda`) and recommends runtime interop over lossy translation. Unsure whether to port vs. build fresh, or only a passing Remotion mention? → /hyperframes.

9018/mychat

Animate SVG character rigs with GSAP, CSS transforms, Remotion frame control, and HyperFrames-compatible browser previews.

9018/mychat

Three.js animation - keyframe animation, skeletal animation, morph targets, animation mixing. Use when animating objects, playing GLTF animations, creating procedural motion, or blending animations.

9018/mychat

Download video and audio from YouTube and 1000+ sites using yt-dlp. No API keys needed. Use when: (1) Downloading a video from YouTube or other sites, (2) Extracting audio from a video URL, (3) Downloading subtitles/captions from a video, (4) Getting video metadata without downloading.

相关技能