AgentSkillsCN

Video Generation

熟练运用 Veo 和 KlingAI 进行 AI 视频生成。

SKILL.md
--- frontmatter
description: Skill for AI video generation with Veo and KlingAI

Video Generation Skill

This skill enables AI-assisted video generation using multiple providers.

Capabilities

  • Google Veo 3.1: Fast generation, text-to-video and image-to-video
  • KlingAI v2.1: Highest quality, slower (5-14 minutes)

Provider Selection Matrix

NeedProviderWhy
Quick previewVeo~30 second generation
Highest qualityKlingv2.1-master model
Vertical (9:16)EitherBoth support all aspects
Image animationEitherBoth support image-to-video
Budget-consciousVeoTypically cheaper

Prompt Engineering Patterns

Scene Description Best Practices

code
[Subject][Action][Setting][Lighting][Camera][Style]

Example:

code
A majestic lion slowly walks through tall savanna grass,
golden hour sunlight casting long shadows,
cinematic slow motion with a tracking dolly shot,
nature documentary style, 8K resolution, shallow depth of field

Camera Movement Keywords

EffectKeywords
Following subjecttracking shot, dolly, follow cam
Stable scenestatic shot, locked off
Dramatic revealcrane shot, push in
Smooth motionsteadicam, gimbal
First personPOV, first-person

Style Keywords

  • Cinematic: film grain, anamorphic, color graded
  • Documentary: natural lighting, handheld
  • Commercial: pristine, studio lighting
  • Artistic: stylized, abstract, surreal

Common Issues

"Generation timed out" (Kling)

  • Normal for Kling (5-14 min)
  • Check KLINGAI_API_KEY and KLINGAI_SECRET_KEY
  • Verify JWT token generation

"No video generated" (Veo)

  • Check GEMINI_API_KEY
  • Verify prompt doesn't violate content policy
  • Try simpler prompt

Integration Example

python
from ai_content import ProviderRegistry
from ai_content.presets import get_video_preset

# Get preset
preset = get_video_preset("space")

# Get provider
provider = ProviderRegistry.get_video("veo")

# Generate
result = await provider.generate(
    prompt=preset.prompt,
    aspect_ratio=preset.aspect_ratio,
)

if result.success:
    print(f"Saved: {result.file_path}")

Resources