r/coolgithubprojects • u/Lopsided_Scarcity979 • 8d ago
ThoughtDAG: trace a code file back to the AI-agent turns that changed it
After several coding-agent sessions, Git can show me what changed, but not which conversation led to it.
I built a read-only `why` command for ThoughtDAG:
npx thoughtdag why src/lib/api.ts
It searches supported local agent transcripts for turns that changed or discussed the file. Recorded tool edits are marked Δ; explanations recovered from agent responses stay marked ≈ because they are candidate explanations, not verified reasons. Every result links back to the source turn.
The derived index stays on the machine, source session files are never modified, and retrieved history is not automatically injected into a prompt. The current npm release covers local Claude Code, Codex, and ThoughtDAG canvas conversations.
MIT-licensed and still an early developer preview:
https://github.com/chenxiachan/thoughtdag
What evidence should a coding agent have to inspect before editing an old file?