AI Agents 相关度: 9/10

Lore: Repurposing Git Commit Messages as a Structured Knowledge Protocol for AI Coding Agents

Ivan Stetsenko
arXiv: 2603.15566v1 发布: 2026-03-16 更新: 2026-03-16

AI 摘要

Lore协议通过结构化Git提交信息,捕获代码决策过程中的上下文,增强AI编码agent的知识。

主要贡献

  • 提出Lore协议,使用Git trailers结构化提交信息
  • 强调了代码决策过程中被忽略的“决策阴影”
  • 提供CLI工具,支持查询Lore信息

方法论

形式化协议定义,对比现有方法,并通过论证和经验验证路径评估Lore的有效性。

原文摘要

As AI coding agents become both primary producers and consumers of source code, the software industry faces an accelerating loss of institutional knowledge. Each commit captures a code diff but discards the reasoning behind it - the constraints, rejected alternatives, and forward-looking context that shaped the decision. I term this discarded reasoning the Decision Shadow. This paper proposes Lore, a lightweight protocol that restructures commit messages - using native git trailers - into self-contained decision records carrying constraints, rejected alternatives, agent directives, and verification metadata. Lore requires no infrastructure beyond git, is queryable via a standalone CLI tool, and is discoverable by any agent capable of running shell commands. The paper formalizes the protocol, compares it against five competing approaches, stress-tests it against its strongest objections, and outlines an empirical validation path.

标签

AI Agent Code Generation Version Control Knowledge Management

arXiv 分类

cs.SE cs.AI eess.SY