Skitso is an AI-assisted collaborative performance platform that enables groups to create, perform, and share theatrical skits. Built with Next.js 16+, PartyKit for real-time synchronization, and OpenAI for AI-generated content.
- π VibeContext System: Five production styles (Viral Neon, Indie A24, Sitcom Studio, Brainrot Theater, Quiet Studio) that transform the entire app's aesthetic
- π€ AI-Generated Content: Automated script, character, and visual generation using OpenAI
- β‘ Real-Time Synchronization: Multi-device synchronization powered by PartyKit
- π¬ Teleprompter: Synchronized script advancement with Director controls
- π Wrap Party: Voting and social sharing after performances
- Node.js 20+ and npm/yarn/pnpm
- TypeScript 5+
- OpenAI API key (for AI generation features)
- PartyKit account (for real-time features - free tier available)
# Clone repository
git clone <repository-url>
cd skitso
# Install dependencies
npm install
# Set up environment variables
cp .env.example .env.local
# Edit .env.local and add your OPENAI_API_KEYStart the development servers:
# Option 1: Run both Next.js and PartyKit dev servers concurrently
npm run dev:all
# Option 2: Run separately in different terminals
# Terminal 1: Next.js dev server
npm run dev
# Terminal 2: PartyKit dev server
npm run dev:partykitOpen http://localhost:3000 with your browser to see the result.
Required environment variables in .env.local:
# OpenAI API (required for AI generation)
OPENAI_API_KEY=your_openai_api_key_here
# Application URL
NEXT_PUBLIC_APP_URL=http://localhost:3000
# PartyKit Configuration (for local dev, uses localhost:1999 by default)
# NEXT_PUBLIC_PARTYKIT_HOST=http://localhost:1999For production, see Deployment section below.
Skitso uses PartyKit for real-time WebSocket synchronization, which is required for multi-device collaboration. The PartyKit server must be deployed separately from the Next.js app.
-
Generate PartyKit Access Token (one-time setup):
npx partykit token generate
This opens your browser for GitHub authentication and saves
PARTYKIT_LOGINandPARTYKIT_TOKENvalues locally. Save these values securely - you'll need them for CI/CD automation. -
Deploy PartyKit Server:
npx partykit deploy
You'll be prompted to log in (if not already authenticated). The deployment will output your PartyKit host URL, e.g.:
https://skitso.[your-username].partykit.dev -
Save PartyKit Host URL:
Save the PartyKit host URL - you'll need it for Vercel configuration.
-
Configure GitHub Secrets:
In your GitHub repository, go to Settings β Secrets and variables β Actions, and add:
PARTYKIT_LOGIN: Your GitHub username (from token generation)PARTYKIT_TOKEN: The generated token value (from token generation)
β οΈ Never commit these values to source control. -
GitHub Actions Workflow:
The project includes
.github/workflows/deploy-partykit.ymlwhich automatically deploys the PartyKit server on push tomainbranch when PartyKit-related files change.The workflow triggers when changes are made to:
parties/**filespartykit.json- The workflow file itself
-
Verify Automated Deployment:
After pushing to
main, check the GitHub Actions tab to verify the deployment succeeded. The PartyKit host URL will be logged in the workflow output.
-
Deploy to Vercel:
# Install Vercel CLI (if not already installed) npm i -g vercel # Deploy vercel
Or connect your repository to Vercel through the Vercel Dashboard.
-
Configure Environment Variables in Vercel:
In your Vercel project settings, add the following environment variables:
OPENAI_API_KEY=your_openai_api_key_here NEXT_PUBLIC_APP_URL=https://your-app.vercel.app NEXT_PUBLIC_PARTYKIT_HOST=https://skitso.[your-username].partykit.devβ οΈ Important: Replace[your-username]with your actual PartyKit username from the deployment output. -
Redeploy:
After adding environment variables, trigger a new deployment in Vercel (or push a commit to trigger automatic deployment).
-
Test PartyKit Connection:
- Open your deployed Vercel app
- Open browser DevTools β Network tab
- Filter by "WS" (WebSocket)
- You should see a connection to your PartyKit host URL
-
Test Real-Time Features:
- Open the app in multiple browser tabs/devices
- Create a session and join from multiple devices
- Verify that VibeContext changes, script updates, and performance progress synchronize across all devices within 500ms
Problem: WebSocket connection fails, "PartyKit not connected" errors
Solutions:
- Verify
NEXT_PUBLIC_PARTYKIT_HOSTis set correctly in Vercel environment variables - Ensure the PartyKit server is deployed and accessible
- Check PartyKit server logs:
npx partykit tail(requires authentication) - Verify CORS settings if using a custom domain
Problem: GitHub Actions deployment fails with authentication errors
Solutions:
- Verify
PARTYKIT_LOGINandPARTYKIT_TOKENare correctly set in GitHub Secrets - Ensure the token hasn't expired (tokens don't expire, but double-check the values)
- Try regenerating the token:
npx partykit token generate
Problem: Changes don't synchronize across devices
Solutions:
- Verify both Next.js app and PartyKit server are deployed
- Check browser console for WebSocket connection errors
- Ensure
NEXT_PUBLIC_PARTYKIT_HOSTpoints to the correct PartyKit server - Test with PartyKit dev server locally first:
npm run dev:all
Problem: Manual or automated deployment fails
Solutions:
- Verify
partykit.jsonexists and is correctly configured - Check that
parties/session.tsexists and has no syntax errors - Ensure PartyKit account is active (free tier: 10 projects max)
- Check PartyKit status page for service issues
| Variable | Required | Description | Example |
|---|---|---|---|
OPENAI_API_KEY |
Yes | OpenAI API key for AI generation | sk-... |
NEXT_PUBLIC_APP_URL |
Yes | Public URL of your Next.js app | https://skitso.vercel.app |
NEXT_PUBLIC_PARTYKIT_HOST |
Yes | PartyKit server host URL | https://skitso.user.partykit.dev |
PARTYKIT_LOGIN |
CI/CD only | GitHub username for automated deployment | your-username |
PARTYKIT_TOKEN |
CI/CD only | PartyKit access token for automated deployment | pk_... |
- 10 projects max: Free tier allows up to 10 PartyKit projects
- 24-hour storage: Session data expires after 24 hours (matches MVP requirement)
- Domain pattern: Projects use the pattern
[project-name].[github-username].partykit.dev
For production scaling beyond free tier, consider upgrading or migrating to a self-hosted WebSocket solution.
skitso/
βββ parties/ # PartyKit server (real-time WebSocket)
β βββ session.ts # Session management and synchronization
βββ src/
β βββ app/ # Next.js App Router pages
β βββ components/ # React components
β βββ lib/ # Utilities and integrations
β β βββ partykit/ # PartyKit client wrapper
β β βββ openai/ # OpenAI API integration
β βββ state/ # Jotai state management
βββ public/ # Static assets
βββ specs/ # Project specifications and documentation
See the specs/001-skitso-platform/ directory for detailed specifications:
spec.md- Full feature specificationplan.md- Technical implementation planquickstart.md- Development setup guidetasks.md- Implementation task breakdown
[Add your license here]