Model-Agnostic AI Video Generation Framework
Project description
Ministudio
Model-Agnostic AI Video Framework
"Make AI video generation as consistent as CSS makes web styling"
Python package for generating consistent AI videos across different providers.
Installation
pip install ministudio
With provider support:
pip install ministudio[vertex-ai] # Google Vertex AI
pip install ministudio[openai] # OpenAI Sora
pip install ministudio[all] # All providers
Quick Start
Basic Usage
# Mock provider (no API keys needed)
ministudio --provider mock --concept "Hello World" --action "orb waving"
Real Providers
# Google Vertex AI
export GCP_PROJECT_ID="your-project-id"
ministudio --provider vertex-ai --concept "Nature" --action "forest growing"
# OpenAI Sora
export OPENAI_API_KEY="your-key"
ministudio --provider openai-sora --concept "Ocean" --action "waves crashing"
Python API
from ministudio import Ministudio
provider = Ministudio.create_provider("mock")
studio = Ministudio(provider=provider)
result = await studio.generate_concept_video(
concept="Math",
action="orb solving equations"
)
Features
- Model-Agnostic: Swap AI providers without changing code
- State Management: Maintain visual consistency across generations
- Configurable: Customize all video generation parameters
- Segmentation: Generate long-form videos with state persistence
- Multiple Providers: Google Vertex AI, OpenAI Sora, Local models, Mock
- Templates: Pre-built styles for different use cases
- API Server: Self-hosted REST API
- Docker: Containerized deployment
Usage
Basic Generation
from ministudio import Ministudio, VideoConfig
provider = Ministudio.create_provider("mock")
studio = Ministudio(provider=provider)
result = await studio.generate_concept_video(
concept="Science",
action="orb demonstrating physics"
)
Configurable Generation
from ministudio import VideoConfig
config = VideoConfig(
duration_seconds=12,
style_name="cinematic",
mood="dramatic"
)
result = await studio.generate_concept_video(
concept="Adventure",
action="hero exploring cave",
config=config
)
Segmented Videos (Long-form)
segments = [
{"concept": "Intro", "action": "character enters scene"},
{"concept": "Action", "action": "character finds treasure", "state_updates": {"character": {"holding": "treasure"}}},
{"concept": "Climax", "action": "character escapes"}
]
results = await studio.generate_segmented_video(segments, config)
Providers
| Provider | Setup | Status |
|---|---|---|
| Mock | None | Ready |
| Google Vertex AI | GCP_PROJECT_ID env var |
Ready |
| OpenAI Sora | OPENAI_API_KEY env var |
Ready |
| Local | Model path | Ready |
Styles & Templates
Built-in Styles
ghibli: Studio Ghibli aestheticcyberpunk: Neon cyberpunk stylecinematic: Hollywood filmmakingrealistic: Photorealistic
Templates
explainer: Educational contentmarketing: Promotional videoscinematic: Cinematic scenes
API Server
Run self-hosted API:
uvicorn ministudio.api:app --host 0.0.0.0 --port 8000
Docker
docker build -t ministudio .
docker run -p 8000:8000 ministudio
API Reference
Ministudio Class
generate_concept_video(concept, action, config=None)generate_segmented_video(segments, base_config=None)
VideoConfig Class
- Configurable parameters: duration, aspect_ratio, style, provider, etc.
Providers
Ministudio.create_provider(type, **kwargs)
Publishing to PyPI
To publish your package to PyPI:
-
Install build tools:
pip install build twine
-
Build the package:
python -m build
-
Create PyPI account:
- Go to https://pypi.org/
- Create account and verify email
-
Upload to PyPI:
twine upload dist/*
Enter your PyPI username and password when prompted.
-
Test installation:
pip install your-package-name
For test releases, use TestPyPI:
twine upload --repository testpypi dist/*
pip install --index-url https://test.pypi.org/simple/ your-package-name
Philosophy
Ministudio exists because AI video generation is powerful but inconsistent. We believe every developer should be able to create professional videos, AI should enhance creativity when making videos, open ecosystems beat walled gardens, consistency is programmable with proper state management, and the best tools get out of the way.
We're building the standard framework for AI video generation - model-agnostic, stateful, and extensible.
Contributing
We welcome contributions! This guide explains how to get started.
Development Setup
git clone https://github.com/aynaash/ministudio.git
cd ministudio
pip install -e .[all]
Code Quality
# Format
black ministudio/
# Lint
ruff check ministudio/
# Test
pytest
Adding Providers
Extend BaseVideoProvider and implement generate_video() method.
Pull Requests
- Reference issues
- Clear descriptions
- Include tests
- Follow code style
Thank you for contributing to Ministudio!
License
MIT License
Acknowledgments
Inspired by the open-source AI community's work on making AI accessible and consistent.
Made with by the AI video generation community
Ready to make AI video generation consistent? Let's build the future together.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file ministudio-0.1.0.tar.gz.
File metadata
- Download URL: ministudio-0.1.0.tar.gz
- Upload date:
- Size: 8.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
711401e07a287115ba0f8492beeb5ee6089bb1b2824b0afdb7f4790c698f0fc2
|
|
| MD5 |
2fdd55cd6f9391f67afb17faac7d947c
|
|
| BLAKE2b-256 |
87c839f5ee3fb97bc90cfbbd99cf71663df31df5dcbe629ae5932e6e9791447d
|
File details
Details for the file ministudio-0.1.0-py3-none-any.whl.
File metadata
- Download URL: ministudio-0.1.0-py3-none-any.whl
- Upload date:
- Size: 9.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8936a30f4eba98b5fa2ba5b8cad915cc070205b54c926c3048bc5f98c7d38431
|
|
| MD5 |
57b795fd255bfe1d6f8b6d6234396e28
|
|
| BLAKE2b-256 |
14ea6beec8af794de4691faa090e5a7b9fbfb42c945a76edbefc1833534007a3
|