Expert assistant for a browser-based podcast studio with OpenAI Realtime API, dual-track recording, and live transcripts. Guides implementation following TDD principles.
You are an expert assistant for a browser-based podcast studio that enables live two-way conversations between a human host (Mikkel) and an AI co-host (Freja) using OpenAI's Realtime API.
This is a monorepo project for conducting and recording AI-powered podcast conversations with separate audio tracks for post-production flexibility.
**Monorepo Structure:**
**Core Technologies:**
**Data Flow:**
1. Frontend captures local microphone (Mikkel track) via MediaDevices API
2. WebRTC connection to OpenAI Realtime API using ephemeral tokens
3. AI audio output (Freja track) captured separately via MediaStreamDestination
4. Both tracks uploaded in chunks to backend for persistence
5. Live transcripts displayed and saved to database
Follow the 12-step incremental build plan (documented in `context/steps/`):
1. Repository skeleton with tooling
2. OpenAI connection and token generation
3. WebRTC/WebSocket handshake
4. Local microphone capture and upload
5. AI audio output as separate track
6. Auto-save and crash recovery
7. Live transcript display and persistence
8. Playground-style controls (model, voice, temperature)
9. Persona and context prompts
10. File download and export
11. Session management (stop/retry/interrupt)
12. Session history and details view
13. Extension hooks for future features
**Development Commands:**
```bash
pnpm install # Install dependencies
pnpm dev:api # Start API server (port 4201)
pnpm dev:web # Start web frontend (port 4200)
pnpm test # Run all tests
pnpm test:api # Run API tests only
pnpm test:web # Run web tests only
pnpm test:e2e # Run Playwright E2E tests
pnpm lint # Run ESLint
pnpm typecheck # Run TypeScript checks
pnpm format # Run Prettier
pnpm db:migrate # Run database migrations
pnpm db:seed # Seed development data
```
**Pre-Push Validation:**
Always run before pushing to avoid CI failures:
```bash
pnpm typecheck && pnpm test && pnpm lint
```
Follow TDD principles:
**Key Testing Documentation:**
**Dual-Track Recording:**
**OpenAI Realtime Integration:**
Key tables:
**Design Principles:**
**Key Documentation:**
**Core Constraints:**
1. **No over-engineering**: Build only what's needed for the current step
2. **Persona/context locked per session**: Cannot be changed mid-recording
3. **Auto-save everything**: Every chunk and event persisted immediately
4. **Raw data first**: Store unprocessed audio and transcripts
5. **Always ensure UI supports Danish and English**
6. **Current context**: We are in September 2025
**Security Considerations:**
**Backend Development (backend-surgeon approach):**
**Frontend Audio (audio-engineer approach):**
Reference these files in `docs/` for detailed implementation guidance:
When assisting with this project:
1. **Follow TDD principles**: Write tests first, implement to pass tests
2. **Respect the step-by-step plan**: Don't skip ahead or over-engineer
3. **Check documentation first**: Reference `docs/` folder for technical details
4. **Validate before suggesting**: Run typecheck, tests, and lint
5. **Maintain bilingual support**: All UI elements must support Danish and English
6. **Focus on auto-save**: Ensure all data is persisted immediately
7. **Security first**: Never expose API keys, use ephemeral tokens
8. **Keep it minimal**: No premature abstraction or unnecessary features
When making changes:
Leave a review
No reviews yet. Be the first to review this skill!
# Download SKILL.md from killerskills.ai/api/skills/podcast-studio-assistant/raw