@swestash/agent-lens 0.17.3 → 0.17.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +28 -56
- package/dist/agent-lens.js +10 -3
- package/dist/agent-lens.js.map +1 -1
- package/package.json +1 -1
- package/web/404.html +2 -2
- package/web/assets/{AboutView-CUWj_rU_.js → AboutView-aUqi2IBU.js} +1 -1
- package/web/assets/{Dashboard-DNignR_W.js → Dashboard-DByihW7N.js} +1 -1
- package/web/assets/{FileView-B7B7lrWB.js → FileView-Aqwd0lJV.js} +1 -1
- package/web/assets/{FilesView-BxaV2-YJ.js → FilesView-MMsd5fgG.js} +1 -1
- package/web/assets/{SecurityView-BkWmmke4.js → SecurityView-CL8p3Drg.js} +1 -1
- package/web/assets/{SessionView-DdxaD2e2.js → SessionView-DrCE0ZFH.js} +1 -1
- package/web/assets/{SkillView-CxQL_Y9l.js → SkillView-DqFqSIFK.js} +1 -1
- package/web/assets/{SkillsView-CFPNRSKa.js → SkillsView-BYWpuxva.js} +1 -1
- package/web/assets/{WorkflowView-C0qUousN.js → WorkflowView-D5ulOXFS.js} +1 -1
- package/web/assets/{index-C47tPE_R.js → index-BAzJJeOV.js} +2 -2
- package/web/assets/{index-CCufgBAx.js → index-BInWVVgH.js} +1 -1
- package/web/assets/{index-7p3QjWYa.css → index-CZlMEmLZ.css} +1 -1
- package/web/assets/{jsonish-BNBt84Kn.js → jsonish-CTF43Da0.js} +1 -1
- package/web/assets/{theme-DdWxlWl0.js → theme-C0b3Oyq9.js} +1 -1
- package/web/assets/{useResetOn-MIt0o_vE.js → useResetOn-wnsToI6F.js} +1 -1
- package/web/index.html +2 -2
package/README.md
CHANGED
|
@@ -1,88 +1,60 @@
|
|
|
1
1
|
# Agent Lens
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
Collect, search, and audit your Claude Code session traces. 100% local.
|
|
4
4
|
|
|
5
5
|
[](https://www.npmjs.com/package/@swestash/agent-lens)
|
|
6
6
|

|
|
7
7
|

|
|
8
8
|

|
|
9
9
|
|
|
10
|
-
Claude Code records
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
usage/cost dashboards, and a deterministic, no-AI **audit of what the agent actually did on your
|
|
14
|
-
machine** — **without a single byte leaving your machine**.
|
|
10
|
+
Claude Code prunes its session records after a rolling 30-day window. Agent Lens copies them into a
|
|
11
|
+
local archive first, and gives you a transcript browser, usage and cost dashboards, and a
|
|
12
|
+
deterministic, no-AI audit of what the agent did on your machine. Nothing leaves your machine.
|
|
15
13
|
|
|
16
14
|
## Install
|
|
17
15
|
|
|
16
|
+
Requires Node.js 24 or later.
|
|
17
|
+
|
|
18
18
|
```bash
|
|
19
|
-
npm install -g @swestash/agent-lens # or run
|
|
19
|
+
npm install -g @swestash/agent-lens # or run once: npx @swestash/agent-lens <command>
|
|
20
20
|
```
|
|
21
21
|
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
There are **no compiled dependencies** — SQLite comes from Node's built-in `node:sqlite`. Nothing is
|
|
26
|
-
built at install time, so there is no compiler toolchain to set up, no platform-specific prebuilt
|
|
27
|
-
binary to match, and no install script for npm to prompt about.
|
|
22
|
+
There are no compiled dependencies: SQLite comes from Node's built-in `node:sqlite`, so nothing is
|
|
23
|
+
built or downloaded at install time.
|
|
28
24
|
|
|
29
25
|
## Quick start
|
|
30
26
|
|
|
31
|
-
Agent Lens runs a three-stage local pipeline — `collect → ingest → serve`:
|
|
32
|
-
|
|
33
27
|
```bash
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
agent-lens collect --then-ingest # Stages 1–2: mirror transcripts to the archive, build the DB
|
|
38
|
-
agent-lens serve # Stage 3: browse → http://127.0.0.1:4477
|
|
39
|
-
|
|
40
|
-
# Make it permanent — install as OS services (survives reboot):
|
|
41
|
-
agent-lens service install # periodic collect+ingest AND the always-on UI
|
|
42
|
-
# ...or keep it fresh in the foreground instead:
|
|
43
|
-
agent-lens watch # a resident process that collects+ingests on file change
|
|
28
|
+
agent-lens collect --then-ingest # copy your transcripts and build the database
|
|
29
|
+
agent-lens serve # open http://127.0.0.1:4477
|
|
30
|
+
agent-lens service install # optional: keep collecting and serving across reboots
|
|
44
31
|
```
|
|
45
32
|
|
|
46
|
-
|
|
47
|
-
source `~/.claude`.
|
|
48
|
-
|
|
49
|
-
### Where your data lives
|
|
50
|
-
|
|
51
|
-
Installed from npm, the archive and SQLite store go to a per-user data directory:
|
|
52
|
-
|
|
53
|
-
| Platform | Data directory |
|
|
54
|
-
| --- | --- |
|
|
55
|
-
| Linux | `$XDG_DATA_HOME/agent-lens`, else `~/.local/share/agent-lens` |
|
|
56
|
-
| macOS | `~/Library/Application Support/agent-lens` |
|
|
57
|
-
| Windows | `%LOCALAPPDATA%\agent-lens` |
|
|
58
|
-
|
|
59
|
-
Set `AGENT_LENS_DATA` to put it elsewhere — that is the only way to relocate the archive, which the
|
|
60
|
-
SQLite store and triage sidecar follow. `agent-lens config` prints the resolved paths and where each
|
|
61
|
-
value came from.
|
|
33
|
+
With no config file, Agent Lens collects `~/.claude`.
|
|
62
34
|
|
|
63
|
-
|
|
35
|
+
## Commands
|
|
64
36
|
|
|
65
37
|
| Command | What it does |
|
|
66
38
|
| --- | --- |
|
|
67
|
-
| `agent-lens collect [--then-ingest]` |
|
|
68
|
-
| `agent-lens ingest` |
|
|
69
|
-
| `agent-lens serve` | Serve the web UI
|
|
70
|
-
| `agent-lens watch` |
|
|
71
|
-
| `agent-lens metrics` |
|
|
72
|
-
| `agent-lens export <sessionId>` | Write a session to
|
|
73
|
-
| `agent-lens service <install\|uninstall\|status> [collector\|server\|all]` |
|
|
74
|
-
| `agent-lens config` | Print the effective configuration
|
|
39
|
+
| `agent-lens collect [--then-ingest]` | Copy each account's transcripts into the archive. Never deletes, never copies credentials. |
|
|
40
|
+
| `agent-lens ingest [--full]` | Build or update the SQLite store from the archive. |
|
|
41
|
+
| `agent-lens serve` | Serve the web UI and API on `127.0.0.1:4477`. |
|
|
42
|
+
| `agent-lens watch` | Collect and ingest whenever a transcript changes. |
|
|
43
|
+
| `agent-lens metrics` | Rerun classification, security detection, error typing, and file indexing on the store. |
|
|
44
|
+
| `agent-lens export <sessionId>` | Write a session to Markdown, redacted by default. |
|
|
45
|
+
| `agent-lens service <install\|uninstall\|status> [collector\|server\|all]` | Manage the OS services (systemd, launchd, Task Scheduler). |
|
|
46
|
+
| `agent-lens config` | Print the effective configuration and where each value came from. |
|
|
75
47
|
|
|
76
|
-
##
|
|
48
|
+
## Where your data lives
|
|
77
49
|
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
[
|
|
50
|
+
In a per-user data directory (on Linux, `~/.local/share/agent-lens`). `agent-lens config` prints the
|
|
51
|
+
resolved paths, and `AGENT_LENS_DATA` moves them. All platforms are listed in the
|
|
52
|
+
[usage guide](https://github.com/SWEStash/agent-lens/blob/main/docs/USAGE.md#paths).
|
|
81
53
|
|
|
82
54
|
## Documentation
|
|
83
55
|
|
|
84
|
-
|
|
85
|
-
in the repository:
|
|
56
|
+
Configuration, screenshots, the [privacy posture](https://github.com/SWEStash/agent-lens#privacy),
|
|
57
|
+
and a live demo are in the repository: https://github.com/SWEStash/agent-lens
|
|
86
58
|
|
|
87
59
|
## License
|
|
88
60
|
|
package/dist/agent-lens.js
CHANGED
|
@@ -1335,12 +1335,19 @@ var PRICE_TABLE = {
|
|
|
1335
1335
|
"claude-opus-4-7": { input: 5, output: 25, cacheWrite: 6.25, cacheRead: 0.5 },
|
|
1336
1336
|
"claude-opus-4-8": { input: 5, output: 25, cacheWrite: 6.25, cacheRead: 0.5 },
|
|
1337
1337
|
"claude-opus-5": { input: 5, output: 25, cacheWrite: 6.25, cacheRead: 0.5 },
|
|
1338
|
+
"claude-opus-5-5": { input: 4, output: 20, cacheWrite: 5, cacheRead: 0.2 },
|
|
1338
1339
|
"claude-fable-5": { input: 10, output: 50, cacheWrite: 12.5, cacheRead: 1 },
|
|
1340
|
+
"claude-fable-5-1": { input: 10, output: 50, cacheWrite: 12.5, cacheRead: 0.25 },
|
|
1339
1341
|
"claude-sonnet-4": { input: 3, output: 15, cacheWrite: 3.75, cacheRead: 0.3 },
|
|
1340
|
-
// Sonnet 5
|
|
1341
|
-
//
|
|
1342
|
-
"claude-sonnet-5": { input:
|
|
1342
|
+
// Sonnet 5 launched at an "introductory" $2/$10 that was later made its standard price; the
|
|
1343
|
+
// announced rise to $3/$15 was cancelled.
|
|
1344
|
+
"claude-sonnet-5": { input: 2, output: 10, cacheWrite: 2.5, cacheRead: 0.2 },
|
|
1345
|
+
"claude-sonnet-5-5": { input: 2, output: 10, cacheWrite: 2.5, cacheRead: 0.1 },
|
|
1343
1346
|
"claude-haiku-4": { input: 1, output: 5, cacheWrite: 1.25, cacheRead: 0.1 },
|
|
1347
|
+
// Haiku 5.5 is tiered by prompt size: these are the rates up to 100K prompt tokens. Prompts over
|
|
1348
|
+
// 100K bill at 5× ($0.50/$2.50), which this cannot apply: cost is derived from per-model token
|
|
1349
|
+
// sums, after the per-request size is gone. Long-prompt Haiku 5.5 spend is therefore understated.
|
|
1350
|
+
"claude-haiku-5-5": { input: 0.1, output: 0.5, cacheWrite: 0.125, cacheRead: 0.01 },
|
|
1344
1351
|
"claude-3-5-haiku": { input: 0.8, output: 4, cacheWrite: 1, cacheRead: 0.08 },
|
|
1345
1352
|
"claude-3-5-sonnet": { input: 3, output: 15, cacheWrite: 3.75, cacheRead: 0.3 }
|
|
1346
1353
|
};
|