← 返回
未分类

自动分析视频主体+选择关键帧

上传视频文件,视觉模型智能分析视频主题并生成分析报告,并返回视频高光帧,高光帧数量可选。适用于广告,娱乐,游戏等行业(默认返回3张)。
朱光月
未分类 enterprise v1.2.0 100000 Key: 无需
★ 1
Stars
📥 13
下载
💾 0
安装

概述

Video Analyzer

Overview

Extract keyframes from videos, analyze content with vision models, and generate comprehensive reports with 3 representative screenshots. Optimized for token efficiency using I-frame detection.

Workflow

Video Input → Extract Keyframes → Vision Analysis → Select Top 3 → Generate Report → Send Output

Step-by-Step Process

1. Download Video (if from Feishu)

When user sends video via Feishu, the file is auto-saved to:

~/.openclaw/media/inbound/<filename>.mp4

2. Extract Video Metadata

ffmpeg -i <video_path> 2>&1 | grep -E "(Duration|Video)"

Returns: duration, resolution, bitrate, codec info.

3. Extract Keyframes

Use the provided script for optimal keyframe extraction:

bash ~/.openclaw/workspace/skills/video-analyzer/scripts/extract_keyframes.sh <video_path> [output_dir]

Parameters:

  • video_path: Path to video file (required)
  • output_dir: Output directory (optional, defaults to ~/.openclaw/media/keyframes/)

Output: JPEG images at 640px width, named keyframe_XX.jpg

Token efficiency: Uses I-frame detection to extract only meaningful frames, reducing token consumption by ~7% vs uniform sampling.

4. Analyze with Vision Model

Use the image tool with all extracted keyframes:

prompt: "Analyze these keyframes from a video. Please:
1. Describe the video's theme and content
2. Select 3 most representative frames (explain why)"

5. Generate Report

Structure the analysis report:

## 📌 Video Theme
[Description]

## 🖼️ Representative Screenshots
| Frame | Reason |
|-------|--------|
| frame_XX | [Why representative] |

6. Send Output

Send via Feishu:

  1. Analysis report (text message)
  2. 3 representative screenshots (image messages)

Token Consumption Reference

Video LengthKeyframesEstimated Tokens
-------------------------------------------
5 seconds5-8~8,000-14,000
15 seconds12-16~20,000-28,000
30 seconds20-30~35,000-50,000

Optimization tips:

  • Images account for 95%+ of tokens
  • Shorter videos = fewer tokens
  • Low-motion videos produce fewer keyframes

Resources

scripts/

  • extract_keyframes.sh - Extract keyframes using ffmpeg I-frame detection

references/

  • ffmpeg_reference.md - Advanced ffmpeg commands for video processing

版本历史

共 1 个版本

  • v1.2.0 Initial release 当前
    2026-05-19 19:03 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

life-service

虚拟伴侣

u_c3c8f0a0
创建专属虚拟恋人,可以是自设/真实角色。
★ 1 📥 73
design-media

UI/UX Pro Max

xobi667
提供 UI/UX 设计智能与实现指导,帮助打造精美界面。适用于 UI 设计、UX 流程、信息架构、视觉风格、设计系统/标记、组件规格、文案/微文案、无障碍及前端 UI(HTML/CSS/JS、React、Next.js、Vue、Svelte
★ 219 📥 48,038
design-media

Nano Banana Pro

steipete
使用 Nano Banana Pro (Gemini 3 Pro Image) 生成或编辑图像。支持文生图、图生图及 1K/2K/4K 分辨率,适用于图像创建、修改及编辑请求,使用 --input-image 指定输入图像。
★ 430 📥 117,268