openclaw-engram / src
AGENTS.md231 starsChanged 8 months agoMITView on GitHub
This directory contains the TypeScript source for the openclaw-engram plugin. Active sequencing and contributor priority live in the GitHub Project: Use the project for current order/blockers, then read the relevant historical design doc before changing these surfaces: See AGENTS.md (root) for the full list. Key reminders: After any change to this directory:
We split this AGENTS.md into the rules it gives an agent
2 rules. About 0 are common, 2 are distinctive, and 0 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈2
Distinctive · estimate
This author's own choices. Worth a look.
0
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 11
Use the project for current order/blockers, then read the relevant historical design doc before changing these surfaces:
- Distinctive: line 69
After any change to this directory:
≈ “Common” is an estimate: at least 1 in 5 of the 36,368 AGENTS.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Source Directory — Agent Guide
This directory contains the TypeScript source for the openclaw-engram plugin.
Active Development References
Active sequencing and contributor priority live in the GitHub Project:
Use the project for current order/blockers, then read the relevant historical design doc before changing these surfaces:
orchestrator.ts— seedocs/plans/README.mdand the relevant v8 design docs underdocs/plans/graph.ts— seedocs/plans/2026-02-22-v8.2-pr18-graph.mdtmt.ts— seedocs/plans/2026-02-22-v8.2-tree-graph-design.md
Critical Invariants (enforce in all changes)
See AGENTS.md (root) for the full list. Key reminders:
- Recall pipeline order is a contract — retrieve → filter → rerank → cap → format. Never cap before filter.
- Artifact isolation —
artifacts/paths must never appear in generic QMD recall. no_recallgates everything — when planner returnsno_recall, skip all retrieval paths.- Config
0means0— never coerce zero limits to non-zero values. - OpenAI Responses API only — never use Chat Completions anywhere in this directory.
- Procedural memory (issue #519) — Shipped off until
procedural.enabledistruein plugin config. Seedocs/procedural-memory.mdbefore changing procedure extraction, recall injection, or mining.
File Ownership
| File | Purpose | Stability |
index.ts | Plugin entry point; hook registration | Stable |
config.ts | Config parsing with defaults | Stable |
types.ts | Shared TypeScript interfaces | Stable (add, don't remove) |
logger.ts | Logging wrapper | Stable |
storage.ts | File I/O for memories (markdown + YAML) | Stable |
buffer.ts | Smart turn accumulation | Stable |
extraction.ts | GPT extraction engine | Stable |
retrieval.ts | Recall pipeline implementation | Stable |
qmd.ts | QMD search client | Stable |
intent.ts | Intent heuristics (morphology-aware) | Stable |
signal.ts | Signal-based flush triggers | Stable |
importance.ts | Zero-LLM importance scoring | Stable |
himem.ts | Episode/Note classification (v8.0) | Active development |
boxes.ts | Memory Box builder + Trace Weaver (v8.0) | Active development |
orchestrator.ts | Core coordination | Active development (v8.2) |
tools.ts | Agent-callable tool implementations | Stable |
cli.ts | CLI command implementations | Stable |
extraction-judge.ts | LLM-as-judge fact-worthiness gate (#376) | Stable |
semantic-chunking.ts | Topic-boundary chunking (#368) | Stable |
page-versioning.ts | Snapshot-based version history (#371) | Stable |
source-attribution.ts | Citation/attribution helpers (#379) | Stable |
enrichment/ | External enrichment pipeline (#365) | Stable |
binary-lifecycle/ | Binary file management (#367) | Stable |
taxonomy/ | MECE taxonomy resolver (#366) | Stable |
memory-extension/ | Extension publisher contract (#381, #382) | Stable |
memory-extension-host/ | Extension host discovery (#381) | Stable |
recall-mmr.ts | Maximal marginal relevance reranking | Stable |
recall-qos.ts | Recall quality-of-service | Stable |
recall-audit.ts | Recall audit trail | Stable |
session-integrity.ts | Session integrity checks | Stable |
session-toggles.ts | Per-session feature toggles | Stable |
compat/ | Provider compatibility checks | Stable |
dedup/ | Deduplication engine | Stable |
curation/ | Memory curation pipeline | Stable |
Testing
After any change to this directory:
npm run check-types # TypeScript strict check
npm run check-config-contract # Config schema alignment
npm run preflight:quick # Fast test gate
npm run test:entity-hardening # Required for orchestrator/storage/intent/cache/retrieval/config edits
npm test # Full suiteNew logic in any file above requires corresponding tests in tests/.
Other versions1 project uses a version of this.
Word for word · 1
- joshuaswarren/remnic★ 231100% same
Edited · 0
None found.
Wrote their own version · 0
None found.
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
Where files are headingNew AGENTS.md files have more rules about keeping secrets out of the code, and fewer about code style.
Of the AGENTS.md files we read, the 28,693 first seen in the last six months, against the older ones: the kind of rule that gained most share, and the kind that lost most. About files like this in general, not this one, and an estimate, since a kind is a pattern in the words.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
Reviews can't be read right now.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

