agentdiff
agentdiff copied to clipboard
Should ledger.jsonl be committed to the repo?
Question / Discussion
Currently agentdiff init sets up hooks that write attribution data to .agentdiff/ledger.jsonl inside the target repo, and this file gets committed as part of normal git history.
Concerns with the current approach:
- Adds noise to every commit (auto-amend includes the ledger update)
- Contributors may not want attribution data stored in their repo
- Makes
git log --onelineharder to read - Larger repos accumulate a growing JSONL file
Alternatives worth considering:
- Store the ledger outside the repo (e.g.
~/.agentdiff/<repo-hash>/ledger.jsonl) - Use git notes (
git notes add) to attach attribution metadata to commits without touching the working tree - Store in a dedicated orphan branch (
refs/agentdiff/ledger) - Keep current approach but make it opt-in via
AUTO_AMEND_LEDGER=1(already supported)
Trade-offs: The in-repo approach makes attribution portable — clone the repo, get the history. Out-of-repo approaches are cleaner but lose portability.
Would love input from anyone using agentdiff in a team setting.
this is worked on as of now it should not be directly commited!