Get started
Two steps on one machine: start the recorder, then point your agent's existing OpenTelemetry exporter at it. What each step does, what the recorder reads, the agent-driven variant, and how it stays up and current.
Sessionist records every run your agent makes, on your machine, as it happens: every prompt, every tool result, every reply, exactly as they were. You read the recording, or your coding agent does over MCP. Getting there is two steps; reading a run is the next page.
Step one: start the recorder
npx sessionistThis starts the recorder (an OTLP receiver on 127.0.0.1:4318 and a viewer on 127.0.0.1:4319) and, once, offers to attach your coding agent: it registers the MCP server with Claude Code, installs the connect skill, and starts the recorder at login. Node 22.16 or newer (22.16+ or 24+). The store is Node's built-in SQLite, so there is no native code and nothing compiles on install.
Step two: connect your agent, in its repo
/sessionist-connectTyped into your coding agent, in the repository of the agent you want recorded. The skill finds whatever already owns telemetry in that repo, adds one OpenTelemetry exporter pointed at the recorder, asks before turning on content capture, runs the agent once, and reads the session back over MCP to prove it landed. It installs nothing, never creates a second tracer provider, and leaves an already-connected repo alone. There is no Sessionist SDK.
That's it. The next run is recorded as your agent makes it.
Already emitting OpenTelemetry? You're done.
Point the exporter your agent already has at OTEL_EXPORTER_OTLP_ENDPOINT=http://127.0.0.1:4318 and change nothing else. Protobuf and JSON are both accepted, traces and logs, gzip included.
- On a framework that emits the current OTel GenAI conventions? Turn on content capture, which most frameworks keep off. Any language.
- What exactly does it read? Structure from
gen_ai.operation.name; content fromgen_ai.input.messagesandgen_ai.output.messages. - Already sending traces to a hosted backend? Keep it. Add a second exporter, or fan out from your collector. Sessionist is a layer beside what you run, not a replacement.
- Emitting something older? Kept verbatim as passthrough steps. Never dropped, never interpreted.
If a coding agent is doing the install
A bare npx sessionist in an agent's shell is a foreground process that stops when the agent moves on. Have the agent run this instead:
npx -y sessionist setupIt attaches everything, starts the recorder at login, and exits. npx sessionist --yes does the same and keeps serving. For an agent other than Claude Code, npx sessionist setup --print emits the MCP config block to paste into its settings; the server hands any MCP client its own reading order on connect, so nothing else is installed to read.
Keeping it recording
The recorder is a plain process, and a run that happens while it is stopped is lost: the exporter's connection is refused in your agent, not here. sessionist service install starts it at login instead, a LaunchAgent on macOS or a systemd user service on Linux, with lingering enabled by default so a headless box survives logout. It relaunches after a crash and never after you stop it on purpose. sessionist service status reports installed, loaded, and answering separately, because they are three different things.
Staying current
npx sessionist resolves the newest release each time it starts, so the reader your coding agent starts is current at every new session, and the recorder is current from its next start. npx sessionist update restarts the recorder now and refreshes the skill; it refuses while a run is recording unless you pass --now. When the reader and the recorder are different versions, the reader tells your coding agent, which tells you. A global install (npm i -g sessionist) gets new code from npm i -g sessionist@latest, then the same sessionist update.
The login service and your coding agent both start Sessionist through one small launcher script that Sessionist owns, ~/.sessionist/bin/sessionist, so nothing outside that file knows where the package is installed. Moving to a new Node version, or reinstalling somewhere else, can break only that file, and sessionist update run from the new install repairs it, restarts the recorder, and checks that it answers. If the old install is still there and still works, update leaves the service on it and says so; sessionist setup, run from the install you want, switches. One limit: a coding agent started from the Dock has no shell PATH, so after a Node move that deletes the old install its reader cannot start until sessionist update has run once.
Upgrading from a release before 0.2.0: sessionist update moves that setup onto the launcher and keeps every recorded session.
Every command accepts --json. --help and --version print and exit without starting anything. Every page here is also served as Markdown at its URL plus .md, and all of them at /docs/llms-full.txt.