Skip to content

Repository files navigation

amazon-affiliate-autopilot

End-to-end pipeline that turns Amazon affiliate products into AI talking-head Shorts — one consistent host, one product per video, affiliate funnel through theluxedrawer.com/p/<slug> → YouTube, Instagram, Facebook, Pinterest, and X.

Each pipeline stage is a slash-command skill — idempotent, manifest-driven, and accepts a single slug, a comma-list, or --all-needing.

The Character

A pinned character folder defines the host. Same face, same voice across every Short.

Host pose 1 Host pose 2 Host pose 3

Lifestyle Frames

Examples of starting frames across different products.

Lifestyle 1 Lifestyle 2 Lifestyle 3

Pipeline

Authoritative ordering lives in .claude/skills/PIPELINE.md. Twelve stages, grouped into four phases.

Asset gathering

Character refs
1. Character refs
Pin a host face + voice per channel under characters/<channel>/ — same identity across every Short.
Scraped product image
2. Scrape Amazon
extensions/amazon-product-page-scraper/ Chrome ext pulls link + details + main image into a Downloads dump.
Scraped product folder
3. Import scraped data
/import-referral-data
Converts the scrape dump into products/<slug>/manifest.json. Filters <10% commission, dedupes by ASIN.

Scripting

4. Video-gen prompt
/generate-video-prompt
Authors the image-to-video animation prompt and writes it to manifest["video-prompt"].
5. Narration script
/write-script
15–20s podcast-tone voiceover into script-raw-text.

"Listen, your cleanser matters way more than people give it credit for…"
6. Narration audio
/generate-narration
ElevenLabs TTS with the channel voice pinned per character.

Video generation

Starting frame
7. Starting frame
/generate-starting-image
Hedra image-gen → 9:16 lifestyle composite of the host holding the product.
06-raw-speaker-video.mp4

8. UGC talking head
/generate-hedra-video
Starting image + narration → Hedra Avatar. Audio baked low-quality — fixed next step.
07-stitched-narration.mp4

9. Audio restitch
/stitch-narration (ffmpeg)
Swap Hedra's baked audio for the clean local ElevenLabs mp3.

Post-production & distribution

08-captioned-video.mp4

10. Captions
/caption-video
WhisperX word-level transcription + auto-picked style preset, scored against the background.
09-final-with-music.mp4

11. Background music
/overlay-music
Ducked random track from music/, fade-in / fade-out under the narration.
Multi-platform upload
12. Upload
/upload-ad
Pushes the final mp4 to every configured platform, generates per-platform metadata, writes URLs back to manifest["uploads"]. YouTube + X live; Meta + Pinterest in progress.

Supporting skill: /import-music — ingest local mp4 recordings into the music/ library that stage 11 picks from.

The Storefront

Every CTA across every platform funnels through theluxedrawer.com — our Next.js site (website/) owns the redirect to Amazon, so we control routing, analytics, and link rot.

theluxedrawer home page hero

theluxedrawer product storefront

Published Examples

One product, four platforms — picked from products/amika-aura-hair-and-body-mist.../manifest.json:

Platform URL
YouTube https://youtu.be/8ukBc7rg9KE
Instagram https://www.instagram.com/reels/DYSevZwAoJL/
Facebook https://www.facebook.com/reel/2731583150551450
X https://x.com/theluxedrawer/status/2054224433208840328

What the same product looks like once it lands on each social platform:

Instagram post
Instagram
Facebook post
Facebook
X post
X

Layout

Path Purpose
characters/ Per-channel character refs + pinned voice (the host identity)
extensions/amazon-product-page-scraper/ Chrome extension — scrapes Amazon product pages into a Downloads dump
extensions/youtube-paid-promo-flagger/ Chrome extension — flips the YouTube "paid promotion" toggle automatically
products/ Per-product folders — manifest + all generated media (gitignored)
hedra/ Hedra API client — starting-image + Avatar video generation
narration/ ElevenLabs TTS generation
captioning/ WhisperX transcription + word-level caption renderer + style presets
music/ Background music library — <adjective>-<animal>.mp3 (gitignored)
scripts/ Per-stage CLIs: import_music, stitch_narration, overlay_music, upload_ad, status, credits, script_lint, sanitize_slugs, apply_scripts
uploader/ Per-platform upload CLIs — youtube/, meta/ (Instagram + Facebook), pinterest/, x/
website/ Public Next.js site — theluxedrawer.com. Hosts the /p/<slug> product pages that every video CTA funnels through
dashboard/ Private Next.js dashboard — Supabase-backed pipeline analytics + per-product status
assets/ Branding + character assets (gitignored)
.claude/skills/ Slash-command wrappers for every pipeline stage
docs/ Channel strategy, niche, compliance rules, per-platform upload playbooks

Stack

  • Starting frame + talking head: Hedra (image-gen + Character-3 avatar)
  • TTS: ElevenLabs Turbo v2.5 (channel voice pinned per character)
  • Audio restitch: ffmpeg (swap Hedra's baked audio for the clean ElevenLabs mp3)
  • Captions: WhisperX word-level transcription + local caption renderer with auto-picked style presets
  • Background music: local music/ library, ducked under narration
  • Upload:
    • YouTube — Data API v3 via uploader/youtube/upload.py
    • X — v2 API via uploader/x/upload.py
    • Instagram + Facebook — Graph API via uploader/meta/ (in progress)
    • Pinterest — Pinterest API via uploader/pinterest/ (in progress)
  • Funnel: theluxedrawer.com/p/<slug> (Next.js) → Amazon affiliate link. Every platform CTA points at our site so we control the redirect.

Compliance

  • Every description: "As an Amazon Associate I earn from qualifying purchases."
  • YouTube "paid promotion" toggle ON for every Short (automated by extensions/youtube-paid-promo-flagger/)
  • Affiliate funnel in the first line of the description on every platform (Shorts can't link in-video)
  • All distribution channels stay public
  • Per-platform upload playbooks live in docs/upload-meta.md, docs/upload-pinterest.md, docs/upload-x.md

About

Pipeline that picks Amazon products, generates AI YouTube Shorts, and uploads them with affiliate links.

Resources

Stars

Watchers

Forks

Contributors

Languages