Hacker news

  • Top
  • New
  • Past
  • Ask
  • Show
  • Jobs

Atuin Threads: All your agent sessions on every machine (https://blog.atuin.sh)

242 points by linsomniac 9 days ago | 87 comments | View on ycombinator

nzoschke 9 days ago |

I started building my own version of this in Superlogical Rex.

It's a bit hard to decide where to hook in.

Rex has events, harnesses have hooks, terminal output can set program status, git has hooks.

I'm not sure I actually want every session from every machine saved. That's a lot of noise especially when half of coding sessions are experimental / throwaway.

But at the same time its not that much data that's easy to ripgrep / LLM through.

hugmynutus 9 days ago |

Really enjoyed Atuin for a few weeks, until I realized it doesn't have correct `EFSRO` (Error: Read-Only File System) handling. So when my `/home` mount had a raid array drive failure it broke my local shell. Issue has been sitting open for almost a year. Pretty disappointing.

baalimago 9 days ago |

I suspect this is one of those problems "everyone" has built their own solution for. Including me!

I built slivingdoc[0] with an alternative approach: instead of syncing exact sessions (which are often quite noisy, and not so useful), the agents gets a living document with automatic merge conflict resolution backed by s3 ("infinite" storage). Idea being that the agents are prompted to summarize their context into slivingdoc as normal utf-8 files. So this way only you only need to add the stdio MCP server to all your harnesses which supports it and it just works!

Some harnesses are _super_ hyped about this concept. Codex needs no prompting at all to start communicating. I got the idea from enabling agentic forums via all the openAI hacks.

[0]: slivingdoc.dev

orbis-tertius 9 days ago |

I love Atuin, but have some reservations about a shared server keeping all my shell history and agent sessions. Am I being too paranoid and missing out on convenience?

talloaktrees 9 days ago |

I've built this for myself, but not across multiple machines. It scans the session logs of all coding harnesses I use, one extra thing it does is create embeddings to allow hybrid BM25/semantic search.

I think these kinds of tools are on of the few times I've spent time "using AI to work on my AI tools" that was actually a good use of time.

It's so useful to be able to say "search sessions for the time I was working on XYZ 3 months ago"

yababa_y 8 days ago |

I've been maintaining a tool that does similar: https://github.com/emberian/cv. High performance parsers of the major harness formats at several versions. Not as much autosyncing. Great results using custom prunings compared to compaction summarization.

thesurlydev 9 days ago |

I've a love affair with Atuin but this may turn into a full blown obsession

d4rkp4ttern 8 days ago |

If you only need this on one machine, I've been using my own tool, "aichat search", for the same thing. It's a Rust TUI over a Tantivy index of your Claude Code and Codex sessions. It indexes the session files in place rather than keeping its own copy.

On my machine, with ~22 GB of sessions, its index is under 1 GB, while Threads added 8.1 GB after importing the same sessions (it stores each conversation twice: once encrypted for sync, once for search). Agents can use it too (aichat search --json), and from a search result you can resume, or carry the work into a new session.

  uv tool install claude-code-tools
  brew install pchalasani/tap/aichat-search   # or: cargo install aichat-search
  aichat search

aichat also has other subcommands for working with sessions: porting one between Claude Code and Codex (or to another provider), rolling over to a fresh session that carries the context, trimming bloated sessions, moving a session to another project or account, etc.

No sync across machines; that's where Threads is nicer. Also Threads seems to show sub-agent relations and live-status, which mine doesn't. I like my TUI interface better though.

https://pchalasani.github.io/claude-code-tools/tools/aichat/...

nklmilojevic 9 days ago |

posted on X a couple a days ago how atuin threads saved me from loosing the code I was working on and I accidentally removed uncommited worktree https://x.com/nklmilojevic/status/2118401844401541604

ftchd 9 days ago |

I've gone a different route and prefer using the native harnesses (Claude, Codex), but with multiple accounts due to the limits.

In order to easily switch between accounts I've build Switcheroo, which I've been using for the past 2-3 months now. I've decided to open source it: https://github.com/FTCHD/switcheroo

Works with other AI CLIs like Gemini, and other various CLIs like Vercel (if you're managing multiple accounts like me), Netlify, Github etc

all2 9 days ago |

Fascinating. I just finished implementing this.

https://github.com/comalice/pi-tools contains a 'memory everywhere' module that makes all sessions BM25 vectors, and surfaces a set of memory tools to enable agents to search. You can add a new machine to the mix by registering a 'spoke'. The app runs on the 'hub'. I want to containerize the core app soon.

You can also change which computer is the hub fairly easily.

kristopolous 9 days ago |

My version is very unixy:

$ ctools resume ssh://laptop.local/code/project

Goes to laptop.local, looks for sessions done in that path, finds the most recent, copies it locally and resumes it.

There's also ls, grep, copy, cat... It looks and feels like the existing tools, that's the point.

Workflow is the thing that matters here and I'm terminal first

I'll make it more flashy soon https://github.com/day50-dev/ctools

petesergeant 9 days ago |

I've spent the last couple of months putting a lot of time and energy into isolating my agents from each other: aggressive sandboxing, regular scanning of transcripts for agent-leaked credentials, per-agent encrypted credential stores, even physical (and network) separation of machines with different areas of work on them. Needless to say, as much as I have found atuin an excellent manager of my command-line history, I will be avoiding this.

oorestisime 8 days ago |

I avoided this by not spreading sessions across machines. I have one PC at home that stays on and runs an OpenCode server, and I attach from my laptop or my phone over Tailscale. The session stays on that box, so I don't have to resume it anywhere else. One of the reasons i dont see the appeal of cloud sessions.

NelsonMinar 8 days ago |

It's not clear which parts of Claude state are safe to sync and which you want to keep local to one machine. I'm doing something with syncthing trying to keep agent session history available and little bits of it keep breaking. I haven't looked at this new feature in atuin does it have a really good understanding of what is worth syncing?

jdorfman 8 days ago |

It’s funny I use Atuin multiple times a day without even realizing it. Going to try this out they put out quality software.

RyJones 9 days ago |

I've been using (and supporting) atuin for a while, and I find it a required bit of infrastructure. This is a nice upgrade!

stasomatic 8 days ago |

This sounds cool but over my head. I've used Atuin but only for history, so I switched back to the good old fzf for that. For session history, I used codex and Claude hooks to write to an SQLite, but Atuin now makes a lot more sense.

tristanMatthias 8 days ago |

Will this work for Claude code web sessions?? I am DYING to be able to control and sync between them locally. IE take advantage of anthropics compute to build my toolchain which, when running many sessions locally uses significant ram.

ashenke 9 days ago |

I love this new AI era of coding where the HN submission is about a new way to manage agent, and almost literally all the comments are "I just finished implementing this myself" It's almost like a parody.

baskar12ai 9 days ago |

Yes i too faced the problem, lost valuable content across group of chat and not remembering in which chat it was. Tried searching but couldn't find it. Even asked ai itself does about the content whether it remembered.

TheIronYuppie 9 days ago |

I’ve been a supporter of Atuin and forever, and I really like her model here.

Excited to try it!

ghempton 9 days ago |

Built this for same purpose: https://github.com/codealong/codealong

More of a desktop flavor though

GNOMES 9 days ago |

Correct me if I am wrong, but I imagine this would hammer one's token usage to read past entries to resemble context across machines/terminals and models?

timothyduong 8 days ago |

Atuin is so invaluable to me, I self host an atuin server but even client only is amazing.

ndrake 9 days ago |

Would be great if you could disable sync for Threads but keep history sync going.

amelius 9 days ago |

Aren't session also deleted after some time? It would be nice to keep them.

krisgenre 8 days ago |

I think Jetbrains Air is trying to do this but not across machines.

languagehacker 9 days ago |

Probably a little late to this, because herdr has really eaten this segment. With their new Mac app, I don't see myself going back to atuin for this kind of experience. In fact, I get a little peeved using it on a vanilla terminal.

nharziro 7 days ago |

can you support copilot cli too? i like to go in between codex and copilot.

tacker2000 9 days ago |

So now everyone and their mother are putting out AI harnesses/session managers aka browser tabs for AI.

myagentbudget 9 days ago |

[flagged]

agline_in 9 days ago |

[flagged]

cellularatom 8 days ago |

[flagged]

sick_of_slop 9 days ago |

[dead]

LimitExperience 8 days ago |

[dead]

jackfreeman 9 days ago |

[dead]

sehw 9 days ago |

How much electricity wasted?