@agent-custody/state 0.1.0 → 0.1.1

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.
Files changed (2) hide show
  1. package/README.md +2 -8
  2. package/package.json +3 -3
package/README.md CHANGED
@@ -10,13 +10,7 @@ Retrieval stays with whatever store you already use. This package owns provenanc
10
10
  npm install @agent-custody/state # or bun add, pnpm add
11
11
  ```
12
12
 
13
- Not on npm yet: the `@agent-custody` scope is still to be claimed. Until then, build from a clone and install the tarball:
14
-
15
- ```bash
16
- bun install && bun run build # at the repository root
17
- cd packages/state && bun pm pack # writes agent-custody-state-0.1.0.tgz here
18
- npm install /path/to/agent-custody/packages/state/agent-custody-state-0.1.0.tgz # in your project
19
- ```
13
+ Published on npm as [`@agent-custody/state`](https://www.npmjs.com/package/@agent-custody/state): compiled JavaScript with type declarations, Node 22 or later, Apache-2.0.
20
14
 
21
15
  ```ts
22
16
  import { Ledger } from "@agent-custody/state";
@@ -28,7 +22,7 @@ ledger.retract({ factId: a.fact.factId, actor: "user:admin", reason: "poisoned b
28
22
  ledger.asOf({ validAt: "2026-09-01T00:00:00Z", txAt: "2026-09-01T00:00:00Z" });
29
23
  ```
30
24
 
31
- [examples/01-ledger.ts](examples/01-ledger.ts) walks through a wrong write and its undo, step by step; run it with `node examples/01-ledger.ts` from this directory. The test suite runs it too.
25
+ Two runnable examples, both executed by the test suite. [01-ledger.ts](examples/01-ledger.ts) walks through a wrong write and its undo. [02-receipt-to-belief.ts](examples/02-receipt-to-belief.ts) runs the whole loop with the receipts package: a tool call gets a signed receipt, the receipt is verified, the belief taken from it is recorded citing the receipt, and later retracted. Run them with `node examples/<file>` from this directory, after `bun run build` at the repository root.
32
26
 
33
27
  ## The ledger
34
28
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@agent-custody/state",
3
- "version": "0.1.0",
3
+ "version": "0.1.1",
4
4
  "description": "Governed memory for AI agents: a fact ledger with provenance, valid time, rollback, and lineage, built on @agent-custody/receipts",
5
5
  "license": "Apache-2.0",
6
6
  "repository": {
@@ -24,13 +24,13 @@
24
24
  "scripts": {
25
25
  "build": "tsc -p tsconfig.build.json",
26
26
  "typecheck": "tsc --noEmit",
27
- "test": "vitest run"
27
+ "test": "tsc -p ../receipts/tsconfig.build.json && vitest run"
28
28
  },
29
29
  "engines": {
30
30
  "node": ">=22"
31
31
  },
32
32
  "dependencies": {
33
- "@agent-custody/receipts": "0.1.0"
33
+ "@agent-custody/receipts": "0.1.1"
34
34
  },
35
35
  "devDependencies": {
36
36
  "@types/node": "^26.4.1",