@lmzhen/dsh-evolution-state-storage 0.32.4 → 0.32.6

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 +9 -28
  2. package/package.json +2 -2
package/README.md CHANGED
@@ -1,36 +1,17 @@
1
1
  # @lmzhen/dsh-evolution-state-storage
2
2
 
3
- Provider registry seam for durable evolution state: the consumer (`evolution-state`) never touches
4
- a medium — providers register here (`json` = IO-seam files, `domain` = storage-domain KV).
3
+ Provider registry and shared contract for durable evolution state. It does not choose a storage medium or write the state itself.
5
4
 
6
- ## Model surface
5
+ ## What it owns
7
6
 
8
- - **Model-visible:** nothing of its own: the consumer rows own the injection.
9
- - **Prompt prefix / KV cache:** unchanged by this package: family-level rules single-sourced in `packages/README.md` §"Model-visible prompt prefix and the KV cache".
10
- - **Mount it?** yes — the `evolution-state-storage` row, in `evolution-host`/`evolution-all`/one-click `evolution-preset`; a seam consumed by `evolution-state`, `evolution-state-json`, `evolution-state-domain` and `evolution-approval`.
7
+ - Registration and lookup of the shipped `json` and `domain` providers.
8
+ - Review, curator, and pending-record contracts, including claim/resolve/release transitions.
9
+ - Retention rules and a published provider-conformance suite for alternative implementations.
11
10
 
12
- ## Conformance suite
11
+ The resolved pending-record cap is 200. Pending and executing records are not trimmed by that cap, and capability approvals are exempt from resolved-record eviction. Review cadence state is capped at 500 sessions. The JSON provider archives evicted resolved records; the domain provider has no equivalent JSON archive sidecar.
13
12
 
14
- The package publishes `runStateProviderConsistency(provider, assert)` — the whole seam contract as one call: field-complete pending round-trips, claim/resolve rollback, refusals at the write boundary, clone/alias independence, unknown-field preservation, and the two caps (resolved pending tail, review-state session rows). A third-party provider checks itself by running the suite against its own instance:
13
+ ## Deployment boundary
15
14
 
16
- ```ts
17
- import { runStateProviderConsistency } from '@lmzhen/dsh-evolution-state-storage'
18
- import { expect } from 'vitest' // or any runner wrapped into `ConformanceAssert`
15
+ Storage location depends on the selected provider. JSON state normally lives below the evolution home; a domain deployment can use another configured medium, including a remote backend. Do not assume every provider stores data in `$DSH_HOME`.
19
16
 
20
- await runStateProviderConsistency(myProvider, expect)
21
- ```
22
-
23
- Every value the vectors use is PARAMETERIZABLE (U-2): `runStateProviderConsistency(provider, assert, options)` takes `idPrefix` / `claimPrefix` / `createdAt` / `sessionId` / `attributionSessionId` / `reviewSessionPrefix`, so a medium that already holds records in the default `c-…` namespace — or whose schema insists on a parseable stamp — runs the very same vectors under its own values. Every field defaults to the in-tree literals, so a two-argument call is unchanged. Each vector carries a `since <version>` note saying which release it became binding in.
24
-
25
- The assertion surface is INJECTED rather than imported, which is what lets this module ship: it carries no test-runner dependency, so loading the package never loads vitest. Both shipped providers run the same suite (`evolution-state-json` / `evolution-state-domain` `tests/provider-consistency.spec.ts`) — the json one also runs it under a caller-supplied namespace — and `consistency-forge.spec.ts` proves the suite fails when a single field is forged.
26
-
27
-
28
- ## Known limitations
29
-
30
- - Provider registry has no default medium. Mount `evolution-state-domain` or `evolution-state-json` before state reads.
31
-
32
- **Runtime invariant:** No companion is published. The platform auto-assembles nothing and the family mounts no `<pkg>/invariant` cordis row, so a companion here would never execute (v37 S2.1 / I-3).
33
-
34
- ## Notes and history
35
-
36
- - Conformance suite (S3-2 / J-5)
17
+ Consumers normally mount [evolution-state](../evolution-state/README.md), which delegates to this registry. There is no direct command, panel, or model tool here.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@lmzhen/dsh-evolution-state-storage",
3
3
  "description": "Provider registry seam for durable evolution state (community build)",
4
- "version": "0.32.4",
4
+ "version": "0.32.6",
5
5
  "publishConfig": {
6
6
  "access": "public"
7
7
  },
@@ -26,7 +26,7 @@
26
26
  ],
27
27
  "license": "MIT",
28
28
  "dependencies": {
29
- "@lmzhen/dsh-evolution-contract": "^0.32.4"
29
+ "@lmzhen/dsh-evolution-contract": "^0.32.6"
30
30
  },
31
31
  "peerDependencies": {
32
32
  "@deepseek-ai/cordis": "^4.0.5"