An AI-powered social media campaign generator that helps founders and marketers create complete Instagram campaigns in seconds. Now with campaign history and scheduling!
- AI-Powered Content Generation: Generate comprehensive Instagram campaigns using Groq (Llama 3.3) for lightning-fast results.
- Complete Campaign Strategy: Get a content plan tailored to your product and audience.
- 5 Diverse Post Ideas: Mix of carousels, reels, and static posts.
- Ready-to-Use Content: Captions, hooks, CTAs, and hashtags for each post.
- AI Image & Video Generation:
- High-quality images via Segmind SDXL.
- Video generation via Hugging Face models.
- Campaign History: Automatically saves your generated campaigns to Supabase.
- Content Calendar: Schedule your posts and view them in an interactive calendar.
- Beautiful UI: Modern, responsive design with smooth animations.
- Copy-to-Clipboard: Easily copy any content with one click.
- Frontend: Next.js 16 (App Router) + TypeScript
- Styling: Tailwind CSS v4 + shadcn/ui components
- AI (Text): Groq (Llama 3.3 70B Versatile) via Vercel AI SDK
- AI (Media): Segmind (Images), Hugging Face (Video)
- Database: Supabase (PostgreSQL)
- Deployment: Vercel (recommended)
- Node.js 18+ installed
- Groq API key (Get one here)
- Supabase Project (Create one here)
- Clone the repository:
git clone <your-repo-url>
cd campaign-studio- Install dependencies:
npm install- Create a
.env.localfile in the root directory:
# AI Services
GROQ_API_KEY=your_groq_api_key_here
# Supabase
NEXT_PUBLIC_SUPABASE_URL=your_supabase_url
NEXT_PUBLIC_SUPABASE_ANON_KEY=your_supabase_anon_key-
Set up the Database:
- Go to your Supabase project's SQL Editor.
- Copy the contents of
supabase_schema.sqlfrom this repository. - Run the SQL query to create the necessary tables and policies.
-
Run the development server:
npm run dev- Open http://localhost:3000 in your browser
- Enter Product Description: Describe your product or service
- Specify Target Audience: Define who you're trying to reach
- Generate Campaign: Click the button and watch the AI create your campaign
- Save & Schedule: Campaigns are automatically saved. Click "Schedule" on any post to add it to your calendar.
- View Calendar: Access the calendar from the sidebar to see your scheduled content.
Product Description:
I sell eco-friendly water bottles made from recycled materials. They keep drinks cold for 24 hours and come in vibrant colors.
Target Audience:
College students interested in sustainability and eco-friendly lifestyle
campaign-studio/
├── app/
│ ├── api/
│ │ ├── generate/ # Groq text generation
│ │ ├── generate-image/ # Image generation
│ │ └── generate-video/ # Video generation
│ ├── calendar/ # Calendar page
│ ├── globals.css # Global styles
│ ├── layout.tsx # Root layout
│ └── page.tsx # Main application page
├── components/
│ ├── app-sidebar.tsx # Navigation sidebar
│ └── ui/ # shadcn/ui components
├── lib/
│ ├── supabase.ts # Supabase client
│ └── types.ts # Type definitions
└── supabase_schema.sql # Database schema
- Groq (Llama 3.3): Delivers near-instant text generation for campaign strategies and posts.
- Multi-Modal: Generates text, images, and videos in one workflow.
- Supabase Integration: All campaigns are persisted to a PostgreSQL database.
- Interactive Calendar: Visual planning of your content with status tracking.
- Push your code to GitHub
- Import the project in Vercel
- Add your Environment Variables (
GROQ_API_KEY,NEXT_PUBLIC_SUPABASE_URL,NEXT_PUBLIC_SUPABASE_ANON_KEY) - Deploy!
The app can be deployed to any platform that supports Next.js:
- Netlify
- Railway
- AWS Amplify
- Google Cloud Run
AI Models Used:
- Groq (Llama 3.3-70b): For instant campaign strategy and copy generation.
- Segmind SDXL: For high-fidelity image generation.
- Hugging Face (Zeroscope): For AI video generation.
Why These Models: We switched to Groq to leverage its LPU inference engine, delivering near-instant text generation that makes the app feel real-time. Llama 3.3 offers the perfect balance of creativity and instruction-following for marketing content. Supabase was added to provide persistent storage and real-time capabilities for the new calendar feature.
How AI is Used:
- Contextual Analysis: The AI analyzes the product and target audience to determine the best tone and content strategy.
- Structured Generation: Groq generates a JSON-structured response containing the strategy and 5 distinct post types (Reels, Carousels, Static).
- Visual Synthesis: Image prompts created by the text model are sent to Segmind to generate matching visuals.
Architecture:
- Frontend: Next.js 16 App Router for server-side rendering and optimal performance.
- Backend/DB: Supabase (PostgreSQL) for storing campaigns and managing the content calendar.
- Styling: Tailwind CSS v4 with shadcn/ui for a premium, accessible interface.
- AI Layer: Vercel AI SDK for standardized API interactions.
Deployment: Optimized for Vercel with serverless functions, ensuring fast global delivery and automatic scaling.
Create a .env.local file with:
GROQ_API_KEY=
NEXT_PUBLIC_SUPABASE_URL=
NEXT_PUBLIC_SUPABASE_ANON_KEY=MIT
Contributions are welcome! Feel free to open issues or submit pull requests.
Built as a technical assignment to demonstrate full-stack AI application development.