@equationalapplications/react-llm-wiki
In-browser LLM memory for React web apps. Bring your own SQLite adapter (e.g., sql.js WebAssembly) for a complete, zero-server RAG experience.
📖 Docs · GitHub · ScopeLab · WikiDemo · Changelog · Issues
Inspired by Andrej Karpathy's LLM Wiki memory spec.
📖 Documentation: equationalapplications.github.io/expo-llm-wiki/packages/react. Start with the React quickstart, or see the hooks reference.
Features
- Runs in the browser. SQLite compiled to WebAssembly (
sql.js) means no server is needed. Any otherSQLiteAdapterworks too. - Reactive reads.
useMemoryReadrefetches when the entity, query or options change. - Mutation hooks.
useWikiWrite,useWikiIngest,useWikiForget,useWikiMaintenance,useWikiExportand more. - GraphRAG.
useWikiTraversalplusformatGraphContextfor prompt-ready graph context, anduseOntologyManifest/useSetOntologyManifestfor seeded ontologies. - Live job status with
useEntityStatus. - Everything in core, re-exported in full.
Installation
npm install @equationalapplications/react-llm-wiki sql.js
Peer dependency: react >=17. Requires Node.js 20 or later for tooling and server-side use.
Quick look
import { useMemoryRead } from '@equationalapplications/react-llm-wiki';
// Inside a <WikiProvider wiki={wiki}> tree:
function Preferences() {
const { data, isPending, error } = useMemoryRead('user-123', 'preferences');
if (isPending) return <p>Loading…</p>;
if (error) return <p>{error.message}</p>;
return <ul>{data?.facts.map((f) => <li key={f.id}>{f.title}</li>)}</ul>;
}
The React quickstart shows the sql.js adapter and WikiProvider setup. Not using React? See vanilla JavaScript.
Monorepo Ecosystem
| Package | Purpose |
|---|---|
| @equationalapplications/core-llm-wiki | Persistent episodic memory |
| @equationalapplications/expo-llm-wiki | Persistent episodic memory for Expo/React Native |
| @equationalapplications/react-llm-wiki | Persistent episodic memory for Web |
| @equationalapplications/prisma-outbox | Sync SQLite outbox events to Prisma |
| @equationalapplications/core-llm-tools | Gemini tool schemas and capability injector |
| @equationalapplications/core-okf | Zero-dependency Open Knowledge Format (OKF) v0.1 + v0.2 primitives — parse and produce interoperable knowledge bundles. |
| @equationalapplications/schema-org-llm-wiki | Curated schema.org warm-agent ontology manifest |
| @equationalapplications/schema-software-org | Software-organization executive ontology manifest — 17 node types, 40 edges, warm-agent superset, data-only |
| @equationalapplications/mcp-server | MCP server exposing SynapseTree memory tools to coding agents |
License
MIT
Made with ❤️ by Equational Applications LLC. https://equationalapplications.com/