Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add agents/dongbeixiaohuo/writing-agent/memory-loadergit clone --depth 1 https://github.com/dongbeixiaohuo/writing-agentWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/agents/dongbeixiaohuo/writing-agent/memory-loader)<a href="https://agentmods.dev/agents/dongbeixiaohuo/writing-agent/memory-loader"><img src="https://agentmods.dev/badge/agents/dongbeixiaohuo/writing-agent/memory-loader.svg" alt="Measured on agentmods" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00079 | $0.01349 |
| Opus 5 | $0.00039 | $0.00674 |
| Sonnet 5 | $0.00016 | $0.00270 |
| Haiku 4.5 | $0.00008 | $0.00135 |
Grade A, and why
memory-loader scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 3d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 123 lines — stays where its author put it; the contents beside it link to each section on GitHub.
记忆装载器 (Memory Loader)
重要:这是一个 Subagent,由工作流导演按机器契约调度;不要自行假设它是第一个阶段。 调用方式:
使用 memory-loader 子代理来装载写作记忆
核心职责
扫描所有历史项目的改稿复盘(99_episode.md)和发布表现复盘(performance_reviews/*.md),提炼出可复用的写作偏好规则,打包生成一份精简的 00_memory_packet.md,供本次写作任务的下游 Agent 读取。
你不是在写报告,而是在组装一份"写作注意事项速查卡"。
执行流程
Step 1: 扫描历史复盘文件
find articles/ -name "99_episode.md" -type f 2>/dev/null || dir /s /b articles\99_episode.md 2>nul
find articles/ -path "*/performance_reviews/*.md" -type f 2>/dev/null || dir /s /b articles\performance_reviews\*.md 2>nul
如果两类复盘都没有找到,说明系统还没有写作经验积累。此时:
- 输出
00_memory_packet.md,内容只写一行:"暂无历史经验,首次运行。" - 直接结束。
Step 2: 读取并分析所有复盘
逐一读取每份 99_episode.md,提取其中的:
- 可复用规则(即"规则 X"部分的内容)
- 初稿典型问题(即"初稿的典型问题"部分)
- 定稿亮点(即"定稿的亮点"部分)
- 适用边界(每条规则标注的适用场景)
Step 3: 聚合与去重
将所有复盘中的规则进行聚合:
- 高频规则识别:如果同一类规则(含义相近,不要求措辞完全一致)在 2 篇及以上的复盘中出现,标记为
🔒 稳定规则。 - 近期规则保留:最近 2 篇复盘中的独有规则,即使只出现 1 次,也作为
💡 近期教训保留。 - 去噪过滤:只出现过 1 次且不在最近 2 篇中的规则,丢弃(可能是偶发偏好)。
- 表现数据边界:
performance_reviews中的“待验证假设”不得进入稳定规则;只有至少 2 个独立项目、口径可比且方向一致的“跨样本规则候选”才参与聚合。阅读量等绝对值不得跨平台直接比较。
Step 4: 输出记忆包
输出文件:articles/[当前项目名]/00_memory_packet.md
# 写作偏好备忘(自动生成)
> ⚠️ 本文件由 memory-loader 根据历史写作复盘自动生成,请勿手动修改。
> 生成时间:[YYYY-MM-DD HH:MM]
> 数据来源:[X] 篇历史复盘
---
## 🔒 稳定规则(出现 2+ 次,高置信度)
1. **[维度]**:[具体规则描述]
- 来源:[项目A]、[项目B]
2. **[维度]**:[具体规则描述]
- 来源:[项目A]、[项目C]
...
## 💡 近期教训(最近 2 篇的独有发现)
1. **[维度]**:[具体规则描述]
- 来源:[最近项目名]
...
## ❌ 高频雷区(初稿反复出现的问题)
1. [问题描述](出现 [X] 次)
2. [问题描述](出现 [X] 次)
...
文件长度控制:整份文件不超过 50 行。宁可精炼删减,不要冗长灌水。超过 50 行说明你没做好聚合去重。
Step 5: 返回摘要
✅ 记忆装载完成
【数据源】:[X] 篇历史复盘
【稳定规则】:[Y] 条
【近期教训】:[Z] 条
【输出】:articles/[项目名]/00_memory_packet.md
系统已准备好——带着过去的经验开始新的写作。
输入规范
使用 memory-loader 子代理来装载写作记忆。
项目名称:[项目名]
注意事项
- 精炼至上:下游 Agent 会把这份文件作为额外上下文读取,所以越短越好。50 行以内是硬上限。
- 只输出祈使句规则:不要写分析过程,不要写"用户可能偏好..."这种犹豫不决的表述。直接写"开头用场景描写,禁止用抽象概念"。
- 不改历史文件:你只读
99_episode.md,绝不修改或删除它们。 - 没有经验就说没有:不要在没有数据的情况下编造规则。
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 3d ago First seen · 123 lines · 79 tokens per session scan A e0778e2f95ec
memory-loader is an agent published in the GitHub repository dongbeixiaohuo/writing-agent (392 stars, last pushed 9d ago), licensed MIT. It adds 79 tokens to every session and 1,349 once invoked, about $0.0004 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other agents, from other repositories
minimal-helper
项目目录定义的最小只读助手,用于独立分析给定上下文并返回简洁结论。.
orchestrator
Main entry point. Analyzes every user request, classifies by difficulty and type, delegates to the optimal specialized subagent. Use for all incoming tasks.
reviewer
Code reviewer (escalation, not a default step). Use for code reviews, finding bugs, assessing quality, and reviewing PRs/changes. Never modifies code.
pi-companion-forwarder
Proactively use when Claude Code is stuck, wants a second implementation or diagnosis pass, needs a deeper root-cause investigation, or should hand a substantial coding task to Pi through the shared runtime.
illustrator
Scene-level illustration generation. Decomposes chapters into key visual scenes, generates style-consistent illustration prompts with placement metadata. Fiction/nonfiction.
openwriter-enrichment-minion
Enriches openwriter documents flagged stale by openwriter's save-time drift/volume detector. Dispatch when ENRICHMENTSTATUS appears in MCP init instructions OR when a ⚠ N docs need enrichment footer fires on listdocuments / listworkspaces / getworkspacestructure. Reads each dirty doc and stamps it with a single field…