dynamic-memory-cli

Manage atomic Pending and Built agent memory with SQLite-backed publication, search, and validation.

7.1k|1.1k|Updated Mar 5, 2026
One-click install
npx skills add https://github.com/openJiuwen-ai/jiuwenswarm --skill dynamic-memory-cli
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: dynamic-memory-cli
Source: https://github.com/openJiuwen-ai/jiuwenswarm/tree/main/jiuwenswarm/resources/agent/workspace/skills/dynamic-memory-cli
Command: npx skills add https://github.com/openJiuwen-ai/jiuwenswarm --skill dynamic-memory-cli

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) components.

What problem does it solve?

Long-running agent conversations need durable memory that stays searchable while extraction happens asynchronously, without corrupting state or losing continuity across sessions.

Core Features & Use Cases

  • Atomic Pending Publication: Commit Snapshot, UT changes, and history cursor in one transaction so published memory is immediately searchable.
  • Merged Pending/Built Search: Query memory with lexical scoring where current Pending content shadows stale Built artifacts.
  • Deterministic Build Pipeline: Freeze exact-content batches, build them into a stable index, and gate them with Built-only validation tests.
  • Use Case: An agent Harness extracts memory from an eternal conversation in the background, publishes Pending UTs the foreground can search right away, then a builder agent migrates them into a validated Built index.

Quick Start

Initialize a memory project with the dynamic memory CLI, publish a proposal file containing your Snapshot and UT changes, then run a search query to retrieve the published memories.

Frequently Asked Questions about dynamic-memory-cli

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I publish agent memory that is immediately searchable?

Submit a proposal with the publish-pending command containing the Snapshot, changed UTs, evidence references, and cursor range. The CLI commits everything in one SQLite transaction, and published Pending UTs participate in search right away.

How do I build Pending memory into a stable index?

Run freeze-pending to write an exact-content batch file, have a builder agent review it, then run build-pending with that file. The build validates every UT query against Built-only search and rolls back on any failure.

What happens when a memory proposal is based on stale revisions?

The CLI rejects stale proposals whose base memory or snapshot revision no longer matches current state. The extraction agent must regenerate the proposal against the current revisions and cursor before retrying.

Can I edit the memory SQLite database directly?

No, the contract forbids editing memory.sqlite3 manually. All changes must go through CLI commands like publish-pending, update, or retire so schema validation, transactions, and cursor continuity are enforced.

Why does build-pending skip some frozen memory items?

An item is skipped if its content hash changed since freezing or it is no longer in Pending state, ensuring the Built index only contains exact-content representations. Skipped items remain Pending and searchable.