How pranav-kunjir/prompt2motion works
Project type and purpose
• This is a full-stack, single-page React application (built with Vite and TypeScript) that collects user prompts, invokes AI (OpenAI) to generate Manim animation code, renders videos via a serverless backend (Convex functions), and delivers the resulting animations back to the user.
File structure
• Top-level “src/” folder: contains React components (App.tsx, pages, UI components, CSS, assets, dev-time type definitions, the entry point main.tsx).
• “convex/” folder: Convex-based backend functions, generated API and server stubs, schema, auth config. This is your serverless service layer.
• “src/functions/…”: client-side wrappers around backend calls (e.g., GenerateManimCode.tsx, ChatWithUser.tsx) that invoke Convex functions over HTTP.
• Config files: vite.config.ts, multiple tsconfigs, .prettierrc, eslint.config.js, package.json define the build and lint pipeline.
• “public/” and “src/assets/”: static assets such as demo videos and the index.html shell.
README
• Purpose: “Prompt2motion: An application that takes in user input and creates animation with help of AI in Manim.”
• Clear labels: name each component (e.g., “React SPA”, “Convex Function: GenerateManimCode”, “OpenAI API”, “Manim Render Engine”).
• Blue rectangles for frontend UI modules
• Orange hexagons for serverless functions
• Gray clouds for external services (OpenAI, Manim)
• Annotations: note file locations or module names in small text (e.g., “Auth UI: src/auth/SignInGoogle.tsx”).