tube-assistant
Health Gecti
- License — License: MIT
- Description — Repository has a description
- Active repo — Last push 0 days ago
- Community trust — 16 GitHub stars
Code Gecti
- Code scan — Scanned 12 files during light audit, no dangerous patterns found
Permissions Gecti
- Permissions — No dangerous permissions requested
Bu listing icin henuz AI raporu yok.
Autonomous YouTube AI agent: LLM script, TTS voice, stock clips, FFmpeg editing, AI thumbnail, auto-upload — 100% free, Telegram-controlled.
TubeAssistant — AI Agent for YouTube
Fully autonomous AI agent that runs your YouTube channel 24/7 — script, voice, editing, thumbnail, upload. Zero human input.
▶ Watch the full demo with sound
TubeAssistant is an open-source AI agent that automates your entire YouTube workflow. It generates scripts with an LLM, synthesizes narration, downloads stock footage, edits the video, creates an AI thumbnail, and uploads to YouTube — every day, automatically, at the time you choose.
No editing software. No recording. No scheduling. The agent runs 24/7 and you control it via Telegram.
The Problem
Growing a YouTube channel is a second job. Every single day you need to:
- Research what topics are working
- Write a full script
- Record or synthesize a voice-over
- Find and edit video footage
- Design a thumbnail
- Write SEO-optimized titles, descriptions, and tags
- Upload and schedule at the right time
- Analyze performance and adapt
Most creators quit within 3 months — not because they lack ideas, but because the process is relentless and eats hours every day.
TubeAssistant eliminates every step. It runs 24/7, reads your channel analytics, generates content, and publishes — completely autonomously.
Features
- Full pipeline automation — from topic idea to published video, zero human input
- AI script generation — LLM writes the script based on your niche and what's performing
- Natural voice narration — Edge TTS, no API cost, no robotic voice
- Stock footage — auto-downloads relevant clips from Pexels (free, millions of clips)
- AI video generation (optional) — generate the clips with Replicate, fal.ai, Luma or
OpenRouter instead of downloading them, with a per-video spend cap. OpenRouter has no
text-to-video model: it generates the scene as an image and the clip is built locally with a
camera move — a fraction of the cost, and it reuses the key you already use for scripts.
Set it from the TUI:tube-assistant clips - Smart video editing — FFmpeg montage with synced audio and background music
- AI thumbnail — generated by Pollinations.ai or HuggingFace FLUX with automatic text overlay
- Analytics-driven — reads your channel data, adapts topic and tone accordingly
- Telegram control — send a message, the agent obeys. Stop, force, queue topics, check stats
- Crash recovery — pipeline checkpoints resume from the last completed step
- 100% free tier — OpenRouter, Pexels, Edge TTS, Pollinations.ai — all free
Quick Start
pip install uv # fast installer (one-time)
uv tool install git+https://github.com/metiu1/tube-assistant.git
tube-assistant # interactive menu — pick Setup wizard first
That's it. The wizard handles API keys, Google OAuth, Telegram bot, and channel preferences.
How It Works
Analytics → Strategy → AI Script → TTS Voice → Stock Clips → Montage → AI Thumbnail → Upload
Every day, at the time you choose, TubeAssistant:
- Reads your channel analytics to understand what's performing
- Picks a topic aligned with your niche and goals
- Writes a full script using an LLM (OpenRouter, Ollama Cloud, or local)
- Synthesizes narration with Edge TTS — natural voice, zero cost
- Gets the footage — stock clips from Pexels, or generated by an AI video model
(Replicate / fal.ai / Luma) when you enable it - Edits the video with FFmpeg — synced audio, background music
- Generates a thumbnail with AI (Pollinations.ai or HuggingFace FLUX) + automatic text overlay
- Uploads to YouTube and schedules at the optimal time
Everything controllable in real time via Telegram — just message your bot.
Requirements
- Python 3.11+
- FFmpeg in PATH (download)
- Google account with YouTube Data API enabled
- Telegram bot (free, 2 min via @BotFather)
- OpenRouter API key (free tier works)
- Pexels API key (free)
Installation
# Clone
git clone https://github.com/metiu1/tube-assistant.git
cd tube-assistant
# Install
pip install uv # one-time
uv tool install -e . # or: installa.bat on Windows
# Setup (one-time wizard)
tube-assistant onboard
# Run
tube-assistant start
The onboard wizard walks through every step:
Step 1 — Agent language Any language your Telegram assistant will speak
Step 2 — AI Service OpenRouter / Ollama Cloud / local Ollama / 12 more
Step 3 — Image provider Pollinations (free) or HuggingFace FLUX
Step 4 — Pexels API Free key for stock footage
Step 5 — Telegram Bot Token from @BotFather
Step 6 — Channel setup Name, niche, goals, style, language
→ Send your Google credentials.json
Telegram Control
| Command | Action |
|---|---|
/status |
Current agent state |
/forza |
Trigger pipeline immediately |
/forzaora <topic> |
Publish now with a specific topic |
/topic <text> |
Add topic to queue |
/coda |
View topic queue |
/skip |
Skip today's video |
/setpubblica <hour> |
Change publish time (UTC) |
/setvideogiorno <n> |
Videos per day (1–5) |
/recap |
Analytics on recent videos |
/memoria |
What the agent remembers |
Natural language works too:
"Next video about the future of remote work"
"Avoid mentioning crypto"
"Make the pacing faster"
AI Services
15 providers supported. Set AI_SERVICE in .env to switch at any time.
OpenRouter and Ollama (the wizard defaults) need no extra packages. Providers
with their own SDK are optional extras - install only what you use:
pip install "tube-assistant[openai]" # also deepseek/xai/together/perplexity/fireworks/azure
pip install "tube-assistant[anthropic]" # or: gemini, mistral, groq, cohere, huggingface, all
| Provider | Cost | AI_SERVICE value |
Key |
|---|---|---|---|
| OpenRouter | Free tier | openrouter |
OPENROUTER_API_KEY |
| OpenAI | Paid | openai |
OPENAI_API_KEY |
| Anthropic | Paid | anthropic |
ANTHROPIC_API_KEY |
| Gemini | Free tier | gemini |
GEMINI_API_KEY |
| Mistral | Paid | mistral |
MISTRAL_API_KEY |
| Groq | Free tier | groq |
GROQ_API_KEY |
| DeepSeek | Very cheap | deepseek |
DEEPSEEK_API_KEY |
| xAI (Grok) | Paid | xai |
XAI_API_KEY |
| Cohere | Paid | cohere |
COHERE_API_KEY |
| Together AI | Paid | together |
TOGETHER_API_KEY |
| Perplexity | Paid | perplexity |
PERPLEXITY_API_KEY |
| Fireworks AI | Paid | fireworks |
FIREWORKS_API_KEY |
| Azure OpenAI | Paid | azure_openai |
AZURE_OPENAI_API_KEY |
| Ollama Cloud | Paid | ollama_cloud |
OLLAMA_API_KEY |
| Local Ollama | Free | ollama_local |
— |
Every model is overridable via env (e.g. OPENAI_MODEL=gpt-4o, GROQ_MODEL=mixtral-8x7b-32768).
See .env.example for the full list of variables.
CLI
tube-assistant # interactive TUI menu (recommended)
tube-assistant onboard # first-time setup wizard
tube-assistant start # start the 24/7 daemon
tube-assistant run # one-shot pipeline (one video now)
tube-assistant clips # clip source: Pexels stock or AI video generation
tube-assistant update # update to latest version
tube-assistant status # show workspace and config
tube-assistant workspace # print workspace path
Cost
| Service | Cost |
|---|---|
| OpenRouter free tier | $0 |
| Pexels API | $0 |
| Telegram bot | $0 |
| Pollinations.ai (thumbnails) | $0 |
| Edge TTS (voice) | $0 |
| YouTube Data API | $0 (standard quota) |
Total: $0/month on free tiers.
If you turn on AI video generation
Optional, off by default. A generated clip costs money — an 8-minute video is
~96 five-second segments, so generating all of them is expensive. That is why
the default when you enable it is hybrid: the AI covers the first clips
(the hook, where retention is won) and Pexels fills the rest.VIDEO_AI_MAX_CLIPS is the per-video cap and is never exceeded; generated
clips are cached, so re-running the same topic does not pay twice.
| Mode | What it does |
|---|---|
pexels |
Stock only. Free. Default. |
ibrido |
First N clips generated, rest from Pexels. |
ai |
Every clip generated, no stock download. |
Configure it from the TUI (tube-assistant clips, or Video clips in the
menu): source, provider, API key, model and the cap. If the provider is down or
out of credit the pipeline falls back to Pexels instead of publishing a video
with no b-roll.
Architecture
youtube_ai_agent/ CLI and launcher (pip entry point)
moduli/
cervello.py Topic and script generation (LLM)
audio.py Voice synthesis (Edge TTS)
asset.py Pexels clip download + AI clip pool assembly
video_ai.py AI video generation (Replicate / fal.ai / Luma / OpenRouter)
impostazioni_video.py Clip-source settings screen (wizard + TUI)
montaggio.py Video editing (FFmpeg / MoviePy)
thumbnail.py AI thumbnail (Pollinations.ai / HuggingFace + Pillow)
pubblica.py YouTube Data API v3 upload
analytics.py Channel performance reading
strategia.py Strategy adaptation from analytics
telegram_handler.py Telegram bot (live control)
ai_client.py Multi-provider AI client
agent.py Main daemon (24/7 scheduler)
wizard.py Configuration wizard
License
MIT — use, modify, and distribute freely.
Yorumlar (0)
Yorum birakmak icin giris yap.
Yorum birakSonuc bulunamadi