Skip to content
JanYork edited this page Aug 14, 2026 · 1 revision

LWC — Proactive Memory for AI Agents

Language: English · 简体中文

LWC — Proactive Memory for AI Agents

LWC is an agent-driven proactive memory CLI. It helps AI agents recall, maintain, and evolve persistent, source-grounded knowledge across sessions.

Instead of rebuilding an answer from raw document chunks every time, an agent can use LWC to maintain a durable Wiki of sources, pages, citations, links, decisions, and history. The Wiki gets more useful as the agent integrates new evidence and preserves verified conclusions.

Start here

  • Project overview — what LWC solves, who it is for, and what it deliberately does not do.
  • Basic concepts — sources, Wiki pages, provenance, scopes, graphs, Work, and changesets.
  • Use cases — when persistent Agent memory pays off and when a simpler tool is enough.
  • Installation and upgrades — supported installation paths and Agent setup.
  • Quick start — initialize a project, integrate a source, recall knowledge, and verify the result.

What LWC provides

Capability Purpose
Persistent Wiki Keeps maintained knowledge instead of disposable chat answers.
Source grounding Preserves immutable source snapshots, citations, provenance, and contradictions.
Bounded recall Searches compiled pages first and opens exact source evidence only when needed.
Document knowledge graph Traverses page, source, citation, link, and explicit semantic relationships.
CodeGraph Answers structural questions about symbols, callers, callees, dependencies, and impact.
Word Graph Explores shared terms across a bounded document sample without loading the entire token graph.
Strong tags Loads a small, explicit set of complete core pages without relying on search.
Agent integration Installs the LWC MCP, Skill, Hooks, and Instructions through host-specific AgentTarget adapters.
Safe change lifecycle Uses changesets, checkpoints, durable Work, lint, and graph verification for recoverable maintenance.

Core principles

  • Agent-operated: LWC is a machine interface for agents. People choose sources, goals, and review boundaries; agents handle the bookkeeping.
  • Local-first: SQLite is canonical. Markdown and optional graph stores are rebuildable local projections.
  • Source-grounded: Evidence remains immutable, while maintained pages can be revised as knowledge changes.
  • Explicitly scoped: Project memory stays with the project. Reusable cross-project knowledge belongs in global memory.
  • Auditable: Successful commands return JSON on standard output; failures return structured JSON on standard error.
  • Consent-aware: Optional graph initialization and external integrations are never silently enabled.

Project links

Next: Project overview

LWC Wiki

English · 简体中文


Start here · 开始使用

Core capabilities · 核心能力

Practical guides · 实战指南

Capability configuration · 能力配置

Technical design · 技术设计

Operations · 运行与维护

Reference · 参考资料

Contributing · 参与贡献


Repository · Releases

Clone this wiki locally