@plasius/asset-contracts 0.7.0 → 0.8.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 CHANGED
@@ -14,6 +14,23 @@
14
14
  - **Security**
15
15
  - (placeholder)
16
16
 
17
+ ## [0.8.0] - 2026-10-24
18
+
19
+ - **Added**
20
+ - Opt-in model promotion composition binds complete source/output resource
21
+ bytes, conversion diagnostics and existing approval gates, with exact prior
22
+ package rollback and immutable source/derived lineage.
23
+ - (placeholder)
24
+
25
+ - **Changed**
26
+ - (placeholder)
27
+
28
+ - **Fixed**
29
+ - (placeholder)
30
+
31
+ - **Security**
32
+ - (placeholder)
33
+
17
34
  ## [0.7.0] - 2026-10-24
18
35
 
19
36
  - **Added**
@@ -367,3 +384,4 @@
367
384
  [0.5.0]: https://github.com/Plasius-LTD/asset-contracts/releases/tag/v0.5.0
368
385
  [0.6.0]: https://github.com/Plasius-LTD/asset-contracts/releases/tag/v0.6.0
369
386
  [0.7.0]: https://github.com/Plasius-LTD/asset-contracts/releases/tag/v0.7.0
387
+ [0.8.0]: https://github.com/Plasius-LTD/asset-contracts/releases/tag/v0.8.0
package/README.md CHANGED
@@ -11,6 +11,52 @@
11
11
  Canonical contracts for Plasius asset jobs, model resolution, immutable WebGPU
12
12
  shader assets, screenshot plans, reviews, and promotion records.
13
13
 
14
+ ## Model resource promotion closure
15
+
16
+ `createModelResourcePromotionRecord(input, options?)` composes a typed
17
+ `AssetPromotionRecord<ModelAssetManifest>`, complete source and output byte
18
+ inventories, raw conversion diagnostics, explicit public resource bindings,
19
+ and existing `ModelCandidate` / `ModelCandidateConfirmation` evidence. The
20
+ output uses the existing texture/resource qualification input. Source and
21
+ output must have distinct immutable asset/version identities. Runtime URIs
22
+ end in `/assetId/version/entrypoint` and satisfy existing immutable HTTPS rules.
23
+
24
+ The boundary verifies all file paths/hashes/lengths/MIME, original/derived
25
+ lineage, converter/source/output identity, re-evaluated diagnostics and runtime
26
+ resource bindings before calling `createGpuAssetPromotionRecord`. Review must
27
+ pass without blocking findings; existing rights, security, fidelity, render,
28
+ GPU envelope and human confirmation contracts remain required. Every runtime
29
+ LOD/collision/fidelity resource and projected diagnostic resource needs one
30
+ `{ resource, package: "source" | "output", filePath }` binding to verified bytes.
31
+
32
+ The frozen result retains `promotion`, `source`, qualified `output`, evaluated
33
+ `diagnostics`, sorted `resourceBindings`, `candidate`, `confirmation` and a
34
+ separate deterministic `closureHash`. This package digest includes both complete
35
+ inventories and lineage; it preserves existing candidate leaf/assembly hash
36
+ semantics. No bytes or Blobs are retained. Raw provider diagnostic text is
37
+ excluded; authored package and candidate metadata remain trusted content that
38
+ callers must minimize before public distribution.
39
+
40
+ For `outcome: "rolled-back"`, supply `rollback: { prior, current }` with results
41
+ qualified by this same installed module instance. Requalify the exact prior
42
+ source/output bytes and approval gates; target version/manifest/closure/runtime
43
+ URI must match `prior`, and `rollbackOfVersion` must equal `current`'s distinct
44
+ version for the same asset/channel. The result names both exact closure hashes.
45
+ New independent confirmation is allowed without changing package identity.
46
+ Forward calls reject rollback metadata. A JSON clone has no local qualification
47
+ brand: reconstruct and qualify its original inputs before using it as history.
48
+
49
+ This function performs no storage or pointer changes. Hosted services own
50
+ signature/issuer verification, authenticated immutable history, create-only
51
+ version admission and pointer-last concurrency control. Local qualification
52
+ does not prove embedded model references, derivation algorithms or GPU matrix
53
+ policy; existing downstream gates still apply. Fixed metadata/byte limits,
54
+ abort and a default 10s deadline (configurable 1–60s) bound work. Errors contain
55
+ fixed codes only. Backend `gpu.model.conversion.enabled` controls opt-in caller
56
+ adoption; disabled/rollback adoption retains existing factories. Capability N/A
57
+ for this package-only API. See [ADR0012](./docs/adrs/adr-0012-model-resource-promotion-closure.md)
58
+ and [TDR0007](./docs/tdrs/tdr-0007-model-resource-promotion-closure.md).
59
+
14
60
  ## Install
15
61
 
16
62
  ```bash
@@ -93,7 +139,7 @@ exported files. This helper checks bytes and declarations, not internal format
93
139
  references, MIME sniffing, malware, rendering, storage or promotion authority.
94
140
  Keep source provenance in the canonical document and do not substitute derived
95
141
  hashes for original source hashes. Role qualification is available through the additive helper below; animation/source
96
- relationships and promotion closure remain separately tracked work. The result
142
+ relationships remain adapter-owned; promotion composition uses the opt-in closure boundary above. The result
97
143
  is qualification at call time; callers must preserve the exact bytes in their
98
144
  own immutable storage boundary.
99
145
 
@@ -146,8 +192,8 @@ survive JSON reload. Original image IDs and bytes are never replaced by atlas
146
192
  hashes or upload paths. No Blob payload or renderer allocation is serialized.
147
193
  Adapters own model-internal references, derivation algorithms and image content
148
194
  inspection; qualification does not attest those operations or grant promotion.
149
- Task 12 animation schemas, Task 23 shader ABI and Task 51 promotion closure
150
- remain separate.
195
+ Task 12 animation schemas and Task 23 shader ABI remain separate;
196
+ promotion composition uses the opt-in closure boundary above.
151
197
 
152
198
  This is **trusted package metadata**, including names, extensions, original
153
199
  paths and authored sourceMetadata. Minimize/sanitize that data before public