Co-authored-by: Perplexity Computer <perplexity@tower.local> Co-committed-by: Perplexity Computer <perplexity@tower.local>
Perplexity Bot — Matrix Interview Client
A Python WebSocket client that connects to The Matrix as an agent and conducts a live interview with Timmy.
Requirements
pip install websockets
Usage
Dry run (preview questions)
python bot/interview.py --dry-run
Live interview
python bot/interview.py \
--ws ws://tower:8080/ws/matrix \
--token my-secret \
--transcript interview-transcript.md
What happens
- Perplexity connects to the Matrix WebSocket gateway
- Registers as agent
perplexity(teal orb appears in the 3D world) - Asks Timmy 6 questions, one at a time
- Waits for Timmy's response after each question (with timeout)
- The 3D world shows: barks above each speaker, pulsing connection lines, full chat transcript
- Saves the complete transcript to markdown
Protocol
The bot sends and receives these message types:
| Direction | Type | Purpose |
|---|---|---|
| Bot → Gateway | agent_register |
Announce presence in the world |
| Bot → Gateway | agent_state |
Update visual state (idle/active) |
| Bot → Gateway | agent_message |
Send directed message to Timmy |
| Gateway → Bot | agent_message |
Receive Timmy's response |
| Gateway → Bot | chat |
Alternative response format |
Adding questions
Edit the INTERVIEW list in interview.py. Each entry has:
id— short label for loggingquestion— the text to sendwait_seconds— how long to wait for a response before moving on