/ yt-competitive-analysis / README.md
README.md
1 # YouTube Competitive Analysis 2 3 Find what's actually working on YouTube. Analyzes any set of channels, identifies outlier videos (2x+ average views), and extracts packaging patterns from winners. 4 5 No manual spreadsheet work. No guessing. Data-driven competitive intel in minutes. 6 7 ## What It Does 8 9 1. Pulls recent videos from any YouTube channel(s) 10 2. Separates long-form from Shorts 11 3. Calculates per-channel averages 12 4. Flags outliers (videos performing 2x+ above the channel average) 13 5. Extracts title patterns from winners 14 6. Exports to console, JSON, or Google Sheets 15 16 ## Quick Start 17 18 ```bash 19 # Set your YouTube API key 20 export YOUTUBE_API_KEY="your-key-here" 21 22 # Analyze specific channels 23 python3 analyze.py "$YOUTUBE_API_KEY" --channels "@AlexHormozi,@garyvee,@CodieSanchezCT" 24 25 # Use predefined channel sets 26 python3 analyze.py "$YOUTUBE_API_KEY" --set ai # AI creator set 27 python3 analyze.py "$YOUTUBE_API_KEY" --set business # Business creator set 28 python3 analyze.py "$YOUTUBE_API_KEY" --set both # All channels 29 30 # Export to JSON for programmatic use 31 python3 analyze.py "$YOUTUBE_API_KEY" --set both --output json > results.json 32 33 # Custom lookback period 34 python3 analyze.py "$YOUTUBE_API_KEY" --channels "@mkbhd" --days 60 35 ``` 36 37 ## Setup 38 39 1. Get a [YouTube Data API v3 key](https://console.cloud.google.com/apis/api/youtube.googleapis.com) 40 2. Set it as an environment variable: `export YOUTUBE_API_KEY="your-key"` 41 3. Install dependencies: `pip install -r requirements.txt` 42 43 ## Output 44 45 ### Console (default) 46 47 ``` 48 ================================================================================ 49 AI Creators โ LAST 30 DAYS 50 ================================================================================ 51 52 ๐ CHANNEL SUMMARY: 53 Alex Hormozi | 2,400,000 subs | 12 videos (3.0/wk) | L: 8 S: 4 54 55 ๐ฅ LONG-FORM OUTLIERS (top 15): 56 4.2x | 1,200,000 | [Alex Hormozi] How I'd Start a Business in 2025 57 2025-01-15 | https://youtube.com/watch?v=... 58 59 ๐ฆ TOP TITLE PATTERNS: 60 8x business 61 6x money 62 5x started 63 ``` 64 65 ### JSON 66 67 Full structured data including all video metadata, scores, and multipliers. 68 69 ## Predefined Channel Sets 70 71 **AI Creators:** Jeff Su, Alex Finn, Riley Brown, Dan Martell, Matt Wolfe, Nate Herk, Grace Leung, Matt Berman 72 73 **Business Creators:** Alex Hormozi, Gary Vaynerchuk, Patrick Bet-David, Codie Sanchez, Leila Hormozi, Iman Gadzhi, My First Million 74 75 Edit the channel dictionaries in `analyze.py` to customize. 76 77 ## Interpreting Results 78 79 | Metric | What It Means | 80 |--------|--------------| 81 | **Multiplier** | How many times above channel average (2.0x = double normal) | 82 | **Outlier threshold** | 2x average. Videos above this are worth studying. | 83 | **Title patterns** | Common words in outlier titles = proven formats | 84 | **Cadence** | Videos per week. Higher cadence may mean lower per-video averages. | 85 86 ## Proven Packaging Formats 87 88 Based on outlier analysis, these title formats consistently overperform: 89 90 **Long-form:** 91 - "X, Clearly Explained" (definitive explainer) 92 - "X hours of Y in Z minutes" (condensed value) 93 - "The Laziest Way to X" (low-effort promise) 94 - "Give me X minutes and I'll Y" (time-boxed promise) 95 - "X INSANE Use Cases for Y" (listicle + power word) 96 97 **Shorts:** 98 - "2024 vs 2025 X" (year comparison) 99 - "Bad Good Great X" (tier ranking) 100 - "Stop doing X, do Y instead" (contrarian) 101 102 ## Weekly Automation 103 104 Run weekly to surface new outliers automatically: 105 106 ```bash 107 # Cron: every Sunday at 8am 108 0 8 * * 0 YOUTUBE_API_KEY="your-key" python3 /path/to/analyze.py "$YOUTUBE_API_KEY" --set both --output json > /path/to/weekly-results.json 109 ``` 110 111 ## Requirements 112 113 - Python 3.8+ 114 - YouTube Data API v3 key 115 - No external Python dependencies (uses only stdlib) 116 117 ## License 118 119 MIT 120 121 --- 122 123 <div align="center"> 124 125 **๐ง [Want these built and managed for you? โ](https://singlebrain.com/?utm_source=github&utm_medium=skill_repo&utm_campaign=ai_marketing_skills)** 126 127 *This is how we build agents at [Single Brain](https://singlebrain.com/?utm_source=github&utm_medium=skill_repo&utm_campaign=ai_marketing_skills) for our clients.* 128 129 [Single Grain](https://www.singlegrain.com/?utm_source=github&utm_medium=skill_repo&utm_campaign=ai_marketing_skills) ยท our marketing agency 130 131 ๐ฌ **[Level up your marketing with 14,000+ marketers and founders โ](https://levelingup.beehiiv.com/subscribe)** *(free)* 132 133 </div>