Skip to content

Commit 71330a9

Browse files
author
yashksaini-coder
committed
Add README
1 parent 5fcc752 commit 71330a9

File tree

3 files changed

+127
-23
lines changed

3 files changed

+127
-23
lines changed

.env.example

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
# Deployment used by `npx convex dev`
2+
CONVEX_DEPLOYMENT=dev:your-deployment-id # team: your-team-name, project: your-project-name
3+
4+
NEXT_PUBLIC_CONVEX_URL=https://your-deployment-id.convex.cloud
5+
6+
NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY=your_clerk_publishable_key
7+
CLERK_SECRET_KEY=your_clerk_secret_key
8+
9+
NEXT_PUBLIC_CLERK_FRONTEND_API_URL=https://your-clerk-frontend-api-url
10+
11+
# SERVER APIs
12+
NEXT_PUBLIC_SERVER_PROCESSOR=http://127.0.0.1:5000
13+
PORT=5000
14+
15+
OPENAI_API_KEY=your_openai_api_key
16+
GROQ_API_KEY=your_groq_api_key
17+
18+
USE_LOCAL_STORAGE=true
19+
BASE_URL=http://localhost:5000/
20+
21+
# Digital ocean space
22+
DO_SPACES_ACCESS_KEY=your_do_spaces_access_key
23+
DO_SPACES_ACCESS_SECRET=your_do_spaces_access_secret
24+
DO_SPACES_REGION=your_do_spaces_region
25+
DO_SPACES_BUCKET=your_do_spaces_bucket
26+
DO_SPACES_ENDPOINT=https://your-bucket.your-region.digitaloceanspaces.com
27+
28+
FLASK_APP=app.py

.gitignore

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,8 @@ yarn-error.log*
3131
.pnpm-debug.log*
3232

3333
# env files (can opt-in for committing if needed)
34-
.env*
34+
.env
35+
.env.local
3536

3637
# vercel
3738
.vercel

README.md

Lines changed: 97 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,36 +1,111 @@
1-
This is a [Next.js](https://nextjs.org) project bootstrapped with [`create-next-app`](https://nextjs.org/docs/app/api-reference/cli/create-next-app).
1+
# Manim AI (v0 Animation)
2+
3+
v0 Manim uses AI to create beautiful mathematical animations from simple text prompts.
4+
5+
## Features
6+
7+
- AI-powered generation of Manim code from natural language prompts
8+
- Automatic rendering of animations as videos
9+
- Chat interface for iterative refinement of animations
10+
- Support for multiple AI models (OpenAI and Groq)
11+
- History tracking of all generated animations
12+
- User authentication via Clerk
13+
14+
## Tech Stack
15+
16+
- **Frontend**: Next.js 14 with App Router, React, TailwindCSS, shadcn/ui
17+
- **Backend**: Node.js, Python (Manim server)
18+
- **Database**: Convex
19+
- **Authentication**: Clerk
20+
- **AI**: OpenAI, Groq
21+
- **Animation Engine**: Cairo/OpenGL
222

323
## Getting Started
424

5-
First, run the development server:
25+
### Prerequisites
26+
27+
- Node.js 18+ and npm/pnpm
28+
- Python 3.9+
29+
- Docker (for Manim server)
30+
- Convex database
31+
32+
### Environment Setup
33+
34+
1. Clone the repository:
35+
```bash
36+
git clone https://github.com/yashksaini-coder/manim-ai
37+
cd manim-ai
38+
```
39+
40+
2. Install frontend dependencies:
41+
```bash
42+
pnpm install
43+
```
44+
45+
3. Create a `.env` file in the root directory with the following variables:
46+
```
47+
# Deployment used by `npx convex dev`
48+
CONVEX_DEPLOYMENT=dev:your-deployment-id # team: your-team-name, project: your-project-name
49+
50+
NEXT_PUBLIC_CONVEX_URL=https://your-deployment-id.convex.cloud
51+
52+
NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY=your_clerk_publishable_key
53+
CLERK_SECRET_KEY=your_clerk_secret_key
54+
55+
NEXT_PUBLIC_CLERK_FRONTEND_API_URL=https://your-clerk-frontend-api-url
56+
DATABASE_URL=postgresql://username:password@your-database-host/your-database-name?sslmode=require
57+
58+
# SERVER APIs
59+
NEXT_PUBLIC_SERVER_PROCESSOR=http://127.0.0.1:5000
60+
PORT=5000
61+
62+
OPENAI_API_KEY=your_openai_api_key
63+
GROQ_API_KEY=your_groq_api_key
64+
65+
USE_LOCAL_STORAGE=true
66+
BASE_URL=http://localhost:5000/
67+
68+
# Digital ocean space
69+
DO_SPACES_ACCESS_KEY=your_do_spaces_access_key
70+
DO_SPACES_ACCESS_SECRET=your_do_spaces_access_secret
71+
DO_SPACES_REGION=your_do_spaces_region
72+
DO_SPACES_BUCKET=your_do_spaces_bucket
73+
DO_SPACES_ENDPOINT=https://your-bucket.your-region.digitaloceanspaces.com
674
7-
```bash
8-
npm run dev
9-
# or
10-
yarn dev
11-
# or
12-
pnpm dev
13-
# or
14-
bun dev
15-
```
75+
FLASK_APP=app.py
76+
```
1677

17-
Open [http://localhost:3000](http://localhost:3000) with your browser to see the result.
78+
4. Set up the database with convex:
79+
```bash
80+
npx convex dev
81+
pnpx convex dev
82+
```
1883

19-
You can start editing the page by modifying `app/page.tsx`. The page auto-updates as you edit the file.
84+
### Running the Manim Server
2085

21-
This project uses [`next/font`](https://nextjs.org/docs/app/building-your-application/optimizing/fonts) to automatically optimize and load [Geist](https://vercel.com/font), a new font family for Vercel.
86+
1. Navigate to the manim-server directory:
87+
```bash
88+
cd manim-server
89+
```
2290

23-
## Learn More
91+
2. Start the Docker container:
92+
```bash
93+
docker-compose up -d
94+
```
2495

25-
To learn more about Next.js, take a look at the following resources:
96+
### Running the Frontend
2697

27-
- [Next.js Documentation](https://nextjs.org/docs) - learn about Next.js features and API.
28-
- [Learn Next.js](https://nextjs.org/learn) - an interactive Next.js tutorial.
98+
1. Start the development server:
99+
```bash
100+
pnpm dev
101+
```
29102

30-
You can check out [the Next.js GitHub repository](https://github.com/vercel/next.js) - your feedback and contributions are welcome!
103+
2. Open [http://localhost:3000](http://localhost:3000) in your browser.
31104

32-
## Deploy on Vercel
105+
### Adding New AI Models
33106

34-
The easiest way to deploy your Next.js app is to use the [Vercel Platform](https://vercel.com/new?utm_medium=default-template&filter=next.js&utm_source=create-next-app&utm_campaign=create-next-app-readme) from the creators of Next.js.
107+
To add support for new AI models:
35108

36-
Check out our [Next.js deployment documentation](https://nextjs.org/docs/app/building-your-application/deploying) for more details.
109+
1. Add the API key to your `.env` file
110+
2. Create a new integration in `src/lib/ai-models.ts`
111+
3. Update the UI in `src/components/chat/ChatInput.tsx` to include the new model

0 commit comments

Comments
 (0)