Transform overwhelming YouTube playlists into actionable insights using AI.
Features β’ Installation β’ Usage β’ Architecture β’ API β’ Contributing
YouTube Curator is a Chrome extension that uses artificial intelligence to analyze YouTube playlists and provide intelligent recommendations. Instead of manually scanning through hundreds of videos, let AI categorize, summarize, and prioritize content for you.
- π Playlists with 50+ videos are overwhelming
- β° No time to watch everything
- π Hard to find the most relevant content
- π No way to understand playlist themes at a glance
YouTube Curator automatically:
- π€ Scrapes video metadata from any YouTube playlist
- π§ Analyzes content using AI (via OpenRouter)
- π Categorizes videos by theme and topic
- β Recommends which videos to watch first
- π Summarizes the entire playlist in seconds
| Feature | Description |
|---|---|
| π Auto-Scroll Scraping | Automatically scrolls through lazy-loaded playlists to capture all videos |
| π€ AI Analysis | Uses OpenRouter API to access multiple LLM models (GPT-4, Claude, Gemini, etc.) |
| π·οΈ Smart Categorization | Groups videos by identified themes and topics |
| β Priority Recommendations | Suggests most valuable videos to watch first |
| π Visual Dashboard | Beautiful dark-themed UI with progress indicators |
| πΎ Persistent State | Saves analysis results for later viewing |
| π§ Configurable Models | Choose from free or paid AI models |
| π Privacy-First | Your data stays local; only video titles go to AI |
- Node.js 18+ and npm
- Google Chrome browser
- OpenRouter API Key (free tier available)
# Clone the repository
git clone https://github.com/yourusername/youtube-curator.git
cd youtube-curator
# Install dependencies
npm install
# Build for production
npm run build- Open
chrome://extensionsin Chrome - Enable "Developer mode" (top right toggle)
- Click "Load unpacked"
- Select the
dist/folder from this project - Pin the extension to your toolbar
- Visit OpenRouter.ai
- Sign up (free) and create an API key
- Click the YouTube Curator extension icon β Settings
- Paste your API key and click Save
1. Navigate to YouTube β Open any YouTube playlist page
2. Click Extension Icon β Opens the YouTube Curator popup
3. Click "Start Scan" β Extension scrolls and extracts videos
4. Wait for Analysis β AI processes video metadata
5. View Results β Browse categorized insights
- β
Regular playlists (
/playlist?list=...) - β Watch Later playlist
- β Liked videos playlist
- β Channel playlists
β οΈ Mix playlists (limited support)
The AI provides:
- Summary: One-paragraph overview of the playlist
- Themes: Key topics with video counts
- Categories: Grouped videos with rationale
- Recommendations: Top videos to watch first with reasons
YouTube Curator follows a modular Chrome Extension architecture using Manifest V3:
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β CHROME BROWSER β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β β
β ββββββββββββββββ Messages ββββββββββββββββββββββββββββ β
β β βββββββββββββββββΊβ β β
β β Popup β β Background Service β β
β β (React) β β Worker β β
β β β β β β
β ββββββββββββββββ ββββββββββββββ¬ββββββββββββββ β
β β β
β β Messages β
β βΌ β
β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β
β β Content Script β β
β β (Runs in YouTube tab context) β β
β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ β
β β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β
β HTTPS
βΌ
ββββββββββββββββββββ
β OpenRouter β
β API (AI) β
ββββββββββββββββββββ
| Component | Technology | Purpose |
|---|---|---|
| Popup | React + TypeScript | User interface and controls |
| Background | Service Worker | State management, AI communication |
| Content Script | Vanilla TypeScript | DOM scraping, scroll automation |
| Messaging | Chrome Runtime API | Type-safe inter-process communication |
youtube-curator/
βββ src/
β βββ popup/ # React UI
β β βββ App.tsx # Main app component
β β βββ components/ # UI components
β β β βββ ScanButton.tsx
β β β βββ AnalysisResult.tsx
β β β βββ SettingsPage.tsx
β β β βββ ProgressIndicator.tsx
β β βββ styles.css # Dark theme styling
β β βββ main.tsx # React entry point
β β
β βββ background/
β β βββ serviceWorker.ts # Background orchestration
β β
β βββ content/
β β βββ youtubeScript.ts # YouTube DOM interaction
β β
β βββ lib/ # Shared modules
β βββ common/
β β βββ messaging.ts # Type-safe messaging
β β βββ types.ts # TypeScript interfaces
β βββ ai/
β β βββ openRouterClient.ts # AI API client
β βββ settings/
β β βββ storage.ts # Chrome storage wrapper
β βββ youtube-mechanics/
β βββ scroller.ts # Infinite scroll handler
β βββ parser.ts # Video metadata extractor
β
βββ public/
β βββ icons/ # Extension icons
β
βββ manifest.json # Chrome extension manifest
βββ vite.config.ts # Vite + CRXJS configuration
βββ tsconfig.json # TypeScript configuration
βββ package.json # Dependencies and scripts
The extension uses a type-safe messaging system:
interface MessageTypeMap {
// Popup β Background
'START_SCAN': { tabId: number };
'STOP_SCAN': {};
'GET_STATE': {};
'CLEAR_RESULTS': {};
// Background β Content Script
'SCROLL_TO_BOTTOM': { selector: string };
'PARSE_VIDEOS': { containerSelector: string };
// Content Script β Background
'SCROLL_PROGRESS': { loaded: number; estimatedTotal: number };
'VIDEOS_PARSED': { videos: VideoMetadata[] };
// Background β Popup
'STATE_UPDATE': ExtensionState;
'ANALYSIS_COMPLETE': { analysis: AnalysisResult };
}interface VideoMetadata {
id: string;
title: string;
channel: string;
duration: string;
thumbnail: string;
url: string;
}
interface AnalysisResult {
summary: string;
themes: Array<{ name: string; description: string; videoCount: number }>;
categories: Array<{ name: string; rationale: string; videos: string[] }>;
recommendations: Array<{
videoId: string;
reason: string;
priority: 'high' | 'medium' | 'low'
}>;
}# Development with hot reload
npm run dev
# Production build
npm run build
# Type checking
npm run typecheck
# Run tests
npm run test- Build Tool: Vite + CRXJS
- Language: TypeScript 5.3
- UI Framework: React 18
- Extension API: Chrome Manifest V3
- AI Provider: OpenRouter (LLM Gateway)
- Use
npm run devfor hot-reload during development - Check
chrome://extensionsβ "Errors" for debugging - Use Chrome DevTools on the popup: right-click β "Inspect"
- Background script logs appear in the service worker console
- β No user tracking - Zero analytics or telemetry
- β Data stays local - Video data stored in Chrome's local storage
- β Minimal AI exposure - Only video titles and channels sent to AI
- β Your API key - You control and pay for AI usage
- β Open source - Audit the code yourself
Contributions are welcome! Please follow these steps:
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
- Follow existing TypeScript patterns
- Add types for all new code
- Test in Chrome before submitting
- Update documentation for new features
This project is licensed under the MIT License - see the LICENSE file for details.
- OpenRouter for providing LLM API access
- CRXJS for excellent Chrome extension tooling
- Vite for blazing-fast builds
Made with β€οΈ by developers who had too many videos in their Watch Later