0ee5a9ce476c96a1327eb5f63babbcea88c2983f
- lyra.memory.remember(session_id, role, content) embeds and stores - lyra.memory.recent(session_id, n) returns the last N from a session - lyra.memory.recall(query, k, session_id=None) returns top-k by cosine similarity across the chosen scope (all sessions by default) - Embeddings live in the exchanges.embedding BLOB column as float32 bytes - Connection reopens automatically if LYRA_DB_PATH changes (test-friendly)
Lyra
A persistent, autonomous AI assistant. From-scratch rewrite of an earlier attempt.
The design thinking that survives the rewrite lives in docs/ — start with docs/ARCH_v0-6-1.md. The previous implementation is preserved on the archive branch.
Status
Pre-MVP. Building toward the smallest useful version: chat with persistent memory across sessions.
Setup
uv sync
cp .env.example .env
# fill in ANTHROPIC_API_KEY and point LOCAL_BASE_URL at your Ollama
Architecture
The long-term target is the cognitive split in docs/ARCH_v0-6-1.md — Inner Self as the seat of consciousness, Executive for hard reasoning, Cortex Chat for drafting, Persona for voice. The MVP implements only the chat + memory baseline. Cognitive layers come back one at a time.
Description
Languages
Python
92.8%
HTML
3.9%
JavaScript
1.7%
CSS
1.3%
Dockerfile
0.3%