← 返回
开发者工具 中文

Minimal Memory

Maintain organized agent memory by tagging entries as GOOD, BAD, or NEUTRAL, storing essentials in MEMORY.md and daily logs for efficient search and cleanup.
通过将条目标记为 GOOD、BAD 或 NEUTRAL,并将要点存储于 MEMORY.md 及每日日志中,保持智能体记忆有序,便于高效检索与清理。
zencrust-ai zencrust-ai 来源
开发者工具 clawhub v1.0.0 1 版本 99922.2 Key: 无需
★ 0
Stars
📥 1,284
下载
💾 16
安装
1
版本
#latest

概述

Minimal Memory Management

Keep agent memory lean, searchable, and actionable through structured categorization and two-tier storage.

Core Principle

MEMORY.md = Long-term essentials (GOOD/BAD learnings only)

memory/YYYY-MM-DD.md = Daily operations (GOOD/BAD/NEUTRAL tagged)

Information Categorization

Tag every memory entry with its value:

TagMeaningKeep in MEMORY.md?Example
------------------------------------------
[GOOD]Worked well, repeat✅ Yes[GOOD] CSV batch format prevents duplicates
[BAD]Failed, avoid✅ Yes[BAD] Bird CLI blocked by X anti-automation
[NEUTRAL]Facts, context, state❌ No[NEUTRAL] Day 5 of 30-day media plan

Writing Rules

  1. Always tag new entries in daily files
  2. Be specific: What worked/failed and why
  3. One tag per entry - pick the strongest category
  4. NEUTRAL expires: Archive after 30 days unless promoted to GOOD/BAD

What Goes Where

MEMORY.md (Categorized Learnings)

Keep under 150 lines. Only GOOD and BAD entries:

## GOOD - What Works
- `[GOOD]` Cron jobs with CSV batching = zero duplicates
- `[GOOD]` Browser tool > CLI for X.com automation
- `[GOOD]` Moltbook "crypto" submolt for token posts

## BAD - What to Avoid  
- `[BAD]` Never use bird CLI for X (anti-bot blocks it)
- `[BAD]` Don't post identical content across platforms

memory/YYYY-MM-DD.md (Daily Log)

All three categories with full context:

# 2026-02-15

## [GOOD]
- Fixed duplicate posting with 4-batch CSV structure
- Created 10 cron jobs for complete automation

## [BAD]  
- Old CSV format caused content duplication (now deprecated)

## [NEUTRAL]
- Day 5 of 30-day media plan
- Posted $ZEN token shill at 07:00 batch

Quick Commands

Search Memory

# Search all memory files
~/.openclaw/skills/minimal-memory/scripts/search.sh "duplicate posting"

# Search only GOOD learnings
~/.openclaw/skills/minimal-memory/scripts/search.sh --good "CSV"

# Search only BAD learnings  
~/.openclaw/skills/minimal-memory/scripts/search.sh --bad "CLI"

# Recent entries only (last 7 days)
~/.openclaw/skills/minimal-memory/scripts/search.sh --recent "cron job"

Daily Memory

# Create today's memory file with template
~/.openclaw/skills/minimal-memory/scripts/daily.sh

# Add entry with auto-tagging
~/.openclaw/skills/minimal-memory/scripts/add.sh GOOD "Browser tool works better than CLI"

Cleanup

# Review and migrate GOOD/BAD to MEMORY.md
~/.openclaw/skills/minimal-memory/scripts/cleanup.sh

# Archive old NEUTRAL entries (>30 days)
~/.openclaw/skills/minimal-memory/scripts/archive.sh

Workflow

When Writing a Memory

  1. Tag it: Is this GOOD, BAD, or NEUTRAL?
  2. Write to daily file with tag prefix
  3. Weekly review: Promote GOOD/BAD to MEMORY.md
  4. Archive NEUTRAL after 30 days

When Searching

  1. Use search script for fast grep across all files
  2. Check MEMORY.md first for established patterns
  3. Fall back to daily files for specific context
  4. Prefer recent entries unless looking for historical

Weekly Cleanup

  1. Read last 7 days of daily files
  2. Extract [GOOD] and [BAD] entries
  3. Add to MEMORY.md "GOOD" and "BAD" sections
  4. Remove duplicates, condense similar items
  5. Ensure MEMORY.md < 150 lines

Anti-Patterns

Don't skip tagging - every entry needs a category

Don't put NEUTRAL in MEMORY.md

Don't let MEMORY.md grow past 200 lines

Don't keep NEUTRAL entries forever (30 day max)

Don't create topical files - use daily + search

Do search before asking user "did we try this?"

Do migrate GOOD/BAD weekly

Do be specific in failure/success descriptions

Do trust the search script to find context

Migration from Old System

If MEMORY.md has untagged content:

  1. Read entire MEMORY.md
  2. Categorize each entry: GOOD/BAD/NEUTRAL
  3. Move NEUTRAL to appropriate daily file
  4. Keep GOOD/BAD in MEMORY.md with tags
  5. Future entries: always tag in daily files first

版本历史

共 1 个版本

  • v1.0.0 当前
    2026-03-29 06:49 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

ai-agent

Skill Vetter

spclaudehome
AI智能体技能安全预审工具。安装ClawdHub、GitHub等来源技能前,检查风险信号、权限范围及可疑模式。
★ 1,232 📥 268,321
ai-agent

self-improving agent

pskoett
捕获经验教训、错误及修正内容,以实现持续改进。适用于以下场景:(1)命令或操作意外失败;(2)用户纠正Claude(如“不,那不对……”“实际上……”);(3)用户请求的功能不存在;(4)外部API或工具出现故障;(5)Claude发现自身
★ 4,086 📥 814,886
ai-agent

ontology

oswalpalash
类型化知识图谱,用于结构化智能体记忆与可组合技能。适用于以下场景:创建/查询实体(人物、项目、任务、事件、文档)、关联相关对象、强制执行约束、将多步操作规划为图谱变换,或当技能需要共享状态时。触发关键词包括"记住""我知道关于什么""将X链
★ 722 📥 245,167