Inspiration

90% of startups fail because they solve problems nobody has. We looked at a $250B problem everyone has: advertising is broken. 42% of internet users block ads. Creators can't monetize without annoying their audience. Enterprise solutions like Mirriad and Amazon VPP cost $100K+ and are inaccessible to independent creators.

We asked: what if AI could find the perfect moment in any video and seamlessly insert branded content — no ad breaks, no interruptions?

What it does

AdScene analyzes any video and:

  1. Detects natural ad slots — parses subtitles to find dialogue gaps, then uses AI to pick the ideal insertion point based on scene context, emotional pacing, and brand relevance
  2. Recommends brands — AI analyzes the video content and suggests which brands would be a natural fit (e.g., Coca-Cola for an office scene, Ray-Ban for Breaking Bad)
  3. Generates & inserts ad content — uses AI video generation to create a branded clip and stitches it seamlessly into the original video
  4. Shows results — custom video player with timeline markers showing exactly where the ad was inserted, plus a CTA popup during the ad segment

Paste a YouTube link or upload any video — AdScene does the rest.

How we built it

  • Frontend: Next.js 16 + TypeScript + Tailwind CSS — single-page app with upload form, processing animation, and custom video player with ad timeline markers
  • AI Analysis: Cerebras (gpt-oss-120b at ~3000 tok/s) for near-instant brand recommendation and ad slot detection, with Claude as fallback
  • Video Generation: WaveSpeed Wan 2.7 — takes an extracted video segment and generates a branded continuation
    • Video Processing: FFmpeg for segment extraction, codec normalization, and 3-part video stitching with hardware-accelerated encoding
  • Subtitle Parsing: Custom SRT/VTT parser that detects dialogue gaps and extracts context for AI analysis
  • YouTube Integration: yt-dlp for downloading videos with auto-generated subtitles directly from YouTube URLs

Challenges we faced

  • Character morphing — early video generation prompts caused AI to morph characters into products. Solution: keep the prompt to one simple sentence
  • Codec mismatches — different video sources use different codecs (AV1, H.264) and resolutions. Built auto-detection with ffprobe to normalize everything before stitching
  • Subtitle quality — some YouTube clips have sparse auto-generated subtitles with no real gaps. Had to carefully select demo videos with enough dialogue pauses
  • Speed vs quality tradeoff — Claude gives better analysis but takes ~8s. Switching to Cerebras (~1.3s) made live demos feel instant

What we learned

  • The hardest part of AI product placement isn't the generation — it's finding the right moment. Transcript analysis + contextual AI reasoning is where the real value lives
  • Simple prompts beat complex ones for video generation models
  • Pre-processing demo videos is essential — never rely on live generation for a hackathon presentation

Built With

Share this project:

Updates