{"_id":"@act-spec/inspector","name":"@act-spec/inspector","dist-tags":{"rc":"0.2.0-rc.1","latest":"0.2.0-rc.1"},"versions":{"0.2.0-rc.1":{"name":"@act-spec/inspector","version":"0.2.0-rc.1","description":"PRD-601 inspector CLI + library for the ACT (Agent Content Tree) v0.1 wire format. Subcommands: fetch, walk, diff, token-budget. Reuses @act-spec/validator for parsing and structural checks (PRD-601-R1).","license":"Apache-2.0","author":{"name":"Jeremy Forsythe","email":"jeremy@act-spec.org"},"homepage":"https://act-spec.org","bugs":{"url":"https://github.com/act-spec/act/issues"},"type":"module","main":"./dist/index.js","types":"./dist/index.d.ts","bin":{"act-inspect":"bin/act-inspect.js"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","default":"./dist/index.js"}},"publishConfig":{"access":"public"},"repository":{"type":"git","url":"git+https://github.com/act-spec/act.git","directory":"packages/inspector"},"dependencies":{"@act-spec/core":"0.2.0-rc.1","@act-spec/validator":"0.2.0-rc.1"},"devDependencies":{"@vitest/coverage-v8":"^2.1.9","tsx":"^4.19.2","typescript":"^5.6.3","vitest":"^2.1.4"},"scripts":{"build":"tsc -p tsconfig.json","start":"pnpm -F @act-spec/site-browser dev","test":"vitest run","test:watch":"vitest","test:coverage":"vitest run --coverage","lint":"eslint src","typecheck":"tsc -p tsconfig.json --noEmit","conformance":"pnpm -F @act-spec/example-astro-docs build && tsx conformance.ts"},"_id":"@act-spec/inspector@0.2.0-rc.1","_integrity":"sha512-DBs8yT7NnE2L9SrD06JpqEfW29LqUJTqxWGdeRI4k6tDFsMogkDGthFAPcZBpxyFVDA0dn1p1r4e9UNYIOCRPQ==","_resolved":"/private/var/folders/yp/y7frhcvj70jgr6b8g633lghr0000gn/T/ca8fa22087b92a4350103d9a9dadbf49/act-spec-inspector-0.2.0-rc.1.tgz","_from":"file:act-spec-inspector-0.2.0-rc.1.tgz","_nodeVersion":"22.19.0","_npmVersion":"11.6.0","dist":{"integrity":"sha512-DBs8yT7NnE2L9SrD06JpqEfW29LqUJTqxWGdeRI4k6tDFsMogkDGthFAPcZBpxyFVDA0dn1p1r4e9UNYIOCRPQ==","shasum":"ac88e0f0cf2b1fbace3f991838fce6a23d3c7305","tarball":"https://registry.npmjs.org/@act-spec/inspector/-/inspector-0.2.0-rc.1.tgz","fileCount":80,"unpackedSize":374823,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEQCIDht1Q8/ZZODqKNGmWwk4kIDdb5lvH8P8rmr4s2mQ7eCAiBESlMXbZQ3GdVBsgwMyiRgRVhbqqDFz8RvtAvCp6wAHA=="}]},"_npmUser":{"name":"jdforsythe","email":"jdforsythe@gmail.com"},"directories":{},"maintainers":[{"name":"jdforsythe","email":"jdforsythe@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/inspector_0.2.0-rc.1_1777915313384_0.6472210615870069"},"_hasShrinkwrap":false}},"time":{"created":"2026-05-04T17:21:53.217Z","0.2.0-rc.1":"2026-05-04T17:21:53.533Z","modified":"2026-05-04T17:21:53.867Z"},"maintainers":[{"name":"jdforsythe","email":"jdforsythe@gmail.com"}],"description":"PRD-601 inspector CLI + library for the ACT (Agent Content Tree) v0.1 wire format. Subcommands: fetch, walk, diff, token-budget. Reuses @act-spec/validator for parsing and structural checks (PRD-601-R1).","homepage":"https://act-spec.org","repository":{"type":"git","url":"git+https://github.com/act-spec/act.git","directory":"packages/inspector"},"author":{"name":"Jeremy Forsythe","email":"jeremy@act-spec.org"},"bugs":{"url":"https://github.com/act-spec/act/issues"},"license":"Apache-2.0","readme":"# @act-spec/inspector\n\nInspector CLI + library for the ACT (Agent Content Tree) wire format.\nSubcommands: `fetch`, `walk`, `diff`, `token-budget`. The binary is\n`act-inspect`; the library exposes one programmatic function per\nsubcommand.\n\nTwo architectural invariants drive the design:\n\n- Every envelope this package sees passes through `@act-spec/validator`'s\n  per-envelope validators. The inspector never ships its own JSON Schema\n  parser.\n- The inspector emits `findings` — user-facing observations — never\n  `gaps`. For a conformance verdict, run `act-validate`\n  (`@act-spec/validator`).\n\n## Status\n\nACT v0.1 internal hand-test candidate. Public release lands at v0.2.\n\n## Install\n\nUnpublished in v0.1. Consume via the workspace:\n\n```jsonc\n// package.json\n{ \"devDependencies\": { \"@act-spec/inspector\": \"workspace:*\" } }\n```\n\nFor out-of-tree hand-test, run `pnpm pack` inside `packages/inspector`\nand install the resulting tarball locally; the `act-inspect` binary is\nexposed via the package's `bin` field.\n\n## Usage\n\nCLI:\n\n```bash\nact-inspect fetch  https://example.com/act/                # manifest + index summary\nact-inspect walk   https://example.com/act/  --max 50       # walk N nodes\nact-inspect diff   ./before/index.json ./after/index.json   # ETag-keyed diff\nact-inspect token-budget https://example.com/act/  --limit 8000\n```\n\nProgrammatic:\n\n```ts\nimport { inspect, walk, diff, budget, node, subtree } from '@act-spec/inspector';\n\nconst result = await inspect({ url: 'https://example.com/act/' });\nfor (const finding of result.findings) {\n  console.log(finding.code, finding.message);\n}\n```\n\nBrowser UI (boots the site browser SPA on http://localhost:5175/browser/, paste\nany URL — including `http://localhost:<port>` for a locally-running ACT site):\n\n```bash\npnpm -F @act-spec/inspector start\n```\n\n## Conformance / what's tested\n\nEach subcommand has a citing test in the suite covering the validator-reuse\ninvariant, the `findings` reporting contract, etag-keyed diff semantics,\nand the token-budget walk policy. The conformance gate exercises every\nsubcommand against the bundled fixtures.\n\n```bash\npnpm -F @act-spec/inspector conformance\n```\n\n## Compatibility\n\nPure JS, no host-framework peer. Targets Node 20+. Reuses the schema\nbundle and per-envelope validators shipped by `@act-spec/validator`;\nupgrading the validator picks up new schema versions automatically.\n\n## Links\n\n- Validator: [`@act-spec/validator`](../validator)\n- Repository: <https://github.com/act-spec/act>\n","readmeFilename":"README.md","_rev":"1-5956fefed89f5e951cbfd26b407749a6"}