{"slug": "git-blame-but-for-conversations", "title": "Git Blame, but for Conversations", "summary": "A developer released loch, an experimental open-source tool that hooks into Claude Code and records file changes per conversation turn, letting users run `loch blame <file>` to see which agent session produced each block of lines and `loch ask <file:line>` to fork and resume the original conversation with its full context. Conversations are compressed into a `.loch/` directory that can be synced to a shared S3 backend for teammates, and the author warns that secret-scrubbing from chat logs is not 100% successful, recommending against giving agents access to secrets. The tool currently supports only Claude Code, with other harnesses promised, and the author describes it as very experimental.", "body_md": "**the short story:**\n\nLast week I wrote a brief post about how the future of agentic editing is [multiplayer](https://www.staycaffeinated.com/2026/11/05/the-future-is-multiplayer). I believe in the same way that\ngit allowed multiplayer editing before, we need to build a new primitive that syncs the conversations along with the file changes.\n\nI have prototyped a tool ([loch](https://github.com/ness-dev/loch)) which hooks into claude code (other harnesses coming soon) and tracks file changes per conversation\nturn. You can `loch blame <file>` to figure out which agent made a change, and `loch ask <file:line>` to resume the conversation that made the change.\n\nIn its current state it’s useful for:\n\nIn the future I intend to add:\n\n**the slightly less short story:**\n\nIn [the future is multiplayer](https://www.staycaffeinated.com/2026/11/05/the-future-is-multiplayer) I said we are going to be checking in our conversations.\n\nMore and more I find myself wishing I could just talk to the chat who made a change to figure out the context, to debug a new issue,\nor to continue a conversation when I have feedback in a pull request. So I built [loch](https://github.com/ness-dev/loch).\n\n**1. hook it up**\n\n```\nloch install     # Installs hooks into claude code (other harnesses coming soon)\nloch backfill    # Attempts to link previous chats based on all of your locally stored sessions\n```\n\nConversations are stored and compressed into `.loch/`. They can be synced to a shared S3 backend if you’d like to share with teammates. WARNING: I \ntry to clean secrets out of chat logs, but it’s obviously not 100% successful. I really recommend you just don’t give agents access to secrets.\n\nFrom there, two basic primitives have been added on top:\n\n**2. blame a file**\n\n``` bash\n$ loch blame myfile.py\nloch/format.py\n        1-2  45b565e  Add loch format v1 and the Claude Code ingest converter\n                      session 37d467e5 — asked: \"I would prefer this tool to be agnostic of the editor that surrounds it…\"\n     19-100  6eb7b0d  Canonicalize per RFC 8785, fold agent events into facts\n                      session 37d467e5 — asked: \"honeslty none of those seem like open questions they all seem like you …\"\n```\n\nInstead of just a commit and an author, every block of lines comes with the request that led to it. Typos included.\n\n**3. ask it (or resume a chat)**\n\n``` bash\n$ loch ask myfile.py:105 \"why did you write this by hand instead of using json.dumps?\"\nforked session 37d467e5, which made 6eb7b0d, to its end: 765 records, as e87ec144-3a54-4d0e-8cd4-a30e2d2cc020\n\n  ⋮ (the rest of the original conversation)\n\n> why did you write this by hand instead of using json.dumps?\n\n⏺ I wrote format.canonical by hand because json.dumps doesn't match RFC 8785: it\n  prints floats in Python's exponent forms (1e-05 instead of 0.00001), sorts keys by\n  code point instead of UTF-16 code units, and writes lone surrogates raw instead of\n  escaping them, so a second implementation in another language couldn't reproduce\n  the ids byte for byte.\n```\n\nIt forks the original conversation (rather than resuming it) and will allow you to speak to an agent that has exactly the same context.\n\nSo far this is very experimental. I would love people’s thoughts on this direction.", "url": "https://wpnews.pro/news/git-blame-but-for-conversations", "canonical_source": "https://www.staycaffeinated.com/2026/11/09/git-blame-for-conversations", "published_at": "2026-11-19 18:57:42+00:00", "updated_at": "2026-11-19 19:17:08.637596+00:00", "lang": "en", "topics": ["ai-agents", "ai-tools", "developer-tools"], "entities": ["loch", "Claude Code", "GitHub", "RFC 8785", "S3"], "also_reported_by": [], "takeaway": "loch installs hooks into Claude Code to store per-turn conversations in `.loch/`, enabling `loch blame <file>` to map line ranges to the originating session and `loch ask <file:line>` to fork that session with its original context.", "recommendation": null, "alternates": {"html": "https://wpnews.pro/news/git-blame-but-for-conversations", "markdown": "https://wpnews.pro/news/git-blame-but-for-conversations.md", "text": "https://wpnews.pro/news/git-blame-but-for-conversations.txt", "jsonld": "https://wpnews.pro/news/git-blame-but-for-conversations.jsonld"}}