惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

L
LangChain Blog
有赞技术团队
有赞技术团队
博客园_首页
IT之家
IT之家
爱范儿
爱范儿
量子位
小众软件
小众软件
Jina AI
Jina AI
WordPress大学
WordPress大学
酷 壳 – CoolShell
酷 壳 – CoolShell
博客园 - 聂微东
The Cloudflare Blog
博客园 - 司徒正美
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
V
V2EX
大猫的无限游戏
大猫的无限游戏
月光博客
月光博客
雷峰网
雷峰网
V
Visual Studio Blog
博客园 - Franky
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
美团技术团队
Last Week in AI
Last Week in AI
S
SegmentFault 最新的问题

Recent Commits to openclaw:main

test: merge chat side-result checks · openclaw/openclaw@ddd2c2a test: merge cron history checks · openclaw/openclaw@f7eb746 test: merge responsive navigation shell checks · openclaw/openclaw@c2e4b47 docs(changelog): add codex oauth fixes · openclaw/openclaw@628e6cd test: merge navigation routing cases · openclaw/openclaw@5d8cecb Tests: mock channel registry bundled fallback · openclaw/openclaw@2b08233 Secrets: avoid broad web search discovery for single plugin config · openclaw/openclaw@a464f59 test: merge config view browser checks · openclaw/openclaw@20cf511 fix(status): align oauth health with runtime · openclaw/openclaw@eed7116 feat: add macOS screen snapshots for monitor preview (#67954) thanks … · openclaw/openclaw@f377db1 fix: report shared auth scopes in hello-ok (#67810) thanks @BunsDev · openclaw/openclaw@0b6c39b Auto-reply: avoid eager bundled route fallback · openclaw/openclaw@3ea1bf4 Tests: narrow session binding contract setup · openclaw/openclaw@54e4e16 fix(macOS): enable undo/redo in webchat composer text input (#34962) · openclaw/openclaw@00951dc Tests: speed up channel setup promotion · openclaw/openclaw@82b529a Docs: refresh agent instructions · openclaw/openclaw@5775fe2 fix(auth): serialize OAuth refresh across agents to fix #26322 (#67876) · openclaw/openclaw@8e79080 test: allow ollama public surface boundary test · openclaw/openclaw@7d4f1a6 Docs: add test performance guardrails · openclaw/openclaw@89706d3 Tests: restore context-engine usage proof · openclaw/openclaw@e4c4f95 Tests: slim context engine runtime coverage · openclaw/openclaw@74c198f ci: retry failed custom checkouts · openclaw/openclaw@0ee5baf test: trim duplicate provider auth onboarding cases · openclaw/openclaw@1ffc02e matrix: fix sessions_spawn --thread subagent session spawning (#67643) · openclaw/openclaw@1ce2596 test: reduce auth choice fixture churn · openclaw/openclaw@857b9cd test: mock health status config boundaries · openclaw/openclaw@9d5ab4a test: mock onboard config io boundary · openclaw/openclaw@299694d test: mock legacy state plugin boundaries · openclaw/openclaw@2713089 test: mock channel install boundaries · openclaw/openclaw@b945248 test: mock doctor preview channel boundaries · openclaw/openclaw@b1a3ad4
docs(memory): clarify memory maintenance expectations · o...
rubencu · 2026-05-10 · via Recent Commits to openclaw:main
Original file line numberDiff line numberDiff line change

@@ -88,7 +88,7 @@ These are the standard files OpenClaw expects inside the workspace:

8888

Daily memory log (one file per day). Recommended to read today + yesterday on session start.

8989

</Accordion>

9090

<Accordion title="MEMORY.md - curated long-term memory (optional)">

91-

Curated long-term memory. Only load in the main, private session (not shared/group contexts). See [Memory](/concepts/memory) for the workflow and automatic memory flush.

91+

Curated long-term memory: durable facts, preferences, decisions, and short summaries. Keep detailed logs in `memory/YYYY-MM-DD.md` so memory tools can retrieve them on demand without injecting them into every prompt. Only load `MEMORY.md` in the main, private session (not shared/group contexts). See [Memory](/concepts/memory) for the workflow and automatic memory flush.

9292

</Accordion>

9393

<Accordion title="skills/ - workspace skills (optional)">

9494

Workspace-specific skills. Highest-precedence skill location for that workspace. Overrides project agent skills, personal agent skills, managed skills, bundled skills, and `skills.load.extraDirs` when names collide.

Original file line numberDiff line numberDiff line change

@@ -23,6 +23,30 @@ Your agent has three memory-related files:

2323
2424

These files live in the agent workspace (default `~/.openclaw/workspace`).

2525
26+

## What goes where

27+
28+

`MEMORY.md` is the compact, curated layer. Use it for durable facts,

29+

preferences, standing decisions, and short summaries that should be available at

30+

the start of a main private session. It is not meant to be a raw transcript,

31+

daily log, or exhaustive archive.

32+
33+

`memory/YYYY-MM-DD.md` files are the working layer. Use them for detailed daily

34+

notes, observations, session summaries, and raw context that may still be useful

35+

later. These files are indexed for `memory_search` and `memory_get`, but they are

36+

not injected into the normal bootstrap prompt on every turn.

37+
38+

Over time, the agent is expected to distill useful material from daily notes

39+

into `MEMORY.md` and remove stale long-term entries. The generated workspace

40+

instructions and heartbeat flow can do that periodically; you do not need to

41+

manually edit `MEMORY.md` for every remembered detail.

42+
43+

If `MEMORY.md` grows past the bootstrap file budget, OpenClaw keeps the file on

44+

disk intact but truncates the copy injected into the model context. Treat that as

45+

a signal to move detailed material back into `memory/*.md`, keep only the

46+

durable summary in `MEMORY.md`, or raise the bootstrap limits if you explicitly

47+

want to spend more prompt budget. Use `/context list`, `/context detail`, or

48+

`openclaw doctor` to see raw vs injected sizes and truncation status.

49+
2650

<Tip>

2751

If you want your agent to remember something, just ask it: "Remember that I

2852

prefer TypeScript." It will write it to the appropriate file.

Original file line numberDiff line numberDiff line change

@@ -179,8 +179,11 @@ All of these files are **injected into the context window** on every turn unless

179179

a file-specific gate applies. `HEARTBEAT.md` is omitted on normal runs when

180180

heartbeats are disabled for the default agent or

181181

`agents.defaults.heartbeat.includeSystemPromptSection` is false. Keep injected

182-

files concise — especially `MEMORY.md`, which can grow over time and lead to

183-

unexpectedly high context usage and more frequent compaction.

182+

files concise, especially `MEMORY.md`. `MEMORY.md` is intended to stay a

183+

curated long-term summary; detailed daily notes belong in `memory/*.md` where

184+

`memory_search` and `memory_get` can retrieve them on demand. Oversized

185+

`MEMORY.md` files increase prompt usage and can be partially injected because of

186+

the bootstrap file limits below.

184187
185188

When a session runs on the native Codex harness, Codex loads `AGENTS.md`

186189

through its own project-doc discovery. OpenClaw still resolves the remaining

@@ -202,6 +205,12 @@ occurs, OpenClaw can inject a concise system-prompt warning notice; control this

202205

default: `once`). Detailed raw/injected counts stay in diagnostics such as

203206

`/context`, `/status`, doctor, and logs.

204207
208+

For memory files, truncation is not data loss: the file remains intact on disk,

209+

but the model only sees the shortened injected copy until it reads or searches

210+

memory directly. If `MEMORY.md` is repeatedly truncated, distill it into a

211+

shorter durable summary and move detailed history into `memory/*.md`, or

212+

intentionally raise the bootstrap limits.

213+
205214

Sub-agent sessions only inject `AGENTS.md` and `TOOLS.md` (other bootstrap files

206215

are filtered out to keep the sub-agent context small).

207216