Function: analyzeVideo()
analyzeVideo(
opts):Promise<AnalyzeVideoResult>
Defined in: packages/agentos/src/api/analyzeVideo.ts:194
Analyses a video and returns structured understanding results.
Creates a SimpleVideoAnalyzer (backed by auto-detected VisionPipeline + STT when available), dispatches the analysis request, and returns a normalised AnalyzeVideoResult.
Parameters
opts
Video analysis options.
Returns
Promise<AnalyzeVideoResult>
A promise resolving to the analysis result with description, scenes, objects, text, and optional RAG indexing metadata.
Example
const analysis = await analyzeVideo({
videoUrl: 'https://example.com/demo.mp4',
prompt: 'What products are shown in this video?',
transcribeAudio: true,
descriptionDetail: 'detailed',
});
console.log(analysis.description);
for (const scene of analysis.scenes ?? []) {
console.log(`[${scene.startSec}s] ${scene.description}`);
}