Claude Gif Generate 标志

Claude Gif Generate

社区
AgriciDaniel
claude-gif-generate

使用 Veo 3.1 将视频生成为 GIF。生成短 AI 视频片段,并通过调色板优化和无缝循环将其转换为 GIF。适合制作电影感循环动画、产品演示、抽象艺术和逼真动态效果。用户提出“AI gif”“电影感 gif”“生成逼真 gif”“产品演示 gif”“Veo gif”“抽象艺术 gif”或“电影级 gif”时使用。

Add to TypingMind

概览

发布者AgriciDaniel
代码仓库claude-gif
技能名称claude-gif-generate
星标数
31
复刻数
8
附带文件
仅含指令
许可协议MIT
链接
  • Markdown 格式的指令

    模型按需加载 SKILL.md 文件,因此只有在请求确实与该技能匹配时才会消耗 Token。

  • 兼容任何大语言模型

    AI 技能采用纯 Markdown,而非特定提供商的代码,因此可搭配 GPT、Claude、Gemini、Grok 或本地模型使用。

  • 指令自成一体

    模型所需的一切都包含在指令中,无需同步额外文件。

  • 开源

    由 AgriciDaniel 发布于 GitHub。请在安装前查看技能的源文件。

安装

在 TypingMind 中安装 Claude Gif Generate AI 技能,即可搭配任意大语言模型使用;也可以将其放入其他支持读取 SKILL.md 的智能体中。

1

安装到 TypingMind

TypingMind 可直接从 GitHub 文件夹安装技能:读取 SKILL.md,打包资源文件,并将结果保存在本地。

  1. 打开应用,前往“插件 → 技能”。
  2. 选择“从 GitHub 安装”。
  3. 粘贴下方的技能文件夹 URL 并确认。
    https://github.com/AgriciDaniel/claude-gif/tree/main/skills/claude-gif-generate
  4. 请在每个需要使用该技能的聊天中启用它。
依次选择“插件 → 技能 → 添加技能 → 从 GitHub URL 导入”,然后粘贴文件夹 URL 并点击“继续”。
2

安装到其他智能体

任何支持 Agent Skills 格式的智能体都可以使用此技能,只需将文件夹复制到该智能体的技能目录中。

Claude Code — .claude/skills
git clone --depth 1 https://github.com/AgriciDaniel/claude-gif.git /tmp/claude-gif
mkdir -p .claude/skills
cp -r /tmp/claude-gif/skills/claude-gif-generate .claude/skills/claude-gif-generate
复制后,请重启 Claude Code,以加载新技能。

在 TypingMind 中使用此技能

在任意 TypingMind 聊天中启用 Claude Gif Generate,后续即可交由模型处理。技能的名称和描述会放在系统提示词中,一旦请求匹配,模型就会自动加载完整指令,无需您手动调用,且在实际使用前不会消耗 Token。

一旦请求与技能匹配,模型就会自动加载 Claude Gif Generate。

兼容任何 AI 模型

AI 技能是纯 Markdown 指令,而非特定提供商的代码,因此 Claude Gif Generate 不局限于最初适配的模型。只需在 TypingMind 中安装一次,即可搭配 GPT-5、Claude、Gemini、Grok、DeepSeek、Mistral、Llama 或您自行运行的本地模型使用,全程使用您自己的 API 密钥。

  • 仅在需要时加载

    系统提示词中仅包含技能名称和描述。首次遇到匹配的请求时才会加载完整指令,因此技能未使用时,这些指令不会消耗 Token。

  • 在聊天中切换模型

    技能是指令而非代码,因此切换模型不会导致技能失效,新模型会读取同一个 SKILL.md。

技能指令

这是模型会加载的 SKILL.md 内容。请在安装前阅读,因为技能就是模型将遵循的指令。

claude-gif-generate -- AI Video-to-GIF (Veo 3.1)

Generates photorealistic or stylized AI video clips using Google Veo, then converts them to optimized GIFs with palette optimization, perfect loops, and platform sizing.

Pipeline Overview

Prompt Engineering --> Veo Generate (MP4) --> gif_convert.sh (GIF) --> gif_loop.py (Loop) --> gif_optimize.py (Shrink)

Step-by-Step Procedure

1. MANDATORY: Read Prompt Reference

Before constructing ANY Veo prompt for GIF output:

Read ~/.claude/skills/claude-gif/references/prompt-engineering.md

This is not optional. GIF-optimized prompts differ significantly from general video prompts. Loop-friendly prompts and static-background strategies reduce file size dramatically.

2. Cost Confirmation

Veo generation costs real money. ALWAYS confirm with the user before proceeding.

ModelDurationApproximate Cost
veo-3.0-fast-generate-0014 seconds~$0.60
veo-3.0-fast-generate-0018 seconds~$1.20
veo-3.0-generate-0014 seconds~$1.20
veo-3.0-generate-0018 seconds~$2.40

Recommendation: Use veo-3.0-fast-generate-001 with 4 seconds for GIFs. Shorter clips make better GIFs (smaller files, easier to loop). Fast model quality is excellent for GIF resolution (480px).

Tell the user: "This will use Veo 3.0 Fast (4s) costing approximately $0.60. Proceed?"

3. Analyze GIF Concept

Determine from the user's request:

  • Loop requirement: Most GIFs should loop. Identify if the content naturally loops.
  • Aspect ratio: 16:9 (landscape), 9:16 (portrait/mobile), 1:1 (square, best for GIFs)
  • Duration: 4 seconds minimum (Veo constraint). 4s is ideal for GIFs.
  • Subject matter: Affects prompt engineering strategy.
  • Target platform: Determines final optimization pass.

4. Construct Loop-Friendly Prompt

Read references/prompt-engineering.md for detailed patterns. Key principles:

Natural loops (motion returns to start):

  • Circular camera orbits: "Camera slowly orbits 360 degrees around..."
  • Pendulum motion: "swinging", "rocking", "bobbing"
  • Cyclical natural motion: fire, waves, rain, clouds, breathing, flickering

Static background strategy (reduces GIF file size via diff_mode):

  • "A [moving subject] against a solid [color] background"
  • "Isolated [subject] on a clean, minimalist backdrop"
  • Moving subject on static background = only changed pixels encoded = smaller GIF

What to AVOID in prompts:

  • Narrative progression ("walks across", "enters the room", "picks up")
  • Scene changes or cuts
  • Camera movement that doesn't return to start
  • Complex multi-subject interactions

5. Generate Video

bash
~/.video-skill/bin/python3 ~/.claude/skills/veo/scripts/generate.py \
  --prompt "A single candle flame flickering gently against a solid black background, close-up macro shot, the flame dances in a continuous loop, warm orange and yellow tones, 4K quality" \
  --model veo-3.0-fast-generate-001 \
  --duration 4 \
  --aspect-ratio 16:9 \
  --resolution 720p \
  --output /tmp/claude-gif/veo_output.mp4

Parameters:

  • --model: Use veo-3.0-fast-generate-001 for cost efficiency
  • --duration: 4 (minimum and ideal for GIF)
  • --aspect-ratio: Match GIF intent (16:9 for landscape, 1:1 for social)
  • --resolution: 720p is sufficient; GIF will be downscaled to 480px anyway

6. Convert to GIF

bash
bash ~/.claude/skills/claude-gif/scripts/gif_convert.sh \
  --input /tmp/claude-gif/veo_output.mp4 \
  --preset web \
  --output ~/Documents/gif_output/candle.gif

Choose preset based on target. For unknown targets, use web (480px, 15fps, 256 colors, 2MB cap).

7. Perfect Loop (If Needed)

Inspect the GIF. If the loop has a visible "jump" at the seam:

bash
~/.video-skill/bin/python3 ~/.claude/skills/claude-gif/scripts/gif_loop.py \
  --input ~/Documents/gif_output/candle.gif \
  --method crossfade \
  --frames 5 \
  --output ~/Documents/gif_output/candle_looped.gif

Methods:

  • crossfade: Alpha-blend last N frames into first N frames. Best for most content.
  • pingpong: Play forward then reverse. Best for pendulum/oscillating motion.
  • freeze: Blend first and last frames. Subtle, good for slow-moving content.

Read references/perfect-loops.md for detailed technique guidance.

8. Platform Optimization (If Needed)

If the GIF exceeds the target platform's size limit:

bash
~/.video-skill/bin/python3 ~/.claude/skills/claude-gif/scripts/gif_optimize.py \
  --input ~/Documents/gif_output/candle_looped.gif \
  --target-size 256 \
  --output ~/Documents/gif_output/candle_discord.gif

9. Cleanup

bash
rm -f /tmp/claude-gif/veo_output.mp4

Prompt Templates by GIF Type

Cinematic Loop (Nature)

"[Natural element] in continuous seamless motion, [lighting], static camera,
[color palette], cinematic quality, the motion naturally repeats"

Examples: crackling fire, ocean waves, falling rain, swirling smoke, flickering aurora

Product Demo (Turntable)

"A [product] slowly rotating 360 degrees on a clean [color] surface,
studio lighting, product photography, the rotation completes one full cycle"

Abstract Art Loop

"Abstract [pattern/shape] flowing and morphing in a continuous cycle,
[color palette], minimalist background, mesmerizing seamless loop"

Cinemagraph (Partial Motion)

"A [scene description] where only the [specific element] moves,
everything else perfectly still, cinematic quality, subtle continuous motion"

Examples: steam rising from a cup (cup static), hair blowing in wind (person still)

Reaction GIF

"Close-up of a [subject/character] [facial expression or gesture],
[emotion], isolated against [simple background], short expressive motion"

Decision Matrix: Veo vs Remotion

FactorUse Veo (generate)Use Remotion (create)
ContentPhotorealistic, nature, people, productsText, UI, geometric, data
MotionComplex physics, fluid dynamicsProgrammatic, spring-based
Cost~$0.60+ per generationFree (local render)
Speed30-90 seconds generation5-15 seconds render
LoopingNeeds post-processingDesigned into component
File sizeLarger (complex scenes)Smaller (flat colors)
PredictabilityAI may varyExact output every time

Error Handling

ErrorCauseFix
Veo rate limitToo many requestsWait 60 seconds, retry
Veo safety filterPrompt flaggedRephrase prompt, remove potentially sensitive terms
Video too darkPrompt lacks lighting cuesAdd "well-lit", "bright", specific lighting description
Loop seam visibleMotion doesn't naturally cycleApply crossfade via gif_loop.py
GIF too largeComplex scene, many colorsUse discord/slack preset, or optimize aggressively
Generation failedAPI errorCheck ~/.claude/skills/veo/scripts/generate.py logs

常见问题

Claude Gif Generate AI 技能有什么作用?

使用 Veo 3.1 将视频生成为 GIF。生成短 AI 视频片段,并通过调色板优化和无缝循环将其转换为 GIF。适合制作电影感循环动画、产品演示、抽象艺术和逼真动态效果。用户提出“AI gif”“电影感 gif”“生成逼真 gif”“产品演示 gif”“Veo gif”“抽象艺术 gif”或“电影级 gif”时使用。

为什么在 TypingMind 中使用 Claude Gif Generate?

因为您只需安装一次,就能搭配任何模型使用。Claude Gif Generate 采用纯 Markdown 格式,而非特定提供商专用的代码,因此同一技能可用于 GPT-5、Claude、Gemini、Grok 或本地模型。您甚至可以在聊天中途切换模型,而不会影响技能的正常使用。TypingMind 使用您自己的 API 密钥,因此您直接向提供商付费,而不是按席位订阅;您的技能和聊天记录也都保留在您自己的存储空间中。

如何在 TypingMind 中安装 Claude Gif Generate?

在 TypingMind 中打开“插件 → 技能 → 从 GitHub 安装”,然后粘贴 https://github.com/AgriciDaniel/claude-gif/tree/main/skills/claude-gif-generate。TypingMind 会读取其中的 SKILL.md,并将其安装为技能,供您在各个聊天中按需启用。

哪些 AI 模型可以使用 Claude Gif Generate?

您在 TypingMind 中连接的任何模型都可以。AI 技能采用纯 Markdown 指令,而非特定提供商专用的代码,因此 GPT、Claude、Gemini、Grok 和本地模型都能在请求匹配时加载此技能。

Claude Gif Generate 可以搭配多少个 AI 模型使用?

数量不限。只要模型支持技能,您就可以将它与 Claude Gif Generate 搭配使用。GPT、Claude、Gemini、Grok、DeepSeek、Mistral、Llama 等模型都可以通过您自己的 API 密钥接入 TypingMind。

Claude Gif Generate AI 技能免费吗?

是的。AgriciDaniel 已在 GitHub 上根据 MIT 许可证发布了该技能。您只需向自己的 AI 提供商支付所用 Token 的费用。

什么是 AI 技能?

AI 技能是一组可复用的指令,用于教会 AI 模型完成某项特定任务。它遵循开放的 Agent Skills 格式:包含名称和描述的 SKILL.md 文件,以及模型可能需要的脚本、模板或参考文件。模型仅在您的请求与技能匹配时才会读取这些指令,因此已安装的技能在使用前不会产生任何费用。

AI 技能与插件或 MCP 服务器有何不同?

插件或 MCP 服务器为模型提供可调用的新工具,也就是在某处运行并返回结果的代码。AI 技能则为模型提供知识和流程:如何处理任务、遵循哪些步骤,以及怎样的输出才算优质。技能采用纯 Markdown 格式,因此不需要服务器、API 密钥或运行时环境,并且适用于任何模型。

查看全部

立即创建您自己的 AI 工作区

订阅我们的电子简报,获取新功能和后续赠奖活动的通知 👇