Skip to content

Repository files navigation

Locium

Korean README

Locium is a local-first memory system for people and AI agents.

It turns notes, documents, transcripts, and imported text into a workspace that humans can browse as a wiki and AI tools can query as a structured memory graph. The goal is to keep useful context close to the user, preserve where each claim came from, and make long-running work easier to resume.

Locium runs on your machine. Workspace files, journal events, wiki pages, graph projections, search indexes, and history checkpoints are local by default.

Why Locium

Modern AI tools can answer quickly, but they often lose project history, decision rationale, and evidence. Locium is designed around inspectable memory:

  • Humans get a readable wiki with search, backlinks, review queues, and history.
  • AI agents get recall tools that include provenance and freshness signals.
  • Raw sources stay immutable, so generated memory can be audited.
  • User-written text is protected from automated overwrites.
  • Durable changes flow through a journal before they update wiki or graph views.

Core Features

Local Workspace

Locium creates a self-contained workspace for memory data. The workspace separates raw evidence, journal events, generated wiki pages, graph projections, indexes, and sidecar state. This makes the system easier to replay, inspect, and repair.

Source Import

The import pipeline supports direct notes, Markdown/text files, extracted PDF text, transcripts, and shared snapshots. Imported content is treated as source evidence, then transformed into reviewable memory candidates instead of being silently merged into the workspace.

Human Wiki

The wiki surface is built for reading and correction. Users can browse pages, search full text, follow backlinks, append notes, and keep user-authored sections separate from system-owned sections. Automated updates preserve user-owned text so the wiki can remain a trustworthy editing surface.

AI Memory Graph

The graph surface stores structured memory for recall. It tracks entities, claims, relations, evidence, decisions, procedures, and freshness information. AI recall is routed through graph-aware retrieval so answers can include the evidence behind them.

Review and Apply Flow

Locium favors reviewable automation. Extraction and consolidation candidates can be inspected before being applied. This keeps AI-generated structure useful without making it an unchecked source of truth.

Journal and Recovery

Durable changes are recorded as append-only journal events. The system can create checkpoints, show diffs, restore previous state, and replay journaled changes into projections. This gives the workspace a recoverable history instead of only a mutable current state.

MCP Integration

Locium exposes an MCP surface so compatible AI clients can use local memory tools:

  • memory.overview
  • memory.recall
  • memory.remember_note
  • memory.provenance
  • memory.import_source

These tools are designed for grounded recall rather than hidden background rewriting. Important answers should carry evidence, not just a generated summary.

Desktop App

The desktop app is a React + Tauri interface for the local sidecar engine.

  • Explorer: wiki pages, full-text search, backlinks, and page reading
  • Activity: imports, note capture, page append, and extraction review
  • Graph: recall, provenance, warnings, diagnostics, and consolidation review
  • Journal: checkpoints, diffs, restore, and recovery metadata
  • Settings: workspace selection, diagnostics, local runtime inventory, model roles, and health checks

Screenshots

Knowledge Map

Locium knowledge map

The Knowledge Map visualizes the local memory graph around a selected root entity. Nodes represent entities, assertions, episodes, page views, and support evidence, while the side panel summarizes the current root, visible sections, linked pages, graph distance, and structure distribution.

Docs

Locium docs view

The Docs view presents generated topic pages as a readable wiki. The left pane supports page navigation and search, the center pane shows the selected page with system-owned sections, and the right pane lets users write correction notes or generate review suggestions without overwriting the page silently.

Review Queue

Locium review queue

The Review Queue keeps memory updates human-reviewable. In this example, a supersession proposal compares a primary assertion against an older related assertion, shows the decision basis, preserves source text, and gives the user explicit Apply and Reject controls before the graph is updated.

Implementation Overview

Locium uses a journal-driven local architecture:

Raw sources
  -> Import Pipeline
  -> Journal
  -> Sync Engine
      -> Wiki Projection
      -> Graph Projection
      -> Search/Index Views
      -> History Checkpoints
      -> MCP Recall Surface

The architecture is built around a few rules:

  • Raw sources are evidence and remain immutable.
  • The journal records durable mutations.
  • The Sync Engine is the write gate for persistent changes.
  • The wiki is the human-readable projection.
  • The graph is the AI-readable projection.
  • User-authored sections are preserved during automated updates.
  • Provider-specific model logic is isolated behind package boundaries.

Technical Design

Monorepo Structure

Locium is organized as a TypeScript workspace with separate packages for domain contracts, workspace management, journaling, import, sync, graph storage, retrieval, policy, MCP, and local model orchestration. This keeps core memory logic independent from the desktop UI and transport layers.

Durable Write Path

Writes are represented as commands/events and appended to the journal before projections are updated. The Sync Engine then materializes wiki files, graph data, indexes, and history checkpoints from that durable event stream.

This avoids separate write paths for human and AI surfaces. The wiki and graph may look different, but they are derived from the same mutation history.

Projection Model

Locium treats the wiki and graph as projections:

  • The wiki projection is optimized for human reading, editing, backlinks, and page-level navigation.
  • The graph projection is optimized for typed recall, evidence lookup, relation traversal, and AI context assembly.

Because projections can be rebuilt, the workspace can recover from many classes of derived-state errors without losing source evidence.

Retrieval Pipeline

Human browsing and AI recall use different paths. Human browsing prioritizes page search, backlinks, and wiki navigation. AI recall uses intent routing, hybrid retrieval, graph expansion, reranking, provenance, and diagnostics so results are better suited for agent context.

Local Model Layer

Local models are treated as helper engines, not as the source of truth. Model recommendations, runtime inventory, candidate generation, and candidate application are kept behind explicit interfaces so providers can change without rewriting the core memory system.

Desktop and Daemon Boundary

The desktop app is responsible for interaction and visualization. The daemon-side packages own workspace operations, import, sync, graph maintenance, retrieval, history, and MCP behavior. This separation keeps business logic out of the UI and makes the sidecar engine reusable.

Tech Stack

  • TypeScript monorepo with npm workspaces
  • React desktop UI
  • Tauri native desktop host
  • Rust host layer for the desktop shell
  • Node.js local daemon and package runtime
  • SQLite-backed graph projection and local indexes
  • JSONL journal for durable event history
  • MCP tools for AI-client integration
  • Package-level and integration tests for core workflows

Windows Quick Launch

For the easiest Windows setup, double-click:

Launch-Locium.cmd

The launcher checks your local tools, installs npm dependencies when needed, builds the Tauri desktop executable if it does not exist yet, and starts Locium.

The first launch can take several minutes because it downloads dependencies and compiles the desktop app. Later launches are much faster because the built executable is reused.

Requirements

Before running Locium locally, install the following tools.

Required

  • Operating system: Windows 10/11 is the primary supported desktop environment for this build.
  • Node.js: Node.js 24 or newer. npm is included with the standard Node.js installer.
  • Git: required for cloning the repository and for Locium's local history features.
  • Rust stable toolchain: required for the Tauri desktop host. Install it with rustup.
  • Network access for setup: the first install downloads npm packages and Rust crates.
  • Local disk space: leave enough space for dependencies, Rust/Tauri build artifacts, and your Locium workspace data.

Windows Desktop Build Tools

For the native desktop app on Windows, install Visual Studio Build Tools and include:

  • Desktop development with C++
  • MSVC C++ build tools
  • Windows 10 or Windows 11 SDK
  • WebView2 Runtime, if it is not already installed on your system

Recommended Checks

After installing the tools, confirm they are available in your terminal:

node -v
npm -v
git --version
rustc --version
cargo --version

Locium expects node -v to report v24.x or newer.

Manual Start

Install dependencies:

npm install

Build and type-check the workspace:

npm run build

Run the desktop app in development mode:

npm run desktop:dev

Build the desktop web bundle without launching the native shell:

npm run desktop:check

Run the Tauri/Rust check from the desktop host folder:

cd apps/desktop/src-tauri
cargo check

Distribution Contents

  • apps/desktop/: React + Tauri desktop shell
  • apps/daemon/: local sidecar daemon, desktop host bridge, and MCP server entry points
  • packages/domain/: shared domain types and contracts
  • packages/workspace/: workspace bootstrap and filesystem layout
  • packages/journal/: append-only event journal
  • packages/import-pipeline/: source import and normalization
  • packages/sync-engine/: durable write gate and projection orchestration
  • packages/graph-store/: graph projection and query support
  • packages/retrieval/: human browse and AI recall retrieval logic
  • packages/wiki-patcher/: wiki update logic with user-text preservation
  • packages/mcp-gateway/: MCP tool contracts and gateway behavior
  • packages/history/: checkpoint, diff, and restore support
  • packages/local-model-*, packages/model-*, packages/providers/: local model inventory, prompts, routing, catalog, and provider adapters
  • scripts/windows/: Windows launch helper used by Launch-Locium.cmd
  • assets/: README screenshots
  • Launch-Locium.cmd: one-click Windows launcher

License

Locium is released under the MIT License.

About

Local-first memory system for people and AI agents.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages