agent-inspect 2.3.0 → 2.5.0
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/CHANGELOG.md +24 -0
- package/README.md +33 -4
- package/docs/ADAPTERS.md +47 -0
- package/docs/CLI.md +57 -1
- package/docs/LIMITATIONS.md +6 -0
- package/docs/SCHEMA.md +1 -0
- package/package.json +2 -2
- package/packages/cli/dist/index.cjs +1454 -74
- package/packages/cli/dist/index.cjs.map +1 -1
- package/packages/cli/dist/index.mjs +1455 -75
- package/packages/cli/dist/index.mjs.map +1 -1
- package/packages/core/dist/advanced.cjs +581 -3
- package/packages/core/dist/advanced.cjs.map +1 -1
- package/packages/core/dist/advanced.d.cts +172 -8
- package/packages/core/dist/advanced.d.ts +172 -8
- package/packages/core/dist/advanced.mjs +572 -4
- package/packages/core/dist/advanced.mjs.map +1 -1
- package/packages/core/dist/checks.d.cts +2 -2
- package/packages/core/dist/checks.d.ts +2 -2
- package/packages/core/dist/{context-yv2VSDQF.d.ts → context-BDZmi53V.d.ts} +3 -3
- package/packages/core/dist/{context-CSKnzpXR.d.cts → context-DjY-jvQk.d.cts} +3 -3
- package/packages/core/dist/diff.d.cts +3 -3
- package/packages/core/dist/diff.d.ts +3 -3
- package/packages/core/dist/exporters.d.cts +3 -3
- package/packages/core/dist/exporters.d.ts +3 -3
- package/packages/core/dist/index.d.cts +6 -6
- package/packages/core/dist/index.d.ts +6 -6
- package/packages/core/dist/{inspect-event-CevRYp58.d.cts → inspect-event-CYAV7Hxm.d.cts} +1 -1
- package/packages/core/dist/{inspect-event-CevRYp58.d.ts → inspect-event-CYAV7Hxm.d.ts} +1 -1
- package/packages/core/dist/{log-config-8aE5Kxtr.d.cts → log-config-BNQ9UTmP.d.cts} +1 -1
- package/packages/core/dist/{log-config-DVimQJho.d.ts → log-config-D3Yp1SZN.d.ts} +1 -1
- package/packages/core/dist/logs.d.cts +3 -3
- package/packages/core/dist/logs.d.ts +3 -3
- package/packages/core/dist/{persisted-inspect-event-D-WpXeZX.d.ts → persisted-inspect-event-BLvb0jSX.d.ts} +1 -1
- package/packages/core/dist/{persisted-inspect-event-DHcHPUKv.d.cts → persisted-inspect-event-D5SjBz9b.d.cts} +1 -1
- package/packages/core/dist/persisted.d.cts +5 -5
- package/packages/core/dist/persisted.d.ts +5 -5
- package/packages/core/dist/readers.d.cts +2 -2
- package/packages/core/dist/readers.d.ts +2 -2
- package/packages/core/dist/{types-DgMN3qow.d.cts → types-C-llnPH0.d.cts} +1 -1
- package/packages/core/dist/{types-D-Y1kOU-.d.ts → types-CQun9LW6.d.ts} +1 -1
- package/packages/core/dist/writers.d.cts +2 -2
- package/packages/core/dist/writers.d.ts +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,21 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 2.5.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- 11edf90: Release v2.5.0 with deterministic guardrails and circuit utilities.
|
|
8
|
+
|
|
9
|
+
This train adds `@agent-inspect/guardrails` and `@agent-inspect/circuit`, optional `check --guardrails` / `check --circuit` flags, eval safety rule factories, and recipes. No compliance claims, no remote policy engine, and no default enforcement.
|
|
10
|
+
|
|
11
|
+
## 2.4.0
|
|
12
|
+
|
|
13
|
+
### Minor Changes
|
|
14
|
+
|
|
15
|
+
- 483168d: Release v2.4.0 with sessions workflow navigation and MCP client telemetry.
|
|
16
|
+
|
|
17
|
+
This train adds multi-run session indexing on `agent-inspect/advanced`, `sessions` / `session` CLI, session-aware `search` and `check`, and the new `@agent-inspect/mcp` package for local MCP client `tools/list` and `tools/call` tracing. No schema break, no MCP gateway/server, and no default network behavior.
|
|
18
|
+
|
|
3
19
|
## 2.3.0
|
|
4
20
|
|
|
5
21
|
### Minor Changes
|
|
@@ -18,6 +34,14 @@
|
|
|
18
34
|
|
|
19
35
|
## Unreleased
|
|
20
36
|
|
|
37
|
+
### Draft v2.4.0 Notes
|
|
38
|
+
|
|
39
|
+
- Added session/workflow causality model and `agent-inspect/advanced` session index helpers (`buildSessionIndex`, scope/cohort helpers, session fixtures).
|
|
40
|
+
- Added `agent-inspect sessions` and `agent-inspect session` CLI for multi-run handoff/retry navigation with timeline, critical-path, diagnostics, and JSON output.
|
|
41
|
+
- Added session-aware `search --session` and `check --session` / `--group` with aggregated per-run evidence.
|
|
42
|
+
- Added public optional `@agent-inspect/mcp` for local MCP **client** `tools/list` and `tools/call` telemetry with bounded summaries and `source.type: mcp-client` metadata.
|
|
43
|
+
- No schema version change, no MCP gateway/server, no timestamp-only causality inference, and no root/core dependency on MCP SDKs.
|
|
44
|
+
|
|
21
45
|
### Draft v2.3.0 Notes
|
|
22
46
|
|
|
23
47
|
- Hardened the official adapter paths for AI SDK, OpenAI Agents JS, and LangChain/LangGraph with no-network recipes, local-only defaults, clearer lifecycle coverage, and executable adapter conformance evidence.
|
package/README.md
CHANGED
|
@@ -22,7 +22,7 @@ agent-inspect gives those runs **structure**: an **execution tree** you can read
|
|
|
22
22
|
|
|
23
23
|
## Install
|
|
24
24
|
|
|
25
|
-
Current npm release line: **2.
|
|
25
|
+
Current npm release line: **2.4.0** for the linked public packages (`agent-inspect`, adapters, reporters, redact, eval, mcp). **v2.4.0** adds multi-run **session** navigation (`sessions` / `session` CLI), session-aware `search` and `check`, and optional **`@agent-inspect/mcp`** client telemetry.
|
|
26
26
|
|
|
27
27
|
```bash
|
|
28
28
|
npm install agent-inspect
|
|
@@ -334,13 +334,15 @@ AgentInspect is the **local-first trace workbench** for TypeScript AI agents:
|
|
|
334
334
|
|
|
335
335
|
- Instrument runs with `inspectRun` and `step`
|
|
336
336
|
- Write and read **local JSONL traces** (`schemaVersion: "0.1"` manual traces remain readable; schema 1.0 persisted rows are the v2 writer target)
|
|
337
|
-
- Inspect with **`list`**, **`view`**, **`clean`**, **`logs`**, **`tail`**, **`export`**, **`diff`**, **`timeline`**, **`stats`**, **`search`**
|
|
337
|
+
- Inspect with **`list`**, **`view`**, **`clean`**, **`logs`**, **`tail`**, **`export`**, **`diff`**, **`timeline`**, **`stats`**, **`search`**, **`sessions`**, **`session`**
|
|
338
338
|
|
|
339
339
|
**Stable root APIs:** `createInspector()`, `inspectRun()`, `maybeInspectRun()`, `step()`, `step.llm()`, `step.tool()`, `observe()`, `getCurrentCorrelationMetadata()`.
|
|
340
340
|
|
|
341
341
|
Pass `enabled: false` to `inspectRun` for a no-trace passthrough. Use `maybeInspectRun` with `AGENT_INSPECT=1` to toggle tracing in eval or CI — see [docs/API.md](docs/API.md).
|
|
342
342
|
|
|
343
|
-
**v2.
|
|
343
|
+
**v2.4 shipped:** sessions/MCP client telemetry on `main@2.4.0`. All ten linked packages published at `2.4.0` including `@agent-inspect/mcp`.
|
|
344
|
+
|
|
345
|
+
**v2.3 shipped:** adapter hardening for AI SDK, OpenAI Agents JS, and LangChain/LangGraph with no-network recipes and executable conformance coverage. Mastra and NestJS framework packages remain demand-gated; NestJS is covered through structured-log ingestion.
|
|
344
346
|
|
|
345
347
|
**Shipped in 2.2.0:** public optional Vitest/Jest reporter packages, shared `agent-inspect/reporters` helpers, and `agent-inspect ci-summary` for deterministic local reporter artifact summaries. Linked release aligns `agent-inspect`, `@agent-inspect/ai-sdk`, `@agent-inspect/langchain`, `@agent-inspect/tui`, `@agent-inspect/openai-agents`, `@agent-inspect/redact`, `@agent-inspect/eval`, `@agent-inspect/vitest`, and `@agent-inspect/jest` at **2.2.0**.
|
|
346
348
|
|
|
@@ -358,7 +360,7 @@ Pass `enabled: false` to `inspectRun` for a no-trace passthrough. Use `maybeInsp
|
|
|
358
360
|
|
|
359
361
|
**Shipped in 1.5.0:** non-breaking subpath exports; `what` and `report` CLI; dual-format read path (v0.1 + v0.2 JSONL); [what-report-inspect recipe](examples/recipes/what-report-inspect/). Linked release aligns all three npm packages at **1.5.0**.
|
|
360
362
|
|
|
361
|
-
**Roadmap beyond current release work:** v2.
|
|
363
|
+
**Roadmap beyond current release work:** v2.5 guardrails/circuit patterns, optional viewer/IDE surfaces, and conditional v3 extensibility. See [ROADMAP.md](ROADMAP.md).
|
|
362
364
|
|
|
363
365
|
**Shipped in 1.4.0:** CI artifact recipe ([docs/CI-ARTIFACTS.md](docs/CI-ARTIFACTS.md)); `timeline`, `stats`, and `search` CLI; core helpers `buildRunTimeline`, `buildTraceStats`, `searchTraces`. Linked release aligns all three npm packages at **1.4.0**.
|
|
364
366
|
|
|
@@ -412,6 +414,30 @@ const events = callback.getEvents();
|
|
|
412
414
|
|
|
413
415
|
See [examples/08-langchain-adapter](examples/08-langchain-adapter/README.md) and [docs/ADAPTERS.md](docs/ADAPTERS.md).
|
|
414
416
|
|
|
417
|
+
### MCP client telemetry (`@agent-inspect/mcp`)
|
|
418
|
+
|
|
419
|
+
Optional package for **local MCP client** tracing only. Wrap `tools/list` and `tools/call` so they emit tool steps with `source.type: mcp-client`, bounded argument summaries, server identity, and optional `sessionId` metadata.
|
|
420
|
+
|
|
421
|
+
```bash
|
|
422
|
+
pnpm add agent-inspect @agent-inspect/mcp
|
|
423
|
+
```
|
|
424
|
+
|
|
425
|
+
```ts
|
|
426
|
+
import { inspectRun } from "agent-inspect";
|
|
427
|
+
import { wrapMcpClient } from "@agent-inspect/mcp";
|
|
428
|
+
|
|
429
|
+
const traced = wrapMcpClient(mcpClient, {
|
|
430
|
+
serverName: "docs-server",
|
|
431
|
+
sessionId: "sess-123",
|
|
432
|
+
});
|
|
433
|
+
|
|
434
|
+
await inspectRun("agent-with-mcp", async () => {
|
|
435
|
+
await traced.callTool({ name: "search", arguments: { query: "sessions" } });
|
|
436
|
+
});
|
|
437
|
+
```
|
|
438
|
+
|
|
439
|
+
No-network recipe: [mcp-client-tracing](examples/recipes/mcp-client-tracing/). This is **not** an MCP server, gateway, or hosted broker — see [docs/ADAPTERS.md](docs/ADAPTERS.md).
|
|
440
|
+
|
|
415
441
|
### TUI viewer (`@agent-inspect/tui`)
|
|
416
442
|
|
|
417
443
|
Optional **Ink/React** package, installed separately. Use with an interactive terminal:
|
|
@@ -458,6 +484,9 @@ Reporter artifact behavior and API details are documented in [docs/API.md](docs/
|
|
|
458
484
|
| [examples/recipes/test-reporter-artifacts](examples/recipes/test-reporter-artifacts) | Vitest/Jest reporter artifact patterns |
|
|
459
485
|
| [examples/recipes/what-report-inspect](examples/recipes/what-report-inspect/) | `what` + `report` inspection |
|
|
460
486
|
| [examples/recipes/runtime-and-ingestion](examples/recipes/runtime-and-ingestion/) | v1.6 runtime writers + universal ingestion |
|
|
487
|
+
| [examples/recipes/mcp-client-tracing](examples/recipes/mcp-client-tracing) | v2.4 MCP client tool-call tracing |
|
|
488
|
+
|
|
489
|
+
**Multi-run sessions:** set `sessionId` (and optional handoff/retry metadata) on `run_started`, then browse with `npx agent-inspect sessions` and `npx agent-inspect session <id> --timeline`. See [SESSIONS-AND-WORKFLOW-CAUSALITY](docs/proposals/SESSIONS-AND-WORKFLOW-CAUSALITY.md).
|
|
461
490
|
|
|
462
491
|
**Recipes** are deterministic and require **no external services** by default. Index: [examples/README.md](examples/README.md), [examples/recipes/README.md](examples/recipes/README.md).
|
|
463
492
|
|
package/docs/ADAPTERS.md
CHANGED
|
@@ -406,6 +406,53 @@ A future Nest helper remains demand-gated and must be narrower than a framework
|
|
|
406
406
|
|
|
407
407
|
---
|
|
408
408
|
|
|
409
|
+
## MCP client telemetry (`@agent-inspect/mcp`)
|
|
410
|
+
|
|
411
|
+
**Status:** experimental optional package — v2.4.0 train.
|
|
412
|
+
|
|
413
|
+
`@agent-inspect/mcp` traces **MCP client** `tools/list` and `tools/call` as local AgentInspect tool steps. It records server identity (name + URL hash), tool name, bounded argument/result summaries, duration, errors, and optional session metadata (`sessionId`, `toolCallId`, `mcpToolCallId`).
|
|
414
|
+
|
|
415
|
+
### Install
|
|
416
|
+
|
|
417
|
+
```bash
|
|
418
|
+
npm install agent-inspect @agent-inspect/mcp
|
|
419
|
+
```
|
|
420
|
+
|
|
421
|
+
### Wrap a client
|
|
422
|
+
|
|
423
|
+
```ts
|
|
424
|
+
import { inspectRun } from "agent-inspect";
|
|
425
|
+
import { wrapMcpClient } from "@agent-inspect/mcp";
|
|
426
|
+
|
|
427
|
+
const traced = wrapMcpClient(mcpClient, {
|
|
428
|
+
serverName: "docs-server",
|
|
429
|
+
serverUrl: process.env.MCP_SERVER_URL,
|
|
430
|
+
sessionId: "sess-123",
|
|
431
|
+
});
|
|
432
|
+
|
|
433
|
+
await inspectRun("support-agent", async () => {
|
|
434
|
+
await traced.listTools?.();
|
|
435
|
+
await traced.callTool({ name: "search", arguments: { query: "refund policy" } });
|
|
436
|
+
});
|
|
437
|
+
```
|
|
438
|
+
|
|
439
|
+
`wrapMcpClient` accepts any object matching the documented `McpClientLike` shape. It does **not** require `@modelcontextprotocol/sdk` at runtime.
|
|
440
|
+
|
|
441
|
+
### Boundaries (v2.4)
|
|
442
|
+
|
|
443
|
+
| In scope | Out of scope |
|
|
444
|
+
| -------- | ------------ |
|
|
445
|
+
| Client-side `tools/list` and `tools/call` wrapping | MCP **server** implementation |
|
|
446
|
+
| Bounded summaries on tool step metadata | Gateway, proxy, or hosted MCP broker |
|
|
447
|
+
| `source.type: mcp-client` on tool steps | Invoking tools on behalf of the user from AgentInspect |
|
|
448
|
+
| Session metadata attachment when provided | Default trace upload |
|
|
449
|
+
|
|
450
|
+
Recipe: [examples/recipes/mcp-client-tracing](../examples/recipes/mcp-client-tracing/).
|
|
451
|
+
|
|
452
|
+
Session navigation for multi-run workflows uses `agent-inspect sessions` / `session` and optional `search --session` / `check --session` — see [CLI.md](./CLI.md) and [SESSIONS-AND-WORKFLOW-CAUSALITY.md](./proposals/SESSIONS-AND-WORKFLOW-CAUSALITY.md).
|
|
453
|
+
|
|
454
|
+
---
|
|
455
|
+
|
|
409
456
|
## Future adapters (not shipped)
|
|
410
457
|
|
|
411
458
|
Direction only — see [ROADMAP.md](../ROADMAP.md):
|
package/docs/CLI.md
CHANGED
|
@@ -38,6 +38,8 @@ Core commands:
|
|
|
38
38
|
- `timeline` — chronological view of one run (local JSONL)
|
|
39
39
|
- `stats` — local aggregate stats over a trace directory
|
|
40
40
|
- `search` — deterministic local search over traces
|
|
41
|
+
- `sessions` — list workflow sessions from trace metadata
|
|
42
|
+
- `session` — inspect one session (handoffs, retries, optional timeline)
|
|
41
43
|
- `what` — concise summary of a single run (local JSONL)
|
|
42
44
|
- `report` — markdown or HTML inspection report for a single run
|
|
43
45
|
- `explain` — deterministic local facts/inferences for a trace, with dry-run payloads
|
|
@@ -305,6 +307,11 @@ Options:
|
|
|
305
307
|
- `--max-duration-ms <number>`: add `run.duration`
|
|
306
308
|
- `--required-tool <name>` / `--forbidden-tool <name>`: add `tool.usage`
|
|
307
309
|
- `--allowed-model <model>` / `--max-total-tokens <number>`: add `llm.usage`
|
|
310
|
+
- `--session <id>`: check all runs in a workflow session (uses `--dir`; target may be `.`)
|
|
311
|
+
- `--group <id>`: check all runs sharing a `groupId` metadata value
|
|
312
|
+
- `--correlate-group`: when using `--session`, also match synthetic `group:` session keys
|
|
313
|
+
- `--guardrails <rule>`: optional deterministic guardrail rules (`banned-phrase`, `pii-leak`, `prompt-injection`, …); repeatable
|
|
314
|
+
- `--circuit <rule>`: optional circuit analyzers (`same-tool-repetition`, `max-retries`, …); repeatable
|
|
308
315
|
|
|
309
316
|
By default, `check` runs `run.status`. Additional built-in rules can be selected with `--rule` or config when their options are available.
|
|
310
317
|
|
|
@@ -329,6 +336,8 @@ Examples:
|
|
|
329
336
|
npx agent-inspect check fixtures/traces-v0.2/manual-basic.jsonl --json
|
|
330
337
|
npx agent-inspect check minimal-success --dir fixtures/traces --rule run.status
|
|
331
338
|
npx agent-inspect check trace.jsonl --max-duration-ms 30000 --required-tool search_docs --json
|
|
339
|
+
npx agent-inspect check trace.jsonl --guardrails pii-leak --guardrails prompt-injection --json
|
|
340
|
+
npx agent-inspect check trace.jsonl --circuit same-tool-repetition --circuit max-retries --json
|
|
332
341
|
```
|
|
333
342
|
|
|
334
343
|
Recipe: [examples/recipes/deterministic-ci-checks](../examples/recipes/deterministic-ci-checks/README.md)
|
|
@@ -634,6 +643,8 @@ Options:
|
|
|
634
643
|
- `--tool <query>` — substring on tool step name or `metadata.toolName`
|
|
635
644
|
- `--duration <expr>` — e.g. `>5s`, `>=500ms`
|
|
636
645
|
- `--limit <number>` — default 50
|
|
646
|
+
- `--session <id>` — limit to runs in one workflow session
|
|
647
|
+
- `--correlate-group` — when using `--session`, also match synthetic `group:` keys
|
|
637
648
|
- `--json`
|
|
638
649
|
|
|
639
650
|
Examples:
|
|
@@ -642,11 +653,56 @@ Examples:
|
|
|
642
653
|
npx agent-inspect search --status error --dir ./.agent-inspect
|
|
643
654
|
npx agent-inspect search --kind tool --name search
|
|
644
655
|
npx agent-inspect search --duration ">100ms" --json
|
|
656
|
+
npx agent-inspect search --session sess-retry-001 --dir ./.agent-inspect
|
|
645
657
|
```
|
|
646
658
|
|
|
647
659
|

|
|
648
660
|
|
|
649
|
-
### 6.19 `
|
|
661
|
+
### 6.19 `sessions`
|
|
662
|
+
|
|
663
|
+
List workflow sessions grouped from local trace metadata (`sessionId`, optional `groupId` correlation). Read-only; no network.
|
|
664
|
+
|
|
665
|
+
```bash
|
|
666
|
+
agent-inspect sessions [options]
|
|
667
|
+
```
|
|
668
|
+
|
|
669
|
+
Options:
|
|
670
|
+
|
|
671
|
+
- `--dir <path>`
|
|
672
|
+
- `--correlate-group` — treat shared `groupId` as a synthetic session when `sessionId` is absent
|
|
673
|
+
- `--json` — `SessionIndex` JSON (`sessions`, `unscopedRunIds`, `warnings`)
|
|
674
|
+
|
|
675
|
+
Example:
|
|
676
|
+
|
|
677
|
+
```bash
|
|
678
|
+
npx agent-inspect sessions --dir ./.agent-inspect
|
|
679
|
+
npx agent-inspect sessions --json
|
|
680
|
+
```
|
|
681
|
+
|
|
682
|
+
### 6.20 `session`
|
|
683
|
+
|
|
684
|
+
Inspect one workflow session: runs, handoffs, retries, and optional per-run timelines. Uses the same session index as `sessions`.
|
|
685
|
+
|
|
686
|
+
```bash
|
|
687
|
+
agent-inspect session <session-id> [options]
|
|
688
|
+
```
|
|
689
|
+
|
|
690
|
+
Options:
|
|
691
|
+
|
|
692
|
+
- `--dir <path>`
|
|
693
|
+
- `--timeline` — include per-run timelines (human or JSON `timelines`)
|
|
694
|
+
- `--critical-path` — include critical path section
|
|
695
|
+
- `--diagnostics` — include ambiguity warnings for the session
|
|
696
|
+
- `--json` — structured session view
|
|
697
|
+
|
|
698
|
+
Example:
|
|
699
|
+
|
|
700
|
+
```bash
|
|
701
|
+
npx agent-inspect session sess-handoff-001 --timeline
|
|
702
|
+
npx agent-inspect session sess-retry-001 --critical-path --json
|
|
703
|
+
```
|
|
704
|
+
|
|
705
|
+
### 6.21 `what`
|
|
650
706
|
|
|
651
707
|
Concise human-readable summary of one local trace run. Read-only; accepts v0.1 manual JSONL and v0.2 persisted-event JSONL through the shared dual-format normalization path. Vocabulary: [TRACE-VOCABULARY-V1.5.md](./proposals/TRACE-VOCABULARY-V1.5.md).
|
|
652
708
|
|
package/docs/LIMITATIONS.md
CHANGED
|
@@ -55,6 +55,12 @@ This document states what AgentInspect **does not** provide today. It complement
|
|
|
55
55
|
- **Metadata truncation** applies to string values and nested structures; very large metadata may be replaced with a truncation marker when `maxEventBytes` is exceeded (default 64 KiB per JSONL line).
|
|
56
56
|
- **Redaction is not encryption.** Local trace files remain readable on disk; treat `.agent-inspect-runs/` like any developer artifact that may contain operational data.
|
|
57
57
|
|
|
58
|
+
## Guardrails and circuits (v2.5 planning)
|
|
59
|
+
|
|
60
|
+
- **Guardrails and circuits are deterministic local utilities, not compliance certification.** `@agent-inspect/guardrails` and `@agent-inspect/circuit` (planned v2.5) evaluate text, JSON, and trace patterns with bounded evidence; they do not prove safety for every sharing context or replace human review.
|
|
61
|
+
- **No LLM judge or remote policy engine.** Built-in rules use pattern lists, redact findings, and structural heuristics only.
|
|
62
|
+
- **No automatic remediation by default.** Results are advisory unless caller code maps failures to errors, trace events, or enforcement.
|
|
63
|
+
|
|
58
64
|
## Checks, artifacts, and test reporters
|
|
59
65
|
|
|
60
66
|
- **Checks are deterministic local rules, not compliance certification.** `check`, `scan`, and `verify-safe` surface bounded findings and diagnostics over supported local inputs; they do not prove a trace is safe for every sharing context.
|
package/docs/SCHEMA.md
CHANGED
|
@@ -131,6 +131,7 @@ Unknown status must **not** be treated as success.
|
|
|
131
131
|
|
|
132
132
|
- Runs may include `metadata` on `run_started`.
|
|
133
133
|
- **Correlation metadata (v1.3.0+):** optional `correlationId`, `requestId`, `decisionId`, and `groupId` on `run_started.metadata` when passed via `inspectRun` / `maybeInspectRun` options. Event names remain unchanged (`run_started`, `step_started`, `step_completed`, `run_completed`). `stats --correlation-id` and `--group-id` filter by these fields; `list` / `view` do not filter by correlation yet.
|
|
134
|
+
- **Session and workflow metadata (v2.4.0+, additive):** optional fields for multi-run causality — see [SESSIONS-AND-WORKFLOW-CAUSALITY.md](./proposals/SESSIONS-AND-WORKFLOW-CAUSALITY.md). Recommended placement: `run_started.metadata` (manual v0.1) or persisted `attributes` (v0.2/v1.0). Common keys: `sessionId`, `conversationId`, `parentGroupId`, `attempt`, `retryOf`, `handoffFrom`, `handoffTo`, `subAgentId`, `subAgentName`, `jobId`, `queueName`, `workflowName`, `workflowStep`, `toolCallId`, `mcpToolCallId`, `linkedStepId`. All optional; missing keys mean unknown. Readers must not infer handoff/retry links from timestamps alone. Existing traces without these fields remain fully readable.
|
|
134
135
|
- Steps may include `metadata` on `step_started`.
|
|
135
136
|
- Manual traces intentionally avoid full prompt/output capture by default.
|
|
136
137
|
- **Redaction (default on):** before disk, `inspectRun` / `step` redact sensitive keys using the shared `Redactor` defaults (`authorization`, `cookie`, `token`, `apiKey`, `password`, `secret`, `email`). Opt out with `redact: false`.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "agent-inspect",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.5.0",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"description": "Local-first execution-tree debugger for TypeScript AI agents",
|
|
@@ -178,7 +178,7 @@
|
|
|
178
178
|
},
|
|
179
179
|
"scripts": {
|
|
180
180
|
"clean": "pnpm -r exec -- rm -rf dist",
|
|
181
|
-
"build": "pnpm exec tsup --config tsup.core.config.ts && pnpm exec tsup --config tsup.cli.config.ts && pnpm exec tsup --config tsup.langchain.config.ts && pnpm exec tsup --config tsup.tui.config.ts && pnpm exec tsup --config tsup.ai-sdk.config.ts && pnpm exec tsup --config tsup.vitest.config.ts && pnpm exec tsup --config tsup.jest.config.ts && pnpm exec tsup --config tsup.openai-agents.config.ts && pnpm exec tsup --config tsup.harness.config.ts && pnpm exec tsup --config tsup.redact.config.ts && pnpm exec tsup --config tsup.eval.config.ts",
|
|
181
|
+
"build": "pnpm exec tsup --config tsup.core.config.ts && pnpm exec tsup --config tsup.cli.config.ts && pnpm exec tsup --config tsup.langchain.config.ts && pnpm exec tsup --config tsup.tui.config.ts && pnpm exec tsup --config tsup.ai-sdk.config.ts && pnpm exec tsup --config tsup.vitest.config.ts && pnpm exec tsup --config tsup.jest.config.ts && pnpm exec tsup --config tsup.openai-agents.config.ts && pnpm exec tsup --config tsup.harness.config.ts && pnpm exec tsup --config tsup.redact.config.ts && pnpm exec tsup --config tsup.eval.config.ts && pnpm exec tsup --config tsup.mcp.config.ts && pnpm exec tsup --config tsup.guardrails.config.ts && pnpm exec tsup --config tsup.circuit.config.ts",
|
|
182
182
|
"typecheck": "tsc --noEmit",
|
|
183
183
|
"test": "vitest run",
|
|
184
184
|
"test:watch": "vitest",
|