
Research
/Security News
OpenAPI React Query Codegen Compromised in Mini Shai-Hulud npm Supply Chain Attack
Ten malicious OpenAPI React Query Codegen versions were published to npm in the Mini Shai-Hulud attack, all with valid provenance.
@plur-ai/core
Advanced tools
Shared memory engine for AI agents — learn, recall, forget, feedback
The engine behind PLUR — persistent memory for AI agents.
You correct your agent on Monday. On Tuesday, it makes the same mistake. PLUR fixes this. Corrections, preferences, and conventions persist across sessions. Your data stays on your disk as plain YAML. Search runs locally with zero API calls.
In our tool-routing and local-knowledge benchmark, Haiku with PLUR memory outperformed Opus without it — 2.6x better on tool routing, at 10x less cost. The bottleneck isn't model intelligence. It's context.
This is the engine that powers everything. Use it directly when you're building your own agent framework or want programmatic control over memory. If you just want to add memory to Claude Code or Cursor, use @plur-ai/mcp instead — it wraps this package as MCP tools.
npm install @plur-ai/core
import { Plur } from '@plur-ai/core'
const plur = new Plur()
// Your agent gets corrected — save it. The engine's read and write methods
// are async: they return promises so a `Plur` can be backed by a network store
// as well as the default local YAML one.
await plur.learn('toEqual() in Vitest is strict — use toMatchObject() for partial matching', {
type: 'behavioral',
scope: 'project:my-app',
domain: 'dev/testing'
})
// Next session: recall what was learned (hybrid search, zero cost)
const results = await plur.recallHybrid('vitest assertion matching')
// Or inject the best engrams into a system prompt, within a token budget
const { directives, consider, tokens_used } = await plur.inject('Write tests for the user service', {
scope: 'project:my-app',
budget: 2000
})
// Rate what was useful — the system improves over time
await plur.feedback(results[0].id, 'positive')
// Sync across machines via git — use a PRIVATE remote: the push contains every
// engram, including visibility:private ones. scope:local engrams are the exception —
// they are machine-specific and stripped from every commit, so they never sync.
await plur.sync('git@github.com:you/plur-memory.git')
Knowledge is stored as engrams — small assertions that strengthen with use and decay when irrelevant, modeled on how human memory works (ACT-R activation). The system gets better over time, not just bigger.
You correct your agent → engram created → YAML on your disk
Next session starts → relevant ones injected → agent remembers
You rate the result → engram strengthens → quality improves
Search is fully local: BM25 over enriched text + BGE-small-en-v1.5 embeddings + Reciprocal Rank Fusion. Zero API calls, zero per-query cost. Benchmark methodology →
Five modes, from fastest to most accurate:
| Method | Speed | API calls | Best for |
|---|---|---|---|
recall(query) | Instant | None | Quick keyword lookup |
recallSemantic(query) | ~200ms | None | Meaning-based search (local embeddings) |
recallHybrid(query) | ~200ms | None | Best default — BM25 + embeddings via RRF |
recallAsync(query, { llm }) | ~1s | 1 LLM call | LLM-assisted semantic filtering |
recallExpanded(query, { llm }) | ~3s | 3-5 LLM calls | Query expansion for exhaustive retrieval |
| Method | What it does |
|---|---|
learn(statement, context?) | Store an engram (correction, preference, convention, decision) |
recall(query, options?) | BM25 keyword search — instant, zero cost |
recallHybrid(query, options?) | BM25 + embeddings merged via RRF — best default |
recallSemantic(query, options?) | Embedding-only search — meaning over keywords |
recallAsync(query, { llm }) | LLM-assisted semantic filtering |
recallExpanded(query, { llm }) | Query expansion + hybrid + RRF merge |
inject(task, options?) | Select engrams for a task within a token budget |
feedback(id, signal) | Rate an engram — trains injection relevance over time |
forget(id, reason?) | Retire an engram (history preserved) |
sync(remote?) | Git-based sync across machines |
syncStatus() | Check sync state without making changes |
capture(summary, context?) | Record a session event to the episodic timeline |
timeline(query?) | Query past episodes by time, agent, or search |
ingest(content, options?) | Extract engram candidates from text via pattern matching |
installPack(source, opts?) | Install a shareable engram pack — scans for secrets (always blocked) and prompt-injection text (blocked unless allowInjection), strips pinned/locked fields |
exportPack(engrams, dir, manifest) | Export engrams as a shareable pack — strips private engrams, feedback signals, and pinned/locked fields |
listPacks() | List installed packs |
status() | System health — counts, storage root, config |
Everything is plain YAML. Open it, read it, edit it, version it.
~/.plur/
├── engrams.yaml # learned knowledge
├── episodes.yaml # session timeline
├── candidates.yaml # pending engrams
├── config.yaml # settings
└── packs/ # installed engram packs
Override the location with PLUR_PATH env var or new Plur({ path: '...' }).
Retrieval (LongMemEval R@5): 76.7% out-of-the-box · 97.0% with openai-3-large embeddings
Agent task impact: Haiku + PLUR outperforms Opus without memory at ~10× less cost. House rules: 12–0 across Haiku, Sonnet, Opus. A/B win rate: 89%.
| Package | For |
|---|---|
@plur-ai/mcp | Claude Code, Cursor, Windsurf (MCP server) |
@plur-ai/claw | OpenClaw (automatic memory plugin) |
FAQs
Shared memory engine for AI agents — learn, recall, forget, feedback
We found that @plur-ai/core demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.

Research
/Security News
Ten malicious OpenAPI React Query Codegen versions were published to npm in the Mini Shai-Hulud attack, all with valid provenance.

Security News
Socket joins more than 100 technology, cybersecurity, and financial organizations calling for a global surge in cyber defense.

Product
Enterprise security teams can now detect malware, credential theft, suspicious network activity, and risky updates across Microsoft Edge extensions.