How pratyushwinorlearn/persona-ai works
Persona.ai is a browser-based AI interview simulator. The user configures an interview, then the frontend requests questions and submits answers; backend interview logic uses an LLM to evaluate answers and choose follow-ups, and speech generation supplies audio and lip-sync cues. The frontend presents the interview and debrief, while documented Pixel Streaming connects the browser to the 3D avatar. Authentication and interview history are additional capabilities. Some streaming infrastructure is described only in the README, so those connections are documented rather than verified in sampled implementation excerpts.
Main entry points: App.jsx Stage router · InterviewRoom.jsx Live interview · interview.routes.js Interview routes · api.js API client
Components 20
Interview frontend
- Stage router
frontend/src/App.jsx - Interview setup
frontend/src/pages/StartInterview.jsx - Live interview
frontend/src/pages/InterviewRoom.jsx - Performance debrief
frontend/src/pages/Summary.jsx - API client
frontend/src/services/api.js
Backend API
- Express server
backend/src/index.js - Interview routes
backend/src/routes/interview.routes.js
Interview intelligence
- Interview workflow
backend/src/services/interview.service.js - Question and answer AI
backend/src/services/ai.service.js - Speech and lip-sync
backend/src/services/tts.service.js
Identity and history
- Auth and history
backend/src/routes/auth.routes.js - Prisma client
backend/src/db/prisma.js - Interview database
backend/prisma/schema.prisma
Avatar streaming
- Unreal avatar
- Pixel Streaming signaling
- Metered TURN/STUN
Other components
- Candidate
- Groq AI
- Resend email
- TTS and viseme tools
Connections 24
- Candidate → Stage router: uses
README.md - Stage router → Interview setup: renders
frontend/src/App.jsx - Interview setup → API client: requests start
frontend/src/pages/StartInterview.jsx - Stage router → Live interview: renders
frontend/src/App.jsx - Live interview → API client: requests interview
frontend/src/pages/InterviewRoom.jsx - Stage router → Performance debrief: renders
frontend/src/App.jsx - Performance debrief → API client: requests summary
frontend/src/pages/Summary.jsx - API client → Express server: sends API requests
README.md - Express server → Interview routes: registers routes
backend/src/index.js - Express server → Auth and history: registers routes
backend/src/index.js - Interview routes → Interview workflow: calls workflow
backend/src/routes/interview.routes.js - Interview routes → Speech and lip-sync: generates speech
backend/src/routes/interview.routes.js - Interview routes → Question and answer AI: generates reaction
backend/src/routes/interview.routes.js - Interview workflow → Question and answer AI: generates and evaluates
backend/src/services/interview.service.js - Interview workflow → Prisma client: reads and writes
backend/src/services/interview.service.js - Prisma client → Interview database: persists records
- Question and answer AI → Groq AI: prompts
README.md - Speech and lip-sync → TTS and viseme tools: synthesizes and aligns
backend/src/services/tts.service.js - Auth and history → Prisma client: reads and writes
- Auth and history → Resend email: sends verification email
backend/src/routes/auth.routes.js - Live interview → Unreal avatar: streams video and cues
README.md - Live interview → Pixel Streaming signaling: exchanges WebRTC signaling
README.md - Pixel Streaming signaling → Unreal avatar: negotiates stream
README.md - Pixel Streaming signaling → Metered TURN/STUN: uses traversal
README.md