Heimdall Adds Trust Verdicts to Agent Memory
Heimdall is an open-source knowledge layer that verifies AI coding agent memory hits before an agent acts on them.

Heimdall is ArihantDeva's MIT-licensed open-source knowledge layer for AI coding agents. It deals with a boring, expensive failure mode: the agent forgets work you already did, then rebuilds it in another repo. Heimdall is a trust-verified memory layer that searches across projects and labels each result before the agent acts on it. The useful idea is not more memory; it is memory with a verdict.
That makes it relevant to agentic coding governance without making it feel like policy theater. If an agent is going to reuse old work, it should know whether the file still exists, whether the content actually answers the question, and whether a moved file was re-anchored.
Check the memory hit before trusting it
A trust-verified knowledge layer is a memory system that verifies a retrieved result against current project reality before handing it to an AI agent. Heimdall's README frames this around a simple pain: grep can find strings, but it cannot answer whether you solved the same problem in a different repo under a path you never would have opened.
The project's differentiator is the verdict attached to each result. A STRONG result means the path exists, the lexical coverage is good, and the file content appears to answer the query. A WEAK result is only a semantic match. REBUILT means Heimdall found a moved file and re-anchored it. STALE and REMOVED mean the path should stop influencing the agent.
That last part is the sharp edge. A stale memory hit is worse than no memory hit because it gives the agent confidence and a fake coordinate. Anyone who has watched an agent edit around a deleted hook, renamed service, or old migration knows the smell.
The trap is treating semantic memory like truth. Heimdall's pitch is that semantic recall should be allowed to suggest, but the filesystem gets the final vote.
Why the Show HN pitch landed
The Hacker News interest was easy to understand: this is not another chat pane. Heimdall points at a real agentic coding problem that shows up once you use coding agents across more than one repository.
As of August 22, 2026, the repository had 10 GitHub stars, was mainly JavaScript, used the MIT license, and had been pushed the day before. Small project, clear claim. The README says Heimdall watches what the agent does, keeps a semantic memory graph fresh across projects, and orchestrates over Graft-style semantic memory backends.
The reason developers cared is that the failure mode is familiar. You ask the agent to add a rate-limit hook. It does not know you built a similar hook in billing-api last month. It writes a new one in checkout-web, misses the edge case you already fixed, and now you have two almost-right versions.
The objection is also fair. Memory layers can become a second stale system to maintain. Heimdall's answer is to make staleness visible through verdicts, not hidden behind a nice similarity score.
That is a better default for developer productivity than a huge undifferentiated context dump. It also sits beside other open-source agent experiments, like Proliferate Is a Self-Hostable AI IDE, but with a narrower bet: make retrieved coding knowledge less dangerous.
Use it as a guardrail, not an oracle
Claude Code, Anthropic's coding agent, already works best when repository facts are short, local, and checked. Heimdall fits that habit if you use it as a pre-edit memory check rather than as a source of automatic permission.
A good workflow is small. Before asking Claude Code to implement a feature, ask for prior art across related repos. Let Heimdall return candidate files with verdicts. Then give the agent only the STRONG or clearly explained REBUILT hits as context.
For example, before changing apps/web/src/hooks/useEntitlements.ts, search for old entitlement hooks in adjacent repos. A STRONG hit in services/billing/src/entitlements/check.ts is useful evidence. A WEAK hit in an old prototype is a hint, not an instruction.
The trap is letting the agent treat WEAK as reusable code. Put the rule in the task, not in your head: weak memory may explain history, but it must not drive edits without opening the current file and checking the repo.
Keep Claude Code memory boring and local
Heimdall should not replace normal repo instructions. A concise CLAUDE.md still carries durable local rules: how tests run, where generated files live, what not to touch, and which directories are legacy.
The split is simple. Use repo memory for rules that are true here. Use Heimdall for cross-repo recall that may be useful but must be verified.
A practical note for Claude Code users: if you expose Heimdall through an MCP server, keep the first version read-only. Allow search and verdict retrieval. Do not allow an agent to prune, rewrite, or mark memory as trusted until you have seen enough sessions to know the verdicts match reality. The Model Context Protocol is useful plumbing, but plumbing should not get write access just because the demo worked.
This is where the related training topic becomes concrete. The interesting guardrail is not a meeting or a policy doc. It is a small boundary around what evidence an agent can use.
Copy this safe Heimdall trial receipt
Use this as a lightweight Claude Code slash-command draft or paste it at the top of a risky task. It keeps the experiment about verified memory, not vibes.
/memory-check
Goal:
Find prior work before editing, but only trust verified hits.
Before editing:
- Search Heimdall for the feature, API, hook, migration, or bug pattern.
- Bring back only the top relevant hits with their verdicts.
- Open the current files before proposing changes.
Verdict rules:
- STRONG can be used as implementation evidence.
- REBUILT can be used if the new path is opened and matches the task.
- WEAK can be mentioned as a possible clue, but not copied from.
- STALE or REMOVED must not be used except to explain what not to follow.
MCP permission note:
- Read-only search is allowed.
- Memory writes, pruning, and trust-label changes require human approval.
Handoff receipt:
- List the Heimdall hits used.
- List the files opened locally.
- Name any weak or stale hits ignored.
- State which tests or checks still need to run.
Try it on one narrow task: a hook, a config migration, or a small service helper. It is overkill for a one-file typo fix. It is worth testing when the agent would otherwise invent prior art from memory or rebuild code you suspect already exists.
Try the smallest useful version
Clone Heimdall, read the README, and run one read-only memory check against a task where you know prior work exists. If the verdicts save the agent from one stale path, the idea is worth a deeper look.
One methodology lens
One useful way to read this through our methodology is the Plan step: delegate first-pass decomposition and dependency mapping, review the sequencing and assumptions, and keep ownership of scope and priorities. If that split is still fuzzy, the workflow usually is too.
Practical starter checklist
- [ ] Name the Claude Code artifact first: a hook boundary, an MCP permission note, a slash-command workflow, a Claude skill outline, a review checklist, or a concise CLAUDE.md note when repository memory is the topic.
- [ ] Write the review checklist before generation starts: scope, owner, tests, rollback.
- [ ] Keep the first step small enough that a reviewer can inspect the receipt without replaying the whole chat.
Common questions
-
How should teams start with Claude Code?
Start by writing down one visible team rule for Claude Code, not a loose preference. That usually means a short repository convention, a review checklist, and one owner who can reject agent output when the evidence is missing.
-
Which Claude Code artifact should teams standardize first?
Standardize the smallest artifact that reviewers already touch: a hook checklist, MCP permission rule, slash-command workflow, skill outline, or concise CLAUDE.md note. The point is not documentation volume; it is a shared place where scope, allowed tools, expected tests, and rollback notes are visible before generated code reaches review.
-
How do teams know the convention is working?
The convention is working when reviewers can approve or reject agent output from the artifact and evidence alone. Track whether pull requests name the rule used, include the promised checks, and avoid replaying long sessions just to understand what changed.
Best ways to use this research
- Best for: Claude Code teams deciding which hook, skill, MCP boundary, slash-command workflow, review habit, or repository-memory convention to standardize next around “Heimdall Adds Trust Verdicts to Agent Memory.”
- Best first artifact: turn the named fix into a hook checklist, skill note, MCP permission note, review receipt, or concise CLAUDE.md convention when repository memory is the real topic before the next automated run.
- Best comparison angle: compare the workflow against the current Claude Code handoff, hook behavior, and MCP scope; keep the path that leaves the shortest auditable trail.
Further reading
- heimdall — source
- Claude — Agent
- Model Context Protocol — specification
- developers.google.com: fundamentals creating helpful content
Where to go next
Start from the related training topic and make the first exercise prove scope, verification, and ownership in the PR body.
Related training topics
Related research

Simon Willison Ships alchemy-utils Alpha
Simon Willison’s alchemy-utils 0.1a0 turns an AI-built database spike into a small alpha worth studying.

self-bench Turns Private PRs Into Evals
self-bench turns completed private PRs into coding-agent evals, with a safer way to measure agents on real repo work.

Epho Runs Claude Code with Curl
Epho wraps cloud sandboxes behind one API call, so developers can test coding agents without building the runner.