r/ClaudeCode • • 2h ago

Tips & Workflows A CLI that turns your Claude Code session history into memory your agent can search

Every Claude Code session is already logged as JSONL in ~/.claude/projects. agent-recall-axi lets your agent search all of it across every project, then zoom in: sessions, turns, events, one entry in full.

It is built to the AXI standard (Agent eXperience Interface): a plain CLI designed for an agent to drive through the shell, with no MCP server to run. Here that means three things:

  • Output is compact TOON, so reading history costs few tokens.
  • Every row has a stable id the agent can cite or come back to.
  • Every listing ends with the exact command to go back, forward or deeper, so the agent never guesses the next step.

Read-only, local files only, no network, no server, no database. MIT.

npx -y agent-recall-axi sessions

https://github.com/JarvusInnovations/agent-recall-axi

Install the global session hook to make every Claude Code session start knowing it's there and how to use it:

agent-recall-axi setup hooks
1 Upvotes

10 comments sorted by

•

u/AutoModerator 2h ago

Hey! Thanks for posting to r/ClaudeCode

While participating in this thread, please follow our community rules. Keep discussions constructive. Attack the idea, not the person.

For help, project discussions, tips, and general chat, join the ClaudeCode Discord.

I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.

1

u/calunicornia 2h ago

seems pretty cool, have you considered making it so multiple machines can share the memories?

2

u/themightychris 1h ago

Yeah that's what I started with, I have a postgres server vacuuming up sessions from all my machines and indexing them in various ways. It's been a huge superpower, but was tough for the rest of my team and friends to adopt with the server requirements, so I took all my lessons learned from that I put this together for single-machine use. Since developing it, I find my agents using it 90% of the time instead of reaching for the server since typically what they need will have been on the same machine anyway

1

u/calunicornia 57m ago

did you look at neo4j or any other graph db?

1

u/themightychris 48m ago edited 45m ago

I have not, what would you expect the advantage of a graph model to be in this use case?

I'm definitely in the "just use postgres for everything until you have a really good reason not to" camp lol and I've yet to find one of those

1

u/calunicornia 47m ago

my understanding was postgres is good for facts and graph is good for related things

1

u/themightychris 44m ago

Part of my philosophy here is to defer all the deeper sense-making to question time and keep the ingestion/indexing relatively dumb and mechanical so you don't have to decide a memory structure to fit things into upfront and instead focus more on making it efficient to explore the primary sources on demand

You know more about what you need and in what shape at question time. There are PLENTY of memory building implementations out there and I just don't trust that sort of process to give the best results while they burn lots of compute and tokens on the frontend

But also I'd wager postgres could do a knowledge graph just as well as any graph db

1

u/calunicornia 30m ago

i think i can improve efficiency of sessions and achieve hive mind across sessions, we shall see

your approach might be better but I want cross machine and my goal is to completely remove session context past a single task

and move as much out of agent files...

1

u/calunicornia 2h ago

This code helps write hand offs much much faster, gracias!

1

u/themightychris 57m ago

Check out resume-pack latest