
Aliyun Liveportrait
- 53 installs
- 396 repo stars
- Updated July 18, 2026
- cinience/alicloud-skills
Generate lightweight talking-head portrait videos with Alibaba Cloud Model Studio LivePortrait from a portrait image and speech audio.
About
Uses Model Studio LivePortrait to animate a detected portrait image with speech audio into a talking-head video. A developer uses it for longer or simpler presenter-style portrait animation.
- Run liveportrait-detect first, then liveportrait to generate
- China mainland (Beijing) only; inputs must be public URLs
Aliyun Liveportrait by the numbers
- 53 all-time installs (skills.sh)
- Ranked #879 of 1,335 Generative Media skills by installs in the Skillselion catalog
- Data as of Aug 5, 2026 (Skillselion catalog sync)
npx skills add https://github.com/cinience/alicloud-skills --skill aliyun-liveportraitAdd your badge
Show developers this skill is listed on Skillselion. Paste this into your README.
| Installs | 53 |
|---|---|
| repo stars | ★ 396 |
| Last updated | July 18, 2026 |
| Repository | cinience/alicloud-skills ↗ |
What it does
Generate lightweight talking-head portrait videos with Alibaba Cloud Model Studio LivePortrait from a portrait image and speech audio.
Files
Category: provider
Model Studio LivePortrait
Validation
mkdir -p output/aliyun-liveportrait
python -m py_compile skills/ai/video/aliyun-liveportrait/scripts/prepare_liveportrait_request.py && echo "py_compile_ok" > output/aliyun-liveportrait/validate.txtPass criteria: command exits 0 and output/aliyun-liveportrait/validate.txt is generated.
Output And Evidence
- Save normalized request payloads, template choice, and task polling snapshots under
output/aliyun-liveportrait/. - Record the exact portrait/audio URLs and motion-strength related parameters.
Use LivePortrait when the job is lightweight portrait animation with speech audio, especially for longer clips or simpler presenter-style motion.
Critical model names
Use these exact model strings:
liveportrait-detectliveportrait
Selection guidance:
- Run
liveportrait-detectfirst to verify the portrait image. - Use
liveportraitfor the actual video generation task.
Prerequisites
- China mainland (Beijing) only.
- Set
DASHSCOPE_API_KEYin your environment, or adddashscope_api_keyto~/.alibabacloud/credentials. - Input image and audio must be public HTTP/HTTPS URLs.
Normalized interface (video.liveportrait)
Detect Request
model(string, optional): defaultliveportrait-detectimage_url(string, required)
Generate Request
model(string, optional): defaultliveportraitimage_url(string, required)audio_url(string, required)template_id(string, optional):normal,calm, oractiveeye_move_freq(number, optional):0to1video_fps(int, optional):15to30mouth_move_strength(number, optional):0to1.5paste_back(bool, optional)head_move_strength(number, optional):0to1
Response
task_id(string)task_status(string)video_url(string, when finished)
Quick start
python skills/ai/video/aliyun-liveportrait/scripts/prepare_liveportrait_request.py \
--image-url "https://example.com/portrait.png" \
--audio-url "https://example.com/speech.mp3" \
--template-id calm \
--video-fps 24 \
--paste-backOperational guidance
- Use a clear, front-facing portrait with low occlusion.
- Keep the audio clean and voice-dominant.
paste_back=falseoutputs only the generated face region; keep ittruefor standard talking-head output.- LivePortrait is a better fit than EMO when you need longer, simpler presenter-style clips.
Output location
- Default output:
output/aliyun-liveportrait/request.json - Override base dir with
OUTPUT_DIR.
References
references/sources.md
interface:
display_name: "Alibaba Cloud AI Video LivePortrait"
short_description: "Lightweight portrait video generation with LivePortrait"
default_prompt: "Use $aliyun-liveportrait to complete this ai/video LivePortrait task on Alibaba Cloud."
- 视频生成总览(LivePortrait 条目): https://help.aliyun.com/zh/model-studio/use-video-generation
- LivePortrait 图像检测API参考: https://help.aliyun.com/zh/model-studio/liveportrait-detect-api
- LivePortrait 视频生成 API参考: https://help.aliyun.com/zh/model-studio/liveportrait-api
- LivePortrait 快速开始: https://help.aliyun.com/zh/model-studio/liveportrait-quick-start/
#!/usr/bin/env python3
"""Prepare normalized requests for LivePortrait detect/generate flows."""
from __future__ import annotations
import argparse
import json
from pathlib import Path
def main() -> None:
parser = argparse.ArgumentParser()
parser.add_argument("--image-url", required=True)
parser.add_argument("--audio-url")
parser.add_argument("--template-id", choices=["normal", "calm", "active"])
parser.add_argument("--eye-move-freq", type=float)
parser.add_argument("--video-fps", type=int)
parser.add_argument("--mouth-move-strength", type=float)
parser.add_argument("--paste-back", action="store_true")
parser.add_argument("--head-move-strength", type=float)
parser.add_argument("--detect-only", action="store_true")
parser.add_argument("--output", default="output/aliyun-liveportrait/request.json")
args = parser.parse_args()
if args.detect_only:
payload = {
"model": "liveportrait-detect",
"input": {"image_url": args.image_url},
}
else:
if not args.audio_url:
raise SystemExit("--audio-url is required unless --detect-only is set")
payload: dict[str, object] = {
"model": "liveportrait",
"input": {
"image_url": args.image_url,
"audio_url": args.audio_url,
},
"parameters": {},
}
if args.template_id:
payload["parameters"]["template_id"] = args.template_id
if args.eye_move_freq is not None:
payload["parameters"]["eye_move_freq"] = args.eye_move_freq
if args.video_fps is not None:
payload["parameters"]["video_fps"] = args.video_fps
if args.mouth_move_strength is not None:
payload["parameters"]["mouth_move_strength"] = args.mouth_move_strength
if args.paste_back:
payload["parameters"]["paste_back"] = True
if args.head_move_strength is not None:
payload["parameters"]["head_move_strength"] = args.head_move_strength
output = Path(args.output)
output.parent.mkdir(parents=True, exist_ok=True)
output.write_text(json.dumps(payload, ensure_ascii=False, indent=2), encoding="utf-8")
print(json.dumps({"ok": True, "request_path": str(output)}, ensure_ascii=False))
if __name__ == "__main__":
main()