memory

Append structured memory records to a JSONL file for cross-session recall.

26|2|Updated Dec 23, 2025
One-click install
npx skills add https://github.com/zoubingwu/memory-skill --skill memory-zoubingwu
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: memory
Source: https://github.com/zoubingwu/memory-skill/tree/main/memory
Command: npx skills add https://github.com/zoubingwu/memory-skill --skill memory-zoubingwu

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill provides a simple, reliable long-term memory for AI agents by persisting information across sessions in a single append-only JSONL file, enabling fast retrieval with a recent-window search.

Core Features & Use Cases

  • Append-only JSONL storage: One line per JSON object, easy to backup and inspect.
  • Memory Write & Search: Write new entries, search recent context with a configurable window.
  • Use Case: Remember user preferences or tasks across sessions to reduce repetitive questions.

Quick Start

memory_write(input)

  • Input: {type, content, tags?, meta?}
  • Output: A JSONL file at ~/.codex/memory.jsonl with appended lines. memory_search(q)
  • Input: {q, limit: int=20, window_lines: int=50000}
  • Output: {results: [json objects], truncated: bool, used_window_lines: int}

Frequently Asked Questions about memory

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

FAQPage Schema
How do I persist data across AI agent sessions without a database?

Append-only JSONL storage persists structured records to a single file, enabling reliable cross-session recall. Each line is a complete JSON object, making it easy to backup, inspect, and search without external dependencies.

How do I search recent memory entries efficiently in a large log file?

Recent-window search prioritizes the most recent entries by reading from the tail of the JSONL file and expanding the window exponentially if needed. This approach retrieves relevant context fast without scanning the entire log.

Can I store structured metadata like tags and context with memory records?

Each memory entry accepts type, content, tags, and metadata fields as JSON objects. This structure enables flexible classification, categorization, and retrieval of notes, tasks, or prompts across sessions.

What's the best way to avoid repetitive questions in multi-turn conversations?

Write user preferences and task context to persistent memory after each session, then search that memory at conversation start. This reduces redundant clarifications and maintains continuity across separate interactions.

Does this approach work for high-volume or long-running agent deployments?

Append-only JSONL scales linearly with write volume and supports efficient tail-based reads via configurable window limits. The format is simple and platform-agnostic, suitable for long-term deployments without schema migrations.