How haydenbleasel/tersa works
Project type and purpose
• This is a full-stack web application (“Tersa”) for visually building and running AI workflows.
• Frontend: Next.js App Router with React, Tailwind CSS, ReactFlow canvas, TipTap editor, shadcn/Kibo UI components.
• Backend: Next.js server actions and API routes, Drizzle ORM, Supabase (Auth, Storage, Postgres, RLS), Stripe, Posthog, Vercel AI SDK integrations.
File structure
• app/
• app/(unauthenticated) → public landing, home, pricing, A-U pages, header/footer
• app/(authenticated) → workspace pages, project listing, per-project canvas
• app/api/ → serverless routes for chat, checkout, code, portal, webhooks
• app/actions/ → Next.js Server Actions for project CRUD, media processing (image/speech/video), feedback, credits
• app/auth/ → authentication pages and routes (login, sign-up, forgot/update password, OAuth)
• components/ → client UI elements (canvas, nodes, edges, toolbar, general UI primitives)
• lib/ → shared utilities (auth, env, error handling, database setup, Supabase client/middleware/server, Drizzle config, AI model helpers)
• providers/ → React Context providers (theme, analytics, subscription, project state, Posthog)
• emails/ → email templates for sign-in, sign-up, password reset
• supabase/ + drizzle.config.ts + schema.ts → DB schema and local Supabase setup
• next.config.ts, middleware.ts → Next.js configuration, route middleware
• public/ → static assets (demo media, opengraph image)
README insights
• Emphasizes drag-and-drop canvas, automatic saving to Supabase, multi-modal AI model integrations via Vercel AI SDK, ReactFlow for visual graph.
• Lists primary technologies and integration points: Next.js 15, React 19, Supabase, Drizzle ORM, Stripe, Posthog, Tailwind, shadcn/Kibo/Radix UI.