$ show EpicenterHQ/epicenter
Epicenter is a monorepo platform for building local-first, privacy-focused productivity applications with optional cloud sync. It encompasses a suite of apps including Honeycrisp (notes with Yjs CRDT sync), Whispering (voice transcription/dictation with local and cloud providers), Matter (typed markdown vaults with SQLite projection), Local Mail (Gmail mirror with offline triage), Local Books (QuickBooks mirror with CLI tools), Vocab (AI language tutor), Skills (agent instruction management), and the Epicenter desktop host (Tauri + Bun sidecar). The shared platform provides a CRDT-based data layer (Yjs with Durable Object authority), portable blob storage (IndexedDB, OPFS, S3), an OAuth/infrastructure-agnostic auth system, an agent loop framework with tool catalogs, and a server framework built on Hono for Cloudflare Workers or Bun. The architecture emphasizes offline-first, typed error handling (Result/defineErrors pattern), compile-time platform seams (browser/Tauri/desktop-host), and rigorous ADR-driven design with evidence benchmarks.
The LLM identified 6 files worth highlighting for reuse:
Defines a closed vocabulary of field types (string, number, select, etc.) with builders and a recognition function. This is a self-contained pattern for schema definition that can be reused in any project needing a structured, type-safe field vocabulary. It demonstrates non-obvious skill in API design: immutable builders, branded types, and a single recognition pass.
Defines a portable BlobStore interface (put, get, stat, delete) with immutable blob IDs. Implementations exist for IndexedDB, OPFS, and S3 (presigned). The interface is clean, minimal, and trivially extractable for any application needing content-addressed blob storage across environments.
Provides a factory function `createAppAuthClient` that returns a typed auth client with methods for sign-in, sign-out, session retrieval, and sync credential provisioning. Supports multiple OAuth providers and instance-token auth. The pattern is reusable for any app needing authentication with a pluggable backend.
Implements a UI-free agent conversation loop that streams inference, persists messages on completion, and discovers capabilities through injected tool catalogs. The loop is decoupled from transport, storage, and presentation, making it reusable for any agent system that needs a structured, extensible conversation runtime.
A Svelte 5 rune-based utility `createPersistedState` that synchronizes reactive state with localStorage, including per-key schema validation via arktype. Demonstrates a clean pattern for persisted settings with runtime type checking, extractable for any Svelte 5 app requiring durable client-side state.
Implements the core store abstraction: an account-bound CRDT store backed by SQLite/Yjs. Provides `openDatabase`, `createRow`, `updateRow`, `deleteRow`, and structured data definitions via `defineData`. This is the foundation for local-first apps and could be extracted as a library for building any sync-capable application, though it has internal dependencies on other packages.