CommitLore is a Git-native decision memory tool for coding agents, suitable for coding agents such as Claude Code, Codex, and Cursor. Its core goal is to solve the problem that "code preserves the result but not the judgment": a team rejects an approach because of some non-obvious constraint, and in the end the code only preserves the result, so later agents cannot see the reason it was rejected and may propose the same approach again. CommitLore preserves constraints, rejected alternatives, and warnings alongside the code, and provides agents only with decisions that are still currently valid, rather than handing it decisions the repository has already overturned.
In terms of main capabilities, CommitLore stores records in a Git-native way, with records kept in ordinary Git trailers and notes, so they can branch, merge, clone, and be reviewed along with the code, and still exist after switching hosting services. SQLite serves only as a rebuildable index; deleting it will not lose the records in Git. It emphasizes the distinction between "relevance" and "authority": general memory or retrieval systems ask "which old texts look relevant," while CommitLore asks "which recorded decisions still currently apply to this path." A superseded decision may be highly relevant, but as current guidance it may be wrong. The workflow includes capture (the agent only drafts decision context that the diff cannot show), verification (checking the draft against the session and staged diff), saving (accepted records are stored in Git along with identity and lifecycle), and delivery (before subsequent edits, only the active records for that path are returned). Most commits should not carry records; CommitLore is only for judgments that code cannot preserve, not for narrating every change.
In terms of usage, installation requires Node.js 22.23.2+ and Git, and the installation script checks both before writing anything. After installation, you get a pinned source checkout and a wrapper that runs node <checkout>/dist/commitlore.mjs, with no compilation download or build step required. The plugin does not add commitlore to PATH, so to use the command you still need to install the CLI. After installation, initialization must be performed for each repository where you want to use it. Initialization respects core.hooksPath and preserves existing hooks, moving them to <hook>.commitlore-chained and calling them first; uninstallation restores them. In the affectedAmong the supported skill integrations, ordinary submission requests will consider CommitLore, and remain silent when there is nothing worth preserving, with no need to name it on every commit. A repository can choose once with commitlore auto on to have accepted records automatically staged.
For squash-merge repositories, a squash merge replaces the branch's commits with a new commit, and that commit does not carry the branch's trailers, so records made on the branch are discarded by the merge. One solution is to add .github/workflows/commitlore-preserve.yml. Because pull_request_target uses a writable token, when editing that workflow you must not check out the pull request's head, nor execute anything reachable from refs/commitlore/pr-head; commits from forks should be read as data for trailers, not run as code. When using merge commit or rebase merges, records are preserved on their own, and this setup is not needed.
The applicable scenario is providing decision memory for code repositories with history, so that subsequent agents editing specific files see only still-valid constraints, rejected alternatives, and warnings, reducing repeated review of the same bad idea. It is aimed at coding agent workflows, not a general-purpose user memory system, conversation archive, or vector database replacement.
Regarding limitations, capture is auxiliary rather than deterministic, and no host is certified to evaluate every eligible commit. The default directive mode is not authentication; it only matches the commit author header, and anyone who can write a commit can set that header, so [directive] in default mode is policy metadata rather than proof of identity; signature mode additionally requires Git's verified status and a match in the repository-local commitlore.trustedSigner allowlist, and when the allowlist is missing, empty, or unreadable it authorizes no one, and that mode fails safely. Guard is an experimental suggestion rather than a safety net, with 44.8% precision (95% Wilson confidence interval 32.7%–57.5%) and 22.0% recall on a 417-decision corpus, and an empty guard result is not a safety determination. Delivery consumes tokens on every matching tool call, and the pre-edit hook applies to Read as well as Edit, Write, MultiEdit, and NotebookEdittriggering, with each trigger consuming up to a default payload budget of 800 tokens, changeable with --budget; repositories with no records consume nothing. Answers may be partial, coverage is disclosed, and absence in partial results does not prove there are no records. Commit trailers propagate with clones, notes do not, and Git does not fetch refs/notes/* by default, so records in refs/notes/commitlore are missing in ordinary clones until commitlore init configures that mirror. There is no hosted backend, but once a server or hook returns context, the host handles that context according to its own policy. Records are treated as untrusted until graded, and injection-shaped payloads are withheld from model-readable routes.
Detailed documentation on installation, upgrade and uninstall, capture workflows, the record protocol, evidence and limitations, and the production contract can be viewed in the repository, and the project uses the MIT license.