QuickPeek Core
Core library for QuickPeek - AI-powered demo video generation

Installation
npm install @spark-apps/quickpeek
Overview
This is the core library used by @spark-apps/quickpeek-cli. It provides:
- API Client - Communication with QuickPeek backend for AI planning
- TTS Engine - Text-to-speech via Edge TTS (60+ languages)
- FFmpeg Wrapper - Video composition, watermarks, effects
- Prompt Builder - System and user prompts for AI planning
- Web Crawler - Page analysis for demo planning
- Utilities - Caption styling, ASS subtitle generation, config management
Usage
import {
callAI,
generateVoiceover,
composeVideo,
crawlPage,
buildSystemPrompt,
buildUserPrompt,
DEFAULT_CONFIG,
VERSION,
} from '@spark-apps/quickpeek';
const { title, elements } = await crawlPage('https://example.com');
const systemPrompt = buildSystemPrompt(8);
const userPrompt = buildUserPrompt(url, title, elements, 'English', 'A todo app', 8);
const result = await callAI(systemPrompt, userPrompt, 'user@email.com');
const { voiceoverPath, stepAudio } = await generateVoiceover(
steps,
config,
workDir,
outputDir,
logError,
task,
info
);
await composeVideo({
videoPath,
assPath,
outputPath,
voiceoverPath,
musicPath,
});
Exports
api-client | Backend API communication |
tts | Text-to-speech generation |
ffmpeg | Video composition |
prompts | AI prompt templates |
crawl | Web page analysis |
config | Default configuration |
utils | ASS subtitles, color conversion |
voices | Voice mappings for 60+ languages |
styles | Caption styling |
cursor | Custom cursor CSS/JS |
watermark | Watermark generation |
Related Packages