Generate video from text using AI
821
stars
84
commits
Jupyter Notebook
primary language
Aug 24, 2026
updated
Generate engaging videos from text prompts using AI. Perfect for creating YouTube Shorts, Instagram Reels, TikTok videos, and more.
Want to skip the setup? Use our Premium API to generate videos instantly - no installation required, production-ready, and scales with your needs.
▶ Watch: Best AI Video Generator (API) in 2026 (Quality, Price, Uncensored, Editing)
https://github.com/user-attachments/assets/1e440ace-8560-4e12-850e-c532740711e7
Here are sample videos generated end-to-end directly by this project using the React/Remotion composition engine:
"Wonders of Outer Space" — An educational video about the cosmos, galaxies, and black holes. Generated using local EdgeTTS voiceover, whisper-timestamped local word captions, Suno AI background music, and Veo3 AI B-roll video segments.
"Exploring the Deep Ocean" — A cinematic short exploring deep sea depths, bioluminescent creatures, and thermal vents. Generated using local EdgeTTS voiceover, whisper-timestamped local word captions, Suno AI background music, and Veo3 AI B-roll video segments.
Option 1: Use the Premium API (Recommended)
Skip all setup and generate videos with a single API call:
Option 2: Google Colab
Run directly in your browser with our Colab Notebook
Option 3: Local Installation
See installation instructions below.
Windows users: See INSTALL_WINDOWS.md for detailed setup instructions.
# Clone the repository
git clone https://github.com/SamurAIGPT/Text-To-Video-AI.git
cd Text-To-Video-AI
# Install dependencies
pip install -r requirements.txt
# Create your configuration file
cp .env.example .env
Edit .env with your API keys (see Configuration below).
python app.py "Your topic here"
Output will be saved as rendered_video.mp4
All settings are configured via the .env file. Copy .env.example to get started.
| Service | Required | Get API Key |
|---|---|---|
| Pexels | Always | pexels.com/api |
| OpenAI | If using OpenAI | platform.openai.com |
| Groq | If using Groq | console.groq.com |
| Google Gemini | If using Gemini | makersuite.google.com |
| Deepgram | If using Deepgram STT | console.deepgram.com |
| ElevenLabs | If using ElevenLabs TTS | elevenlabs.io |
# LLM Provider: openai, groq, or gemini
LLM_PROVIDER=openai
# Text-to-Speech: edgetts (free) or elevenlabs
TTS_PROVIDER=edgetts
# Speech-to-Text: whisper (free) or deepgram
STT_PROVIDER=whisper
# Orientation: portrait (1080x1920) or landscape (1920x1080)
# Portrait recommended for YouTube Shorts, Instagram Reels, TikTok
VIDEO_ORIENTATION=portrait
# Muapi API credentials
MUAPI_BASE_URL=https://api.muapi.ai
MUAPI_API_KEY=your_key
# Video Model to use
MUAPI_VIDEO_MODEL=veo3-fast-text-to-video
Supported Muapi Video Models:
veo3-fast-text-to-video, veo3-text-to-video, veo3.1-fast-text-to-video, veo3.1-text-to-video, veo3.1-lite-text-to-videogrok-imagine-text-to-videosd-2-t2v (Seedance 2), seedance-2-vip-text-to-video, seedance-pro-t2v, seedance-lite-t2vwan2.7-text-to-video, wan2.6-text-to-video, wan2.5-text-to-video, wan2.1-text-to-videoltx-2.3-text-to-video, ltx-2-pro-text-to-video, ltx-2-fast-text-to-videokling-v3.0-pro-text-to-video, kling-v3.0-standard-text-to-videovidu-q3-pro-text-to-video, vidu-q2-pro-text-to-videoopenai-sora-2-pro-text-to-video, openai-sora-2-standard-text-to-videominimax-hailuo-2.3-pro-t2v, minimax-hailuo-2.3-standard-t2vhappy-horse-1-text-to-video-1080p# Enable or disable captions
CAPTIONS_ENABLED=true
# Caption styling
CAPTION_FONT_SIZE=100
CAPTION_FONT_COLOR=white
CAPTION_FONT_FACE=Arial-Bold
CAPTION_STROKE_WIDTH=3
CAPTION_STROKE_COLOR=black
CAPTION_POSITION=bottom_center
Caption Position Options: center, top, bottom, bottom_center, bottom_left, bottom_right
Font Color Options: white, yellow, cyan, red, green, blue, magenta
EdgeTTS (Free):
EDGETTS_VOICE=en-AU-WilliamNeural
Popular voices:
en-US-ChristopherNeural - American maleen-US-JennyNeural - American femaleen-GB-RyanNeural - British maleen-GB-SoniaNeural - British femaleen-AU-WilliamNeural - Australian maleElevenLabs:
ELEVENLABS_API_KEY=your_key
ELEVENLABS_VOICE_ID=your_voice_id
We welcome contributions! To get started:
git checkout -b feature/amazing-feature)git commit -m 'Add amazing feature')git push origin feature/amazing-feature)Looking for a production-ready solution? Our Premium API offers:
| Project | Description |
|---|---|
| AI Influencer Generator | Create AI-powered virtual influencers |
| AI YouTube Shorts Generator | Automated YouTube Shorts creation |
| Faceless Video Generator | Create videos without showing your face |
| AI B-roll Generator | Generate B-roll footage with AI |
If you find this project useful, please consider giving it a star! Your support helps us continue improving the project.
Jupyter Notebook
98.5%
TypeScript
1.2%
Generate video from text using AI
821
stars
84
commits
Jupyter Notebook
primary language
Aug 24, 2026
updated
Generate engaging videos from text prompts using AI. Perfect for creating YouTube Shorts, Instagram Reels, TikTok videos, and more.
Want to skip the setup? Use our Premium API to generate videos instantly - no installation required, production-ready, and scales with your needs.
▶ Watch: Best AI Video Generator (API) in 2026 (Quality, Price, Uncensored, Editing)
https://github.com/user-attachments/assets/1e440ace-8560-4e12-850e-c532740711e7
Here are sample videos generated end-to-end directly by this project using the React/Remotion composition engine:
"Wonders of Outer Space" — An educational video about the cosmos, galaxies, and black holes. Generated using local EdgeTTS voiceover, whisper-timestamped local word captions, Suno AI background music, and Veo3 AI B-roll video segments.
"Exploring the Deep Ocean" — A cinematic short exploring deep sea depths, bioluminescent creatures, and thermal vents. Generated using local EdgeTTS voiceover, whisper-timestamped local word captions, Suno AI background music, and Veo3 AI B-roll video segments.
Option 1: Use the Premium API (Recommended)
Skip all setup and generate videos with a single API call:
Option 2: Google Colab
Run directly in your browser with our Colab Notebook
Option 3: Local Installation
See installation instructions below.
Windows users: See INSTALL_WINDOWS.md for detailed setup instructions.
# Clone the repository
git clone https://github.com/SamurAIGPT/Text-To-Video-AI.git
cd Text-To-Video-AI
# Install dependencies
pip install -r requirements.txt
# Create your configuration file
cp .env.example .env
Edit .env with your API keys (see Configuration below).
python app.py "Your topic here"
Output will be saved as rendered_video.mp4
All settings are configured via the .env file. Copy .env.example to get started.
| Service | Required | Get API Key |
|---|---|---|
| Pexels | Always | pexels.com/api |
| OpenAI | If using OpenAI | platform.openai.com |
| Groq | If using Groq | console.groq.com |
| Google Gemini | If using Gemini | makersuite.google.com |
| Deepgram | If using Deepgram STT | console.deepgram.com |
| ElevenLabs | If using ElevenLabs TTS | elevenlabs.io |
# LLM Provider: openai, groq, or gemini
LLM_PROVIDER=openai
# Text-to-Speech: edgetts (free) or elevenlabs
TTS_PROVIDER=edgetts
# Speech-to-Text: whisper (free) or deepgram
STT_PROVIDER=whisper
# Orientation: portrait (1080x1920) or landscape (1920x1080)
# Portrait recommended for YouTube Shorts, Instagram Reels, TikTok
VIDEO_ORIENTATION=portrait
# Muapi API credentials
MUAPI_BASE_URL=https://api.muapi.ai
MUAPI_API_KEY=your_key
# Video Model to use
MUAPI_VIDEO_MODEL=veo3-fast-text-to-video
Supported Muapi Video Models:
veo3-fast-text-to-video, veo3-text-to-video, veo3.1-fast-text-to-video, veo3.1-text-to-video, veo3.1-lite-text-to-videogrok-imagine-text-to-videosd-2-t2v (Seedance 2), seedance-2-vip-text-to-video, seedance-pro-t2v, seedance-lite-t2vwan2.7-text-to-video, wan2.6-text-to-video, wan2.5-text-to-video, wan2.1-text-to-videoltx-2.3-text-to-video, ltx-2-pro-text-to-video, ltx-2-fast-text-to-videokling-v3.0-pro-text-to-video, kling-v3.0-standard-text-to-videovidu-q3-pro-text-to-video, vidu-q2-pro-text-to-videoopenai-sora-2-pro-text-to-video, openai-sora-2-standard-text-to-videominimax-hailuo-2.3-pro-t2v, minimax-hailuo-2.3-standard-t2vhappy-horse-1-text-to-video-1080p# Enable or disable captions
CAPTIONS_ENABLED=true
# Caption styling
CAPTION_FONT_SIZE=100
CAPTION_FONT_COLOR=white
CAPTION_FONT_FACE=Arial-Bold
CAPTION_STROKE_WIDTH=3
CAPTION_STROKE_COLOR=black
CAPTION_POSITION=bottom_center
Caption Position Options: center, top, bottom, bottom_center, bottom_left, bottom_right
Font Color Options: white, yellow, cyan, red, green, blue, magenta
EdgeTTS (Free):
EDGETTS_VOICE=en-AU-WilliamNeural
Popular voices:
en-US-ChristopherNeural - American maleen-US-JennyNeural - American femaleen-GB-RyanNeural - British maleen-GB-SoniaNeural - British femaleen-AU-WilliamNeural - Australian maleElevenLabs:
ELEVENLABS_API_KEY=your_key
ELEVENLABS_VOICE_ID=your_voice_id
We welcome contributions! To get started:
git checkout -b feature/amazing-feature)git commit -m 'Add amazing feature')git push origin feature/amazing-feature)Looking for a production-ready solution? Our Premium API offers:
| Project | Description |
|---|---|
| AI Influencer Generator | Create AI-powered virtual influencers |
| AI YouTube Shorts Generator | Automated YouTube Shorts creation |
| Faceless Video Generator | Create videos without showing your face |
| AI B-roll Generator | Generate B-roll footage with AI |
If you find this project useful, please consider giving it a star! Your support helps us continue improving the project.
Jupyter Notebook
98.5%
TypeScript
1.2%