Skip to content

About

Wikipedia-style, fully editable browser for OpenClaw agent memory. Local-only, reads/writes ~/.openclaw/ directly.

Topics

Resources

Stars

1 star

Watchers

0 watching

Forks

Latest commit

 

History

7 Commits

Folders and files

Repository files navigation

OpenClaw Wiki

A Wikipedia-style, fully editable browser for the memory of your OpenClaw agents. Runs entirely on your own machine, reads and writes directly to ~/.openclaw/, never phones home.

Home page

OpenClaw's agents accumulate a lot of memory — daily dream diaries, identity files, extracted chunks with embeddings, memory-palace pages synthesized from session history. All of it lives as markdown and SQLite inside ~/.openclaw/, but it's not designed to be read by a human.

This project renders that memory like an encyclopedia: article pages with summaries, a table of contents, wikilinks between articles, a "What links here" backlinks panel, search, categories, and — unlike a typical memory-viewer — a built-in editor so you can curate, correct, and expand the wiki by hand.


Screenshots

Article view — TOC, body with auto-wikilinks, "What links here" panel.

Article

Editor — split-pane markdown with live preview; safe writes leave a .bak-<ts> next to every save.

Editor

Setup & config — installed version, gateway health, models, plugins, skills (with bin/env checks), cron jobs, dependencies.

Setup

Search — hybrid keyword + FTS5 search with snippet highlighting across every memory source.

Search


Features

Feature Notes
Article pages Wikipedia-style layout with TOC, summary, categories, "What links here"
Auto-wikilinks Plain-text mentions of known article titles are linked automatically
Full-text search FTS5 over memory chunks + title/body scoring, snippet highlighting
Live editor Split-pane markdown editor with live preview, unsaved-changes warning
Create pages New wiki pages land under agents/<agent>/memory/wiki/<slug>.md
Safe writes Every save leaves a timestamped .bak-<ts> next to the file
Soft delete Removed pages are moved to memory/.trash/, never unlinked
Multi-agent Every agent's memory is indexed, filterable by namespace + agent
Filter / sort / group URL-backed filters: sort A–Z, recent, agent, namespace; group by namespace/agent/letter; editable-only toggle
Setup & config viewer One page showing installed version, gateway health, models, agents, channels, plugins, skills with requirement checks, cron jobs with last/next run, extensions, and dependency status
Live reload chokidar watches the filesystem; the catalog rebuilds on change
Local-only Binds 127.0.0.1; no auth because nothing leaves your loopback

Namespaces

Memory is organized into Wikipedia-like namespaces so you can tell at a glance what kind of page you're looking at.

Namespace Source Editable?
Main agents/<id>/memory/wiki/*.md (Memory Palace) ✅ edit, create, delete
Identity agents/<id>/IDENTITY.md, SOUL.md, USER.md, etc. ✅ edit only
Diary agents/<id>/memory/*.md (dream diary) 🔒 read-only (journal)
Chunk memory/<agent>.sqlite → chunks table 🔒 read-only (synthesized)

Diary and Chunk are read-only by design: Diary entries are timestamped journal records, and chunks are regenerated by OpenClaw's embedding pipeline, so editing them would be erased on the next dreaming cycle.


Quick start

Requires Node.js 18+ and a running OpenClaw install at ~/.openclaw.

git clone https://github.com/Noopy420/openclaw-wiki.git
cd openclaw-wiki
npm install
npm run build     # builds the frontend once
npm start         # serves http://127.0.0.1:4700

Open http://127.0.0.1:4700 in your browser.

Development mode

npm run dev

Runs the backend on :4700 and a Vite dev server on :4701 with hot reload. Vite proxies /api/* to the backend.


Configuration

All configuration is via environment variables. None are required.

Variable Default Purpose
OPENCLAW_HOME ~/.openclaw Root of the OpenClaw data directory
WIKI_PORT 4700 HTTP port
WIKI_HOST 127.0.0.1 Bind address — keep on loopback, memory is private
WIKI_CACHE_DIR ~/.openclaw/.wiki-cache Reserved for future materialized cache

Example (PowerShell):

$env:WIKI_PORT = 5000
$env:OPENCLAW_HOME = "D:\openclaw-data"
npm start

Enable the Memory Palace

For the best experience, enable OpenClaw's memory-wiki plugin so the gateway synthesizes curated wiki pages from the dream diary. In ~/.openclaw/openclaw.json:

"plugins": {
  "entries": {
    "memory-wiki": { "enabled": true }
  },
  "allow": ["memory-wiki", "..."]
}

Then restart the gateway (openclaw doctor --fix or openclaw). OpenClaw Wiki will pick up the new pages automatically via its file watcher — you don't need to restart it.


Editing

On any editable article, click Edit in the top-right. You'll get a split-pane editor:

  • Left pane: raw markdown
  • Right pane: live preview, including wikilink resolution

Every save:

  1. Writes a timestamped backup (<file>.md.bak-2026-04-23T04-36-06-216Z)
  2. Overwrites the original file atomically
  3. Rebuilds the article catalog so the UI reflects the new state

Wikilinks

Use Wikipedia-style double-bracket syntax inside your markdown. The left side is the target article id; the right side (optional) is the display label:

See also [[main.gordon.pizza-preferences|Gordon's pizza rules]].

Plain-text mentions of known article titles are auto-linked at render time, so you usually don't need to write [[…]] manually — it's there for when you want to disambiguate.

Creating new articles

Click Create new article in the sidebar. Pick the owning agent, give the article a title, and optionally seed it with some initial markdown. The file is written to agents/<agent>/memory/wiki/<slug>.md.

Deleting

Articles in the Main namespace can be deleted from the editor. The file is moved to memory/.trash/ (never actually unlinked), so recovering from a misclick is just a mv away.


Setup & config viewer

Navigate to Setup & config in the sidebar (or visit http://127.0.0.1:4700/setup) for a single-page dashboard showing:

  • Installed OpenClaw version vs. the version that last touched the config
  • Gateway health: is it reachable on its configured port, auth mode, bind address, control-UI origins, and whether device auth is disabled
  • Models: every provider, their API key status (masked), every defined model, and which one is the primary vs. fallback. Flags any referenced model that isn't actually defined in models.providers
  • Agents: the union of agents declared in config and agents present on disk, with their workspace paths
  • Channels: Discord/Telegram/etc. — enabled, token status, guild count
  • Plugins: whether each one will actually load (enabled ∧ in allowlist), and whether it has a config block
  • Skills: scans openclaw/skills/*/SKILL.md, parses the frontmatter, and reports for each skill whether required binaries are on PATH and whether required env vars / API keys are set. Filter by name
  • Cron jobs: each job's schedule, last run time, last status, next run time, duration, and delivery target
  • Extensions: whether Python-based extensions have a built venv
  • Dependencies: better-sqlite3, node, python — installed or not, with howToFix hints when something's missing

All read-only — it just reports what's on disk and what the gateway responds with. Nothing is written.

Filtering & organizing articles

The home page has a filter bar with:

  • Full-text filter — narrow by title/summary substring
  • Sort — title A-Z, title Z-A, recently updated, oldest, agent, namespace
  • Group by — flat list, namespace, agent, or first letter (Wikipedia-style alphabetical index)
  • Agent — show only articles from one agent
  • Namespace — show only Main / Diary / Identity / Chunk
  • Editable only — hide synthesized and read-only pages

All filter state is stored in the URL, so bookmarks and links preserve your current view.

API reference

Everything the frontend does is available as a JSON API on :4700.

Read

GET  /api/status                       aggregate counts, agents, namespaces
GET  /api/articles                     ?namespace= &agent= &category=
GET  /api/articles/:id                 full article (markdown + rendered + sections + backlinks)
GET  /api/articles/:id/raw             raw markdown source
GET  /api/articles/:id/backlinks       { backlinks: [{id, title, namespace}] }
GET  /api/search?q=                    hybrid keyword + FTS5 search
GET  /api/categories                   [{name, count}] sorted by count
GET  /api/recent                       most recently updated articles
GET  /api/random                       { id } — random article
GET  /api/agents                       [agent, ...] for the create form
GET  /api/setup                        full config/state snapshot for the setup page

Write

PUT    /api/articles/:id       body: {content}          overwrite markdown
POST   /api/articles           body: {agent, title, content?}   new page
DELETE /api/articles/:id                                 move to .trash/
POST   /api/reindex                                      force a catalog rebuild

Write endpoints refuse to touch anything outside OPENCLAW_HOME and will 403 if the target article is in a read-only namespace.


Architecture

server/
├── config.mjs     env + paths
├── sources.mjs    read markdown + SQLite chunks
├── articles.mjs   normalize sources into Article model, build catalog
├── wikilinks.mjs  entity index + [[wikilink]] injection
├── search.mjs     hybrid keyword search
├── editor.mjs     safe writes: save / create / delete
├── setup.mjs      config + skills + cron + deps inspector (read-only)
├── routes.mjs     REST endpoints
└── index.mjs      Fastify server + chokidar watcher

web/
├── index.html
├── vite.config.js
└── src/
    ├── main.jsx              router bootstrap
    ├── App.jsx               routes table
    ├── api.js                thin fetch wrapper
    ├── styles.css            Wikipedia-Vector-inspired theme
    ├── components/
    │   ├── Layout.jsx        header, sidebar, footer
    │   ├── SearchBar.jsx
    │   ├── ArticleBody.jsx   markdown renderer + wikilink resolution
    │   └── TableOfContents.jsx
    └── pages/
        ├── Home.jsx          front page + filter/sort/group toolbar
        ├── Article.jsx       read view
        ├── Edit.jsx          split-pane editor
        ├── Create.jsx        new-article form
        ├── Setup.jsx         OpenClaw setup/config dashboard
        ├── Search.jsx
        ├── Category.jsx
        ├── Recent.jsx
        ├── Random.jsx
        └── NotFound.jsx

The catalog lives in-memory and is rebuilt whenever a source file changes (debounced 500ms). The rebuild traverses the agents directory, reads all markdown + SQLite chunk groups, normalizes them into Article objects, builds an entity index over article titles, and does a second pass to inject wikilinks and compute backlinks.

For small-to-medium memory stores (a few thousand articles) this is near-instant. For very large stores, the plan is to materialize the catalog to wiki.sqlite — see the roadmap below.


Security

  • The server binds 127.0.0.1 only. Do not expose it to a network — it renders and edits private agent memory with no access control.
  • SQLite is opened readonly: true, fileMustExist: true.
  • Write endpoints refuse paths outside OPENCLAW_HOME, refuse namespaces that aren't explicitly editable, and always write a backup before overwriting.
  • Deletes are soft (move to .trash/).

Optional: SQLite chunks source

The Chunk namespace requires better-sqlite3, which wraps the native SQLite C library. It's declared as an optionalDependency so npm install never fails because of it — if it's missing, you just lose that namespace.

The package ships prebuilt binaries for common Node versions:

  • Node 18 / 20 / 22: works out of the box with better-sqlite3 11.x.
  • Node 24: needs better-sqlite3 12.x or later (12.x added prebuilt Windows binaries for Node 24). This repo targets ^12.9.0.

If you hit a build error mentioning Visual Studio, it means npm fell back to compiling from source. Either:

  1. Upgrade better-sqlite3 (npm install better-sqlite3@latest), or
  2. Install Visual Studio Build Tools with the "Desktop development with C++" workload so the source build can complete.

The Setup & config page shows live dependency status — check there first if the Chunk namespace doesn't appear.


Roadmap

  • Semantic search via sqlite-vec (embeddings are already on disk)
  • Interactive knowledge graph view (Cytoscape/D3 force-directed)
  • LLM-synthesized articles that cluster raw chunks into topical pages when the memory-wiki plugin hasn't curated any
  • History diff viewer using chunks.updated_at or the .bak-* files
  • Per-agent color palette so multi-agent setups read at a glance
  • Orphans / dead-links / wanted-pages "special pages" like Wikipedia
  • Markdown editor upgrade to CodeMirror for syntax highlighting + folding

License

MIT — see LICENSE.

About

Wikipedia-style, fully editable browser for OpenClaw agent memory. Local-only, reads/writes ~/.openclaw/ directly.

Topics

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages