Source code (+excalidraw file): https://github.com/Andreaswt/ai-music...
Discord & More: https://andreastrolle.com
Modal: https://modal.com/andreas
Inngest: https://innge.st/yt-andreas-3
Neon: https://get.neon.com/3p6OW2q
Hi 🤙 In this project, you'll build a SaaS application that generates original music using AI. The tool uses a state-of-the-art music generation model to create songs from simple text descriptions, custom lyrics, or style prompts. You'll learn how to build a complete production-ready SaaS with user authentication, a credit-based payment system using Polar.sh, and background processing queues to handle user load. All services used in this project are free, so you won't have to pay anything to follow along. We'll use technologies such as Next.js 15, React, Typescript, Tailwind CSS, ShadCN, BetterAuth, Polar, Python, FastAPI, Modal, Inngest, Neon, S3 on AWS, and more.
Features
🎵 AI Music Generation with ACE-Step
🧠 LLM-Powered Lyric & Prompt Generation with Qwen2-7B
🖼️ AI Thumbnail Generation with stabilityai/sdxl-turbo
🎤 Multiple Generation Modes for descriptions, custom lyrics, or described lyrics
🎸 Instrumental Tracks option to generate music without vocals
⚡ Serverless GPU Processing with Modal for fast generation
📊 Queue System with Inngest for handling generation tasks in the background
💳 Credit-Based System
💰 Polar Integration for purchasing credit packs
👤 User Authentication with BetterAuth
🎧 Community Music Feed to discover, play, and like user-generated music
🎛️ Personal Track Dashboard to manage, play, and publish songs
🐍 Python & FastAPI Backend for music generation logic
📱 Modern UI with Next.js, Tailwind CSS & Shadcn UI
Chapters
0:00 Demo
2:37 Theory
48:33 Backend initialization
01:21:05 Music generation test
01:38:53 Modal endpoints
01:57:56 AWS setup
02:40:35 Next.js initialization
02:54:17 Auth
03:13:54 Database structure
03:28:42 Queue
04:10:43 Dashboard layout
04:33:38 Generate songs page
06:41:55 Sound bar
07:17:25 Home page
08:03:35 Payments
08:26:42 Deployment
08:51:17 Exercises