A greenfield Next.js app for practicing Mom Test-style customer interviews with realtime Gemini voice personas, a silent visual coach, and an exportable post-session debrief.
- Apple-inspired setup flow where a website URL alone is enough; optional text, images, pitch deck PDFs, and audio memos enrich the context.
- Context synthesis route using Gemini 3.5 Flash, with Managed Agent notes attempted for URL/image context and graceful local fallback when no API key is present.
- Curated customer personas plus a Custom persona text box, all with voice names for
gemini-3.1-flash-live-previewand grounded bycontent/customer-speech.mdso they sound like real humans instead of assistants. - Ephemeral Live API token route that keeps
GEMINI_API_KEYserver-side. - Browser Live session hook with AudioWorklet PCM capture, typed text input, PCM playback, input/output transcription accumulation, silence nudges, and teardown.
- Synced text transcript for both spoken and typed founder turns plus customer voice output transcription.
- Live customer persona attempts Google Search grounding for public facts, competitors, pricing, docs, reviews, and websites mentioned during roleplay.
- Parallel Mom Test coach evaluators on
gemini-3.5-flashwith explicit thinking levels and deterministic fallback heuristics. - Session report generation, markdown copy, and
.mddownload.
| Layer | Model |
|---|---|
| Voice persona | gemini-3.1-flash-live-preview |
| Context synthesis | gemini-3.5-flash + Managed Agent notes where available |
| Live coach | gemini-3.5-flash |
| Session report | gemini-3.5-flash |
Copy .env.example to .env.local:
GEMINI_API_KEY=your_google_gemini_api_key_here
NEXT_PUBLIC_APP_URL=http://localhost:3000Without GEMINI_API_KEY, the app still demos setup, fallback context synthesis, heuristic coaching, and report export. Live voice requires the key.
npm install
npm run devOpen http://localhost:3000.
npm run typecheck
npm run lint
npm test
npm run buildA local smoke test was also run against the dev server for:
/page loadPOST /api/context/synthesizefallback responsePOST /api/coach/evaluateheuristic Mom Test flagging
app/— App Router pages and API routescomponents/setup/— context intake and persona pickercomponents/session/— live practice studio, transcript, coach railcomponents/report/— debrief UI and export actionshooks/useCustomerLiveSession.ts— Live API client lifecycle and audio handlinglib/coach/parallel-evaluate.ts— parallel rubric evaluatorslib/personas.ts— curated v1 personascontent/mom-test.md— editable coaching reference read by coach/report agentscontent/customer-speech.md— editable persona speech guide read by the Live customer token routeagents/context-synthesizer/AGENTS.md— Managed Agent instructions
Deploy to Vercel and set GEMINI_API_KEY for Production and Preview. The API routes are dynamic server routes and return Cache-Control: no-store for token/coaching/report responses.