This is the full developer documentation for Wisdom
# The intent behind every change your coding agent makes
> Wisdom records Claude Code, Codex and Pi sessions on your machine and links every file change to the request and the commands behind it. You read them in a dashboard; your agents read them through a skill.
## Record your first session
[Section titled “Record your first session”](#record-your-first-session)
Install and connect
```sh
npm install -g @oqura/wisdom
cd your-project
wisdom connect
claude # or codex, or pi: use it as usual
```
Then read what happened: the session at a glance, then any turn in full, or start from the commit it made. Below is an example session, written to show the format.
* glance
\~/invoice-api
```txt
❯ wisdom glance latest
session 3f9c2a71-8d4e-4b1a-9c55-2e7f0b6d1a90 · claude-code 2.1.319 · closed (idle) · version 412
resume with: wisdom resume 3f9c2a71-8d4e-4b1a-9c55-2e7f0b6d1a90
workspace /home/maya/invoice-api
started 2026-11-11 09:12Z · ended 2026-11-11 09:41Z
3 turns · 12 tool calls · 1 failed · 3 changes · 0 subagents · 412,906 tokens · $1.8420 reported
t1 in totals are off by a cent on some invoices, find out why
out Each line item is rounded before the sum, so cents drift on long invoices.
6 tool calls · no changes
t2 in fix it and add a test
out Totals now round once, after the sum. A new test covers a 40-line invoice.
5 tool calls · 1 failed · changed src/totals.ts, test/totals.test.ts
t3 in commit it
out Committed as a4c91e2 "fix: round invoice totals once".
1 tool call · no changes
complete · 17 lines
```
* open t2
\~/invoice-api
```txt
❯ wisdom open t2 --capture latest
t2 · session 3f9c2a71 · version 412 · 168,204 tokens
in fix it and add a test
thinking redacted (it happened; its text was not recorded)
c1 Edit src/totals.ts · ok · 12 ms · → p1
input and output repeat p1 · open t2/c1 to read them
c2 Write test/totals.test.ts · ok · 9 ms · → p2
input and output repeat p2 · open t2/c2 to read them
c3 Bash · failed · 1.8 s
input {"command":"npm test -- totals"}
output
Exit code 1
✖ rounds a 40-line invoice once (2.1 ms)
expected 1204.37, received 1204.3656
c4 Edit src/totals.ts · ok · 10 ms · → p3
input and output repeat p3 · open t2/c4 to read them
c5 Bash · ok · 1.6 s
input {"command":"npm test -- totals"}
output
{
"stdout": "✔ rounds a 40-line invoice once (1.9 ms)",
"stderr": "",
"interrupted": false,
"isImage": false,
"noOutputExpected": false
}
reply Totals now round once, after the sum. A new test covers a 40-line invoice.
p1 src/totals.ts · modify · +1 −1 · observed during c1
--- src/totals.ts
+++ src/totals.ts
@@ -6,5 +6,5 @@
// Prices are in the invoice's currency.
export function invoiceTotal(lines: Line[]): number {
- return lines.reduce((sum, l) => sum + round(l.qty * l.price), 0);
+ return lines.reduce((sum, l) => sum + l.qty * l.price, 0);
}
p2 test/totals.test.ts · create · +8 −0 · observed during c2
--- /dev/null
+++ test/totals.test.ts
@@ -0,0 +1,8 @@
+import assert from 'node:assert/strict';
+import test from 'node:test';
+import { invoiceTotal } from '../src/totals.js';
+
+test('rounds a 40-line invoice once', () => {
+ const lines = Array.from({ length: 40 }, () => ({ qty: 3, price: 10.03638 }));
+ assert.equal(invoiceTotal(lines), 1204.37);
+});
p3 src/totals.ts · modify · +2 −1 · observed during c4
--- src/totals.ts
+++ src/totals.ts
@@ -6,5 +6,6 @@
// Prices are in the invoice's currency.
export function invoiceTotal(lines: Line[]): number {
- return lines.reduce((sum, l) => sum + l.qty * l.price, 0);
+ const raw = lines.reduce((sum, l) => sum + l.qty * l.price, 0);
+ return round(raw);
}
complete · 61 lines
```
* glance --commit
\~/invoice-api
```txt
❯ wisdom glance --commit a4c91e2
commit a4c91e2b7f30 · fix: round invoice totals once · committed 2026-11-11 09:40Z · version 412
parent 7d2e9b1c04aa · 3 files · 3 pieces: 2 from recorded steps, 1 not recorded
record kept when the commit was made, 2026-11-11 09:40Z
the commit's own diff: git show a4c91e2b7f30
README.md · modify · +1 −0 · not recorded
src/totals.ts · modify · +2 −1
@@ -9,1 +9,2 @@ t2/c1, t2/c4 in session 3f9c2a71
test/totals.test.ts · create · +8 −0
@@ -0,0 +1,8 @@ t2/c2 in session 3f9c2a71
sessions
3f9c2a71-8d4e-4b1a-9c55-2e7f0b6d1a90 claude-code t2/c1, t2/c2, t2/c4 · window t1–t3
window: from the start of these sessions (no earlier commit of yours on this branch), up to this commit
To read a step, open its position in its session, such as {"capture":"3f9c2a71","open":"t2/c1"}.
guide · plain, built from the record now, no model · derived, not evidence · not stored; a model guide on request: wisdom guide a4c91e2b7f30
## Summary
fix: round invoice totals once. Written by Wisdom from the commit's record, without a model: which recorded step made each piece and what was asked in that turn. It does not say why beyond those requests.
## Items
- README.md (modify) · not recorded
No recording explains this change.
- src/totals.ts @@ -9,1 +9,2 @@ · t2/c1, t2/c4 in session 3f9c2a71
Made by [t2/c1 3f9c2a71] (claude-code). Asked in t2: "fix it and add a test". Made by [t2/c4 3f9c2a71] (claude-code).
- test/totals.test.ts @@ -0,0 +1,8 @@ · t2/c2 in session 3f9c2a71
Made by [t2/c2 3f9c2a71] (claude-code). Asked in t2: "fix it and add a test".
complete · 28 lines
```
Each part of the commit points to the step that wrote it. See [Read a commit](/wisdom-docs/guides/read-a-commit/).
## What you get
[Section titled “What you get”](#what-you-get)
* Prompts, replies, tool calls and file diffs, recorded as they happened. Nothing is summarized, and gaps in the recording are marked where they occur.
* One way to read Claude Code, Codex and Pi sessions: for you in the terminal or in Usage, for your agents through a skill.
* From any commit back to the steps that made it, with `wisdom glance --commit` in the terminal or `wisdom commits` in your browser. See [Read a commit](/wisdom-docs/guides/read-a-commit/).
* Work that carries on: [hand it off](/wisdom-docs/guides/hand-off-work/) to another agent, [resume](/wisdom-docs/guides/resume-a-session/) it, or [clone](/wisdom-docs/guides/clone-a-session/) it.
* Hooks that never block your agent. If the background service is down, events wait on disk.
* Everything stays in the project’s `.wisdom/` folder until you choose to share it.
Start with the [quick start](/wisdom-docs/getting-started/quick-start/), or read [how it works](/wisdom-docs/concepts/how-it-works/).
# Subagents, forks and worktrees
> What Wisdom records when a session starts helpers, splits in two, or works in another folder.
One agent session is one record. This page covers what happens when the work doesn’t stay in one straight line.
## Subagents
[Section titled “Subagents”](#subagents)
A subagent belongs to the session that started it. A glance counts them, the call that started one points to it (`→ a1`), and `open` reads it like a turn:
Terminal
```sh
wisdom open a1 --capture latest # its task, calls, changes and report
wisdom open a1/c2 --capture latest # one of its calls, whole
```
In Usage’s Dev view, a subagent is nested under the call that started it. Claude Code’s internal helpers (prompt suggestions, recaps) are recorded too, but folded out of that tree.
Its calls, their results and its file changes are recorded as they happen. Its report, transcript and tokens arrive only when the agent says the subagent stopped.
Note
A subagent that fails or is cut off before then loses those three, and nothing marks it yet. Judge it by its own calls and by the result of the call that started it. Wisdom records no success or failure for a subagent as a whole.
## Two sessions at once
[Section titled “Two sessions at once”](#two-sessions-at-once)
Two terminals, or a background `/fork`, are two records, both recording. If they work in the same folder, each sees the other’s file changes. Wisdom labels them honestly: a change it saw while no tool of that session ran is `external-or-unknown`.
When you [read a commit](../../guides/read-a-commit/), each piece goes to the session whose own tool call named the file or held its text. When none did, every session that saw it is listed.
## Forks, branches and other commands
[Section titled “Forks, branches and other commands”](#forks-branches-and-other-commands)
| What you do | How it’s recorded |
| ----------------------------------------------- | --------------------------------------------------------------------------------------------- |
| Resume a session | The same record continues. The time between is a gap. |
| `/clear`, `/new` | A new session. The old one isn’t linked to it. |
| `/fork`, `/branch` | A separate session, with no link to its parent yet. |
| `wisdom clone` | A new session, linked as `cloned from`. See [Clone a session](../../guides/clone-a-session/). |
| `wisdom handoff` | Linked as `continues` or `continued after`. See [Hand off work](../../guides/hand-off-work/). |
| Claude Code `/rewind` | The same session, with no marker. |
| Pi `/tree` | The same session, with no marker. |
| Compaction (Codex) | The same session; the event is kept. |
| A finished background command wakes Claude Code | A turn, shown as `in (harness notice)`, not as something you asked. |
## Git worktrees
[Section titled “Git worktrees”](#git-worktrees)
A session started in a linked worktree belongs to the main project. Each session watches its project and any worktree it works in, and shows those changes with the worktree’s name and branch: `in worktree bp3 (branch x)`. Paths are then relative to that worktree.
* The baseline is taken when the session first works there, so checking a worktree out isn’t recorded as changes. A `worktree-entered` gap marks what came before.
* Files changing in a worktree the session never worked in get one `other-worktree` gap and no diffs.
* Work in a folder outside the one being watched is marked `outside-watched-folder`.
* When Claude Code moves a session’s file on entering a worktree, Wisdom’s copy follows it.
Connected Codex is the exception: it ignores a project’s hooks inside a worktree. Use [`wisdom track codex`](../../guides/record-sessions/#track-a-home-of-its-own) there.
## When a session ends
[Section titled “When a session ends”](#when-a-session-ends)
A record closes when the agent ends the session, or after 10 minutes with no event and no tool running (`recording.idleMinutes`). Its next event continues it. If the background service restarts mid-session, the record is interrupted, and the next event continues it with a gap, since the files’ baseline was only in memory.
# How it works
> How an event travels from your agent's hook to a record you can read.
Wisdom has three parts: hooks inside your agent, a background service on your machine, and the readers (the CLI, Usage and Commits in your browser, and your agents’ skill). This page follows one event through them.

## One event’s path
[Section titled “One event’s path”](#one-events-path)
**Hook fires**a prompt, a tool starting or finishing
**Daemon**finds the session the event names
**Files diffed**what changed while the tool ran
**Stored**SQLite record + payload on disk
1. The agent’s own hook fires. Claude Code and Codex call Wisdom’s hook; Pi loads Wisdom’s extension. The hook posts the event to the background service and returns once it’s saved.
2. The service finds the session. Every event names its agent’s session ID. The first event opens a record for it; a later one, after a pause or a resume, continues it.
3. The service compares files. It keeps a baseline of the project’s files in memory. When a tool finishes, it checks what changed and stores a diff, labelled with the tool call that was running.
4. The record goes into SQLite. Large bodies (tool output, diffs) are saved as files named by their SHA-256 hash. The agent’s own transcript is copied byte for byte beside it.
If the service can’t take the event, the hook writes it to `.wisdom/spool/`, starts the service, and returns.
## One session, one record
[Section titled “One session, one record”](#one-session-one-record)
Wisdom records each session under the agent’s own session ID; there’s no second ID. Two sessions running at once, such as a background `/fork`, are two records. A record closes when the agent ends the session, or after 10 idle minutes (`recording.idleMinutes`), and the next event continues it. More in [Subagents, forks and worktrees](../forks-and-subagents/).
## Who changed a file
[Section titled “Who changed a file”](#who-changed-a-file)
Wisdom sees when a file changed, not who changed it:
* `observed during c1`: the change happened while tool call `c1` was running. Usually that call made it, but timing isn’t proof.
* `external-or-unknown`: no tool was running. You, your editor, or another process.
* `reported-by-harness`: Wisdom didn’t see the change; the agent’s own transcript reports it.
Two agents working in one folder see each other’s changes. Wisdom labels them honestly, but can’t always tell them apart. When you [read a commit](../../guides/read-a-commit/), each change goes to the session whose own tool call named the file or held its text; when none did, every session that saw it is listed.
## From sessions to commits
[Section titled “From sessions to commits”](#from-sessions-to-commits)
When you commit, Wisdom matches each change in the commit to the recorded step that produced those exact file contents, and keeps the answer as a record in your repository’s `.git`, under `refs/wisdom/records/`. It’s never on a branch, and a normal push doesn’t send it. In team mode, when an amend or a rebase gives the commit a new sha, git’s own `post-rewrite` hook lets Wisdom keep a link from the new commit to the old one’s record. See [Read a commit](../../guides/read-a-commit/).
In [team mode](../../team/set-up/), which you turn on per repository, your `git push` also sends these records and the sessions they name to your own git remote, with secrets redacted. Teammates and CI read them from there.
## Reads that hold still
[Section titled “Reads that hold still”](#reads-that-hold-still)
Every record gets a version number, and every answer states the version it read. Pass it back with `--at` and you see exactly the same evidence, even while the session keeps recording. This is how a long answer can be read in pages without gaps or repeats.
# Privacy
> Where your recordings live, what's in them, and the only ways they leave your machine.
Wisdom keeps exact recordings, which is what makes them useful, and also why they need care. This page covers where they live and how to keep them private.
## Everything stays local
[Section titled “Everything stays local”](#everything-stays-local)
Recordings live in the project’s `.wisdom/` folder. The background service, Usage and Commits listen only on `127.0.0.1`. Every request to the service needs the token in `.wisdom/daemon.json`. Usage and Commits have no sign-in and answer only requests addressed to localhost, so anyone using your machine can open them. By default, nothing is uploaded and no model reads your sessions. The two exceptions below, commit guides and team mode, are both ones you turn on.
## What’s in `.wisdom/`
[Section titled “What’s in .wisdom/”](#whats-in-wisdom)
Your sessions **exactly as they happened**: prompts, tool output, diffs, transcripts. If a key appeared in a command’s output, it’s in there. In a tracked project, `.wisdom/` also holds each agent’s login.
Treat .wisdom/ like a password
Git ignores it, but zips, copies, shared drives and synced folders don’t. Keep it out of them.
## The only ways out
[Section titled “The only ways out”](#the-only-ways-out)
A recording leaves your machine only when you run one of these:
| Command | Writes | Secret check |
| -------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------- |
| `wisdom share` | One file for a teammate, with no logins | Yes |
| `wisdom export` | A Markdown document | Yes |
| `git push` or `wisdom team push`, in [team mode](../../team/set-up/) | Sessions and commit records, to your own git remote | Yes, redacted without asking |
| `wisdom commits deploy`, in team mode | The [team dashboard](../../team/team-dashboard/): what the remote holds, copied into your Vercel project by CI, behind a GitHub sign-in unless you chose `--public` | Already redacted at push |
The check lists each value that looks like a key, token, password or email address. With `share` and `export` you choose to redact it, keep it, or cancel; a team-mode push redacts all of them, since nobody is there to answer. Redaction changes only what leaves, never your recording. See [Share a session](../../guides/share-a-session/).
Outside team mode, commit records stay in your own `.git`: a normal `git push` never sends them. `git push --mirror` sends every ref, so it sends them too.
In team mode, `check` and `guides.command` in the team file are commands that run on your machine. They run only after you allow them with `wisdom team trust`, and again after any change.
## Commit guides
[Section titled “Commit guides”](#commit-guides)
A model writes a [commit guide](../../guides/read-a-commit/#guides) only when you ask: `wisdom guide `, `wisdom guide on`, or team mode, where it’s on unless you run `wisdom guide off`. The default writer reads the commit’s sessions through your own Claude Code login, so that text goes to the model’s provider, as in any Claude Code session. A team that sets its own `guides.command` sends it wherever that command does. The plain guide uses no model.
## Your global settings
[Section titled “Your global settings”](#your-global-settings)
Wisdom never edits `~/.claude`, `~/.codex` or `~/.pi/agent`. `wisdom connect` writes only to the project’s own settings, kept out of git, and `wisdom disconnect` removes exactly that. The one exception is yours to choose: deleting a connected session in Usage with the box ticked to also delete the agent’s own copy.
# What gets recorded
> What Wisdom keeps, what it can't see, and how it marks the difference.
Wisdom records what the agent reports and what it can observe on disk. Where it can’t see something, it marks the gap in place.
## Principles
[Section titled “Principles”](#principles)
1. Records are only added. Transcripts are copied byte for byte. Nothing is edited later, except when you delete a session.
2. Recordings are never summarized or generated. What you read is what happened. The one thing a model writes is a [commit guide](../../guides/read-a-commit/#guides), only when you ask for one or turn on team mode, and it’s always labelled `derived, not evidence`.
3. A gap is listed as `not recorded`, with [the reason](../../reference/recording-gaps/).
4. Labels state only what was observed. A change seen during a tool call is timing, not authorship, and a tool that finished is not proof the code is right.
## Kept
[Section titled “Kept”](#kept)
| Item | Recorded as |
| ---------------------- | -------------------------------------------------------------------------------------------------------------------------------- |
| Your prompts | In full, as typed |
| Replies | In full |
| Thinking | When the agent records it; otherwise `redacted` with its duration |
| Tool calls | Full input and output, status, duration |
| File changes | A unified diff of each one, with the tool call it happened during |
| Subagents | Their task, calls, changes and report |
| Tokens and cost | As the agent reports them |
| The agent’s transcript | A byte-for-byte copy |
| Your commits | A record in your repository’s `.git` linking each change to the step that made it ([Read a commit](../../guides/read-a-commit/)) |
## Not seen
[Section titled “Not seen”](#not-seen)
| What | Why | How it shows |
| ----------------------------------- | ------------------------------------------------------------------ | ------------------------------------------------------- |
| Thinking text the provider encrypts | The agent never has it in plain text | `thinking redacted` |
| Changes while the service was down | No baseline to compare against | `not recorded delivered-late` |
| Changes between visits | Nothing was recording | `not recorded not-recording-between-visits` |
| A session whose hooks never ran | Only the agent’s file exists | `in (from session file)`, `not-recorded-live` |
| Edits by other processes | Not a tool call | `external-or-unknown` |
| A tool that never reported back | No result arrived | `no result recorded` |
| Files over the size limit | 1 MiB each (`recording.maxFileMB`), 64 MiB of file contents in all | `not recorded oversize-file` or `baseline-memory-limit` |
| Projects over 10,000 files | Live recording stops; the agent’s own session file is still read | The session is `degraded`, `not recorded capture-error` |
| What changed inside a binary file | It has no lines to diff | `patch not recorded: binary-or-non-utf8` |
Folders such as `.git`, `node_modules`, `dist` and `build` are never diffed, and don’t count toward these limits. You can [leave out more](../../guides/record-sessions/#leaving-files-out).
## Per agent
[Section titled “Per agent”](#per-agent)
| | Claude Code | Codex | Pi |
| --------------- | ------------- | ------------------------------ | ------------- |
| Reports through | Hooks | Hooks, once trusted | Extension |
| Thinking | When recorded | Usually encrypted | When recorded |
| Cost | Per session | Not reported (Usage estimates) | Per message |
Versions and details: [Harness support](../../reference/harness-support/).
# Installation
> Install Wisdom with npm, check it works, update or remove it.
Wisdom is one npm package. Install it once per machine, then connect each project you want to record.
## Requirements
[Section titled “Requirements”](#requirements)
* **Node.js 24 or newer.** Wisdom uses the SQLite built into Node, so there’s no database to install. On an older Node, every `wisdom` command stops with `Wisdom needs Node.js 24 or newer. This is v22.x.` Check yours with `node --version`.
* **Claude Code, Codex (0.164.0 or newer) or Pi.**
## Install
[Section titled “Install”](#install)
Terminal
```sh
npm install -g @oqura/wisdom
wisdom --version
```
The same commands work on macOS, Linux and Windows. If Windows PowerShell blocks scripts, use `npm.cmd` and `wisdom.cmd` in their place.
Install globally, not with npx
Each project’s hooks store the path to the installed copy of Wisdom. An `npx` copy lives in a cache folder that can disappear, and recording stops with it.
## Check a project
[Section titled “Check a project”](#check-a-project)
Terminal
```sh
wisdom doctor
```
Run it inside a project. It checks the background service, Usage and Commits, each agent’s hooks and version, `wisdom.yaml`, any events waiting to be recorded, and team mode when it’s on. It changes nothing, prints the command that fixes each problem it finds, and exits with code 1 when there is one.
## Update
[Section titled “Update”](#update)
Terminal
```sh
wisdom daemon stop # in each project
npm install -g @oqura/wisdom@latest
wisdom doctor
```
Then run `wisdom connect` again in each connected project (`wisdom init` in a tracked one). It refreshes the hooks, the reading skill and, in [team mode](../../team/set-up/), the git hooks. Your recorded sessions are kept across updates.
Wisdom’s repository moved to [wisdomlayer/wisdom](https://github.com/wisdomlayer/wisdom). The npm package is still `@oqura/wisdom`, so the install command is the same.
Switched Node versions?
Version managers such as nvm keep global packages per Node version. If you switch, install Wisdom again under the new version, then run `wisdom connect` in each connected project (or `wisdom init` in a tracked one) to point its hooks at the new copy.
## Uninstall
[Section titled “Uninstall”](#uninstall)
1. In each connected project, remove Wisdom’s hooks and stop the service:
Terminal
```sh
wisdom disconnect
wisdom daemon stop
```
If you turned on commit guides or team mode, also remove Wisdom’s git hooks: `wisdom guide off` or `wisdom team hooks off`. `disconnect` leaves them in place.
2. Remove the package:
Terminal
```sh
npm uninstall -g @oqura/wisdom
```
3. Decide about your recordings. They stay in each project’s `.wisdom/` folder, and your settings in `wisdom.yaml`, until you delete them. To delete a project’s recordings, and in a tracked project its agents’ logins, for good:
Terminal
```sh
rm -rf .wisdom # macOS, Linux
Remove-Item -Recurse -Force .wisdom # Windows PowerShell
```
Commit records stay in `.git`, under `refs/wisdom/`.
If you uninstalled before stopping a service, it keeps running until you end it. Its process ID is in `.wisdom/daemon.json`.
Wisdom never changes `~/.claude`, `~/.codex` or `~/.pi/agent` (except for a copy you chose to [delete](../../guides/delete-sessions/)), so your agents work exactly as before.
Next: [Quick start](../quick-start/).
# What is Wisdom?
> An open-source recorder for coding agents, and the way you and your agents read what it recorded.
Wisdom records your coding agent’s sessions on your own machine: what you asked, what the agent ran, which files it changed, and what it said it did. You read those sessions in the terminal or in Usage, a local viewer, and your agents read them through a skill, so the next agent starts from what actually happened.
It works with:
* [Claude Code](https://code.claude.com)
* [Codex CLI](https://developers.openai.com/codex)
* [Pi](https://pi.dev)
Terminal
```sh
npm install -g @oqura/wisdom # Node.js 24 or newer
cd your-project
wisdom connect # then start your agent here as usual
```
That’s the whole setup. [Quick start](../quick-start/) walks through it and reads your first session back.
## What you can do with it
[Section titled “What you can do with it”](#what-you-can-do-with-it)
* Review an agent’s work against the request behind it, not only against its final reply.
* See the test that failed before the fix, and the approach the agent tried and dropped.
* Hand unfinished work to another agent, even a different one, that reads the session first.
* Go on in [the same session](../../guides/resume-a-session/), or in [a copy of it](../../guides/clone-a-session/), yours or a teammate’s.
* Review a teammate’s pull request with the session behind each commit, in [team mode](../../team/set-up/).
* Find the session behind a change weeks later, [starting from its commit](../../guides/read-a-commit/), from the terminal or from any agent.
A diff shows what changed. The session shows why, and it’s gone once the terminal closes unless something records it.
## How it works
[Section titled “How it works”](#how-it-works)

1. Your agent’s own hooks send each event (a prompt, a tool call, its result) to a small background service on `127.0.0.1`.
2. The service saves it in the project’s `.wisdom/` folder, together with a byte-for-byte copy of the agent’s transcript and a diff of every file change it observed.
3. You read it in the terminal or in your browser. Your agents read it through a skill Wisdom gives them.
4. When you commit, Wisdom keeps a record in your repository’s `.git` that links each change to the step that made it. In [team mode](../../team/set-up/), your `git push` shares those records and their sessions with your team.
More detail in [How it works](../../concepts/how-it-works/).
## Where to start
[Section titled “Where to start”](#where-to-start)
[Installation](../installation/)Node.js 24 and one npm command.
[Quick start](../quick-start/)Record your first session and read it back, in about five minutes.
[Record sessions](../../guides/record-sessions/)The two ways to record, and which one to pick.
For coding agents, these docs are also published as plain text: [`llms.txt`](/wisdom-docs/llms.txt) is the index, and [`llms-full.txt`](/wisdom-docs/llms-full.txt) has every page in one file.
## Common questions
[Section titled “Common questions”](#common-questions)
Does it slow down my agent?
Each hook sends one request to a service on your own machine and waits for its answer. If the service is down or takes over 10 seconds, the hook writes the event to disk and the agent carries on. Wisdom never refuses anything your agent does.
Does it send my code or prompts anywhere?
No. Everything stays in the project’s `.wisdom/` folder. A recording leaves your machine only when you run [`wisdom share` or `wisdom export`](../../guides/share-a-session/), or push in [team mode](../../team/set-up/), which you turn on per repository. All of them check for secrets first. A [team dashboard](../../team/team-dashboard/), if your team sets one up, copies what was pushed to its Vercel project. See [Privacy](../../concepts/privacy/).
Does it use a model, or cost tokens?
Recording uses no model and costs nothing. Nothing is summarized. When one of your agents reads a session, that reading counts toward your agent’s own usage, like any other command output.
The one place a model writes anything is a [commit guide](../../guides/read-a-commit/#guides), and only when you ask for one or turn on team mode. By default it runs through your own Claude Code.
Do I need to change how I start my agent?
No. After `wisdom connect`, you start `claude`, `codex` or `pi` as usual, with your own login. See [Record sessions](../../guides/record-sessions/) for the one rule each agent has.
Does it change my global agent settings?
No. Wisdom never edits `~/.claude`, `~/.codex` or `~/.pi/agent`. It writes only to the project’s own settings, keeps them out of git, and `wisdom disconnect` removes exactly that.
# Quick start
> Connect a project, use your agent as usual, and read what it did. About five minutes.
Record one session with your normal agent login, then read it back in the terminal, in your browser, and through your agent.
You need:
* Wisdom [installed](../installation/) (Node.js 24 or newer).
* A project folder, ideally a git repository.
* Claude Code, Codex or Pi.
**Rather let your agent install and connect it?** Paste this into Claude Code, Codex or Pi, started in your project. When it’s done, restart the agent there and go on from step 2.
Setup prompt
```txt
Set up Wisdom (npm package @oqura/wisdom) in this project:
1. Run `node --version`. If it is older than 24, stop and tell me.
2. Install it globally: `npm install -g @oqura/wisdom`. Do not use npx.
On Windows PowerShell, use `npm.cmd` and `wisdom.cmd`.
3. In the project's top folder, run `wisdom connect` and show me its output.
4. Run `wisdom doctor` and tell me any problem it finds, with the fix it prints.
Do not edit any other files.
```
1. ### Connect your project
[Section titled “Connect your project”](#connect-your-project)
Terminal
```sh
cd your-project
wisdom connect
```
Wisdom adds its hook and reading skill to the project’s own agent settings, keeps those files out of git, and tells you how to start each agent:
Output
```txt
Wisdom is set up in /home/maya/invoice-api. Start your agent here as you always do, with your own login:
Claude Code claude (start it in this folder, not a subfolder)
Codex codex (trust this project if it asks, then review Wisdom's hooks once in /hooks)
Pi pi (start it in this folder, and trust this project when it asks)
Wisdom added its hook and reading skill to: .claude/settings.local.json, .codex/hooks.json, .pi/settings.json, .claude/skills/wisdom-ledger, .agents/skills/wisdom-ledger.
They are listed in .git/info/exclude, so git ignores them and they never reach your teammates. wisdom disconnect removes them.
Settings: wisdom.yaml, every default shown and commented out. Git ignores it.
Keep .wisdom/ private: it holds your sessions, unredacted. Git ignores it, but leave it out of zips and synced folders.
```
`wisdom.yaml` holds your own settings for the project, such as the ports and what to leave out of recordings. You don’t need to touch it; see [Files & config](../../reference/files-and-config/#wisdomyaml).
2. ### Use your agent as usual
[Section titled “Use your agent as usual”](#use-your-agent-as-usual)
Start it from the project’s top folder.
* Claude Code
Terminal
```sh
claude
```
Nothing else to set up. A session started in a subfolder isn’t recorded, because Claude Code loads project settings only from the top folder.
* Codex
Terminal
```sh
codex
```
The first time, Codex asks you to trust the project. Then run `/hooks` and approve Wisdom’s hooks. You do this once per project.
* Pi
Terminal
```sh
pi
```
The first time, Pi asks you to trust the project.
Ask it for something small, such as a fix with a test.
3. ### Read the session
[Section titled “Read the session”](#read-the-session)
In a second terminal, in the same folder:
Terminal
```sh
wisdom glance latest
```
You get one entry per turn: your prompt, the start of the agent’s reply, and what happened (tool calls, failures, changed files). To read a turn in full:
Terminal
```sh
wisdom open t1 --capture latest
```
This shows the turn in the order it happened: each tool call with its full input and output, the reply, and every file change as a diff.
4. ### Open Usage
[Section titled “Open Usage”](#open-usage)
Terminal
```sh
wisdom usage
```
It prints an address, `http://127.0.0.1:7435` by default. Open it in your browser to see the session update while your agent works. Once you commit, `wisdom commits` opens the same work from the git side.

5. ### Ask your agent about it
[Section titled “Ask your agent about it”](#ask-your-agent-about-it)
The reading skill from step 1 lets any connected agent read past sessions, including ones recorded from a different agent. Try:
Prompt
```txt
Read the last Wisdom session. What did it change, and did the tests pass?
```
Need a separate login per project?
`wisdom init` and `wisdom track claude` give each agent its own home inside `.wisdom/`. This also records sessions started from a subfolder. See [Record sessions](../../guides/record-sessions/).
## Next steps
[Section titled “Next steps”](#next-steps)
[Read a session](../../guides/read-a-session/)Positions like t3/c2, and what each label means.
[Read a commit](../../guides/read-a-commit/)See which step made each part of a commit.
[Hand off work](../../guides/hand-off-work/)Continue in another agent that reads this session first.
[Clone a session](../../guides/clone-a-session/)A new session that already holds this one's conversation.
[Share a session](../../guides/share-a-session/)Send one to a teammate, after a secret check.
# Let agents read sessions
> The skill every connected agent gets, what to ask it, and the optional MCP tool.
Your agents read sessions the way you do: `glance`, then `open`. Any agent can read any session, so Codex can read what Claude Code did, and the other way round.
## The skill
[Section titled “The skill”](#the-skill)
`wisdom connect` and `wisdom init` give each agent a skill that teaches it to run these in its shell:
Terminal
```sh
wisdom glance # recorded sessions, newest first
wisdom glance latest # one session: its shape and every turn
wisdom open t3 --capture latest # turn 3, whole
```
The skill also teaches an agent to hand a bug or a follow-up to another session, in the background, with [`wisdom handoff --emit`](../hand-off-work/#in-the-background).
Running `connect` or `init` again updates the skill to match your Wisdom version, and so does starting an agent with `wisdom track`. `wisdom doctor` tells you if it’s missing or old.
## What to ask
[Section titled “What to ask”](#what-to-ask)
Ask in plain words. The agent finds the session and the turn on its own.
* *Which session changed `src/totals.ts`, and was that on purpose?*
* *Read the last Wisdom session. Did the tests pass before it said they did?*
* *What did the Claude Code session try before it settled on this fix?*
* *Which session wrote the last commit, and did it do what I asked?*
For the last one, the skill uses [`wisdom glance --commit`](../read-a-commit/). It also tells your agents not to run `wisdom guide` unless you ask, since that calls a model on your account.
Here an agent checks a change against the request behind it:
Output
```txt
t3 in Add a one-line docstring to main() in jev_router/tool.py.
c4 Edit src/optim_jev/tools/jev_router/tool.py · ok · → p1
reply I added a one-line docstring to main().
p1 src/optim_jev/tools/jev_router/tool.py · modify · +2 −1 · observed during c4
def main() -> None:
- mode = sys.argv[1] if len(sys.argv) > 1 else ""
+ """Dispatch a JSON request from stdin to the handler named by argv[1]."""
+ mode =sys.argv[1] if len(sys.argv) > 1 else ""
```
The request and the reply both say “docstring”, but the diff shows the line below changed too. The agent sees the change, the request behind it, and where they differ.

Inside a recorded session, latest can be the agent itself
The newest session is often the one the agent is running in. To read an earlier one, it runs `wisdom glance` and names the session’s ID. The skill teaches this.
## Long answers through a shell
[Section titled “Long answers through a shell”](#long-answers-through-a-shell)
An agent’s shell can cut output shorter than Wisdom’s own 80,000 characters: Claude Code saves all of it to a file, and Codex takes out the middle. The skill teaches agents to notice, and to read the rest in pages with `--at` and `--from`:
Terminal
```sh
wisdom open t3 --capture 3f9c2a71 --at 412 --from 1 | head -n 300
wisdom open t3 --capture 3f9c2a71 --at 412 --from 301 | head -n 300
```
`complete` at the end describes Wisdom’s answer, not what the agent’s shell showed of it.
## In a sandbox
[Section titled “In a sandbox”](#in-a-sandbox)
A sandbox can let an agent read through a running service but not start a stopped one (Codex’s on Windows does this). The hooks normally start it first. If it isn’t running, run `wisdom daemon start` yourself, outside the sandbox.
## An agent Wisdom doesn’t record
[Section titled “An agent Wisdom doesn’t record”](#an-agent-wisdom-doesnt-record)
Copy the [`wisdom-ledger` skill](https://github.com/wisdomlayer/wisdom/tree/main/skills/wisdom-ledger) in through that agent’s own skill mechanism. It only needs a shell in the project’s folder.
## The MCP tool (optional)
[Section titled “The MCP tool (optional)”](#the-mcp-tool-optional)
Most agents don’t need it. It’s for an agent without a shell, or if you’d rather give a tool than a command. One read-only tool, `ledger`, returns the same text as the CLI. It takes `glance`, `open`, `capture`, `commit`, `from` and `at`. It can’t start an agent or edit code. `wisdom track` already passes it to Claude Code and Codex. Starting it can start the background service.
To add it to another agent:
* macOS / Linux
MCP settings
```json
{
"mcpServers": {
"wisdom": {
"command": "wisdom",
"args": ["mcp", "--data", "/path/to/your-project/.wisdom"]
}
}
}
```
* Windows
MCP settings
```json
{
"mcpServers": {
"wisdom": {
"command": "cmd",
"args": ["/c", "wisdom", "mcp", "--data", "C:/path/to/your-project/.wisdom"]
}
}
}
```
# Clone a session
> Carry a session on as a new one that already holds its conversation, one you imported or your own.
A clone is a **new** session of the same agent that already holds another session’s conversation. The agent carries on as if it had done that work itself. The original is never changed.
Terminal
```sh
wisdom clone 3f9c2a71
```
**A recorded session**imported, or your own
**wisdom clone**copies the conversation, with a new ID
**The agent opens**it remembers all of it
**Recorded from here**your next prompt is its t1
## When to use it
[Section titled “When to use it”](#when-to-use-it)
* **Carry on a session shared with you.** You can’t resume someone else’s recording, so a clone is how you continue it with the whole conversation, in your own checkout.
* **Try another direction** in your own work, without touching the session that works.
* **Start several attempts** from the same point. Each clone is a session of its own.
If you want the agent to *read* what happened instead of remembering it, or you want a different agent, use a [handoff](../hand-off-work/). If you want to go on in the same session, use [resume](../resume-a-session/).
| | Same session? | What the agent knows | Agent |
| ------------------------------ | ---------------------------------- | ----------------------------- | -------- |
| [Resume](../resume-a-session/) | Yes | Everything, as its own memory | The same |
| **Clone** | No, a new one | Everything, as its own memory | The same |
| [Handoff](../hand-off-work/) | A new one, or another existing one | What it reads from the record | Any |
## Clone a shared session
[Section titled “Clone a shared session”](#clone-a-shared-session)
After [`wisdom share`](../share-a-session/) on their machine and `wisdom import` on yours, clone it:
Terminal
```sh
wisdom import 3f9c2a71-20261111-1402.wisdom-share
wisdom clone 3f9c2a71
```
Output
```txt
Cloned claude-code session 3f9c2a71-8d4e-4b1a-9c55-2e7f0b6d1a90 (shared from invoice-api), 3 turns, into new session 3bc87174-4faa-44d9-9860-2d2f81a20c60.
Wisdom records it from here on. The cloned turns stay readable in the original.
Note: 2 files differ on disk from what this session remembers: src/totals.ts, test/totals.test.ts.
```
Then the agent opens in your terminal, with the conversation in place. If the agent can’t start, the clone is kept and Wisdom prints the command that starts it later.
Read the note about files
A clone copies the conversation, not your files. The agent will remember edits as they were. Wisdom compares each file the session changed with your disk and names the ones that differ, so tell the agent to read those again.
Folder paths are rewritten to your project in the copy. Paths inside old tool output stay as they were. To match their files as well, check out the commit or branch they worked on first. You still need the same agent installed and your own login.
## Clone your own session
[Section titled “Clone your own session”](#clone-your-own-session)
To go on where you stopped, you usually want [resume](../resume-a-session/). Clone when you want a second attempt and the original left alone. There’s nothing to share or import. Use the session’s ID, its first 8 characters or more, or `latest`:
Terminal
```sh
wisdom glance # find it
wisdom clone 3f9c2a71
```
Output
```txt
Cloned claude-code session 3f9c2a71-8d4e-4b1a-9c55-2e7f0b6d1a90, 3 turns, into new session bd19c3f3-17e2-4563-8e2d-bcccd636dae3.
Wisdom records it from here on. The cloned turns stay readable in the original.
Note: 1 file differs on disk from what this session remembers: src/totals.ts.
```
## How a clone is recorded
[Section titled “How a clone is recorded”](#how-a-clone-is-recorded)
A clone’s glance says where it came from:
Output
```txt
session bd19c3f3-17e2-4563-8e2d-bcccd636dae3 · claude-code 2.1.319 · closed (idle) · version 53
resume with: wisdom resume bd19c3f3-17e2-4563-8e2d-bcccd636dae3
…
cloned from 3f9c2a71-8d4e-4b1a-9c55-2e7f0b6d1a90 (claude-code) at version 38 · 3 turns
…
not recorded history-cloned:The first 3 turns happened in 3f9c2a71-8d4e-4b1a-9c55-2e7f0b6d1a90; their file changes were made there, not here. (seq 3)
t1 in now do the same for credit notes
```
* **Only prompts after the clone are its turns.** The copied ones are read in the original.
* **Usage** shows the copied turns as a collapsed **Cloned history** block that opens the original.
* **Deleting the original** doesn’t delete the clone. The clone then says it came from a deleted session, and the copied turns can no longer be read in Wisdom.
## Where it goes, and options
[Section titled “Where it goes, and options”](#where-it-goes-and-options)
In a connected project the copy goes into your own agent’s home, so it opens with your normal login. Otherwise it goes into the agent’s home inside `.wisdom/`.
| Option | What it does |
| ------------------------------------------------ | ------------------------------------------------------------------------------------------------ |
| `--cwd DIR` | The project to clone in. |
| `--trust-all-hooks` | Codex only: skip the hook review for **every** hook in that run. Only in repositories you trust. |
| `--claude-bin`, `--codex-bin`, `--pi-entry FILE` | Use another installation of the agent. |
## Limits
[Section titled “Limits”](#limits)
* **Same agent only.** A Claude Code conversation can’t become a Codex one.
* **The whole history goes to your model** with the first prompt, and that usage counts. For a very long session, a [handoff](../hand-off-work/) starts lighter.
* **It needs the agent’s transcript.** A session Wisdom holds no transcript copy of can’t be cloned; Wisdom says so and suggests reading it or handing off.
* **Another login is not confirmed yet.** Claude Code signs its thinking and Codex encrypts its reasoning, and whether a clone resumes under a different login than the one that recorded it hasn’t been tested. Claude Code, Codex and Pi all find and open a clone; Pi was resumed in full with a scripted model.
# Usage, the session viewer
> The local web viewer for a project's sessions, live while your agent works.
Usage shows a project’s sessions in your browser, live while your agent works. It starts with the background service and listens only on your own machine. Your agents read the same sessions through their skill instead.
Terminal
```sh
wisdom usage # prints the address, http://127.0.0.1:7435 by default
```
`wisdom dashboard`, its earlier name, does the same. If the service isn’t running, start it first with `wisdom daemon start`. For commits rather than sessions, the same service runs a second viewer, [Commits](../read-a-commit/#in-the-browser).
* Overview
Every session across Claude Code, Codex and Pi, with tool usage, the most-changed files, tokens, and disk space.

* Chat view
A session as a conversation: one box per request, with its steps folded (thinking, each tool call, each change) and the response rendered as Markdown.

* Dev view
The record as a tree: request → tool calls → file changes, with subagents under the call that started them. Select any node to inspect its input, output or diff.

## Also in Usage
[Section titled “Also in Usage”](#also-in-usage)
| Feature | What it does |
| ------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Tokens and cost | Fresh input, cache read, cache write, output, reasoning and cache hit rate, per agent, model, session and request. Cost is what the agent reports. Codex reports none, so it’s estimated at OpenAI’s standard API prices and labelled as an estimate. Agents reading the ledger see only reported cost. |
| Shared sessions | The ones you [imported](../share-a-session/#import), or fetched from your team, under **Shared with you**. |
| Continue a session | A command to copy that resumes the session from any terminal, still recording. |
| Linked sessions | Handoffs from both ends, and a clone’s copied turns as a collapsed **Cloned history** block. |
| Repair | **Repair…** rewrites broken hooks or an old skill. It backs up every file first, in `.wisdom/backups/`, and can restore each backup. |
| Health | The same checks as `wisdom doctor`, at the top of every page. See [Keep it healthy](../keep-it-healthy/). |
| Storage | Space per session, and [deleting](../delete-sessions/) old ones. |
| Display | Light, Dark and Night themes and a text size, remembered per browser. |
Usage never affects recording. If it can’t start, capture carries on and `wisdom doctor` says why. To run the service without Usage and Commits: `wisdom daemon start --no-dashboard`, or `daemon.dashboard: false` in [`wisdom.yaml`](../../reference/files-and-config/#wisdomyaml).
# Delete sessions
> Remove a recorded session for good, free up space, and what stays behind.
You delete sessions in [Usage](../dashboard/); there’s no command for it. Wisdom never deletes anything on a schedule.
## Delete one
[Section titled “Delete one”](#delete-one)
Open the session in Usage and press **Delete**. A dialog lists what goes and how big it is. Nothing is deleted until you confirm.
## Delete old ones
[Section titled “Delete old ones”](#delete-old-ones)
On the Usage overview, **Storage** shows the space used by each session, the database and each agent’s home. **Clean up…** lists sessions not active for 30 days (change the number). Pick some or choose all, and the same dialog then shows exactly what goes.
## What goes and what stays
[Section titled “What goes and what stays”](#what-goes-and-what-stays)
| Part | What happens |
| -------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| The session’s record and evidence | Deleted. Its rows are overwritten inside the database, not only unlinked. |
| Its transcript and own files in the project’s agent home | Deleted. |
| A connected session’s copy in your own agent home (`~/.claude`, for example) | Kept, unless you tick the box. Ticked, the agent can no longer resume it. Left off, the agent still can, but Wisdom doesn’t record it again. |
| Prompt history all sessions share (`history.jsonl`, and Codex’s `session_index.jsonl`) | Only this session’s own lines go. In your own agent home, only with the box ticked. If the agent keeps writing to the file, Wisdom leaves it as it was and says so. |
| Codex’s own databases | Never edited, so a Codex session’s text can remain there. |
| Sessions that continue it or were cloned from it | Kept. They now say they came from a deleted session. |
| Other sessions’ prompts and output | Not edited, so they may still mention its ID. |
| A commit’s record in `.git` | Kept. Its steps then show `(session not available)`. |
Wisdom keeps one hash of the session’s ID in `.wisdom/deleted.json`, so the session is never recorded again.
Caution
Deleting can’t be undone. A session that is still recording can’t be deleted until it ends. If another session that links to it is still recording, the dialog names it, because its agent may still be reading the one you delete.
## Before you delete: model guides
[Section titled “Before you delete: model guides”](#before-you-delete-model-guides)
A [model guide](../read-a-commit/#guides) reads the sessions behind a commit. Once one of them is deleted, `wisdom guide ` can’t write it any more. The plain guide still works, without the quoted request of the deleted turn.
## Delete from the team’s remote
[Section titled “Delete from the team’s remote”](#delete-from-the-teams-remote)
Deleting in Usage is local. To remove a session your pushes sent, see [Remove a session](../../team/manage/#remove-a-session). Sessions shared with you have no **Delete** button; a teammate’s fetched session goes when the team deletes it and you run `wisdom team fetch`.
## Delete everything
[Section titled “Delete everything”](#delete-everything)
To remove all of a project’s recordings, and in a tracked project its agents’ logins, stop the service and delete the folder. See [Uninstall](../../getting-started/installation/#uninstall).
# Export as Markdown
> Turn a session into one Markdown document for a pull request, an issue or anyone without Wisdom.
An export is one Markdown file that anyone can read, with or without Wisdom. Use it in a pull request description, an issue, or your own notes.
Terminal
```sh
wisdom export 3f9c2a71 # saved in .wisdom/shared-out/
wisdom export 3f9c2a71 --out session.md # choose the file
wisdom export 3f9c2a71 --redact --out - # print it, to paste or pipe
```
With `--out -` only the document goes to standard output; every message goes to standard error. So you can pipe it:
Terminal
```sh
wisdom export 3f9c2a71 --redact --out - | clip # Windows
wisdom export 3f9c2a71 --redact --out - | pbcopy # macOS
```
## What’s in it
[Section titled “What’s in it”](#whats-in-it)
Everything, in recorded order: each prompt and reply in full, each tool call as a folded block with its whole input and output, and each turn’s changes as raw `diff` blocks. Gaps appear where they happened. Recorded thinking is folded too, and thinking the agent didn’t record is named, not hidden. Nothing is summarized or cut, and there’s no length limit.
This is how one starts:
3f9c2a71.md
````md
# totals are off by a cent on some invoices, find out why · claude-code session 3f9c2a71
claude-code 2.1.319 · 2026-12-02 16:53Z · 3 turns · 9 tool calls · 1 failed · 3 changes · 320,104 tokens
Session `3f9c2a71-8d4e-4b1a-9c55-2e7f0b6d1a90`, read at version 38. Recorded evidence in recorded order: nothing below is summarized or reworded.
## t1 · totals are off by a cent on some invoices, find out why
**Prompt**
> totals are off by a cent on some invoices, find out why
t1/c1 · Bash · ok
**Input**
```
{
"command": "rg -n \"round(\" src"
}
```
````
GitHub, GitLab and most editors open and close the folds. The calls keep the numbers `wisdom open` uses, so a reader who does have Wisdom can open `t1/c1` directly.
## Before it’s written
[Section titled “Before it’s written”](#before-its-written)
The same [secret check](../share-a-session/#the-secret-check) as `wisdom share` runs first, with the same choices. In a script, pass `--redact` or `--keep-secrets`; without either, nothing is written when the check finds something. Your own recording is never changed.
Your own sessions and shared ones both export. A shared one says so.
Caution
The check finds the shapes it knows and will miss others. Look through the file before you post it.
## Export or share?
[Section titled “Export or share?”](#export-or-share)
| You want to… | Use |
| ------------------------------------------------------- | --------------------------------------------------------- |
| Show someone what happened | `wisdom export`: Markdown, readable anywhere |
| Let a teammate’s agent read it, clone it or continue it | [`wisdom share`](../share-a-session/): one file to import |
| Share every commit’s sessions automatically | [Team mode](../../team/set-up/) |
# Hand off work
> Continue in another agent, or another session, that reads the first one before it starts.
An agent runs out of context, or you want a different one to finish the job. Wisdom gives you three ways to carry the work on:
| You want to… | Use | What you get |
| ------------------------------------------------- | --------------------------------------- | ------------------------------------------------------------- |
| Continue in **another agent**, or another session | `wisdom handoff` | A new session that reads the old one first |
| Continue **the same session** | [`wisdom resume`](../resume-a-session/) | The same session, still recording |
| Continue **a copy** of a session | [`wisdom clone`](../clone-a-session/) | A new session of the same agent, holding the old conversation |
## Handoff
[Section titled “Handoff”](#handoff)
Terminal
```sh
wisdom handoff codex
```
This starts a new Codex session whose first prompt names the newest session from another agent (or else Codex’s own) and tells Codex to read it with `glance` and `open` before changing anything.
**Claude Code session**recorded by Wisdom
**wisdom handoff codex**first prompt names the session
**Codex reads it**`glance`, then `open` the turns it needs
**Codex continues**linked to the session it read
Nothing is summarized or pasted in. The first prompt is written from facts: your words, the session’s ID and how many turns it has, the files it changed, and the branch, commit and files not yet committed. Handing into an existing session, it also names its own files that changed on disk since it last worked. The agent reads the record itself, as much as it needs. Claude Code may run Wisdom’s reading commands without asking you; anything else asks as usual. To add the same words to every handoff, set `handoff.extra` in [`wisdom.yaml`](../../reference/files-and-config/#wisdomyaml).
Terminal
```sh
# name the session to read (full ID)
wisdom handoff pi --from 0f3c8a1e-…
# add what it should know to the first prompt
wisdom handoff codex "the tests fail on CI"
# an existing session reads another one
wisdom handoff 0f3c8a1e-… --from 01a1aca0-…
```
### What the other agent is told
[Section titled “What the other agent is told”](#what-the-other-agent-is-told)
This is the whole first prompt for `wisdom handoff codex "the tests fail on CI"`, with the session from the [home page](/wisdom-docs/):
First prompt
```txt
Wisdom session 3f9c2a71-8d4e-4b1a-9c55-2e7f0b6d1a90 (claude-code) hands its work to you.
From the person handing it off: the tests fail on CI
Read it, and check its claims against its own evidence: run `wisdom glance 3f9c2a71-8d4e-4b1a-9c55-2e7f0b6d1a90`, then `wisdom open --capture 3f9c2a71-8d4e-4b1a-9c55-2e7f0b6d1a90` for the turns you need. It has 3 turns; start with t3, the newest. It changed src/totals.ts, test/totals.test.ts.
The work is on branch main at a4c91e2, with 0 files not committed.
Before changing anything, read it. Then say in a few lines what you understood and what you will do first.
```
When an agent runs the handoff from inside its own session, its words are labelled `From that session` instead.
Good words are short: the goal, what you found (with positions such as `t3/c2`), what you ruled out, and what you want back. Wisdom adds the facts itself.
### How the sessions are linked
[Section titled “How the sessions are linked”](#how-the-sessions-are-linked)
A glance of the session that took the work shows the link: `continues ()` for a new one, `continued after () · at t5` for an existing one. Usage shows it from both ends. One handoff links one session: a `/clear` or `/new` later in the same terminal isn’t a continuation.
Note
A session that’s still running can’t take outside input. Handing off into one prints the prompt for you to paste instead, and the command for a new session.
Resuming a very long session (past `handoff.longSessionTokens`, 150,000 by default) prints a note that a new session starts lighter.
### In the background
[Section titled “In the background”](#in-the-background)
Add `--emit` to hand off without opening anything. The other session reads in the background and changes nothing, so you, or the agent that ran the command, keep working:
Terminal
```sh
wisdom handoff 0f3c8a1e-… --emit "the totals test fails on CI; check what t3 changed"
```
When it’s done, the command prints `Handoff complete: …` with that session’s reply in four parts: what happened, what is still open, conflicts with its own earlier work (or its questions, for a new session), and what it would do next. If that agent fails, it prints `Handoff failed: …` and where its log is. The work goes on there when you open it with `wisdom resume`. Ctrl+C stops the waiting, not the handoff, and replies are kept in `.wisdom/handoffs/`.
* **Claude Code** runs it with no editing tools: its shell can only run `wisdom glance` and `wisdom open`, and it can read the project’s files. **Codex** runs it in its `read-only` sandbox, once its hooks are trusted. **Pi** can’t take an emitted handoff, since it reads only through its shell, but it can send one.
* Run from inside a Claude Code session, a handoff reads that session by default. From Codex or Pi, name it with `--from`.
* Your agents can do this too: the reading skill teaches them to hand a bug or a follow-up to another session with `--emit`.
## Not a handoff?
[Section titled “Not a handoff?”](#not-a-handoff)
To go on in the same session, see [Resume a session](../resume-a-session/). To go on in a copy that already remembers everything, see [Clone a session](../clone-a-session/).
# Keep it healthy
> Check, repair, run the background service, and clean up old sessions.
Wisdom mostly runs on its own. When a session isn’t recorded, or after you move Wisdom or change Node versions, start here.
## Check
[Section titled “Check”](#check)
Terminal
```sh
wisdom doctor
```
Checks the background service, Usage and Commits, each agent’s hooks, skill and version, Codex hook trust, events waiting to be recorded, and `wisdom.yaml`. In team mode it also checks the team file, its trusted commands, whether `git pull` brings commit links, and links waiting to be sent. It changes nothing, prints the fix for each problem, and exits with code 1 when there is one.
| Level | Meaning |
| --------- | ----------------------------------------------------------------------------------------------------------------------- |
| `ok` | Working. |
| `note` | Worth knowing: the service is stopped (it starts by itself), or an agent isn’t the version Wisdom was last tested with. |
| `problem` | Recording or reading is affected until you run the fix. |
A healthy project looks like this:
Output
```txt
Wisdom 0.6.1 · Node 26.13.0
Project /home/maya/invoice-api
ok Daemon running at http://127.0.0.1:7434 (PID 14144), 45 sessions
ok Usage http://127.0.0.1:7435
ok Commits http://127.0.0.1:7436
note Claude Code hooks in place in the project's settings (your own login), skill installed, version 2.1.335, last tested with 2.1.317
note Codex hooks are not trusted yet (10 to review), so sessions are read from their files only
fix: codex, here: trust this project, then review Wisdom's hooks in /hooks
ok Pi hooks in place in the project's settings (your own login), skill installed, version 1.2.0
ok Spool no events waiting
ok Settings wisdom.yaml reads correctly
No problems found.
```
For a symptom rather than a check, see [Troubleshooting](../../help/troubleshooting/). The same checks run at the top of every page in [Usage](../dashboard/).
## Repair
[Section titled “Repair”](#repair)
Hooks store the full path of the installed Wisdom. They break when that path changes: you moved the install, or switched Node versions with nvm. Your agent keeps working either way; only live recording stops.
Terminal
```sh
wisdom connect # a connected project
wisdom init # a tracked project
```
Both are safe to run again. In Usage, **Repair…** does the same and backs up every file it changes first, so you can restore it. Codex asks you to approve changed hooks again in `/hooks`.
## The background service
[Section titled “The background service”](#the-background-service)
It starts by itself when a hook or command needs it, and keeps running after your agent exits.
Terminal
```sh
wisdom daemon status
wisdom daemon stop # the next hook starts it again
wisdom daemon start
```
It listens on `127.0.0.1:7434`, with Usage and Commits on the next two ports. If another project already uses them, it takes the next free three. Each project has its own service, and about 20 can run at once.
## Storage and delete
[Section titled “Storage and delete”](#storage-and-delete)
The Usage overview shows how much space each session takes, and cleans up old ones. See [Delete sessions](../delete-sessions/).
## A degraded session
[Section titled “A degraded session”](#a-degraded-session)
`degraded` means recording stopped for that session because of an error, which the glance names under `not recorded capture-error`. Its next event tries again.
The usual cause is a project with more than 10,000 files: `Workspace exceeds 10000 files`. Skip the folders you don’t need diffed with `recording.skipFolders` or `recording.ignore` in [`wisdom.yaml`](../../reference/files-and-config/#wisdomyaml), then start a new session.
## Commit guides
[Section titled “Commit guides”](#commit-guides)
Each commit’s record and guide are made by a background job after the commit. It writes one line to `.wisdom/jobs.log` when it ends:
.wisdom/jobs.log
```txt
2026-11-11T09:41:02.118Z a4c91e2b7f30 job · record kept · guide by claude-haiku-5-5 via Claude Code, reading the sessions' windows, check passed, writer 38.4 s, $0.0031 · 40 s
```
A job that died is started again, up to three times; after that your next `git push` or `wisdom guide ` finishes it. When that’s more than two minutes after the commit, the record says `record kept later`.
| You see | What to do |
| ---------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------ |
| `guide · none: no guide writer: Claude Code is not installed and wisdom-team.yaml names no guides.command` | Install and log in to Claude Code, or use `wisdom guide off` for the plain guide. |
| `guide · none: the guide writer failed: …` | The writer’s own error follows. `wisdom guide ` tries again. |
| `No guide written: the guide must read session …, which is no longer recorded here` | That session was deleted, so a model guide can’t be written. Outside team mode, `glance --commit` still shows the plain guide. |
## Move or back up a project
[Section titled “Move or back up a project”](#move-or-back-up-a-project)
Stop the service first (`wisdom daemon stop`), then move or copy the whole folder. Recording carries on in the new place, and sessions recorded there get a `project-moved` gap, since their older records name the old folder. Codex asks you to approve the changed hook again in `/hooks`. For a backup, copy all of `.wisdom/`, and treat the copy like a password: it holds your sessions unredacted, and in a tracked project, your agents’ logins.
# Read a commit
> Start from a git commit and see which recorded step made each part of it, with a short guide for reviewers.
[Read a session](../read-a-session/) starts from a session. This page goes the other way: start from a commit, and see which recorded step wrote each part of it.

Try it on your last commit:
Terminal
```sh
wisdom glance --commit HEAD # or a hash, or a branch
wisdom open t2/c1 --capture 3f9c2a71 # read a step it names
```
There’s nothing to set up. A commit your agent makes, or one you make from its work, is read the same way.
## From a line of code
[Section titled “From a line of code”](#from-a-line-of-code)
Find the commit the way you always do, then follow it into the session:
Terminal
```sh
git blame -L 9,10 src/totals.ts # the commit that wrote these lines: a4c91e2
wisdom glance --commit a4c91e2 # the steps that made them: t2/c1, t2/c4 in 3f9c2a71
wisdom open t2 --capture 3f9c2a71 # the request, the failing test, the fix
```
Three commands take you from a line in your editor to what was asked, what the agent ran, and what failed before it got there.
## In the browser
[Section titled “In the browser”](#in-the-browser)
Terminal
```sh
wisdom commits # prints the address, http://127.0.0.1:7436 by default
```
Commits is a page beside [Usage](../dashboard/) that starts from git rather than from a session: what landed on main, your other branches, each commit with how its record was found, its pieces, its guide and its sessions, and a session’s turns down to the chat view.
* **Only this machine.** Your branches, the records Wisdom keeps for your commits, and your recordings. It needs neither team mode nor a remote.
* **Live.** It checks every two seconds for new commits, branch moves and new recording, and the open page updates in place as you or an agent commit, amend or rebase.
* **Checked here, not trusted.** Each status is worked out again from your recordings: a step’s change must still be in its session, and a guide must pass its check. A session a record names that isn’t here shows as *needs attention*.
- Main
What landed on main and how: a status for each change, and a canvas of how it got there (merge, squash, direct).

- A commit and its session
A commit from #118, the steps that made it, and that turn opened beside it: the request, the edits, the test that failed and the run that passed.

Shown with the invoice-api example from these docs, built by Wisdom’s own Commits builder.
The sidebar has Main, Branches, People and Sessions. Choose a commit to see its pieces, then a step to open its turn beside it.
### What the statuses mean
[Section titled “What the statuses mean”](#what-the-statuses-mean)
| Status | When you see it |
| ------------------- | ---------------------------------------------------------------------------------------------------- |
| **all good** | Each piece has a recorded step, and the evidence checks out. |
| **look closer** | A piece was changed outside any recorded step, or seen by two sessions. |
| **needs attention** | Evidence is missing or doesn’t hold up. See below. |
| **no record** | The commit has no record or link: made without Wisdom, or a merge, which carries no work of its own. |
A status always comes with its reason. **Needs attention** means one of these:
| Reason | What to do |
| --------------------------------------- | ----------------------------------------------------------------------------------------------------------------- |
| A session isn’t here | It was deleted, or never pushed or fetched. In team mode, run `wisdom team fetch`. |
| Its record isn’t here | The commit names a record that is missing. Whoever made it runs `wisdom team push`. |
| No guide, or the guide failed its check | Run `wisdom guide `. |
| Tied by position only | A rebase merge paired two commits by their order, not by an identical change. Compare them yourself. |
| A cited step changed | The session no longer holds that step as recorded, such as after a redaction. Read the step before relying on it. |
No status judges the code. They say only how well the recording explains it.
For the whole team, the same app runs from your git remote: see [Team dashboard](../../team/team-dashboard/).
## An example
[Section titled “An example”](#an-example)
Here the agent from the [home page](/wisdom-docs/) fixed a rounding bug in t2 and committed it in t3. You also edited the README while nothing was recording.
\~/invoice-api
```txt
❯ wisdom glance --commit HEAD
commit a4c91e2b7f30 · fix: round invoice totals once · committed 2026-11-11 09:40Z · version 412
parent 7d2e9b1c04aa · 3 files · 3 pieces: 2 from recorded steps, 1 not recorded
record kept when the commit was made, 2026-11-11 09:40Z
the commit's own diff: git show a4c91e2b7f30
README.md · modify · +1 −0 · not recorded
src/totals.ts · modify · +2 −1
@@ -9,1 +9,2 @@ t2/c1, t2/c4 in session 3f9c2a71
test/totals.test.ts · create · +8 −0
@@ -0,0 +1,8 @@ t2/c2 in session 3f9c2a71
sessions
3f9c2a71-8d4e-4b1a-9c55-2e7f0b6d1a90 claude-code t2/c1, t2/c2, t2/c4 · window t1–t3
window: from the start of these sessions (no earlier commit of yours on this branch), up to this commit
To read a step, open its position in its session, such as {"capture":"3f9c2a71","open":"t2/c1"}.
guide · plain, built from the record now, no model · derived, not evidence · not stored; a model guide on request: wisdom guide a4c91e2b7f30
## Summary
fix: round invoice totals once. Written by Wisdom from the commit's record, without a model: which recorded step made each piece and what was asked in that turn. It does not say why beyond those requests.
## Items
- README.md (modify) · not recorded
No recording explains this change.
- src/totals.ts @@ -9,1 +9,2 @@ · t2/c1, t2/c4 in session 3f9c2a71
Made by [t2/c1 3f9c2a71] (claude-code). Asked in t2: "fix it and add a test". Made by [t2/c4 3f9c2a71] (claude-code).
- test/totals.test.ts @@ -0,0 +1,8 @@ · t2/c2 in session 3f9c2a71
Made by [t2/c2 3f9c2a71] (claude-code). Asked in t2: "fix it and add a test".
complete · 28 lines
```
A **piece** is one hunk of the commit’s diff against its parent, and its `@@` header matches `git show`. Each piece names the steps that made it. Open one with `wisdom open` to see the call, its input and output, and the turn it ran in.
## How a session is linked
[Section titled “How a session is linked”](#how-a-session-is-linked)
Every recorded file change keeps a hash of the whole file before and after it. Wisdom starts from the file as committed and follows those hashes back, change by change, to the file in the parent commit. Then it traces each line through the recorded diffs.
So a session is linked only because it produced these exact bytes, never because it touched a file with the same name. When two sessions saw the same edit and the record can’t tell which made it, the piece lists both rather than guess.
## Reading the labels
[Section titled “Reading the labels”](#reading-the-labels)
| Label | What it means |
| -------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `t2/c1 in session 3f9c2a71` | The step that wrote these lines or removed them. |
| `(changed outside any recorded step)` | A session saw the change while no tool was running: you, your editor, a formatter. `outside` when it fell between turns. |
| `not recorded` | Nothing recorded explains it: made before recording, while nothing was recording, or in a session that’s gone. |
| `2 lines not recorded` | Part of the piece is explained, part isn’t. |
| `whole file from …` | Lines couldn’t be matched (a binary file, a missing diff), so the steps that produced the file are listed. |
| `lined up by file, not by line` | The steps explain the file, but git lines this hunk up differently, for example around repeated lines. |
| `earlier changes not recorded` | The steps lead to the committed file, but not all the way back to the parent’s. |
| `excluded from recording` | The path is excluded, such as `node_modules` or anything in `.wisdomignore`. |
| `(changed since the commit)` | The session no longer holds that exact change. |
| `(reported by the harness)` | The agent’s own account of the change; Wisdom didn’t observe it. |
| `(session not available)` | The session isn’t here: deleted, or a teammate’s you haven’t fetched. |
| `squash merge of PR #12, from GitHub's pull request: it came from 2 commits; their records follow` | The commit has no record of its own, but a [link](../../team/how-sharing-works/#when-a-commit-gets-a-new-sha) to the commits it came from. Each of their records follows under `── from: `. |
| `amended, git reported the rewrite, from ` | The commit has its own record and came from another one; the line after it says how to read that one’s record. |
Every label is in the [vocabulary](../../reference/vocabulary/#commits).
## When Wisdom keeps a record
[Section titled “When Wisdom keeps a record”](#when-wisdom-keeps-a-record)
While the background service runs, it notices each commit you make in this clone, including ones your agent makes with your git identity, and keeps the answer as a **record**. The link then outlives the sessions it points to. It doesn’t keep one for merges, or for commits that arrive by pull or checkout. A renamed file reads as a delete and a create.
A commit with no record is worked out when you ask, from the recordings that are still here. The output then says `worked out now from the recordings`, and has no guide.
After `wisdom guide on`, and in team mode, Wisdom’s `post-commit` hook keeps the record instead.
Records live in your own `.git`, as `refs/wisdom/records/`. They’re never on a branch, and a normal `git push` doesn’t send them.
Caution
`git push --mirror` sends every ref, so it sends your commit records and guides too.
## Guides
[Section titled “Guides”](#guides)
A **guide** is a short account of a commit for whoever reviews it, citing the steps behind each piece. Read it as a summary, not as evidence: Wisdom checks that it covers every piece and that each citation exists, but not that it’s right. Only commits with agent work get one.
| Guide | How you get it | Model |
| ------------------------ | ---------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------- |
| Plain | Shown by `glance --commit` for any kept record with agent work. Built each time you read it, never stored. | None |
| Model, on request | `wisdom guide ` writes one now and keeps it in the commit’s record. | Claude Haiku 5.5 through your Claude Code, or `guides.model` in [`wisdom.yaml`](../../reference/files-and-config/#wisdomyaml) |
| Model, after each commit | `wisdom guide on`. `wisdom guide off` turns it back off. | The same |
The plain guide names each piece’s step and quotes what was asked in that turn. It says nothing about why beyond those requests.
A model guide reads the commit’s sessions from your previous commit on this branch up to this one, because the reason for a change often sits in an earlier turn. Besides a paragraph per piece, it has a short **Beyond the edits** section: where the agent didn’t do what was asked, reasons given in other turns, and the tests it ran and what they reported. On a big commit the model can run out of room before the end of the list; a piece it left out is filled from the plain guide, marked `From the record, no model`, and the guide says how many (`for 5 of 95 items; 90 from the record, no model`). Past 30 pieces, those made by the same steps share one item. A guide that doesn’t pass Wisdom’s check is asked for once more.
After `wisdom guide a4c91e2`, the end of `glance --commit` shows the model’s guide instead of the plain one. An example, for the commit above:
Output
```txt
guide · written by claude-haiku-5-5 via Claude Code, reading the sessions' windows, 2026-11-11 09:42Z · derived, not evidence · Wisdom checked that it covers every item and that its citations exist, not that it is right
## Summary
Invoice totals are now rounded once, after the sum, instead of per line, with a test for a long invoice.
## Items
- README.md (modify) · not recorded
The README gained one line. No recording explains this change.
- src/totals.ts @@ -9,1 +9,2 @@ · t2/c1, t2/c4 in session 3f9c2a71
The total is summed first and rounded once [t2/c1 3f9c2a71], because rounding each line made cents drift on long invoices [t1 3f9c2a71]. A second edit followed a failing test [t2/c4 3f9c2a71].
- test/totals.test.ts @@ -0,0 +1,8 @@ · t2/c2 in session 3f9c2a71
A new test checks a 40-line invoice [t2/c2 3f9c2a71].
## Beyond the edits
Departed from the request: none found in the window.
Reasons from other turns: t1 found that each line item was rounded before the sum [t1 3f9c2a71].
Tests run: npm test -- totals failed, expected 1204.37 and received 1204.3656 [t2/c3 3f9c2a71], then passed after the second edit [t2/c5 3f9c2a71].
```
The citations are positions you can open, so a reviewer can check each sentence against the recording.
* **Cost.** In Wisdom’s own tests a guide cost $0.0013 to $0.0081 at API prices. On a subscription, it comes from your plan.
* **What it sends.** The session text it reads goes to the model’s provider through your Claude Code login, as in any Claude Code session.
* **Its sessions must be here.** If a session the commit names was deleted, `wisdom guide` says so and writes nothing.
`wisdom guide on` adds one git hook, `post-commit`, in `.git/hooks`. It doesn’t change your commit messages and never pushes anything. If your repository tracks its hooks folder (Husky’s `.husky/`), Wisdom doesn’t write there and prints the line to add instead.
For your agents
The reading skill teaches your agents `glance --commit` too. It also tells them not to run `wisdom guide` unless you ask, since it calls a model on your account.
# Read a session
> See a session at a glance, open the turn that matters, and read its labels.
Reading a session takes two moves: **glance** to see its shape, then **open** the part that matters. Your agents use the same two moves, through their skill.
Terminal
```sh
wisdom glance # every recorded session, newest first
wisdom glance latest # one session: its shape and every turn
wisdom open t2 --capture latest # turn 2, whole
```
Name a session by its full ID, by its first 8 or more characters, or as `latest` (the newest session with a turn). Every command finds `.wisdom/` from the folder you’re in, like git finds `.git`.
To start from a commit instead, see [Read a commit](../read-a-commit/).
## Positions
[Section titled “Positions”](#positions)
Everything in a session has a short address. A glance shows them; `open` takes them.

| Position | What it opens |
| --------- | ------------------------------------------------------------------------ |
| `t3` | Turn 3: your third prompt and everything the agent did until it answered |
| `t3/c2` | The second tool call of turn 3, its full input and output |
| `a1` | The first subagent, laid out like a turn |
| `a1/c2` | A tool call of that subagent |
| `outside` | Calls and file changes outside any turn |
`p1`, `p2`… label the file changes inside a turn. They aren’t addresses: open the turn or the call to see them.
## Opening a turn
[Section titled “Opening a turn”](#opening-a-turn)
A turn comes back in recorded order: thinking, each call with its result, the reply, and then all the turn’s file changes together, as diffs. An example:
\~/invoice-api
```txt
❯ wisdom open t2 --capture latest
t2 · session 3f9c2a71 · version 412 · 168,204 tokens
in fix it and add a test
thinking redacted (it happened; its text was not recorded)
c1 Edit src/totals.ts · ok · 12 ms · → p1
input and output repeat p1 · open t2/c1 to read them
c2 Write test/totals.test.ts · ok · 9 ms · → p2
input and output repeat p2 · open t2/c2 to read them
c3 Bash · failed · 1.8 s
input {"command":"npm test -- totals"}
output
Exit code 1
✖ rounds a 40-line invoice once (2.1 ms)
expected 1204.37, received 1204.3656
c4 Edit src/totals.ts · ok · 10 ms · → p3
input and output repeat p3 · open t2/c4 to read them
c5 Bash · ok · 1.6 s
input {"command":"npm test -- totals"}
output
{
"stdout": "✔ rounds a 40-line invoice once (1.9 ms)",
"stderr": "",
"interrupted": false,
"isImage": false,
"noOutputExpected": false
}
reply Totals now round once, after the sum. A new test covers a 40-line invoice.
p1 src/totals.ts · modify · +1 −1 · observed during c1
--- src/totals.ts
+++ src/totals.ts
@@ -6,5 +6,5 @@
// Prices are in the invoice's currency.
export function invoiceTotal(lines: Line[]): number {
- return lines.reduce((sum, l) => sum + round(l.qty * l.price), 0);
+ return lines.reduce((sum, l) => sum + l.qty * l.price, 0);
}
p2 test/totals.test.ts · create · +8 −0 · observed during c2
--- /dev/null
+++ test/totals.test.ts
@@ -0,0 +1,8 @@
+import assert from 'node:assert/strict';
+import test from 'node:test';
+import { invoiceTotal } from '../src/totals.js';
+
+test('rounds a 40-line invoice once', () => {
+ const lines = Array.from({ length: 40 }, () => ({ qty: 3, price: 10.03638 }));
+ assert.equal(invoiceTotal(lines), 1204.37);
+});
p3 src/totals.ts · modify · +2 −1 · observed during c4
--- src/totals.ts
+++ src/totals.ts
@@ -6,5 +6,6 @@
// Prices are in the invoice's currency.
export function invoiceTotal(lines: Line[]): number {
- return lines.reduce((sum, l) => sum + l.qty * l.price, 0);
+ const raw = lines.reduce((sum, l) => sum + l.qty * l.price, 0);
+ return round(raw);
}
complete · 61 lines
```
Each piece of evidence is shown once. An edit’s input *is* its diff, so the call points to `p1` instead of repeating it. A file the agent read is listed by size; open the call to read it.
## The same text everywhere
[Section titled “The same text everywhere”](#the-same-text-everywhere)
The terminal prints the exact text your agents read: plain, uncoloured and unfolded. To keep a turn, send it to a file:
Terminal
```sh
wisdom open t2 --capture latest > turn.txt
```
## Reading the labels
[Section titled “Reading the labels”](#reading-the-labels)
These labels say how much the record can tell you:
| Label | What it means |
| ------------------------------ | ---------------------------------------------------------------------------------------------------------------------------- |
| `observed during c1` | The file changed while that call ran. Timing, not proof the call made it. |
| `external-or-unknown` | The file changed while no tool was running: you, your editor, another process. |
| `reported-by-harness` | The agent’s own account of a change Wisdom didn’t observe. |
| `thinking redacted` | The agent thought, but its text wasn’t recorded (Claude Code omits it; Codex encrypts it). |
| `not recorded` | A [gap in the recording](../../reference/recording-gaps/), with the reason. |
| `no result recorded` | The call never reported back. Not the same as success. |
| `in (harness notice)` | The agent’s own program woke it, such as a finished background command. Nobody asked this. |
| `script step` | Codex’s own scripting (`exec`, `wait`); the calls beside it are the real actions. |
| `pending` | The call has no result yet, and the session is still recording. |
| `in worktree bp3 (branch x)` | The path is inside that [git worktree](../../concepts/forks-and-subagents/#git-worktrees). |
| `cloned from …`, `continues …` | The session is [a clone](../clone-a-session/), or [took a handoff](../hand-off-work/). Earlier work is in the other session. |
| `ok` | The tool reported success. Not proof the code is right. |
Long answers
One answer holds at most 80,000 characters. A longer one ends with `limited · lines 1–1,950 of 41,230 · continue: {…}` and the exact way to get the rest: add `--from` and `--at` as shown. `--at` pins the version, so a session that’s still recording can’t change under you while you read.
# Record sessions
> Two ways to record Claude Code, Codex and Pi, and what happens when things go wrong.
Wisdom records an agent through the agent’s own hooks. There are two ways to put them in place. Most people only need the first.
| | **Connect** | **Track** |
| --------------------- | ------------------------------------------------- | -------------------------------------------------------------------- |
| Start your agent with | `claude`, `codex`, `pi`, as usual | `wisdom track claude` (or `codex`, `pi`) |
| Login | Your normal one | One per project, kept in `.wisdom/` |
| Hooks live in | The project’s own agent settings, kept out of git | The agent’s home inside `.wisdom/` |
| Records | Agents started in the project’s top folder | Every process using that home, from any folder |
| Best for | Everyday work | Subfolders, Codex in a git worktree, keeping everything in one place |
## Connect: your normal login
[Section titled “Connect: your normal login”](#connect-your-normal-login)
Terminal
```sh
cd your-project
wisdom connect
```
Wisdom adds its hook and reading skill to the project’s own settings for each agent:
| Agent | Settings | Skill |
| ----------- | ----------------------------- | ----------------- |
| Claude Code | `.claude/settings.local.json` | `.claude/skills/` |
| Codex | `.codex/hooks.json` | `.agents/skills/` |
| Pi | `.pi/settings.json` | `.agents/skills/` |
These paths go in `.git/info/exclude`, your clone’s own ignore file, so nothing reaches git. Wisdom only adds its own entries and leaves the rest of each file alone. Running `wisdom connect` again repairs them. To leave one agent out, set it to `false` under `harnesses` in [`wisdom.yaml`](../../reference/files-and-config/#wisdomyaml).
Each agent has its own rule for loading project settings:
* Claude Code
Start `claude` in the project’s **top folder**. Started in a subfolder, it doesn’t load the project’s settings, and that session isn’t recorded.
* Codex
Trust the project when Codex asks, then approve Wisdom’s hooks once in `/hooks`. Codex records from any folder in the project, but **not inside a git worktree**, where it ignores project hooks.
* Pi
Start `pi` in the project’s **top folder**, and trust the project when it asks.
To stop recording, run `wisdom disconnect`. It removes exactly what `connect` added. Your recordings are kept.
## Track: a home of its own
[Section titled “Track: a home of its own”](#track-a-home-of-its-own)
Terminal
```sh
wisdom init
```
`init` creates `.wisdom/` and gives each agent a home inside it, with Wisdom’s hooks already in place. Any process that uses that home is recorded, however it was started: a resume, a background `/fork`, a worktree. Then start an agent with `track`. Each one asks you to log in once per project.
* Claude Code
Terminal
```sh
wisdom track claude
wisdom track claude -- --continue # options after -- go to claude
```
* Codex
Codex runs a hook only after you review it. Do that once:
Terminal
```sh
wisdom track codex --setup-hooks # open /hooks, trust Wisdom's hooks, quit
wisdom track codex
```
* Pi
Terminal
```sh
wisdom track pi # run /login once inside Pi
```
Your global `~/.claude`, `~/.codex` and `~/.pi/agent` are never touched. Settings, plugins and MCP servers there don’t apply inside a tracked home.
Both in one project
You can connect and track the same project. A tracked session is recorded once, by its own home’s hook; the project’s copy stands aside.
## When something goes wrong
[Section titled “When something goes wrong”](#when-something-goes-wrong)
| Situation | What Wisdom does |
| ---------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| The background service is down | The hook keeps the event in `.wisdom/spool/` and starts the service. It shows a warning only if the service refused the event, answered too slowly or couldn’t be started. Kept events are recorded later, marked `delivered-late`. File changes in that time aren’t observed. |
| You resume a session | The same record continues. The time in between is marked `not-recording-between-visits`. |
| Hooks never ran (Codex hooks not yet trusted, for example) | Once the agent’s own session file has been quiet for two minutes, Wisdom reads it. Prompts show as `in (from session file)`, and the session is marked `not-recorded-live`. |
| The session goes quiet | After 10 minutes (`recording.idleMinutes` in `wisdom.yaml`) with no event and no running tool, the record closes as `idle`. The next event continues it. |
| You work in a linked git worktree | A session watches its project and any worktree it works in, and shows those changes with the worktree’s name and branch. Connected Codex is the exception: it ignores project hooks there. |
| `connect` says an agent is “not connected: git tracks …” | The project commits that agent’s settings file, and Wisdom won’t write your machine’s paths into a file your teammates share. Record that agent with `wisdom track` instead. |
## Leaving files out
[Section titled “Leaving files out”](#leaving-files-out)
To stop Wisdom diffing some files, add a `.wisdomignore` to the project: one relative path or folder per line, `#` for comments. There are no globs. `.git`, `node_modules`, `dist`, `build` and similar folders are skipped already. In `wisdom.yaml`, `recording.ignore` does the same, and `recording.skipFolders` skips a folder name wherever it appears.
This matters most in a big project: past 10,000 files, live recording stops and the session is marked [`degraded`](../keep-it-healthy/#a-degraded-session).
.wisdomignore
```txt
# generated
src/generated/
fixtures/large-dump.json
```
# Resume a session
> Continue a recorded session in its own agent and folder, and keep recording it.
Resume picks a session up where it stopped: the same agent, the same session ID, the same record.
Terminal
```sh
wisdom resume 3f9c2a71-8d4e-4b1a-9c55-2e7f0b6d1a90
```
Wisdom knows which agent the session belongs to and which folder it ran in, so you can run this from anywhere in the project. `wisdom glance` prints the exact command as `resume with:`, and a session’s page in Usage has a command to copy that works from any terminal.
Resume takes the **full** session ID, never a prefix or `latest`, so it can’t land in the wrong session.
## What happens to the record
[Section titled “What happens to the record”](#what-happens-to-the-record)
* **The turns go on.** If the session stopped at t3, your next prompt is t4.
* **The time in between is a gap.** Nothing was watching your files then, so the glance says `not recorded not-recording-between-visits`.
* **It stays in its home.** A connected session resumes with your normal login; a tracked one resumes in its home inside `.wisdom/`.
You don’t have to use `wisdom resume`. If you resume the agent’s own way (`claude --continue`, for example, in a connected project’s top folder), Wisdom’s hooks see the same session ID and continue the same record.
## Options
[Section titled “Options”](#options)
| Option | What it does |
| ------------------------------------------------ | ------------------------------------------------------------------------------------------------ |
| `--trust-all-hooks` | Codex only: skip the hook review for **every** hook in that run. Only in repositories you trust. |
| `--claude-bin`, `--codex-bin`, `--pi-entry FILE` | Use another installation of the agent. |
A teammate's session
An imported or fetched session is someone else’s recording, so it can’t be resumed. [Clone it](../clone-a-session/), or [hand it off](../hand-off-work/) to a new session that reads it.
If the command says `No recorded session has the ID …`, check that you passed the full ID, and that the session isn’t a shared one.
# Share a session
> Send a session to a teammate as one file, and read one you received.
Recordings never leave your machine on their own. These commands send one session by hand, and each one checks for secrets first. To share with every push instead, see [Set up team mode](../../team/set-up/).
**wisdom share**secret check, then one file
**You send it**chat, email, a drive
**wisdom import**on your teammate's machine
**Read-only copy**`glance`, `open`, clone or hand off
## Share
[Section titled “Share”](#share)
Terminal
```sh
wisdom share 0f3c8a1e
wisdom share 0f3c8a1e 01a1aca0 --out a.wisdom-share
```
This writes one file with the sessions’ records, diffs and transcript copies. It never holds logins. By default it goes to `.wisdom/shared-out/`, which git ignores.
## The secret check
[Section titled “The secret check”](#the-secret-check)
Before writing anything, Wisdom lists every value that looks like a secret (API keys, tokens, private keys, `PASSWORD=` and similar) or a personal detail such as an email address, masked, with where it appears:
Output
```txt
Found 2 possible secrets:
1 openai-key sk-pro…3456 t1 · Bash output (and 2 other places)
2 secret-assignment hu… t1 · patch of notes.txt
Redact all and share? [r] redact all [c] choose one by one [k] keep all [x] cancel:
```
| Choice | Effect |
| ------ | -------------------------------------------------------------------------------------------------------- |
| Redact | Replaces the value with `[redacted by sender: ]` in the file. Your own recording is never changed. |
| Keep | Sends it as it is, for example a fake key a test depends on. |
| Cancel | Writes nothing. So does any answer it doesn’t understand. |
### What it looks for
[Section titled “What it looks for”](#what-it-looks-for)
| Kind | Examples |
| ---------------- | ------------------------------------------------------------------------------------------------ |
| Keys and tokens | Anthropic, OpenAI and Google API keys, AWS access keys, GitHub and Slack tokens, `Bearer` tokens |
| Private keys | A whole `BEGIN … PRIVATE KEY` block |
| Assignments | An upper-case name holding `PASSWORD`, `SECRET`, `TOKEN`, `API_KEY` and similar, with a value |
| Personal details | Email addresses, and Claude Code’s organization ID |
Placeholders (`$TOKEN`, ``), `example.com` addresses and no-reply senders are skipped. Files that aren’t text can’t be checked, and Wisdom says how many there were. A patch a redaction edited is named in the file.
### Without being asked
[Section titled “Without being asked”](#without-being-asked)
In a script, pass `--redact` or `--keep-secrets`. Without either, nothing is written when the check finds something. `share.secrets` in [`wisdom.yaml`](../../reference/files-and-config/#wisdomyaml) sets your own default. Wisdom also says how often your home folder’s path, which holds your username, appears.
Caution
The check finds the shapes it knows and will miss others. Look through what you send.
## Import
[Section titled “Import”](#import)
Terminal
```sh
wisdom import 0f3c8a1e-20261106-1402.wisdom-share
```
Or drop the file into `.wisdom/shared/`, and the service imports it within a few seconds. A file it can’t import is renamed `.rejected`, with the reason in `.wisdom/daemon.log`. It’s kept as its own read-only copy, never mixed into your recordings, and listed under “shared with you”:
Output
```txt
shared with you · 1, read-only
0f3c8a1e-… claude-code 2026-11-06 10:00Z 3 turns from shop-api, shared 2026-11-06 14:02Z
```
Importing the same file again changes nothing. A glance of it says where it came from, and what the sender redacted:
Output
```txt
session 0f3c8a1e-… · claude-code 2.1.318 · closed · version 24
shared copy from shop-api, shared 2026-11-06 14:02Z · read-only, as recorded on the sender's machine
redacted by sender ×2 · patches edited by redaction: notes.txt
```
Read it like any session. You can’t resume someone else’s recording. To carry the work on, [clone it](../clone-a-session/), or start a new session that reads it: `wisdom handoff claude --from `. If you also recorded that session yourself, reads show your own recording.
Note
Checksums catch a damaged file, not a deliberately edited one. Treat what you read as the sender’s account of their recording.
## For people without Wisdom
[Section titled “For people without Wisdom”](#for-people-without-wisdom)
[Export the session as Markdown](../export-a-session/) instead.
# Limitations
> What Wisdom can't do yet, what it can't do at all, and what to do instead.
Wisdom is early. These are its limits today, with a way around each where there is one.
## Recording
[Section titled “Recording”](#recording)
| Limit | What it means for you |
| ------------------------------ | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Connected recording has rules | Claude Code and Pi must start in the project’s top folder; connected Codex isn’t recorded in a git worktree. [`wisdom track`](../../guides/record-sessions/#track-a-home-of-its-own) covers these. |
| Timing isn’t authorship | Wisdom sees when a file changed, not who changed it. Two agents in one folder see each other’s changes. |
| Big projects | Past 10,000 files, live recording stops. Past 64 MiB of kept contents, changes become gaps. Skip folders in [`wisdom.yaml`](../../reference/files-and-config/#wisdomyaml). |
| Failed subagents aren’t marked | One cut off before it stops loses its report, transcript and tokens. See [Subagents](../../concepts/forks-and-subagents/#subagents). |
| Forks aren’t linked | `/fork`, `/branch` and `/clear` make separate sessions with no link to their parent. `/rewind` isn’t marked. |
| Renames | Recorded as a delete and a create. |
| Agents’ formats can change | A new agent version can change what Wisdom reads. `wisdom doctor` notes when you’re past the version it was tested with. |
**Never possible:** what an agent doesn’t report. Thinking a provider encrypts, tools that bypass hooks, and who was behind a change made by another process. These are marked where they occur, never filled in.
## Reading
[Section titled “Reading”](#reading)
| Limit | What it means for you |
| -------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| No search | You read one session at a time. Starting [from a commit](../../guides/read-a-commit/) or `git blame` is often quicker. |
| One project at a time | Each project has its own service, Usage and Commits. There’s no view across projects. |
| Codex cost is an estimate | Codex reports tokens only. Usage prices them at OpenAI’s standard rates on a set date; long prompts cost more, and on a ChatGPT plan you aren’t billed per token. |
| Long answers in an agent’s shell | The shell can cut them. The skill teaches agents to read the rest. |
## Carrying work on
[Section titled “Carrying work on”](#carrying-work-on)
| Limit | What it means for you |
| ------------------------------- | ------------------------------------------------------------------------------- |
| A clone keeps its agent | To change agents, use a [handoff](../../guides/hand-off-work/). |
| Clones under another login | Not confirmed yet. See [Clone a session](../../guides/clone-a-session/#limits). |
| A background handoff only reads | The work goes on when you open it with `wisdom resume`. Pi can’t take one. |
| Delete only in Usage | There’s no command for it. |
## Commits and team mode
[Section titled “Commits and team mode”](#commits-and-team-mode)
| Limit | What it means for you |
| ----------------------------------- | ---------------------------------------------------------------------------------------------------------------------------- |
| Records are for commits Wisdom sees | Those you make while it runs. Others are worked out when you ask. Merges get no record. |
| Huge commits | Thousands of files take minutes to record, and a model guide can run out of time. |
| Model guides need their sessions | Once one is deleted, `wisdom guide` can’t write it. |
| GitHub first | Team mode is tested with GitHub, not yet GitLab. The [team dashboard](../../team/team-dashboard/) is GitHub and Vercel only. |
| Deleting from a remote | A deleted session stays fetchable by its hash until the host cleans up, and there’s no command to delete a commit record. |
All the team limits: [How team sharing works](../../team/how-sharing-works/#limits).
## Privacy
[Section titled “Privacy”](#privacy)
| Limit | What it means for you |
| ----------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------- |
| Recordings aren’t redacted | They hold secrets exactly as they appeared. Only what leaves your machine is redacted. Treat `.wisdom/` [like a password](../../concepts/privacy/). |
| The secret check knows shapes | It catches common ones and misses others. Look through what you send. |
| `git push --mirror` | It sends every ref, so commit records and guides go too. |
## Running it
[Section titled “Running it”](#running-it)
| Limit | What it means for you |
| -------------------------------------------- | -------------------------------------------------- |
| About 20 projects at once | Each running project takes three ports. |
| No database upgrades yet | One will come with the first change to the layout. |
| The service starts and stops in the terminal | Usage is served by it, so it can’t start it. |
What’s planned is in the [roadmap](https://github.com/wisdomlayer/wisdom/blob/main/docs/roadmap.md).
# Troubleshooting
> Find what you see, and what to do about it.
Start here, in the project:
Terminal
```sh
wisdom doctor
```
It checks everything, changes nothing, and prints the command that fixes each problem. If your question isn’t answered by it, look below. If nothing here helps, open an [issue](https://github.com/wisdomlayer/wisdom/issues) with the doctor’s output. Read it first: it names your project’s folder.
## My session isn’t recorded
[Section titled “My session isn’t recorded”](#my-session-isnt-recorded)
| Agent | Check |
| ----------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| Any | Did you run `wisdom connect` in this project, and restart the agent after? `wisdom doctor` shows each agent’s hooks. |
| Claude Code | Was it started in the project’s **top folder**? In a subfolder it doesn’t load the project’s settings. |
| Codex | Is the project trusted, and are Wisdom’s hooks approved in `/hooks`? Until then sessions are read from their own files, marked `not-recorded-live`. In a git worktree, use `wisdom track codex`. |
| Pi | Was it started in the project’s **top folder**, and did you trust the project when it asked? |
A session whose hooks never ran appears only after its own file has been quiet for two minutes.
## Recording stopped
[Section titled “Recording stopped”](#recording-stopped)
| You see | What to do |
| ------------------------------------------------------------ | ---------------------------------------------------------------------------------------------------------------------- |
| `its hooks point to a copy of Wisdom that has moved or gone` | You moved the install or removed an old Node version. Run `wisdom connect` (`wisdom init` in a tracked project). |
| `its hooks run a different copy of Wisdom` | The same fix. Usually an install left under another Node version. |
| `running from a different version of Wisdom` | `wisdom daemon stop`, then `wisdom daemon start`. |
| A session is `degraded` | See [a degraded session](../../guides/keep-it-healthy/#a-degraded-session). The usual cause is more than 10,000 files. |
| Events waiting in the spool | They are recorded when the service starts: `wisdom daemon start`. |
| Codex hooks are “not trusted yet” | Approve them in `/hooks`. Codex asks again whenever the hook changes, such as after moving the install or the project. |
Your agent keeps working in all of these. Wisdom never blocks it.
## A command fails
[Section titled “A command fails”](#a-command-fails)
| You see | What to do |
| ---------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------- |
| `Wisdom needs Node.js 24 or newer` | Update Node, then install Wisdom again under it. |
| `… is not inside a Wisdom project` | Go into the project, or run `wisdom connect` there first. `--cwd DIR` names another folder. |
| `No recorded session has the ID …` | `resume` and handoff need the **full** ID. `wisdom glance` lists them. A shared session can’t be resumed: [clone it](../../guides/clone-a-session/). |
| `Cannot run Claude Code (…)` | Wisdom couldn’t find the agent. Put it on your `PATH`, or pass `--claude-bin` (`--codex-bin`, `--pi-entry`). |
| `--… is not valid for …` | The option belongs to another command. See [CLI](../../reference/cli/#options). |
| `Unknown command: start` | Service commands start with `daemon`: `wisdom daemon start`. |
| PowerShell refuses to run `wisdom` | Scripts are blocked: use `wisdom.cmd` and `npm.cmd`. |
| PowerShell loses what follows `--` | It drops a `--` it is given. Quote the words instead: `wisdom handoff codex "the tests fail"`. |
| `Using Wisdom's defaults: …` | `wisdom.yaml` has a mistake; the rest of the line names it. Until it’s fixed, every setting is its default. |
## Usage or Commits won’t open
[Section titled “Usage or Commits won’t open”](#usage-or-commits-wont-open)
* `wisdom usage` and `wisdom commits` print the real address. With several projects running, it isn’t always 7435 or 7436.
* If one stopped, read `.wisdom/dashboard.log` (Usage) or `.wisdom/commits.log` (Commits).
* The doctor says `the running daemon is from before Commits`: restart the service after an update.
* `daemon.dashboard: false` in `wisdom.yaml`, or `--no-dashboard`, leaves both out.
## My agent can’t read sessions
[Section titled “My agent can’t read sessions”](#my-agent-cant-read-sessions)
| You see | What to do |
| ---------------------------- | ------------------------------------------------------------------------------------------------------------------------------- |
| It doesn’t know the commands | Run `wisdom connect` or `wisdom init` again to refresh the skill, then restart the agent. |
| It reads its own session | Inside a recorded session `latest` can be the agent itself. Name the session’s ID. |
| Its output is cut | The agent’s shell cuts long output. Ask it to [read in pages](../../guides/agents-read-sessions/#long-answers-through-a-shell). |
| It can’t start the service | A sandbox can block that. Run `wisdom daemon start` yourself, outside it. |
## Team mode
[Section titled “Team mode”](#team-mode)
| You see | What to do |
| --------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------- |
| `not trusted yet` | Read the team file’s commands, then `wisdom team trust`. |
| `held back …; it is tried again at each push` | The team’s `check` refused that session, or couldn’t run here. |
| `agent work without a guide` in CI | The commit has no guide; the reason follows. `wisdom guide `, then push. |
| `session … is not on origin` in CI | Whoever made the commit runs `wisdom team push`. |
| `no record or link` in CI | Made without Wisdom, or not linked yet. It isn’t counted against you. |
| `Commit links not sent` | They are retried in the background, and at your next commit and push. |
| `(session not available)` | Run `wisdom team fetch`. If it stays, the session was deleted or never pushed. |
| A merge shows no record | The [relink job](../../team/ci/#link-merges) didn’t run. `wisdom team relink --range ..` still works later. |
## Guides
[Section titled “Guides”](#guides)
See [Commit guides](../../guides/keep-it-healthy/#commit-guides).
# CLI
> Every command and option of the wisdom CLI.
Every command finds `.wisdom/` from the current folder upward, the way git finds `.git`. On Windows PowerShell with scripts blocked, type `wisdom.cmd`. Your own defaults for a project live in [`wisdom.yaml`](../files-and-config/#wisdomyaml); a flag always wins over it.
`` is a session ID, its first 8 or more characters, or `latest`. `` is `t3` (a turn), `t3/c2` (a tool call), `a1` (a subagent), `a1/c2`, or `outside`.
## Set up a project
[Section titled “Set up a project”](#set-up-a-project)
| Command | What it does |
| ------------------- | ------------------------------------------------------------------------------------------------------------------------ |
| `wisdom connect` | Record plain `claude`, `codex` and `pi` started here, with your own login, and write `wisdom.yaml`. Run again to repair. |
| `wisdom disconnect` | Take out exactly what `connect` added. Recordings are kept. |
| `wisdom init` | Set up `.wisdom/` and a home for each agent, for `wisdom track`, and write `wisdom.yaml`. Run again to repair. |
| `wisdom doctor` | Check that everything works, and print the fix for each problem. Exits with 1 when there is one. |
## Run an agent
[Section titled “Run an agent”](#run-an-agent)
| Command | What it does |
| ------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------ |
| `wisdom track claude\|codex\|pi` | Start an agent with its home in this project, recording. |
| `wisdom resume ` | Continue a recorded session, still recording. Full ID only. |
| `wisdom handoff ["what it should know"]` | Continue in a new or existing session that reads another session first. |
| `wisdom handoff … --emit` | The same in the background, reading only, while you keep working. Its reply is printed when it’s done. |
## Read a session
[Section titled “Read a session”](#read-a-session)
| Command | What it does |
| -------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------- |
| `wisdom glance` | List recorded sessions, newest first. |
| `wisdom glance ` | One session’s shape and every turn. |
| `wisdom open --capture ` | One turn, tool call or subagent, whole. |
| `wisdom glance --commit ` | Which recorded steps made each piece of a commit (a hash, a branch or `HEAD`). |
| `wisdom usage` | Print the address of Usage, the live view of your sessions. `wisdom dashboard` does the same. |
| `wisdom commits` | Print the address of Commits, starting the service if needed: main and your branches, each commit and the sessions behind it, live. |
## Commit guides
[Section titled “Commit guides”](#commit-guides)
See [Read a commit](../../guides/read-a-commit/).
| Command | What it does |
| ----------------------- | ------------------------------------------------------------------------------------------------------ |
| `wisdom guide ` | Have a model write that commit’s guide now, and keep it in the commit’s record. |
| `wisdom guide on\|off` | Whether a model writes a guide after each of your commits. Off by default; on by default in team mode. |
## Team mode
[Section titled “Team mode”](#team-mode)
See [Set up team mode](../../team/set-up/).
| Command | What it does |
| ------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------- |
| `wisdom team init` | Write `wisdom-team.yaml`. Commit it to turn team mode on. |
| `wisdom team hooks on\|off` | Install or remove Wisdom’s four git hooks. `connect` and `init` install them in a team-mode repository. |
| `wisdom team trust` | Show the commands `wisdom-team.yaml` runs on this machine (`check`, `guides.command`), and allow them. |
| `wisdom team push` | Send your commit links, sessions and records now, without a `git push`. |
| `wisdom team fetch` | Bring here, read-only, the records and links of the commits your branches reach and the sessions they name, and apply the deletion list. |
| `wisdom team sync on\|off` | Whether `git fetch` and `git pull` also bring the team’s commit links and records. |
| `wisdom team relink --range ..` | Link commits that GitHub or a rewrite gave a new sha to the records of the commits they came from. The CI job after a merge runs it. |
| `wisdom team relink --commit-map FILE` | The same after `git filter-repo`, from its own list of commits. |
| `wisdom team delete ` | Remove a pushed session for everyone. Your own recording is kept. |
| `wisdom team prune` | Remove pushed sessions older than `retentionDays`. |
| `wisdom check --range ..` | For CI: check each commit’s guide, and that its sessions are on the remote. Exits with 1 when a commit needs attention. |
## Team dashboard
[Section titled “Team dashboard”](#team-dashboard)
See [Team dashboard](../../team/team-dashboard/).
| Command | What it does |
| ----------------------- | --------------------------------------------------------------------------------------------------------- |
| `wisdom commits deploy` | Set up Commits for the whole team: Vercel, a GitHub sign-in app, the CI file. Run again to fix the setup. |
| `wisdom commits build` | For CI: the team’s Commits from the remote, ready to deploy. |
| `wisdom commits prune` | For CI: remove its older Vercel deployments. |
## Share a session
[Section titled “Share a session”](#share-a-session)
| Command | What it does |
| --------------------------- | -------------------------------------------------------- |
| `wisdom share ...` | Write one file to send a teammate, after a secret check. |
| `wisdom import ` | Read a teammate’s file here, read-only. |
| `wisdom export ` | Write a session as Markdown, after a secret check. |
| `wisdom clone ` | Carry a session on as a new one, in the same agent. |
## Background service and other
[Section titled “Background service and other”](#background-service-and-other)
| Command | What it does |
| ----------------------------------- | ------------------------------------------------ |
| `wisdom daemon start\|stop\|status` | Control the background service. |
| `wisdom daemon run` | Run it in the foreground. |
| `wisdom mcp` | Serve the optional read-only MCP tool, `ledger`. |
| `wisdom --version` | Print the version. |
## Options
[Section titled “Options”](#options)
| Option | Used with | What it does |
| ---------------------------------------------------------- | --------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `--cwd DIR` | any | Use the project at `DIR`. |
| `--capture ` | `open` | The session to open a position in. |
| `--json` | `doctor` | Print the checks as JSON. |
| `--data DIR` | any | Use the data folder `DIR` directly. Also `WISDOM_DATA_DIR`. |
| `--from N` | `glance`, `open` | Continue a long answer from line `N`. |
| `--at VERSION` | `glance`, `open` | Read at a fixed version. |
| `--commit ` | `glance` | Read a git commit instead of a session. |
| `--range ..` | `check`, `team relink` | The commits to check or link, as git names a range. |
| `--commit-map FILE` | `team relink` | After `git filter-repo`: link each rewritten commit from its `.git/filter-repo/commit-map`. |
| `--remote NAME` | `team`, `check`, `commits build` | Use this remote instead of the one in `wisdom-team.yaml`. |
| `--public` | `commits deploy`, `commits build` | No GitHub sign-in in front of the team dashboard, on purpose. |
| `--main BRANCH`, `--out DIR` | `commits build` | The default branch, and where the build goes (default `.wisdom-commits/`). |
| `--from ` | `handoff` | The session to read. Default: the one running the command. Otherwise the newest from another agent for a new session, or the newest other one for an existing session. |
| `--emit` | `handoff` | Hand off in the background, reading only. |
| `--port N` | `daemon`, and commands that start it | Start the service on exactly this port. |
| `--no-dashboard` | `daemon` | Don’t start Usage and Commits. |
| `--claude-bin FILE`, `--codex-bin FILE`, `--pi-entry FILE` | `init`, `connect`, `track`, `resume`, `handoff`, `clone` | Use another installation of the agent. |
| `--setup-hooks` | `track codex` | Review Wisdom’s hooks in `/hooks`, first time only. |
| `--trust-all-hooks` | `track codex`; `resume`, `handoff` and `clone` into Codex | Skip the review for **every** hook in that run. Only in repositories you trust. |
| `-- ARGUMENTS` | `track`, `handoff` | `track`: pass the rest to the agent. `handoff`: add it to the first prompt (quoting the words works in every shell). |
| `--out FILE` | `share`, `export` | Where to save. Default `.wisdom/shared-out/`. `export --out -` prints it. |
| `--redact`, `--keep-secrets` | `share`, `export` | Redact or keep what the secret check finds, without asking. |
# Files & config
> The .wisdom/ folder, Wisdom's git refs, wisdom.yaml, wisdom-team.yaml, .wisdomignore, environment variables and ports.
Everything Wisdom stores, and the settings you can change. Most projects never need any of them.
## The `.wisdom/` folder
[Section titled “The .wisdom/ folder”](#the-wisdom-folder)
.wisdom/
```txt
wisdom.json marks the project
daemon.json, daemon.lock the running service: port, process ID, token
connected.json the agents wisdom connect connected, and since when
daemon.log, dashboard.log
ledger.sqlite every record (SQLite is the source of truth)
spool/// events kept while the service was down
clones/.json what a clone was copied from
deleted.json hashes that keep deleted sessions out
backups/