Convert research papers into animated explainer videos suitable for 8th graders.
This application takes a research paper PDF and converts it into an engaging, animated video explanation using:
- Mistral OCR for PDF to markdown conversion
- Claude AI for presentation planning and Manim code generation
- Manim for 3blue1brown-style animations
- ElevenLabs for text-to-speech voiceovers
- Shotstack for final video composition
- Create virtual environment:
python -m venv venv
source venv/bin/activate # On Windows: venv\Scripts\activate- Install dependencies:
pip install -r requirements.txt- Copy
.env.exampleto.envand fill in your API keys:
cp .env.example .env- Run the server:
uvicorn app.main:app --reload- Open http://localhost:8000 in your browser
-
Go to render.com and sign up/login
-
Click New + → Web Service
-
Connect your GitHub repo
-
Configure the service:
- Build Command:
pip install -r requirements.txt - Start Command:
uvicorn app.main:app --host 0.0.0.0 --port $PORT
- Build Command:
-
Add environment variables in the Render dashboard:
MISTRAL_API_KEY- Your Mistral API keyANTHROPIC_API_KEY- Your Anthropic API key
-
Click Create Web Service
Your app will be live at https://your-app-name.onrender.com
Render advantages over Vercel:
- Longer timeouts (better for OCR processing)
- Persistent filesystem during instance lifetime
- Better suited for Python backends
GET /health- Health checkPOST /api/upload- Upload a PDF filePOST /api/process/{job_id}- Process PDF through OCRGET /api/status/{job_id}- Get job statusGET /api/markdown/{job_id}- Get extracted markdown
- Upload a PDF:
curl -X POST -F "file=@paper.pdf" http://localhost:8000/api/upload- Process through OCR:
curl -X POST http://localhost:8000/api/process/{job_id}- Check status:
curl http://localhost:8000/api/status/{job_id}- Get extracted markdown:
curl http://localhost:8000/api/markdown/{job_id}paper-to-video/
├── app/
│ ├── __init__.py
│ ├── main.py # FastAPI application
│ ├── config.py # Environment variables
│ ├── models/
│ │ └── schemas.py # Pydantic models
│ ├── services/
│ │ └── ocr_service.py # Mistral OCR
│ ├── agents/ # (Phase 2+)
│ ├── prompts/ # (Phase 2+)
│ └── utils/
├── static/
│ ├── index.html # Frontend UI
│ ├── style.css # Styles
│ └── app.js # Frontend JavaScript
├── tests/
│ └── test_ocr.py
├── render.yaml # Render deployment config
├── requirements.txt
├── .env.example
└── .gitignore
MIT License