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 skills/acn-ericlaw/agent-memory/harvest-knowledgenpx skills add acn-ericlaw/agent-memory --skill harvest-knowledgegit clone --depth 1 https://github.com/acn-ericlaw/agent-memoryWrote 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/skills/acn-ericlaw/agent-memory/harvest-knowledge)<a href="https://agentmods.dev/skills/acn-ericlaw/agent-memory/harvest-knowledge"><img src="https://agentmods.dev/badge/skills/acn-ericlaw/agent-memory/harvest-knowledge.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.00089 | $0.01622 |
| Opus 5 | $0.00044 | $0.00811 |
| Sonnet 5 | $0.00018 | $0.00324 |
| Haiku 4.5 | $0.00009 | $0.00162 |
Grade A, and why
harvest-knowledge 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 5d 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 — 86 lines — stays where its author put it; the contents beside it link to each section on GitHub.
harvest-knowledge
⚠️ Tool-managed skill provided by agent-memory (
provenance: agent-memory-builtin). Don't edit it in place — it is overwritten on upgrade. To change behavior: fork it under a new skill name, or upstream a genuine fix to the agent-memory project (file an issue in its repo, or bring it to the tool maintainer) for back-port + validation. SeeSKILLS.md→ "Tool-provided (system) skills".
The on-demand, recurring counterpart to the enable-time knowledge harvest (ENABLE.md Step 4b).
Enable seeds memory once from the team's docs; this skill keeps it in sync as those docs evolve.
When to use
- The repo's docs have grown or changed since it was enabled — new ADRs, a design spec, decision-log entries, a roadmap/kanban update.
- To backfill a repo that was enabled before the curious harvest existed (the post-upgrade catch-up).
- A human or agent asks to "harvest knowledge" / "refresh memory from the docs."
On demand only — never part of the per-session ritual, and not tied to enable/upgrade mode.
It is NOT a vendor /init
A vendor /init does a deep code analysis and (re)writes a vendor steering file (CLAUDE.md,
.cursorrules, …), usually overwriting it. harvest-knowledge instead:
- reads the team's human-authored knowledge docs (prose — not code),
- distills durable facts into the neutral, shared, committed
memory/layer (every vendor sees it), - is additive + incremental — it never overwrites curated facts; a conflict becomes a
Contradictionthread, not a silent rewrite, - is repeatable — run it whenever docs change, not a one-shot bootstrap.
You may borrow /init's analysis muscle, but the output goes to memory/, never a vendor file.
What to do
- Enumerate, recursively (same net as
ENABLE.mdStep 4b). Recurse every documentation tree —docs/,doc/,documentation/,wiki/,rfcs/,adr/,design/,notes/(all subfolders) — and sweep the repo + module roots for human-authored knowledge markdown: decision logs /DECISIONS*,ADR*,ROADMAP*/TODO*/BACKLOG*, kanban/board files,ARCHITECTURE*/DESIGN*,CONTRIBUTING*,RFC*,GLOSSARY*, onboarding / runbook / postmortem notes. Match.md/.markdown/.mdx/.rst/.txt/.adoc. Exclude (not team prose):node_modules/,vendor/,.venv/venv/,target/,dist/,build/,.git/, generated API reference, minified/vendored files, anything already.gitignored. - Scope to what's NEW or CHANGED since the last harvest. Read
last_harvestfromcontinuity.md→ Project State (the marker this skill stamps in step 7). If present, look only at docs changed since then —git log --since=<date>/git diff --name-only <since>..HEADover the doc paths. If it's absent (never harvested — or the repo predates this field), treat it as a full first pass. Either way, budget with disclosure: cap the read (prioritize roots →docs/→ recently-modified); if the budget is hit, record a- [ ] (knowledge-harvest)Open Thread listing what's left, so nothing vanishes silently. (last_harvestonly scopes the read — the step-4 check-existing-first guard is what actually prevents duplicates, so a re-scan is always safe.) - Distill — don't transcribe — into memory, additively:
- conventions / architecture decisions / hard constraints →
memory/instructions.md(and seed Architectural Invariants from explicit "must / never" rules); - current goals / roadmap / in-flight work / decision-log open items → Open Threads; the aspiration →
the Current-state context of
memory/vision.md(never fabricate the target); - newcomer-facing knowledge → candidate smoke-test questions.
- Map, don't mirror: link the canonical doc and capture only the enduring fact — never duplicate a living doc into memory.
- conventions / architecture decisions / hard constraints →
- Check each candidate against existing facts first (
DECAY.md§10) so a re-run doesn't duplicate. A harvested fact that contradicts an existing one → raise a- [ ] Contradiction: …Open Thread (never-pick-a-winner); a genuine replacement → supersede the old fact (DECAY.md§9). Never silently overwrite curated memory. - Human-gated. Summarize what you folded in, what you superseded/flagged, and what you skipped for budget — let the human review before it's treated as settled.
- Record it. A harvest is a memory-relevant event → write a session log with a
## Memory Referencessection listing the fact ids you created / changed (it stays inside the normal after-session ritual). - Stamp
last_harvestincontinuity.md→ Project State:last_harvest: <today> | through <this session-file>(create the field if absent — it sits withlast_review/last_invariant_check). This is what step 2 reads next time, so each run scopes incrementally. The harvest ownslast_harvest, the way the review ownslast_review. Even a no-op run (nothing new to fold) stamps it — that records "docs were checked through here." Write it safely (REVIEW.md→ Safety: never truncate-before-read).
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.
- 5d ago First seen · 86 lines · 89 tokens per session scan A ed410356f880
harvest-knowledge is a skill published in the GitHub repository acn-ericlaw/agent-memory (5 stars, last pushed today), licensed Apache-2.0. It adds 89 tokens to every session and 1,622 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-31.
Other skills, from other repositories
excel-author
Create and edit Excel (.xlsx) workbooks with openpyxl. Supports formulas, charts, formatting, and data analysis.
ppt-author
Create and edit PowerPoint (.pptx) presentations programmatically. Requires python-pptx.
ocr-document
Extract text from PDFs, images, and scanned documents. Uses pymupdf (local) or optional cloud OCR APIs.
file-convert
Convert between file formats: CSV↔JSON, Markdown↔HTML, YAML↔JSON, images, and more. No external service needed.
notion-sync
Read, create, and update Notion pages and databases. Requires Notion API integration token.
local-mirror
Declare and refresh a LOCAL MIRROR — a one-way local copy of a chosen zone of an internal tool (Notion today) replicated into this brain's vault as Markdown, so the LOCAL RAG can search and cite it OFFLINE. A mirror is a 'synchronized source' kept locally: copied once, then refreshed on demand. Use when the user wants…