ChaitanyaEswarRajeshJakki/gemini-youtube-automation
A fully autonomous AI Agent/Python pipeline that utilizes Large Language Models (LLMs) like Gemini to generate content, produce videos, and automatically upload educational videos to YouTube.
What it solves
This project automates the entire process of creating and publishing educational YouTube content. It eliminates the need for manual scriptwriting, video editing, narration, and uploading, allowing a channel to run entirely autonomously on a daily schedule.
How it works
The system operates as a scheduled pipeline running on GitHub Actions. It follows these steps:
- Planning: It reads a
content_plan.jsonfile to identify the next pending lesson. - Scripting: Gemini 2.5 Flash generates a multi-slide script, a short-form version for YouTube Shorts, and the necessary metadata (titles and hashtags).
- Production: The bot uses gTTS for narration, fetches relevant background images via the Pexels API, and uses MoviePy and PIL to render both a long-form (16:9) and a short-form (9:16) video with background music.
- Distribution: The final videos and auto-generated thumbnails are uploaded to YouTube via the YouTube Data API v3.
- Maintenance: The bot updates the content plan in the repository and commits the change back to GitHub to mark the lesson as complete.
Who it’s for
Content creators and developers who want to build autonomous educational channels without manual production overhead.
Highlights
- Zero-touch operation: Fully autonomous execution via GitHub Actions cron schedules.
- Dual-format output: Simultaneously produces a standard long-form video and a YouTube Short from a single lesson.
- Dynamic visuals: Automatically matches stock imagery from Pexels to the slide topics.
- Self-updating: Manages its own content queue by committing updates directly back to the repository.