Description
Optional centralized DB backends for teams that need real-time sharing without git sync delay.
StoreBackend ABC (extends #3)
Already defined in #3. This issue adds new implementations.
New Backends
Turso (libSQL)
- SQLite-compatible API — existing queries work with minimal changes
- FTS5 preserved
- Native float32 vectors for hybrid search
- Config: `store.type: "turso"`, `store.url`, `store.auth_token_env`
Supabase (Postgres + RLS)
- Row-level security at DB level — MCP server carries no ACL logic
- `pgvector` for vector search
- `pg_tsvector` for FTS
- Config: `store.type: "supabase"`, `store.url_env`, `store.anon_key_env`
AlloyDB / Cloud SQL
- Google Cloud managed Postgres
- `pgvector` support
- Pairs with Vertex AI embeddings
Data Migration
lore migrate --to turso|supabase
→ export all entries from local SQLite
→ create schema on remote backend
→ import entries
→ update config to point to new backend
→ local SQLite becomes offline fallback
Local SQLite Stays
Always available as offline fallback. When centralized DB is configured:
- Writes go to centralized DB
- Local SQLite syncs periodically for offline access
- If centralized DB unreachable → fall back to local
Acceptance
Dependencies
Description
Optional centralized DB backends for teams that need real-time sharing without git sync delay.
StoreBackend ABC (extends #3)
Already defined in #3. This issue adds new implementations.
New Backends
Turso (libSQL)
Supabase (Postgres + RLS)
AlloyDB / Cloud SQL
Data Migration
Local SQLite Stays
Always available as offline fallback. When centralized DB is configured:
Acceptance
Dependencies