← Back to Skills Marketplace
x3r081

Agent Memory Optimizer

by x3r081 · GitHub ↗ · v1.0.0 · MIT-0
cross-platform ✓ Security Clean
77
Downloads
0
Stars
0
Active Installs
1
Versions
Install in OpenClaw
/install agent-memory-optimizer
Description
Archives older daily memory notes into month folders to keep active memory lean and reduce prompt token usage. Use when users want lower token overhead, clea...
README (SKILL.md)

Agent Memory Optimizer

Optimize active memory context by archiving old daily notes into month-based folders.

What it does

  • Scans memory/*.md
  • Moves files older than the current month into memory/archive/YYYY-MM/
  • Supports --dry-run to preview changes
  • Safe to run repeatedly

Run

python3 scripts/agent_memory_optimizer.py --dry-run
python3 scripts/agent_memory_optimizer.py

Optional custom cutoff:

python3 scripts/agent_memory_optimizer.py --before 2026-05

Installation

Install into your workspace skills directory:

\x3Cworkspace>/skills/agent-memory-optimizer/

Or install from ClawHub after publishing.

Usage Guidance
This skill appears to do what it says and only operates on local files, but review these points before installing: (1) Default memory directory is ~/.openclaw/workspace/memory — confirm that this is the folder you want to affect or pass --memory-dir. (2) Run with --dry-run first to preview changes. (3) The script will delete an existing destination file (dst.unlink()) before moving a source file, so if you have files with identical names in archive folders the existing archived file will be overwritten; back up if that is a concern. (4) The tool only moves files whose names match YYYY-MM(-DD).md; files not matching that pattern are ignored. (5) No network calls or credentials are used. If you require additional guarantees, inspect the included scripts yourself or run in a test workspace first.
Capability Assessment
Purpose & Capability
Name/description match the included script and SKILL.md: the tool scans a local memory directory for YYYY-MM(-DD).md filenames and moves files older than the cutoff into memory/archive/YYYY-MM/. The only required binary is python3, which is appropriate.
Instruction Scope
The SKILL.md tells the agent to run the included Python script (with an optional --dry-run). The instructions operate only on the local memory directory (default ~/.openclaw/workspace/memory) and do not request other files, env vars, or external endpoints.
Install Mechanism
There is no install spec; this is an instruction-only skill with an included script. Nothing is downloaded or installed automatically, so no additional install risk is introduced.
Credentials
The skill requires no environment variables or credentials. Its default path is a user-local workspace directory, which is appropriate for its purpose.
Persistence & Privilege
The skill is not always-enabled and does not modify other skills or system-wide settings. It runs only when invoked and acts on the specified local files.
How to Use
  1. Make sure OpenClaw is installed (local or Docker)
  2. Run the install command in chat: /install agent-memory-optimizer
  3. After installation, invoke the skill by name or use /agent-memory-optimizer
  4. Provide required inputs per the skill's parameter spec and get structured output
Version History
v1.0.0
- Initial release of Agent Memory Optimizer. - Archives outdated daily memory notes into organized month-based folders. - Reduces prompt token usage by minimizing active memory file clutter. - Includes dry-run support to preview archiving actions safely. - Easy installation and compatible with standard Python3 environments.
Metadata
Slug agent-memory-optimizer
Version 1.0.0
License MIT-0
All-time Installs 0
Active Installs 0
Total Versions 1
Frequently Asked Questions

What is Agent Memory Optimizer?

Archives older daily memory notes into month folders to keep active memory lean and reduce prompt token usage. Use when users want lower token overhead, clea... It is an AI Agent Skill for Claude Code / OpenClaw, with 77 downloads so far.

How do I install Agent Memory Optimizer?

Run "/install agent-memory-optimizer" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.

Is Agent Memory Optimizer free?

Yes, Agent Memory Optimizer is completely free, licensed under MIT-0. You can download, install and use it at no cost.

Which platforms does Agent Memory Optimizer support?

Agent Memory Optimizer is cross-platform and runs anywhere OpenClaw / Claude Code is available (cross-platform).

Who created Agent Memory Optimizer?

It is built and maintained by x3r081 (@x3r081); the current version is v1.0.0.

💬 Comments