How gianpaj/sexyvoice works
Project type and purpose
• SexyVoice.ai is a full-stack, multi-language AI voice generation and cloning platform.
• Frontend: Next.js 15 with App Router and TypeScript.
• Backend: Next.js server-side API routes, Supabase (PostgreSQL + Auth), Redis (Upstash KV), Vercel Blob storage.
• External AI services: Replicate, Fal.ai, Google Generative AI.
• Payments: Stripe.
• Monitoring & analytics: Sentry, PostHog; CI/CD on Vercel.
File structure
• app/ → Next.js App Router pages and Server/Client components.
• app/api/ → Route handlers (clone-voice, generate-text, generate-voice, stripe/webhook, etc.).
• supabase/ → Infrastructure: SQL migrations, edge functions (Telegram cronjob).
• lib/ & utils/ → Core logic: API wrappers (supabase, stripe, redis, ai), constants, helpers.
• components/ & hooks/ → UI and client hooks.
• public/, posts/, contentlayer.config.ts → CMS for blog.
• config files: next.config.js, vercel.json, .env.example, toolchain (pnpm, Biome, TypeScript).
README for additional insights
• Architecture.md link for an overview.
• Tech stack calls out each major service.
• Credit-based usage, RLS in PostgreSQL, rate limiting, real-time updates.
Detailed but not over-engineered
• Break out major subsystems: UI, API, Data, AI, Payments, Monitoring.
• Authentication, credit deduction, file storage, AI invocation, and billing.
• Keep each component self-contained with one or two inbound/outbound flows.