AGENT SKILL

inference

Run LatentSync single-pair, small-batch, Gradio, and deployment-aware inference workflows safely.

License 许可
Apache-2.0
最近更新
2026-09-03
Stars
★ 351
Forks
27

01 前言 Front Matter

name
inference
license
Apache 2.0
metadata
{ "disco-role": "operating" }
description
Run LatentSync single-pair, small-batch, Gradio, and deployment-aware inference workflows safely.
disable-model-invocation
true

02 资源文件 6

03 SKILL.md 正文

Inference

Use this sub-skill when you need LatentSync to synthesize lip-synced video from an input video and an input audio file, or when you need to launch the local demo UI.

Do not use this sub-skill for training, raw preprocessing pipeline stages, or SyncNet/FVD scoring.

What this sub-skill owns

  • Single-pair generation through the repo-maintained scripts.inference module.
  • A safer replacement for the demo shell command with explicit repository root, config, checkpoint, input, output, temp, seed, and DeepCache controls.
  • Small-batch generation for file-list or pair-list inputs when outputs are only being produced.
  • Gradio demo launch with explicit share and browser behavior instead of implicit public sharing.
  • Reference-only notes for Cog/Replicate deployment entry points.

Route here when the request is about

  • Running the demo assets or a user-supplied video/audio pair.
  • Choosing between the 256 and 512 U-Net inference configs.
  • Enabling or disabling DeepCache during generation.
  • Launching, smoke-checking, or adapting the Gradio app.
  • Understanding Cog/Replicate inference behavior before adapting it elsewhere.

Do not route here when the request is about

  • Selecting training stages, launching U-Net/SyncNet training, or editing train configs. Use the training sub-skill when available.
  • Processing raw datasets into face-aligned training clips. Use the data-preparation sub-skill.
  • Scoring generated outputs with SyncNet confidence, SyncNet accuracy, or FVD. Use ../evaluation/SKILL.md when outputs are being evaluated.
  • Downloading remote weights or running network-only deployment helpers as local inference.

Start here

  1. Read references/workflows.md for single-pair, batch, and UI launch flows.
  2. Read references/api-reference.md for prompt-safe CLI, function, pipeline, and config notes.
  3. Read references/troubleshooting.md before long GPU runs or when a preflight check fails.
  4. Use scripts/run_inference.py for CLI and small-batch generation.
  5. Use scripts/launch_gradio.py for local UI launch or Gradio import smoke tests.
  6. Read references/deployment.md only when adapting Cog/Replicate behavior.

Runtime rules

  • Always pass --repo-root to helper scripts so imports, configs, checkpoints, masks, and assets resolve from the intended LatentSync runtime tree.
  • Prefer configs/unet/stage2_512.yaml for the released v1.6 checkpoint and configs/unet/stage2.yaml for a v1.5 or 256-resolution checkpoint.
  • Treat missing checkpoints/latentsync_unet.pt, missing Whisper weights, missing ffmpeg, and unavailable CUDA as preflight blockers.
  • Keep temp directories isolated; the underlying pipeline deletes and recreates its temp_dir.
  • Use the evaluation sub-skill only after batch outputs need scores.

04 同仓库更多 Skills

VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-triton-opt

Make a single PassNet Triton kernel fast AND numerically faithful: performance model (when a replacement can win at all), block/grid/warp tuning, autotune policy, launch overhead, and per-op numeric recipes to pass the dtype baseline tolerances. Use when a pass matches and is correct but speedup below expected, or when correctness fails by small numeric margins.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-solve

END-TO-END playbook for solving one PassNet sample: analyze the computation graphs, decide the optimization strategy (what to fuse, what to replace, what to leave alone), drive the iteration loop, and maximize the sample score. This is the ENTRY skill — invoke it first for any PassNet optimization task; it tells you when to use passnet-pattern-fusion, passnet-triton-opt and passnet-feedback.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-skill

PassNet GPU kernel optimization via compiler passes. Design and implement Triton-based optimization passes, create pass files under ./pass_dir/, self-evaluate with pass_evaluator, and iterate to maximize GPU speedup.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-pattern-fusion

Author PassNet pass files: write patterns that actually MATCH the FX graph, pick fusion regions (which ops to absorb into one Triton kernel), and structure multi-pass submissions with the mandatory shared-dispatch architecture. Use when creating or fixing pattern()/replacement_args()/replacement_func() files, when a pass "failed to match", or when deciding how to fuse multiple kernels/ops.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-orchestrate

Round/batch planning and decision support for PassNet graph optimization. Use for multi-sample triage, worker allocation, eval-budget policy, and post-eval keep/revert decisions. For solving one concrete sample end to end, use passnet-solve as the entry skill; consult this skill only when you need broader planning or a specific decision gate.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

passnet-feedback

Fast, deterministic feedback for PassNet work: pre-flight pattern/match verification WITHOUT burning a GPU evaluation, per-node bottleneck analysis of a sample's graphs, and eval-log parsing into per-variant status + estimated score + failure classification. Use BEFORE every GPU evaluation (check_pattern), at the START of a sample (analyze_graph), and AFTER every evaluation (parse_eval_log).

★ 351