memory-reconciliation
Skill10 starsChanged todayMITView on GitHub
Audit and reconcile persistent agent memory against ground-truth AST and workspace files
In this repository44 other files it gives its agents.
- llms-full.txtllms.txt
- llms.txtllms.txt
- ai-prompt-engineering-safety-reviewSkill
- ast-codemapSkill
- ast-grepSkill
- autoharnessSkill
- autonomous-backlog-driverSkill
- claude-kimi-mcp-normalizationSkill
- cli-self-updaterSkill
- code-frugalitySkill
- codemode-gatewaySkill
- codemode-typesSkill
- consequence-simulationSkill
- context-pruningSkill
- github-update-checkerSkill
- google-agents-cli-evalSkill
- google-agents-cli-scaffoldSkill
- history-searchSkill
- hook-gatingSkill
- hybrid-semantic-searchSkill
- kimi-code-agent-integrationSkill
- kimi-mcp-configurationSkill
- leann-vectorSkill
- log-summarizerSkill
- markdown-vagueSkill
- mode-classificationSkill
- multiagent-orchestrationSkill
- output-compressionSkill
- prompt-injectionSkill
- python-anti-patternsSkill
- regression-sentinelSkill
- restart-trackingSkill
- rollback-guardSkill
- rust-call-graphSkill
- secrets-managementSkill
- security-best-practicesSkill
- session-compactorSkill
- sqlite-memorySkill
- swarm-barrierSkill
- swarm-dagSkill
- autoharnessSkill
- code-reliability-checksSkill
- skill-threat-rulesSkill
- autoharnessSkill
The file
We split this skill into the rules it gives an agent
4 rules. About 0 are common, 0 are distinctive, and 4 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈0
Distinctive · estimate
This author's own choices. Worth a look.
4
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 9
Use when inspecting, auditing, or pruning persistent SQLite agent memory (.autoharness/memory.db) to detect knowledge drift, orphaned …
- Very specific: line 20
Verify referenced symbols against Python AST symbols (ast.parse) collected from existing workspace files.
- Very specific: line 23
If --prune-orphans is specified, wrap deletions in an atomic SQLite transaction (SAVEPOINT) to safeguard database consistency without data …
- Very specific: line 26
Run pytest tests/test_memory_reconciliation.py and execute autoharness memory reconcile --json.
≈ “Common” is an estimate: at least 1 in 5 of the 364,980 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
memory-reconciliation
When to use
Use when inspecting, auditing, or pruning persistent SQLite agent memory (.autoharness/memory.db) to detect knowledge drift, orphaned file/symbol references, or conflicting lessons after refactorings, deletions, or codebase evolution.
Steps
- Open persistent SQLite database (
.autoharness/memory.db) viamemory.get_memory_db(project_root). - Scan active documents across kinds (
ruling,lesson,review,followup,swarm_task). - Differentiate between prescriptive policies and historical review records:
- For
ruling,lesson, andfollowup: extract referenced file paths and code symbols. - For
review: verify only that the source task directory (.autoharness/tasks/{task_id}) still exists. Never flag historical critique prose quoting transient tests or external configurations as code drift or orphans.
- For
- Extract code references with strict token discipline:
- Match path tokens while filtering out external URLs and transient tool directories (
answers/,runs/,evidence/,.cursor/,.gemini/,.claude/, etc.). - Extract code symbols only when explicitly declared in document metadata or formatted in strict backticked identifier syntax (e.g.
defname, `class `Name), filtering out Python keywords and prose verbs.
- Match path tokens while filtering out external URLs and transient tool directories (
- Verify referenced symbols against Python AST symbols (
ast.parse) collected from existing workspace files. - Detect prescriptive contradictions by evaluating policy polarity (
positivevsnegative) on documents sharing multi-token topic overlap or title matches. - Compute drift metrics (
valid_count,drifted_count,orphaned_count,drift_rate). - If
--prune-orphansis specified, wrap deletions in an atomic SQLite transaction (SAVEPOINT) to safeguard database consistency without data loss.
How to verify
Run pytest tests/test_memory_reconciliation.py and execute autoharness memory reconcile --json.
Facts found here
- Research reference: Google Research Harness² (arXiv:2610.14224, https://arxiv.org/abs/2610.14224) and https://github.com/google-research/harness2.
- Transient directory filters:
answers/,prompts/,runs/,evidence/,.cursor/,.gemini/,.claude/,.kimi-code/,KIMI_CODE_HOME/. - Strict symbol backtick syntax eliminates false positive drift from ordinary English sentences.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

