Code Pluginsource linked

Memrokv0.5.0

Memory with judgment. A graph-based curation layer for OpenClaw, complementing built-in recall and dreaming with explicit supersession, expiry, and topic-aware selection.

memrok·runtime memrok·by @michaelschmidle
Community code plugin. Review compatibility and verification before install.
openclaw plugins install clawhub:memrok
Latest release: v0.5.0Download zip

Capabilities

configSchema
Yes
Executes code
Yes
HTTP routes
0
Plugin kind
context-engine
Runtime ID
memrok

Compatibility

Built With Open Claw Version
2026.4.1
Min Gateway Version
2026.3.24-beta.2
Plugin Api Range
>=2026.3.24-beta.2
Plugin Sdk Version
2026.3.24-beta.2
Security Scan
VirusTotalVirusTotal
Benign
View report →
OpenClawOpenClaw
Benign
high confidence
Purpose & Capability
Name/description (graph-based memory curation) match the actual behavior: watches OpenClaw transcripts, persists a local SQLite DB (~/.memrok/memrok.db), derives artifacts via 'scribes', manages supersession/expiry, and injects working-set headers. Declared dependencies (better-sqlite3, chokidar) and file access patterns are expected for this functionality and no unrelated cloud credentials or unrelated binaries are requested.
Instruction Scope
SKILL.md and the bundled system prompts explicitly describe watching session transcript directories, optional bootstrap scanning of workspace Markdown, and running transcript + reflective scribe passes that extract and synthesize knowledge. This scope matches the purpose, but it does include filesystem scanning (watchPaths, optional bootstrap memoryDir/memoryIndex) and the scribe prompts require including transcript evidence (verbatim quotes) which can surface sensitive text in model calls. The skill documentation does call out these risks and provides controls (bootstrap disabled by default, narrow watchPaths, prefer local models).
Install Mechanism
There is no remote arbitrary-download install spec in the skill bundle (it's instruction-only for openclaw plugin install). The package lists reasonable npm deps (better-sqlite3, chokidar). No suspicious URL downloads or extract steps are present in the provided files.
Credentials
The skill does not require any environment variables or external credentials itself. It relies on the OpenClaw runtime model plumbing (scribeProvider/model) which is appropriate for a plugin that delegates scribe calls to configured model providers. No unrelated credentials or broad environment access are requested in the metadata or SKILL.md.
Persistence & Privilege
The plugin persists a local SQLite DB (~/.memrok/memrok.db), temporary session files under ~/.memrok/tmp/, and a health snapshot file. It registers a background service (daemon) to run scribe passes and reflective passes (configurable; reflection enabled by default). This persistent, background file-watching behavior is expected for a context engine but increases privacy/exfiltration blast radius if you configure a remote scribe provider or enable broad bootstrap watchPaths. 'always' is false, and it does not request system-wide agent config modification beyond its own registration.
Scan Findings in Context
[system-prompt-override] expected: The bundle includes explicit system and reflection prompts (dist/system-prompt.md, dist/reflection-prompt.md) used to direct the scribe/reflective model's behavior. This is expected for a scribe/reflection architecture. Be aware the prompts instruct the model to emit evidence (verbatim quotes) and strict JSON outputs, which is functional but increases the chance that sensitive transcript text will be included in model inputs/outputs when a remote provider is used.
Assessment
This plugin is internally consistent with its stated purpose, but it operates continuously and has access to transcripts and optional workspace markdown. Before installing: 1) Understand that any text it reads can be sent to your configured model provider — only configure remote providers you trust. 2) Keep bootstrap.disabled (default) unless you explicitly want to seed from workspace Markdown. 3) Narrow watchPaths to just the session dirs you expect; avoid giving it broad home/workspace access. 4) Prefer local scribe models if you want low-exfiltration posture and consider disabling the reflective scribe if you want to limit synthesis sent to remote models. 5) Treat ~/.memrok/memrok.db and ~/.memrok/health/status files as sensitive; back them up and protect filesystem permissions. If you want extra assurance, review the plugin's source on GitHub and run it in a sandboxed agent workspace first.

Verification

Tier
source linked
Scope
artifact only
Summary
Validated package structure and linked the release to source metadata.
Commit
907043d1458b
Tag
v0.5.0
Provenance
No
Scan status
clean

Tags

latest
0.5.0

Memrok

Memory with judgment.


Memrok is an open-source plugin for OpenClaw that adds a graph-based memory curation layer on top of OpenClaw’s built-in recall and dreaming systems. It watches your conversations, archives raw observations, derives curation artifacts, and brings relevant context into every interaction as judged, structured memory rather than raw recall.

Why Memrok?

OpenClaw’s built-in memory is getting good at recall, dreaming, promotion, and operator tooling. Memrok is not trying to be Yet Another Memory. Its job is the part that still needs sharper structure and judgment:

  • building and maintaining a graph of durable facts, patterns, decisions, and collaboration dynamics
  • handling supersession, expiry, and stale-node cleanup
  • doing topic-aware selection so the right nodes win for the current conversation
  • surfacing memory as curation and interpretation, not just retrieved snippets

If OpenClaw recall answers “what happened?”, Memrok is trying to answer “what still matters, what changed, and what should win now?”

Memrok runs small "scribe" agents alongside your main assistant that continuously curate what they learn about:

  • You — preferences, context, history
  • The agent — capabilities, learned behaviors, evolved identity
  • Your collaboration — patterns, decisions, what works

All of this data stays on your device. Nothing leaves unless you choose a remote scribe model.

Design Principles

  • Local-first. Your memory lives on your machine in SQLite. Always yours, always portable.
  • Model-agnostic. Swap your main model, swap your scribe model — memory persists through both.
  • Biological, not mechanical. Memrok doesn't consolidate on a timer. It waits for material to accumulate and a quiet moment to think — like how humans process experience.
  • Judged, not just retrieved. The point is not more memory text, but better memory selection, supersession, and expiry.

How It Works

Memrok sits between your conversations and your agent's context window:

  1. Archive — Memrok persists raw observations such as transcript chunks, bootstrap file contents, and reflection inputs
  2. Derive — Scribes process those observations into persisted derived artifacts:
    • A transcript scribe extracts facts, preferences, and patterns in near-real-time
    • A reflective scribe periodically steps back to find deeper insights and meta-patterns
  3. Curate — Derived artifacts update the memory graph, where supersession, expiry, and judged curation live
  4. Inject — On every agent turn, Memrok selects a typed working set from the graph using semantic ranking plus stable structural priors such as topical anchors, renders a header from that working set, and prepends it to the conversation. Working-set traces keep a cheap shortcut back to the latest supporting mutation while full lineage remains in graph history.

The result: your agent starts each session already knowing what matters, with a cleaner provenance trail from raw observation to injected context.

Quick Start

openclaw plugins install clawhub:memrok

Then activate Memrok as your context engine. Add to your openclaw.json (or use openclaw config):

{
  "plugins": {
    "slots": {
      "contextEngine": "memrok"
    },
    "entries": {
      "memrok": {
        "enabled": true,
        "config": {
          "scribeProvider": "openai",
          "scribeModel": "gpt-5-mini",
          "reflection": {
            "provider": "openai",
            "model": "gpt-5"
          },
          "bootstrap": {
            "enabled": false
          }
        }
      }
    }
  }
}

Restart OpenClaw. Memrok watches session transcripts automatically and begins curating after the first idle window.

Set both transcript and reflection provider/model explicitly in the plugin config if you do not want Memrok falling back to its built-in defaults. Bootstrap is now opt-in. Enable it only if you explicitly want Memrok to seed itself from existing Markdown memory files.

Privacy & Data Flow

Memrok is local-first, but not magically offline.

  • Local database: Memrok stores memory in a local SQLite database at ~/.memrok/memrok.db by default.
  • Transcript and file access: it watches OpenClaw session directories and any configured watchPaths. If bootstrap is enabled, it may also scan workspace Markdown files.
  • Default posture: bootstrap is disabled by default; broad file scanning should be an explicit choice.
  • Remote model providers: if you configure a remote provider for scribe passes, transcript and file content will be sent to that provider as part of normal operation.
  • Risk controls: narrow watchPaths, disable bootstrap if you do not want broad file scanning, prefer local models where available, and consider disabling the reflective scribe if you want to minimize exfiltration risk.
  • Operational hygiene: treat ~/.memrok/memrok.db as sensitive data; back it up and secure it accordingly.

Hardened / low-exfiltration posture

If you want a stricter setup:

  • set scribeProvider / scribeModel to a local provider when possible
  • keep bootstrap.enabled off unless you explicitly need seeding from Markdown files
  • narrow watchPaths to only what Memrok should ingest
  • disable or narrow reflection if you want less model-side synthesis

Architecture

Memrok is a monorepo with clean separation of concerns:

packages/
├── daemon/           → transcript watcher, scribe scheduler, consolidation engine
├── scribe/           → scribe protocol, system prompts, model interface
├── store/            → archive observations, derived artifacts, graph state, working-set traces
├── injector/         → graph selection into typed working sets, then header rendering
└── openclaw-plugin/  → OpenClaw context engine lifecycle (assemble/ingest/compact)

The Two Scribes

Transcript ScribeReflective Scribe
TriggerEvent-driven: delta threshold + idle windowPeriodic (configurable, default nightly)
InputRaw session transcriptsAccumulated graph state
OutputFacts, preferences, patternsInsights, meta-patterns, coaching notes
ModelLightweight (Haiku-class)Capable recommended (Sonnet-class)

Configuration

Most options are optional, but scribe provider/model should be set explicitly through OpenClaw config instead of relying on Memrok-owned defaults.

OptionTypeDefaultDescription
dbPathstringstate dirPath to the SQLite database
scribeProviderstringnoneModel provider for the transcript scribe; set explicitly in OpenClaw config
scribeModelstringnoneModel for the transcript scribe; set explicitly in OpenClaw config
watchPathsstring[]session dirsAdditional transcript paths to watch
bootstrap.enabledbooleanfalseOpt in to seeding from existing Markdown memory files
deltaThresholdnumber20Messages before triggering consolidation
idleMinutesnumber15Quiet time required before scribe runs
tokenBudgetnumber1000Max tokens for injected memory headers
reflection.enabledbooleantrueEnable the reflective scribe
reflection.deltaPassesnumber5Transcript passes between reflections
reflection.cooldownHoursnumber24Minimum hours between reflection runs
reflection.modelstringscribeModelOverride model for reflection; otherwise inherits explicit transcript model
reflection.providerstringscribeProviderOverride provider for reflection; otherwise inherits explicit transcript provider

Status

Deployed as an OpenClaw context engine plugin with dual-scribe architecture. 93 tests across the monorepo.

Memrok also writes a small health snapshot to ~/.memrok/memrok.status.json, including recent transcript-scribe, reflective-scribe, and injection activity plus last error and node count.

For the full technical design, see docs/architecture.md.

License

MIT