agent-inspect 6.23.0 → 6.24.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 +6 -0
- package/README.md +1 -1
- package/docs/ADOPTION.md +2 -0
- package/docs/CLI.md +35 -3
- package/docs/VSCODE.md +8 -3
- package/package.json +1 -1
- package/packages/cli/dist/{chunk-BVQO5CWA.mjs → chunk-NHVN5AYW.mjs} +21 -2
- package/packages/cli/dist/chunk-NHVN5AYW.mjs.map +1 -0
- package/packages/cli/dist/index.cjs +44 -5
- package/packages/cli/dist/index.cjs.map +1 -1
- package/packages/cli/dist/index.mjs +28 -8
- package/packages/cli/dist/index.mjs.map +1 -1
- package/packages/cli/dist/{src-Y4NXOO2K.mjs → src-SXWEZTIS.mjs} +3 -3
- package/packages/cli/dist/{src-Y4NXOO2K.mjs.map → src-SXWEZTIS.mjs.map} +1 -1
- package/packages/core/dist/advanced.cjs +20 -0
- package/packages/core/dist/advanced.cjs.map +1 -1
- package/packages/core/dist/advanced.d.cts +8 -2
- package/packages/core/dist/advanced.d.ts +8 -2
- package/packages/core/dist/advanced.mjs +20 -1
- package/packages/core/dist/advanced.mjs.map +1 -1
- package/packages/cli/dist/chunk-BVQO5CWA.mjs.map +0 -1
package/CHANGELOG.md
CHANGED
package/README.md
CHANGED
|
@@ -212,7 +212,7 @@ The root package is enough for custom capture, the CLI, checks, and Evidence wor
|
|
|
212
212
|
|
|
213
213
|
## Status and documentation
|
|
214
214
|
|
|
215
|
-
**Current published baseline:** **6.
|
|
215
|
+
**Current published baseline:** **6.24.0** · persisted schema `1.0` · Node.js `>=20` · MIT.
|
|
216
216
|
|
|
217
217
|
Legacy v0.1 and v0.2 traces remain readable. Check the npm badge and [changelog](CHANGELOG.md) for the current published version.
|
|
218
218
|
|
package/docs/ADOPTION.md
CHANGED
|
@@ -14,6 +14,8 @@ AgentInspect is **local-first**: traces stay on disk, checks run in CI, and shar
|
|
|
14
14
|
|
|
15
15
|
See [FIRST-TRACE-IN-5-MINUTES.md](./FIRST-TRACE-IN-5-MINUTES.md) or the [docs site getting started](https://agentinspect.vercel.app/docs/getting-started/).
|
|
16
16
|
|
|
17
|
+
Lifecycle (flush/close by runtime): [LIFECYCLE.md](./LIFECYCLE.md).
|
|
18
|
+
|
|
17
19
|
```bash
|
|
18
20
|
npm install agent-inspect
|
|
19
21
|
npx agent-inspect init --yes
|
package/docs/CLI.md
CHANGED
|
@@ -1026,9 +1026,9 @@ Options:
|
|
|
1026
1026
|
- `--max-p95-duration <ms>` — maximum allowed p95 run duration
|
|
1027
1027
|
- `--forbid-tool <name>` — forbidden tool (repeatable or comma-separated)
|
|
1028
1028
|
- `--require-observation <name>` — required passed observation (repeatable or comma-separated)
|
|
1029
|
-
- `--format <format>` — `markdown`, `json`, `html`, `junit`, or `github` (default: `markdown`)
|
|
1030
|
-
- `-o, --output <dir>` — write `gate-results.json`, `gate-summary.md`, `gate-report.html`, `junit.xml`, `github-step-summary.md`
|
|
1031
|
-
- `--json` — print deterministic JSON result
|
|
1029
|
+
- `--format <format>` — `markdown`, `json`, `json-compact`, `html`, `junit`, `github`, or `github-annotations` (default: `markdown`)
|
|
1030
|
+
- `-o, --output <dir>` — write `gate-results.json`, `gate-summary.md`, `gate-report.html`, `junit.xml`, `github-step-summary.md`, `github-annotations.txt`
|
|
1031
|
+
- `--json` — print deterministic JSON result (pretty); use `--format json-compact` for CI logs
|
|
1032
1032
|
- `--evidence-on <fail|always|never>` — write local Evidence v2 (no upload); omitted = never
|
|
1033
1033
|
- `--evidence-dir <path>` — Evidence output directory or base path
|
|
1034
1034
|
- `--evidence-profile <local|share|strict>` — redaction profile (default `share`)
|
|
@@ -1042,6 +1042,8 @@ Example:
|
|
|
1042
1042
|
npx agent-inspect gate --suite fixtures/configs/outcome-suite.suite.json --output ./gate-artifacts
|
|
1043
1043
|
npx agent-inspect gate --dir fixtures/cohorts/before-after --max-error-rate 5 --forbid-tool deleteAccount
|
|
1044
1044
|
npx agent-inspect gate --suite agent-inspect.suite.ts --evidence-on fail --evidence-profile share
|
|
1045
|
+
npx agent-inspect gate --suite agent-inspect.suite.ts --format github-annotations
|
|
1046
|
+
npx agent-inspect gate --suite agent-inspect.suite.ts --format json-compact
|
|
1045
1047
|
```
|
|
1046
1048
|
|
|
1047
1049
|
Recipe: [github-actions-gate](../examples/recipes/github-actions-gate/README.md).
|
|
@@ -1069,6 +1071,36 @@ npx agent-inspect viewer --suite --config fixtures/configs/outcome-suite.suite.j
|
|
|
1069
1071
|
npx agent-inspect viewer --workspace
|
|
1070
1072
|
```
|
|
1071
1073
|
|
|
1074
|
+
### 6.29 `init`
|
|
1075
|
+
|
|
1076
|
+
Scaffold local AgentInspect config and a metadata-only demo (v3.1+). Does **not** install packages or rewrite application source unless you opt in later.
|
|
1077
|
+
|
|
1078
|
+
```bash
|
|
1079
|
+
agent-inspect init [--framework <name>] [--ci github] [--dry-run] [--yes] [--json]
|
|
1080
|
+
```
|
|
1081
|
+
|
|
1082
|
+
`--framework` values (adoption order):
|
|
1083
|
+
|
|
1084
|
+
| Value | Meaning |
|
|
1085
|
+
| --- | --- |
|
|
1086
|
+
| `ai-sdk` | AI SDK kit pointer + demo |
|
|
1087
|
+
| `langchain` / `langgraph` | LangChain/LangGraph kit pointer + demo |
|
|
1088
|
+
| `openai-agents` | OpenAI Agents kit pointer + demo |
|
|
1089
|
+
| `custom` | Manual `inspectRun` / `step` demo |
|
|
1090
|
+
| `observe` / `manual` | Aliases of `custom` (`observe(...)` demo) |
|
|
1091
|
+
|
|
1092
|
+
Also writes `.agent-inspect/.gitkeep` and optional GitHub Actions workflow when `--ci github` is set. See [ADOPTION.md](./ADOPTION.md), [INSTALL-KITS.md](./INSTALL-KITS.md), and [LIFECYCLE.md](./LIFECYCLE.md).
|
|
1093
|
+
|
|
1094
|
+
### 6.30 `doctor`
|
|
1095
|
+
|
|
1096
|
+
Diagnose local setup **without network probes or installs** (v3.1+).
|
|
1097
|
+
|
|
1098
|
+
```bash
|
|
1099
|
+
agent-inspect doctor [--framework <name>] [--trace-dir <path>] [--check-imports] [--json]
|
|
1100
|
+
```
|
|
1101
|
+
|
|
1102
|
+
Reports version alignment, peer/package resolution, capture posture hints, writer path, redaction profile reminders, and no-default-egress expectations. Failures exit non-zero. Prefer `workspace doctor` when using a managed workspace layout.
|
|
1103
|
+
|
|
1072
1104
|
## 7. Optional TUI behavior
|
|
1073
1105
|
|
|
1074
1106
|
`view --tui` delegates to `@agent-inspect/tui` and requires an interactive terminal. If the package is not installed, the CLI prints a short install hint.
|
package/docs/VSCODE.md
CHANGED
|
@@ -4,11 +4,16 @@ Read-only sidebar for local trace directories. The extension shells out to the p
|
|
|
4
4
|
|
|
5
5
|
**Support level:** Experimental (unpublished). Ignored by Changesets; not part of the fixed npm release group.
|
|
6
6
|
|
|
7
|
-
## Product scope decision (6.
|
|
7
|
+
## Product scope decision (6.24.0)
|
|
8
8
|
|
|
9
|
-
**Disposition:
|
|
9
|
+
**Disposition: close without Marketplace publish (Option A, confirmed).**
|
|
10
10
|
|
|
11
|
-
|
|
11
|
+
- Keep the in-repo extension unpublished.
|
|
12
|
+
- Do **not** publish to the VS Code Marketplace in this train (credentials + product priority).
|
|
13
|
+
- Open PR [#295](https://github.com/rajudandigam/agent-inspect/pull/295) (sample trace command) remains **out of the adoption train** — close or park as contributor-optional; do not merge solely to clear the queue while CI is red.
|
|
14
|
+
- Related issues (#66, #65) stay deferred until a later capacity window revisits VS Code.
|
|
15
|
+
|
|
16
|
+
Core, official adapters, CLI, Evidence, and TraceContract remain the adoption surface.
|
|
12
17
|
|
|
13
18
|
## Develop
|
|
14
19
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "agent-inspect",
|
|
3
|
-
"version": "6.
|
|
3
|
+
"version": "6.24.0",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"description": "Local evidence debugger and trajectory-test toolkit for TypeScript AI agents — execution trees, TraceContract checks, Evidence v2, and read-only MCP",
|
|
@@ -11794,15 +11794,34 @@ ${cases}
|
|
|
11794
11794
|
</testsuite>
|
|
11795
11795
|
</testsuites>`;
|
|
11796
11796
|
}
|
|
11797
|
+
function renderGateGithubAnnotations(result) {
|
|
11798
|
+
return result.checks.filter((check) => !check.ok).map((check) => {
|
|
11799
|
+
const message = check.message.replace(/\r?\n/g, " ").replace(/%/g, "%25");
|
|
11800
|
+
return `::error title=${check.name}::${message}`;
|
|
11801
|
+
}).join("\n");
|
|
11802
|
+
}
|
|
11797
11803
|
function renderGateReport(result, options = {}) {
|
|
11798
11804
|
const format = options.format ?? "markdown";
|
|
11799
11805
|
if (format === "json") return JSON.stringify(result, null, 2);
|
|
11806
|
+
if (format === "json-compact") {
|
|
11807
|
+
return JSON.stringify({
|
|
11808
|
+
ok: result.ok,
|
|
11809
|
+
exitCode: result.exitCode,
|
|
11810
|
+
failed: result.checks.filter((check) => !check.ok).map((check) => check.name),
|
|
11811
|
+
checks: result.checks.map((check) => ({
|
|
11812
|
+
name: check.name,
|
|
11813
|
+
ok: check.ok,
|
|
11814
|
+
message: check.message
|
|
11815
|
+
}))
|
|
11816
|
+
});
|
|
11817
|
+
}
|
|
11800
11818
|
if (format === "html") return renderGateReportHtml(result);
|
|
11801
11819
|
if (format === "junit") return renderGateJUnit(result);
|
|
11802
11820
|
if (format === "github") return renderGateGithubStepSummary(result);
|
|
11821
|
+
if (format === "github-annotations") return renderGateGithubAnnotations(result);
|
|
11803
11822
|
return renderGateSummaryMarkdown(result);
|
|
11804
11823
|
}
|
|
11805
11824
|
|
|
11806
11825
|
export { COHORT_METRIC_IDS, DEFAULT_SUITE_ARTIFACTS_DIR, EVIDENCE_FORMAT_VERSION, EVIDENCE_HTML_FILENAME, EVIDENCE_MANIFEST_FILENAME, Redactor, TraceDirectory, TraceReadError, TreeBuilder, aggregateBundleSafeStatus, aggregateSessionCheckResults, analyzeCohort, applyProfileMetadataCaps, assertBundlePathContained, assertEvidenceRelativePath, buildActivitySummary, buildBundleMetadata, buildBundleSummaryMarkdown, buildEvidenceCausalFailureViewHtml, buildEvidenceCiPackage, buildEvidenceCircuitViewHtml, buildEvidenceContractsViewHtml, buildEvidenceDiffViewHtml, buildEvidenceHtmlShell, buildEvidenceManifest, buildEvidenceOutcomesViewHtml, buildEvidenceProvenanceViewHtml, buildEvidenceSafetyViewHtml, buildEvidenceTimelineViewHtml, buildEvidenceToolsLlmViewHtml, buildEvidenceTreeViewHtml, buildLocalExplanation, buildPlaceholderArtifact, buildRunSummary, buildRunTimeline, buildRunWhatSummary, buildSessionIndex, buildTraceStats, buildZipArchive, bundleFailsOnSafety, bundleRunAssetRelativePath, collectTraceSchemaVersions, compactAttributes, createBaselineRegressionRule, createLlmUsageRule, createMaxStepDurationRule, createObservedOutcomeRule, createRequireCompletedRule, createRunDepthRule, createRunDurationRule, createRunStatusRule, createSafetyOversizedAttributeRule, createSafetyRawContentRule, createSafetyRedactionRule, createSafetySecretPatternRule, createStallDetectionRule, createStructureCycleRule, createStructureOrphanRule, createStructureParallelWidthRule, createStructureRelationshipRule, createToolUsageRule, defaultBundleOutputPath, defaultSuiteConfigTemplate, diffRuns, diffTraceEvents, enrichSessionRunRecord, escapeHtml, escapeMarkdown, extractMetadata, extractOutcomesFromTraceEvents, filterMetasBySessionScope, filterTraces, flattenTree, formatDuration2 as formatDuration, formatStepLabel, formatTimestamp, gateHasThresholds, getIndent, getTraceFilePath, inferEvidenceFileRole, isAgentInspectTrace, isPersistedInspectEvent, loadSessionRunRecords, loadSuiteConfig, loadTraceMetadataList, manualTraceEventsToComparableRun, nanoid, normalizeBundleOutputPath, openTrace, parseCohortMetricList, parseDuration, parseDurationFilter, parseGateList, parseTraceJsonl, persistedInspectEventsToTraceEvents, renderActivitySummaryHuman, renderCohortReport, renderErrorLine, renderGateReport, renderObservedOutcomesHtml, renderObservedOutcomesMarkdown, renderRunDiff, renderRunWhat, renderStepLine, renderSuiteReport, renderTimeline, renderTraceStats, resolveBundleRunIds, resolveRedactionProfile, resolveSuiteTemplate, resolveTraceDir, runGate, runSuite, runTraceChecks, safeString, sanitizeBundleRunId, searchTraces, serializeEvidenceManifest, sha256Hex, stableJson, summarizeObservedOutcomes, summarizeSemanticParity, traceEventToPersistedInspectEvent, truncateName, truncateStringForProfile, validateEvent, validateSuiteConfig, verifyEvidenceDirectory, zeroKinds };
|
|
11807
|
-
//# sourceMappingURL=chunk-
|
|
11808
|
-
//# sourceMappingURL=chunk-
|
|
11826
|
+
//# sourceMappingURL=chunk-NHVN5AYW.mjs.map
|
|
11827
|
+
//# sourceMappingURL=chunk-NHVN5AYW.mjs.map
|