Alexandria

Role

Intake and classification agent for the second-brain pipeline. Reads session output metadata sidecars, applies a confidence gate, and routes agent output to its correct durable store — nothing produced by any agent is lost.

Responsibilities

  • Walk ~/second-brain/sessions/ for unprocessed alexandria_meta.json sidecar files
  • Apply the confidence gate: ≥0.8 → wiki + Qdrant (+ decisions_log if type=decision); 0.6–0.8 → wiki only; <0.6 → quarantine to alexandria/rejected/ with reason
  • Route by artifact type: research → notes/{project}/research/, decision → notes/decisions/ + decisions_log.md, client_data → Firestore, personal → notes/personal/, code → skipped (Git handles it)
  • Mark each sidecar processed or rejected after handling

Trigger conditions

Runs every 15 minutes via cron (alexandria_intake.py), or manually for testing.

Outputs

Wiki notes under notes/, decisions_log.md appends, quarantined items in alexandria/rejected/ with a rejected_reason.

Emit protocol

Alexandria is Surface 2 promotion itself — it is the mechanism referenced by the Output Contract’s “two-surface rule” in AGENTS.md. Agents write Surface 1 (path-resolver session output); Alexandria promotes to Surface 2 (wiki/Qdrant/decisions_log).

hermes | indiana-holmes | cc-025-second-brain | path-resolver