Files
podman/database/README.md
T
Ramis 923ab1cf58 docs: finalize PodMan architecture and write full integration specs
Replaces v1 plan with locked architecture:
- Hermes orchestrator: POST /ingest → Gemini Vision → MongoDB → event detection → Gemini Live 2.5 voice via LiveKit Agents
- Four MongoDB collections: engineer_states, ownership_map, events, nudges
- Continual learning via ownership_map persisting across sessions

New files: docs/idea.md, docs/gemini.md, docs/livekit.md, docs/mongodb.md, docs/digitalocean.md, docs/demo-setup.md
Updated: README.md, docs/PLAN.md (12-hour build plan), database/README.md, infra/README.md, .env.example

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01FFbfi4Cmb7BY75Wtne7bZn
2026-06-27 15:27:23 -07:00

35 lines
1.5 KiB
Markdown

# database
Persistent memory for PodMan: **MongoDB Atlas** stores live engineer state, the ownership map (continual learning), coordination events, and nudge history.
This is what makes PodMan "more useful the more you use it" — the ownership map persists across sessions, so PodMan already knows who owns what when the team comes back.
## Collections
| Collection | Holds | Notes |
|---|---|---|
| `engineer_states` | Latest `EngineerContext` per engineer | Upserted on every `/ingest` call |
| `ownership_map` | File → primary owner + contributors | Persists across sessions — the continual learning artifact |
| `events` | Detected coordination events (DEPENDENCY_READY, BLOCKER_DETECTED, DUPLICATE_WORK) | Append-only |
| `nudges` | Every voice nudge sent to the room | Used for cooldown checks (3 min between nudges) |
Full schemas with indexes in [`docs/mongodb.md`](../docs/mongodb.md).
## Continual learning loop
1. **Observe** — engineer POSTs frame → Hermes calls Gemini Vision → `EngineerContext`
2. **Store** — upsert `engineer_states`, upsert `ownership_map`
3. **Detect** — Hermes runs event detection over all active states
4. **Nudge** — voice nudge sent into LiveKit room, written to `nudges`
5. **Improve** — next session: Hermes loads `ownership_map` on startup, skips cold-start inference
## Setup
Create a free Atlas M0 cluster, then set `MONGODB_URI` in `.env`.
Collections are created automatically on first write — no migration needed.
```bash
MONGODB_URI=mongodb+srv://<user>:<pass>@cluster.mongodb.net/podman
```