@colophon-claims/verify 0.2.0 → 0.2.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.
- package/README.md +18 -8
- package/dist/admission/contracts.d.ts +241 -0
- package/dist/admission/contracts.js +116 -0
- package/dist/admission/index.d.ts +2 -0
- package/dist/admission/index.js +2 -0
- package/dist/admission/prompted-commitment.d.ts +19 -0
- package/dist/admission/prompted-commitment.js +52 -0
- package/dist/admission/prompted-selection.d.ts +24 -0
- package/dist/admission/prompted-selection.js +85 -0
- package/dist/admission/verification.d.ts +1 -0
- package/dist/admission/verification.js +88 -42
- package/dist/assets.d.ts +21 -1
- package/dist/assets.js +60 -3
- package/dist/binding/beacon-binding.d.ts +230 -0
- package/dist/binding/beacon-binding.js +325 -0
- package/dist/binding/report-face.d.ts +45 -0
- package/dist/binding/report-face.js +153 -0
- package/dist/cli.js +74 -12
- package/dist/index.d.ts +14 -3
- package/dist/index.js +16 -3
- package/dist/manifest.d.ts +30 -4
- package/dist/manifest.js +30 -0
- package/dist/materialize.d.ts +7 -0
- package/dist/materialize.js +7 -0
- package/dist/outcome.d.ts +31 -0
- package/dist/outcome.js +45 -0
- package/dist/profile/claim-consistency.d.ts +8 -1
- package/dist/profile/claim-consistency.js +4 -4
- package/dist/profile/claim.d.ts +201 -2
- package/dist/profile/claim.js +178 -47
- package/dist/profile/disclosure.d.ts +273 -0
- package/dist/profile/disclosure.js +240 -0
- package/dist/profile/run-results.d.ts +8 -2
- package/dist/profile/run-results.js +9 -3
- package/dist/profile/task-selection.d.ts +69 -0
- package/dist/profile/task-selection.js +140 -0
- package/dist/reader-instructions.d.ts +38 -1
- package/dist/reader-instructions.js +42 -2
- package/dist/schema.d.ts +4 -3
- package/dist/schema.js +17 -0
- package/dist/signers.d.ts +48 -0
- package/dist/signers.js +77 -0
- package/dist/verify.d.ts +20 -6
- package/dist/verify.js +156 -31
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +14 -14
package/dist/index.d.ts
CHANGED
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
export { verifyPublicBundle, verifyPublicBundleSnapshot } from "./verify.js";
|
|
2
2
|
export type { PublicBundleVerificationCheck, PublicBundleVerificationResult, VerifiedPublicBundleSnapshot, VerifyPublicBundleDeps, } from "./verify.js";
|
|
3
|
+
export type { PublicBundleSigner, PublicBundleSignerRole } from "./signers.js";
|
|
3
4
|
export { derivePublicComparison } from "./comparison.js";
|
|
4
5
|
export type { DerivePublicComparisonInput, PublicComparisonCell, PublicComparisonOutput, PublicComparisonTask, PublicComparisonVerdict, PublicComparisonView, PublicDescriptiveComparison, } from "./comparison.js";
|
|
5
6
|
export { buildPublicAssets } from "./assets.js";
|
|
7
|
+
export { assertTaskSelectionConsistency, taskSelectionContradiction } from "./profile/task-selection.js";
|
|
6
8
|
export type { PublicAssetInput } from "./assets.js";
|
|
7
9
|
export { anchorCertificateReader, anchorChainVerifier, anchorSignatureVerifier, nodeCryptoAnchorPorts, } from "./anchor/ports.js";
|
|
8
10
|
export { evaluateIntegrityAnchors } from "./anchor/check.js";
|
|
@@ -10,14 +12,23 @@ export type { AnchorProofStatus, AnchorSubjectOutcome, AnchorSubjectReport, Anch
|
|
|
10
12
|
export type { InspectRuntimeMethodDisclosure, InspectScoringProjectionDisclosure, } from "./profile/inspect-disclosure.js";
|
|
11
13
|
export { ANCHORED_PRE_REGISTRATION, ANCHORED_TRUST_ROOT, ClaimAnchorProjectionError, ClaimAnchorSchema, SELF_RUN_TRUST_ROOT, STRUCTURAL_PRE_REGISTRATION, additionalLockAnchorLine, anchoredPreRegistration, anchoredPreRegistrationSentence, anchoredTrustRoot, anchoredVenueLimits, carriedMatrixAnchors, deriveClaimAnchors, governingLockAnchors, matrixAnchorLine, } from "./profile/anchor-claims.js";
|
|
12
14
|
export type { CarriedAnchorRecord, ClaimAnchor, ClaimAnchorFacts, ClaimAnchorSubject, DeriveClaimAnchorsInput, OpenTimestampsClaimAnchorFacts, Rfc3161ClaimAnchorFacts, } from "./profile/anchor-claims.js";
|
|
13
|
-
export { BUNDLE_FORMAT, BUNDLE_V4_FORMAT, BUNDLE_V5_FORMAT, BUNDLE_V6_FORMAT, SUPPORTED_BUNDLE_FORMATS, } from "./manifest.js";
|
|
15
|
+
export { BUNDLE_FORMAT, BUNDLE_V4_FORMAT, BUNDLE_V5_FORMAT, BUNDLE_V6_FORMAT, BUNDLE_V7_FORMAT, BUNDLE_V8_FORMAT, SUPPORTED_BUNDLE_FORMATS, } from "./manifest.js";
|
|
16
|
+
export { ClaimDisclosureSectionSchema, DISCLOSURE_ROLE_BINDING, DISCLOSURE_SPECIFICATION_BUNDLE_ROLE, DisclosureProjectionError, assertDisclosureSpecification, deriveDisclosureSpecification, } from "./profile/disclosure.js";
|
|
17
|
+
export type { AssertDisclosureSpecificationInput, ClaimDisclosureSection, DisclosureSpecificationReport, } from "./profile/disclosure.js";
|
|
14
18
|
export type { BundleManifest, VerifiedBundleSnapshot } from "./manifest.js";
|
|
15
19
|
export * from "./admission/index.js";
|
|
16
20
|
export * from "./schema.js";
|
|
17
21
|
export * from "./profile/binary-judge-manifest.js";
|
|
18
22
|
export * from "./profile/binary-qualification.js";
|
|
19
|
-
export { ClaimPackageSchema } from "./profile/claim.js";
|
|
23
|
+
export { ClaimPackageSchema, DISCLOSED_CLAIM_PACKAGE_SCHEMA_ID } from "./profile/claim.js";
|
|
20
24
|
export type { ClaimPackage } from "./profile/claim.js";
|
|
25
|
+
export { firstDifference } from "./profile/claim-consistency.js";
|
|
26
|
+
export { NOT_FETCHED_CHECK, summarizeVerificationOutcome } from "./outcome.js";
|
|
27
|
+
export type { VerificationCheckOutcome, VerificationCheckState, VerificationOutcome, } from "./outcome.js";
|
|
21
28
|
export { VERIFIER_VERSION, renderVerifiedBundle, runVerifierCli } from "./cli.js";
|
|
22
29
|
export type { VerifierCliDeps, VerifierCliResult } from "./cli.js";
|
|
23
|
-
export { PUBLIC_BUNDLE_COMPATIBLE_VERIFICATION_COMMAND, PUBLIC_BUNDLE_VERIFICATION_CHECKS, PUBLIC_BUNDLE_VERIFICATION_COMMAND, PUBLIC_BUNDLE_V4_COMPATIBLE_VERIFICATION_COMMAND, PUBLIC_BUNDLE_V4_VERIFICATION_COMMAND, PUBLIC_BUNDLE_V5_COMPATIBLE_VERIFICATION_COMMAND, PUBLIC_BUNDLE_V5_VERIFICATION_COMMAND, PUBLIC_BUNDLE_V6_CHECKS, PUBLIC_BUNDLE_V6_COMPATIBLE_VERIFICATION_COMMAND, PUBLIC_BUNDLE_V6_VERIFICATION_COMMAND, PUBLIC_BUNDLE_VERIFICATION_INSTRUCTIONS, PUBLIC_BUNDLE_VERIFIER_MAJOR, PUBLIC_BUNDLE_V4_VERIFIER_MAJOR, } from "./reader-instructions.js";
|
|
30
|
+
export { PUBLIC_BUNDLE_COMPATIBLE_VERIFICATION_COMMAND, PUBLIC_BUNDLE_VERIFICATION_CHECKS, PUBLIC_BUNDLE_VERIFICATION_COMMAND, PUBLIC_BUNDLE_V4_COMPATIBLE_VERIFICATION_COMMAND, PUBLIC_BUNDLE_V4_VERIFICATION_COMMAND, PUBLIC_BUNDLE_V5_COMPATIBLE_VERIFICATION_COMMAND, PUBLIC_BUNDLE_V5_VERIFICATION_COMMAND, PUBLIC_BUNDLE_V6_CHECKS, PUBLIC_BUNDLE_V6_COMPATIBLE_VERIFICATION_COMMAND, PUBLIC_BUNDLE_V6_VERIFICATION_COMMAND, PUBLIC_BUNDLE_V7_CHECKS, PUBLIC_BUNDLE_V7_COMPATIBLE_VERIFICATION_COMMAND, PUBLIC_BUNDLE_V7_VERIFICATION_COMMAND, PUBLIC_BUNDLE_V8_CHECKS, PUBLIC_BUNDLE_V8_COMPATIBLE_VERIFICATION_COMMAND, PUBLIC_BUNDLE_V8_VERIFICATION_COMMAND, PUBLIC_BUNDLE_VERIFICATION_INSTRUCTIONS, PUBLIC_BUNDLE_VERIFIER_MAJOR, PUBLIC_BUNDLE_V4_VERIFIER_MAJOR, } from "./reader-instructions.js";
|
|
31
|
+
export { BEACON_BINDING_PROCEDURE, BEACON_SOURCES, BEACON_SOURCE_IDS, MAX_BEACON_ROUND, BeaconReferenceSchema, RunBindingError, RunBindingSchema, beaconRoundInstant, computeBeaconOrder, requiredBeaconRound, verifyRunBinding, } from "./binding/beacon-binding.js";
|
|
32
|
+
export type { BeaconOrderParams, BeaconOrderResult, BeaconPostSealBasis, BeaconReference, BeaconRoundBasis, BeaconSourceDefinition, BeaconSourceId, BeaconSourceTimeBasis, RequiredBeaconRound, RunBinding, VerifiedRunBinding, } from "./binding/beacon-binding.js";
|
|
33
|
+
export { runBindingClass, runBindingSentence, runBoundVenueLimits } from "./binding/report-face.js";
|
|
34
|
+
export type { RunBindingClass } from "./binding/report-face.js";
|
package/dist/index.js
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
export { verifyPublicBundle, verifyPublicBundleSnapshot } from "./verify.js";
|
|
2
2
|
export { derivePublicComparison } from "./comparison.js";
|
|
3
3
|
export { buildPublicAssets } from "./assets.js";
|
|
4
|
+
export { assertTaskSelectionConsistency, taskSelectionContradiction } from "./profile/task-selection.js";
|
|
4
5
|
// The three node:crypto ports the RFC 3161 anchor rule engine injects
|
|
5
6
|
// (anchor-evidence design §6.1 "Placement"). They live here, in the standalone
|
|
6
7
|
// verifier, and are reused by the product core -- which already depends on this
|
|
@@ -13,11 +14,23 @@ export { evaluateIntegrityAnchors } from "./anchor/check.js";
|
|
|
13
14
|
// than mirrored into the product core, so the producer's claim section and the verifier's rebuild
|
|
14
15
|
// of it cannot drift -- the byte-compare depends on them being one function.
|
|
15
16
|
export { ANCHORED_PRE_REGISTRATION, ANCHORED_TRUST_ROOT, ClaimAnchorProjectionError, ClaimAnchorSchema, SELF_RUN_TRUST_ROOT, STRUCTURAL_PRE_REGISTRATION, additionalLockAnchorLine, anchoredPreRegistration, anchoredPreRegistrationSentence, anchoredTrustRoot, anchoredVenueLimits, carriedMatrixAnchors, deriveClaimAnchors, governingLockAnchors, matrixAnchorLine, } from "./profile/anchor-claims.js";
|
|
16
|
-
export { BUNDLE_FORMAT, BUNDLE_V4_FORMAT, BUNDLE_V5_FORMAT, BUNDLE_V6_FORMAT, SUPPORTED_BUNDLE_FORMATS, } from "./manifest.js";
|
|
17
|
+
export { BUNDLE_FORMAT, BUNDLE_V4_FORMAT, BUNDLE_V5_FORMAT, BUNDLE_V6_FORMAT, BUNDLE_V7_FORMAT, BUNDLE_V8_FORMAT, SUPPORTED_BUNDLE_FORMATS, } from "./manifest.js";
|
|
18
|
+
// The disclosed-closure projection and check (disclosure-specification-record design §6.4/§6.6/§7,
|
|
19
|
+
// issue #2839). Single-sourced here for exactly the reason the anchored projection above is: the
|
|
20
|
+
// product core imports this package, so the producer's claim section and the verifier's rebuild of
|
|
21
|
+
// it are one function, and the byte-compare is a comparison of outputs rather than of guesses.
|
|
22
|
+
export { ClaimDisclosureSectionSchema, DISCLOSURE_ROLE_BINDING, DISCLOSURE_SPECIFICATION_BUNDLE_ROLE, DisclosureProjectionError, assertDisclosureSpecification, deriveDisclosureSpecification, } from "./profile/disclosure.js";
|
|
17
23
|
export * from "./admission/index.js";
|
|
18
24
|
export * from "./schema.js";
|
|
19
25
|
export * from "./profile/binary-judge-manifest.js";
|
|
20
26
|
export * from "./profile/binary-qualification.js";
|
|
21
|
-
export { ClaimPackageSchema } from "./profile/claim.js";
|
|
27
|
+
export { ClaimPackageSchema, DISCLOSED_CLAIM_PACKAGE_SCHEMA_ID } from "./profile/claim.js";
|
|
28
|
+
export { firstDifference } from "./profile/claim-consistency.js";
|
|
29
|
+
export { NOT_FETCHED_CHECK, summarizeVerificationOutcome } from "./outcome.js";
|
|
22
30
|
export { VERIFIER_VERSION, renderVerifiedBundle, runVerifierCli } from "./cli.js";
|
|
23
|
-
export { PUBLIC_BUNDLE_COMPATIBLE_VERIFICATION_COMMAND, PUBLIC_BUNDLE_VERIFICATION_CHECKS, PUBLIC_BUNDLE_VERIFICATION_COMMAND, PUBLIC_BUNDLE_V4_COMPATIBLE_VERIFICATION_COMMAND, PUBLIC_BUNDLE_V4_VERIFICATION_COMMAND, PUBLIC_BUNDLE_V5_COMPATIBLE_VERIFICATION_COMMAND, PUBLIC_BUNDLE_V5_VERIFICATION_COMMAND, PUBLIC_BUNDLE_V6_CHECKS, PUBLIC_BUNDLE_V6_COMPATIBLE_VERIFICATION_COMMAND, PUBLIC_BUNDLE_V6_VERIFICATION_COMMAND, PUBLIC_BUNDLE_VERIFICATION_INSTRUCTIONS, PUBLIC_BUNDLE_VERIFIER_MAJOR, PUBLIC_BUNDLE_V4_VERIFIER_MAJOR, } from "./reader-instructions.js";
|
|
31
|
+
export { PUBLIC_BUNDLE_COMPATIBLE_VERIFICATION_COMMAND, PUBLIC_BUNDLE_VERIFICATION_CHECKS, PUBLIC_BUNDLE_VERIFICATION_COMMAND, PUBLIC_BUNDLE_V4_COMPATIBLE_VERIFICATION_COMMAND, PUBLIC_BUNDLE_V4_VERIFICATION_COMMAND, PUBLIC_BUNDLE_V5_COMPATIBLE_VERIFICATION_COMMAND, PUBLIC_BUNDLE_V5_VERIFICATION_COMMAND, PUBLIC_BUNDLE_V6_CHECKS, PUBLIC_BUNDLE_V6_COMPATIBLE_VERIFICATION_COMMAND, PUBLIC_BUNDLE_V6_VERIFICATION_COMMAND, PUBLIC_BUNDLE_V7_CHECKS, PUBLIC_BUNDLE_V7_COMPATIBLE_VERIFICATION_COMMAND, PUBLIC_BUNDLE_V7_VERIFICATION_COMMAND, PUBLIC_BUNDLE_V8_CHECKS, PUBLIC_BUNDLE_V8_COMPATIBLE_VERIFICATION_COMMAND, PUBLIC_BUNDLE_V8_VERIFICATION_COMMAND, PUBLIC_BUNDLE_VERIFICATION_INSTRUCTIONS, PUBLIC_BUNDLE_VERIFIER_MAJOR, PUBLIC_BUNDLE_V4_VERIFIER_MAJOR, } from "./reader-instructions.js";
|
|
32
|
+
// `beacon-binding/1` (issue #2976): the post-seal public-randomness binding, and the report face
|
|
33
|
+
// that states which binding a run carries. Single-sourced here for the same reason the anchored
|
|
34
|
+
// projection is -- the product core imports this package, so producer and reader run one function.
|
|
35
|
+
export { BEACON_BINDING_PROCEDURE, BEACON_SOURCES, BEACON_SOURCE_IDS, MAX_BEACON_ROUND, BeaconReferenceSchema, RunBindingError, RunBindingSchema, beaconRoundInstant, computeBeaconOrder, requiredBeaconRound, verifyRunBinding, } from "./binding/beacon-binding.js";
|
|
36
|
+
export { runBindingClass, runBindingSentence, runBoundVenueLimits } from "./binding/report-face.js";
|
package/dist/manifest.d.ts
CHANGED
|
@@ -6,7 +6,33 @@ export declare const BUNDLE_V5_FORMAT: "benchmark-product-public-bundle/5";
|
|
|
6
6
|
* lists, byte shapes, and values; the `anchors/` member and the `integrity-anchors` check exist
|
|
7
7
|
* only here. */
|
|
8
8
|
export declare const BUNDLE_V6_FORMAT: "benchmark-product-public-bundle/6";
|
|
9
|
-
|
|
9
|
+
/**
|
|
10
|
+
* The anchored binary-qualification closure (issue #3205): v4's member list — `qualification.json`,
|
|
11
|
+
* the v4 evidence catalog, the v4 trust document — plus v6's `anchors/` member and its
|
|
12
|
+
* `integrity-anchors` check. Additive in exactly the same way v6 was: v2, v4, v5, and v6 keep their
|
|
13
|
+
* member lists, check lists, and bytes, and only a run that is BOTH anchored and
|
|
14
|
+
* qualification-projecting emits this one.
|
|
15
|
+
*/
|
|
16
|
+
export declare const BUNDLE_V7_FORMAT: "benchmark-product-public-bundle/7";
|
|
17
|
+
/**
|
|
18
|
+
* The disclosed anchored binary-qualification closure (issue #2839, disclosure-specification-record
|
|
19
|
+
* design §6.5): v7's complete member list plus one `records/<sha256>.bin` member carrying the sealed
|
|
20
|
+
* disclosure-specification record, and the `disclosure-specification` check.
|
|
21
|
+
*
|
|
22
|
+
* **Why it stacks on v7 rather than on v4.** The design reserved this closure for the UNANCHORED
|
|
23
|
+
* qualified branch, on the premise (its §12.2) that anchoring and qualification could never
|
|
24
|
+
* combine. Issue #3205 dissolved that premise: the published official bundle IS anchored and
|
|
25
|
+
* qualified, on v7. Allocating disclosure on the unanchored branch would have forced the flagship to
|
|
26
|
+
* choose between its anchor and its disclosure record, so the allocation follows the real material.
|
|
27
|
+
* Anything narrower — a second, unanchored disclosed cell — would double the enumeration that
|
|
28
|
+
* #2889 exists to kill, and is deliberately not built.
|
|
29
|
+
*
|
|
30
|
+
* Additive in exactly the way v6 and v7 were: v2, v4, v5, v6, and v7 keep their member lists, check
|
|
31
|
+
* lists, and bytes, and only a run that is anchored AND qualification-projecting AND carrying a
|
|
32
|
+
* sealed disclosure declaration emits this one.
|
|
33
|
+
*/
|
|
34
|
+
export declare const BUNDLE_V8_FORMAT: "benchmark-product-public-bundle/8";
|
|
35
|
+
export declare const SUPPORTED_BUNDLE_FORMATS: readonly ["benchmark-product-public-bundle/2", "benchmark-product-public-bundle/4", "benchmark-product-public-bundle/5", "benchmark-product-public-bundle/6", "benchmark-product-public-bundle/7", "benchmark-product-public-bundle/8"];
|
|
10
36
|
export declare const BUNDLE_MANIFEST_FILENAME: "bundle.json";
|
|
11
37
|
export declare const BundleManifestFileSchema: z.ZodObject<{
|
|
12
38
|
path: z.ZodString;
|
|
@@ -14,7 +40,7 @@ export declare const BundleManifestFileSchema: z.ZodObject<{
|
|
|
14
40
|
bytes: z.ZodNumber;
|
|
15
41
|
}, z.core.$strip>;
|
|
16
42
|
export declare const BundleManifestSchema: z.ZodUnion<readonly [z.ZodObject<{
|
|
17
|
-
format: z.ZodUnion<readonly [z.ZodLiteral<"benchmark-product-public-bundle/2">, z.ZodLiteral<"benchmark-product-public-bundle/4">, z.ZodLiteral<"benchmark-product-public-bundle/6">]>;
|
|
43
|
+
format: z.ZodUnion<readonly [z.ZodLiteral<"benchmark-product-public-bundle/2">, z.ZodLiteral<"benchmark-product-public-bundle/4">, z.ZodLiteral<"benchmark-product-public-bundle/6">, z.ZodLiteral<"benchmark-product-public-bundle/7">, z.ZodLiteral<"benchmark-product-public-bundle/8">]>;
|
|
18
44
|
files: z.ZodArray<z.ZodObject<{
|
|
19
45
|
path: z.ZodString;
|
|
20
46
|
sha256: z.ZodString;
|
|
@@ -22,7 +48,7 @@ export declare const BundleManifestSchema: z.ZodUnion<readonly [z.ZodObject<{
|
|
|
22
48
|
}, z.core.$strip>>;
|
|
23
49
|
}, z.core.$strip>, z.ZodObject<{
|
|
24
50
|
format: z.ZodLiteral<"benchmark-product-public-bundle/5">;
|
|
25
|
-
profile: z.ZodLiteral<"https://spec.jinn.network/profiles/benchmark-product-public-bundle/5">;
|
|
51
|
+
profile: z.ZodUnion<readonly [z.ZodLiteral<"https://spec.jinn.network/profiles/benchmark-product-public-bundle/5">, z.ZodLiteral<"https://spec.jinn.network/profiles/benchmark-product-public-bundle/5/metadata-first">]>;
|
|
26
52
|
files: z.ZodArray<z.ZodObject<{
|
|
27
53
|
path: z.ZodString;
|
|
28
54
|
sha256: z.ZodString;
|
|
@@ -45,7 +71,7 @@ export interface VerifyBundleSnapshotDeps {
|
|
|
45
71
|
}
|
|
46
72
|
export interface BuildBundleManifestOptions {
|
|
47
73
|
/** Defaults to v2 so existing producer and golden bytes remain immutable. */
|
|
48
|
-
readonly format?: typeof BUNDLE_FORMAT | typeof BUNDLE_V4_FORMAT | typeof BUNDLE_V6_FORMAT;
|
|
74
|
+
readonly format?: typeof BUNDLE_FORMAT | typeof BUNDLE_V4_FORMAT | typeof BUNDLE_V6_FORMAT | typeof BUNDLE_V7_FORMAT | typeof BUNDLE_V8_FORMAT;
|
|
49
75
|
}
|
|
50
76
|
export declare function buildBundleManifest(bundleDir: string, filePaths: readonly string[], options?: BuildBundleManifestOptions): BuiltBundleManifest;
|
|
51
77
|
export declare function verifyBundleManifest(bundleDir: string): BuiltBundleManifest;
|
package/dist/manifest.js
CHANGED
|
@@ -12,11 +12,39 @@ export const BUNDLE_V5_FORMAT = "benchmark-product-public-bundle/5";
|
|
|
12
12
|
* lists, byte shapes, and values; the `anchors/` member and the `integrity-anchors` check exist
|
|
13
13
|
* only here. */
|
|
14
14
|
export const BUNDLE_V6_FORMAT = "benchmark-product-public-bundle/6";
|
|
15
|
+
/**
|
|
16
|
+
* The anchored binary-qualification closure (issue #3205): v4's member list — `qualification.json`,
|
|
17
|
+
* the v4 evidence catalog, the v4 trust document — plus v6's `anchors/` member and its
|
|
18
|
+
* `integrity-anchors` check. Additive in exactly the same way v6 was: v2, v4, v5, and v6 keep their
|
|
19
|
+
* member lists, check lists, and bytes, and only a run that is BOTH anchored and
|
|
20
|
+
* qualification-projecting emits this one.
|
|
21
|
+
*/
|
|
22
|
+
export const BUNDLE_V7_FORMAT = "benchmark-product-public-bundle/7";
|
|
23
|
+
/**
|
|
24
|
+
* The disclosed anchored binary-qualification closure (issue #2839, disclosure-specification-record
|
|
25
|
+
* design §6.5): v7's complete member list plus one `records/<sha256>.bin` member carrying the sealed
|
|
26
|
+
* disclosure-specification record, and the `disclosure-specification` check.
|
|
27
|
+
*
|
|
28
|
+
* **Why it stacks on v7 rather than on v4.** The design reserved this closure for the UNANCHORED
|
|
29
|
+
* qualified branch, on the premise (its §12.2) that anchoring and qualification could never
|
|
30
|
+
* combine. Issue #3205 dissolved that premise: the published official bundle IS anchored and
|
|
31
|
+
* qualified, on v7. Allocating disclosure on the unanchored branch would have forced the flagship to
|
|
32
|
+
* choose between its anchor and its disclosure record, so the allocation follows the real material.
|
|
33
|
+
* Anything narrower — a second, unanchored disclosed cell — would double the enumeration that
|
|
34
|
+
* #2889 exists to kill, and is deliberately not built.
|
|
35
|
+
*
|
|
36
|
+
* Additive in exactly the way v6 and v7 were: v2, v4, v5, v6, and v7 keep their member lists, check
|
|
37
|
+
* lists, and bytes, and only a run that is anchored AND qualification-projecting AND carrying a
|
|
38
|
+
* sealed disclosure declaration emits this one.
|
|
39
|
+
*/
|
|
40
|
+
export const BUNDLE_V8_FORMAT = "benchmark-product-public-bundle/8";
|
|
15
41
|
export const SUPPORTED_BUNDLE_FORMATS = [
|
|
16
42
|
BUNDLE_FORMAT,
|
|
17
43
|
BUNDLE_V4_FORMAT,
|
|
18
44
|
BUNDLE_V5_FORMAT,
|
|
19
45
|
BUNDLE_V6_FORMAT,
|
|
46
|
+
BUNDLE_V7_FORMAT,
|
|
47
|
+
BUNDLE_V8_FORMAT,
|
|
20
48
|
];
|
|
21
49
|
export const BUNDLE_MANIFEST_FILENAME = "bundle.json";
|
|
22
50
|
const SHA256_HEX = /^[a-f0-9]{64}$/;
|
|
@@ -30,6 +58,8 @@ const LegacyBundleManifestSchema = z.object({
|
|
|
30
58
|
z.literal(BUNDLE_FORMAT),
|
|
31
59
|
z.literal(BUNDLE_V4_FORMAT),
|
|
32
60
|
z.literal(BUNDLE_V6_FORMAT),
|
|
61
|
+
z.literal(BUNDLE_V7_FORMAT),
|
|
62
|
+
z.literal(BUNDLE_V8_FORMAT),
|
|
33
63
|
]),
|
|
34
64
|
files: z.array(BundleManifestFileSchema).min(1),
|
|
35
65
|
});
|
package/dist/materialize.d.ts
CHANGED
|
@@ -2,3 +2,10 @@
|
|
|
2
2
|
export declare const PUBLIC_BUNDLE_FILES: readonly ["static-bundle.json", "benchmark.json", "run.json", "matrix.json", "report.json", "report-envelope.json", "claim-package.json", "verdicts.json", "evidence.json", "verification/assembly.jsonl", "trust/public-keys.json", "index.html", "badge.svg", "social-card.svg", "README.md", "share.txt"];
|
|
3
3
|
/** V4 is the fixed v2 graph with exactly one canonical qualification projection added. */
|
|
4
4
|
export declare const PUBLIC_BUNDLE_V4_FILES: readonly ("benchmark.json" | "run.json" | "matrix.json" | "report.json" | "report-envelope.json" | "claim-package.json" | "qualification.json" | "static-bundle.json" | "evidence.json" | "verdicts.json" | "verification/assembly.jsonl" | "trust/public-keys.json" | "index.html" | "badge.svg" | "social-card.svg" | "README.md" | "share.txt")[];
|
|
5
|
+
/**
|
|
6
|
+
* V8 (issue #2839) adds no mandatory MEMBER. The disclosure-specification record travels at the
|
|
7
|
+
* already-allowlisted `records/<sha256>.bin` path, driven by the evidence catalog exactly like every
|
|
8
|
+
* other sealed record, so v8's mandatory list is v7's — which is v4's. The alias exists so the
|
|
9
|
+
* equality is stated in the file that owns member lists rather than inferred at the call site.
|
|
10
|
+
*/
|
|
11
|
+
export declare const PUBLIC_BUNDLE_V8_FILES: readonly ("benchmark.json" | "run.json" | "matrix.json" | "report.json" | "report-envelope.json" | "claim-package.json" | "qualification.json" | "static-bundle.json" | "evidence.json" | "verdicts.json" | "verification/assembly.jsonl" | "trust/public-keys.json" | "index.html" | "badge.svg" | "social-card.svg" | "README.md" | "share.txt")[];
|
package/dist/materialize.js
CHANGED
|
@@ -11,3 +11,10 @@ export const PUBLIC_BUNDLE_V4_FILES = [
|
|
|
11
11
|
"qualification.json",
|
|
12
12
|
...PUBLIC_BUNDLE_FILES.slice(7),
|
|
13
13
|
];
|
|
14
|
+
/**
|
|
15
|
+
* V8 (issue #2839) adds no mandatory MEMBER. The disclosure-specification record travels at the
|
|
16
|
+
* already-allowlisted `records/<sha256>.bin` path, driven by the evidence catalog exactly like every
|
|
17
|
+
* other sealed record, so v8's mandatory list is v7's — which is v4's. The alias exists so the
|
|
18
|
+
* equality is stated in the file that owns member lists rather than inferred at the call site.
|
|
19
|
+
*/
|
|
20
|
+
export const PUBLIC_BUNDLE_V8_FILES = PUBLIC_BUNDLE_V4_FILES;
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import type { PublicBundleVerificationResult } from "./verify.js";
|
|
2
|
+
/**
|
|
3
|
+
* The one check a metadata-first `benchmark-product-public-bundle/5` defers (issue #2986): its
|
|
4
|
+
* artifact digests are carried, its artifact bodies are not.
|
|
5
|
+
*/
|
|
6
|
+
export declare const NOT_FETCHED_CHECK: "artifact-integrity";
|
|
7
|
+
export type VerificationCheckState = "passed" | "not fetched";
|
|
8
|
+
export interface VerificationCheckOutcome {
|
|
9
|
+
readonly check: string;
|
|
10
|
+
readonly state: VerificationCheckState;
|
|
11
|
+
}
|
|
12
|
+
export interface VerificationOutcome {
|
|
13
|
+
readonly outcomes: readonly VerificationCheckOutcome[];
|
|
14
|
+
/** Checks that actually passed. A deferred check is never counted here. */
|
|
15
|
+
readonly passed: number;
|
|
16
|
+
readonly notFetched: number;
|
|
17
|
+
/** The check count the bundle's declared format promises. */
|
|
18
|
+
readonly total: number;
|
|
19
|
+
/** Present exactly when the bundle deferred artifact content. */
|
|
20
|
+
readonly artifactContent?: {
|
|
21
|
+
readonly notFetched: number;
|
|
22
|
+
readonly notFetchedDigests: readonly string[];
|
|
23
|
+
};
|
|
24
|
+
}
|
|
25
|
+
/**
|
|
26
|
+
* The single derivation of what a verification result may be said to have proved. Every reader
|
|
27
|
+
* surface -- the standalone CLI, the product CLI, the local viewer, the web action -- reads this
|
|
28
|
+
* rather than counting `checks` itself, because a surface that counts for itself is a surface that
|
|
29
|
+
* can print a pass over bytes nobody read (issue #2986).
|
|
30
|
+
*/
|
|
31
|
+
export declare function summarizeVerificationOutcome(result: PublicBundleVerificationResult): VerificationOutcome;
|
package/dist/outcome.js
ADDED
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import { EVIDENCE_NATIVE_BUNDLE_V5_CHECKS } from "@jinn-network/benchmarking-evidence";
|
|
2
|
+
import { PUBLIC_BUNDLE_VERIFICATION_CHECKS, PUBLIC_BUNDLE_V6_CHECKS, PUBLIC_BUNDLE_V7_CHECKS, PUBLIC_BUNDLE_V8_CHECKS, } from "./reader-instructions.js";
|
|
3
|
+
/**
|
|
4
|
+
* The one check a metadata-first `benchmark-product-public-bundle/5` defers (issue #2986): its
|
|
5
|
+
* artifact digests are carried, its artifact bodies are not.
|
|
6
|
+
*/
|
|
7
|
+
export const NOT_FETCHED_CHECK = "artifact-integrity";
|
|
8
|
+
/**
|
|
9
|
+
* The single derivation of what a verification result may be said to have proved. Every reader
|
|
10
|
+
* surface -- the standalone CLI, the product CLI, the local viewer, the web action -- reads this
|
|
11
|
+
* rather than counting `checks` itself, because a surface that counts for itself is a surface that
|
|
12
|
+
* can print a pass over bytes nobody read (issue #2986).
|
|
13
|
+
*/
|
|
14
|
+
export function summarizeVerificationOutcome(result) {
|
|
15
|
+
const total = result.format === "benchmark-product-public-bundle/5"
|
|
16
|
+
? EVIDENCE_NATIVE_BUNDLE_V5_CHECKS.length
|
|
17
|
+
: result.format === "benchmark-product-public-bundle/6"
|
|
18
|
+
? PUBLIC_BUNDLE_V6_CHECKS.length
|
|
19
|
+
: result.format === "benchmark-product-public-bundle/7"
|
|
20
|
+
? PUBLIC_BUNDLE_V7_CHECKS.length
|
|
21
|
+
: result.format === "benchmark-product-public-bundle/8"
|
|
22
|
+
? PUBLIC_BUNDLE_V8_CHECKS.length
|
|
23
|
+
: PUBLIC_BUNDLE_VERIFICATION_CHECKS.length;
|
|
24
|
+
const deferred = result.format === "benchmark-product-public-bundle/5"
|
|
25
|
+
&& result.artifactContent.status === "not-fetched"
|
|
26
|
+
? result.artifactContent
|
|
27
|
+
: undefined;
|
|
28
|
+
const outcomes = result.checks.map((check) => ({
|
|
29
|
+
check,
|
|
30
|
+
state: (deferred !== undefined && check === NOT_FETCHED_CHECK ? "not fetched" : "passed"),
|
|
31
|
+
}));
|
|
32
|
+
const notFetched = outcomes.filter((outcome) => outcome.state === "not fetched").length;
|
|
33
|
+
return {
|
|
34
|
+
outcomes,
|
|
35
|
+
passed: outcomes.length - notFetched,
|
|
36
|
+
notFetched,
|
|
37
|
+
total,
|
|
38
|
+
...(deferred === undefined ? {} : {
|
|
39
|
+
artifactContent: {
|
|
40
|
+
notFetched: deferred.notFetched,
|
|
41
|
+
notFetchedDigests: deferred.notFetchedDigests,
|
|
42
|
+
},
|
|
43
|
+
}),
|
|
44
|
+
};
|
|
45
|
+
}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { type BenchmarkRecord, type MatrixRecord, type ReportRecord, type RunRecord } from "@jinn-network/benchmarking-records";
|
|
2
2
|
import { type ClaimPackage } from "./claim.js";
|
|
3
3
|
import type { ClaimAnchor } from "./anchor-claims.js";
|
|
4
|
+
import type { ClaimDisclosureSection } from "./disclosure.js";
|
|
4
5
|
export interface ClaimRecordIdentities {
|
|
5
6
|
readonly benchmarkSha256: string;
|
|
6
7
|
readonly runSha256: string;
|
|
@@ -8,6 +9,11 @@ export interface ClaimRecordIdentities {
|
|
|
8
9
|
readonly reportSha256: string | undefined;
|
|
9
10
|
readonly reportEnvelopeSha256: string;
|
|
10
11
|
}
|
|
12
|
+
/** The path of the first field that actually differs, or `undefined` when the two values are
|
|
13
|
+
* equal — equal leaves must report NO difference, or the object branch returns on its first key
|
|
14
|
+
* and every mismatch names the first key in sorted order instead of the edited field. Single
|
|
15
|
+
* implementation: product core imports this helper rather than keeping a second copy. */
|
|
16
|
+
export declare function firstDifference(actual: unknown, expected: unknown, path?: string): string | undefined;
|
|
11
17
|
export declare function assertClaimConsistency(input: {
|
|
12
18
|
readonly claim: ClaimPackage;
|
|
13
19
|
readonly identities: ClaimRecordIdentities;
|
|
@@ -22,5 +28,6 @@ export declare function assertClaimConsistency(input: {
|
|
|
22
28
|
readonly previewCount: number;
|
|
23
29
|
readonly timestamps: readonly string[];
|
|
24
30
|
}; /** anchor-evidence §7.4: the anchors section re-derived from the carried AnchorEvidence bytes, never read from the claim under test. */
|
|
25
|
-
readonly anchors?: readonly ClaimAnchor[];
|
|
31
|
+
readonly anchors?: readonly ClaimAnchor[]; /** disclosure-specification-record design §7 step 10: the disclosure section re-derived from the carried record's own bytes, never read from the claim under test. */
|
|
32
|
+
readonly disclosure?: ClaimDisclosureSection;
|
|
26
33
|
}): void;
|
|
@@ -13,9 +13,9 @@ const PAIRED_ESTIMATE_LIMITATION = "This method estimates an effect; it does not
|
|
|
13
13
|
const equal = (left, right) => left.length === right.length && left.every((byte, index) => byte === right[index]);
|
|
14
14
|
/** The path of the first field that actually differs, or `undefined` when the two values are
|
|
15
15
|
* equal — equal leaves must report NO difference, or the object branch returns on its first key
|
|
16
|
-
* and every mismatch names the first key in sorted order instead of the edited field.
|
|
17
|
-
*
|
|
18
|
-
function firstDifference(actual, expected, path = "claim") {
|
|
16
|
+
* and every mismatch names the first key in sorted order instead of the edited field. Single
|
|
17
|
+
* implementation: product core imports this helper rather than keeping a second copy. */
|
|
18
|
+
export function firstDifference(actual, expected, path = "claim") {
|
|
19
19
|
// Never hand `undefined` to canonicalJsonBytes: it is deliberately not a JSON value, and a
|
|
20
20
|
// field carried by one side alone is itself the first difference.
|
|
21
21
|
if (actual === undefined || expected === undefined)
|
|
@@ -54,7 +54,7 @@ export function assertClaimConsistency(input) {
|
|
|
54
54
|
// Presence, not emptiness: an empty section belongs to the anchored closure's declared-but-absent
|
|
55
55
|
// bundle, and an omitted one to every unanchored bundle.
|
|
56
56
|
const anchors = input.anchors;
|
|
57
|
-
const expected = buildClaimPackage({ draftId: input.draftId, benchmarkSha256: identities.benchmarkSha256, runRecord, runSha256: identities.runSha256, matrixRecord, matrixSha256: identities.matrixSha256, reportRecord, reportSha256: identities.reportSha256, reportEnvelopeSha256: identities.reportEnvelopeSha256, venueHonesty: buildLocalVenueHonesty(matrixRecord.cells, runRecord, anchors ?? []), verificationCommandVerb: "bundle verify", assurance: { preset: input.assurancePreset, resolved: { independence: runRecord.policy.independence, minVerdicts, distinctEvaluator, verdictRule } }, ...(input.rehearsal === undefined ? {} : { previewDisclosure: input.rehearsal }), ...(anchors === undefined ? {} : { anchors }) });
|
|
57
|
+
const expected = buildClaimPackage({ draftId: input.draftId, benchmarkSha256: identities.benchmarkSha256, runRecord, runSha256: identities.runSha256, matrixRecord, matrixSha256: identities.matrixSha256, reportRecord, reportSha256: identities.reportSha256, reportEnvelopeSha256: identities.reportEnvelopeSha256, venueHonesty: buildLocalVenueHonesty(matrixRecord.cells, runRecord, anchors ?? []), verificationCommandVerb: "bundle verify", assurance: { preset: input.assurancePreset, resolved: { independence: runRecord.policy.independence, minVerdicts, distinctEvaluator, verdictRule } }, ...(input.rehearsal === undefined ? {} : { previewDisclosure: input.rehearsal }), ...(anchors === undefined ? {} : { anchors }), ...(input.disclosure === undefined ? {} : { disclosure: input.disclosure }) });
|
|
58
58
|
if (!equal(canonicalJsonBytes(claim), canonicalJsonBytes(expected)))
|
|
59
59
|
refuse("record-integrity", "claim-consistency", `claim package ${firstDifference(claim, expected) ?? "claim"} is not the exact projection of verified facts`);
|
|
60
60
|
const rehearsalLine = input.rehearsal === undefined ? undefined : previewDisclosureSummaryLine(input.rehearsal);
|
package/dist/profile/claim.d.ts
CHANGED
|
@@ -27,9 +27,15 @@
|
|
|
27
27
|
* disclosure. The one deliberate exception to "never cross-check here": `buildClaimPackage`
|
|
28
28
|
* THROWS when the stated primitives disagree with what the sealed Run record's own policy
|
|
29
29
|
* carries — a claim stating primitives the sealed Run does not carry would be dishonest.
|
|
30
|
+
*
|
|
31
|
+
* Issue #3205: the claim id is chosen on TWO independent axes — anchored or not, and
|
|
32
|
+
* qualification-projecting or not — which is four allocations, not three. `claim-package/5` is
|
|
33
|
+
* the fourth cell; before it existed an anchored binary-instrument run could not produce a
|
|
34
|
+
* claim at all, which made anchoring and binary-instrument benchmarking mutually exclusive.
|
|
30
35
|
*/
|
|
31
36
|
import { z } from "zod";
|
|
32
37
|
import type { MatrixRecord, ReportRecord, RunRecord } from "@jinn-network/benchmarking-records";
|
|
38
|
+
import type { ClaimDisclosureSection } from "./disclosure.js";
|
|
33
39
|
import { SELF_RUN_TRUST_ROOT } from "./anchor-claims.js";
|
|
34
40
|
import type { ClaimAnchor } from "./anchor-claims.js";
|
|
35
41
|
type VenueHonesty = unknown;
|
|
@@ -42,16 +48,40 @@ export declare const BINARY_QUALIFICATION_CLAIM_PACKAGE_SCHEMA_ID = "benchmark-p
|
|
|
42
48
|
* own later allocation.
|
|
43
49
|
*/
|
|
44
50
|
export declare const ANCHORED_CLAIM_PACKAGE_SCHEMA_ID = "benchmark-product.claim-package/4";
|
|
51
|
+
/**
|
|
52
|
+
* The anchored binary-qualification claim package (issue #3205): claim-package/2's exact
|
|
53
|
+
* qualification projection plus claim-package/4's `anchors` section, carried by
|
|
54
|
+
* `benchmark-product-public-bundle/7`. This is the "later allocation" both earlier guards named:
|
|
55
|
+
* /2 has no anchors slot and /4 has no qualification slot, so before this number existed an
|
|
56
|
+
* anchored run of a binary-instrument benchmark could not produce a claim at all. The allocation is
|
|
57
|
+
* an ADDITION — /1, /2, /3, and /4 keep their meanings and their bytes.
|
|
58
|
+
*/
|
|
59
|
+
export declare const ANCHORED_BINARY_QUALIFICATION_CLAIM_PACKAGE_SCHEMA_ID = "benchmark-product.claim-package/5";
|
|
60
|
+
/**
|
|
61
|
+
* The disclosed anchored binary-qualification claim package (issue #2839,
|
|
62
|
+
* disclosure-specification-record design §6.5/§6.6): claim-package/5 exactly, plus the
|
|
63
|
+
* `disclosure` section, carried by `benchmark-product-public-bundle/8`.
|
|
64
|
+
*
|
|
65
|
+
* The design reserved `/5` for its own disclosure allocation on the UNANCHORED qualified branch, on
|
|
66
|
+
* the premise (its §12.2) that anchoring and qualification could never combine. Issue #3205 both
|
|
67
|
+
* took `/5` and dissolved that premise, so per the design's own §6.5 rule — the implementation
|
|
68
|
+
* packet takes the then-next free numbers if a line has advanced — this is `/6`, and it stacks on
|
|
69
|
+
* the ANCHORED branch so the real flagship bundle can carry its disclosure record without giving up
|
|
70
|
+
* its anchor. The allocation is an ADDITION: /1, /2, /3, /4, and /5 keep their meanings and bytes.
|
|
71
|
+
*/
|
|
72
|
+
export declare const DISCLOSED_CLAIM_PACKAGE_SCHEMA_ID = "benchmark-product.claim-package/6";
|
|
45
73
|
export declare const BINARY_QUALIFICATION_VERIFICATION_COMMAND: "npx @colophon-claims/verify@0.1.0 <bundle-dir>";
|
|
46
74
|
export declare const BINARY_QUALIFICATION_COMPATIBLE_VERIFICATION_COMMAND: "npx @colophon-claims/verify@0.1 <bundle-dir>";
|
|
47
75
|
/** Prompted-screening v2 claims require the verifier release that carries that admission surface. */
|
|
48
|
-
export declare const PROMPTED_BINARY_QUALIFICATION_VERIFICATION_COMMAND: "npx @colophon-claims/verify@0.2.
|
|
76
|
+
export declare const PROMPTED_BINARY_QUALIFICATION_VERIFICATION_COMMAND: "npx @colophon-claims/verify@0.2.1 <bundle-dir>";
|
|
77
|
+
/** Previously materialized prompted bundles remain valid under their immutable 0.2.0 claim. */
|
|
78
|
+
export declare const LEGACY_PROMPTED_BINARY_QUALIFICATION_VERIFICATION_COMMAND: "npx @colophon-claims/verify@0.2.0 <bundle-dir>";
|
|
49
79
|
export declare const PROMPTED_BINARY_QUALIFICATION_COMPATIBLE_VERIFICATION_COMMAND: "npx @colophon-claims/verify@0.2 <bundle-dir>";
|
|
50
80
|
/** The fixed sentence every claim package's assurance block carries (BP-21, spec §6/§7.1): what
|
|
51
81
|
* distinct evaluator identities on this venue actually prove. Never softened per-claim. */
|
|
52
82
|
export declare const ASSURANCE_DISCLOSURE: string;
|
|
53
83
|
export declare const ClaimPackageSchema: z.ZodPreprocess<z.ZodObject<{
|
|
54
|
-
claimSchema: z.ZodUnion<readonly [z.ZodLiteral<"benchmark-product.claim-package/1">, z.ZodLiteral<"benchmark-product.claim-package/2">, z.ZodLiteral<"benchmark-product.claim-package/4">]>;
|
|
84
|
+
claimSchema: z.ZodUnion<readonly [z.ZodLiteral<"benchmark-product.claim-package/1">, z.ZodLiteral<"benchmark-product.claim-package/2">, z.ZodLiteral<"benchmark-product.claim-package/4">, z.ZodLiteral<"benchmark-product.claim-package/5">, z.ZodLiteral<"benchmark-product.claim-package/6">]>;
|
|
55
85
|
scope: z.ZodObject<{
|
|
56
86
|
draftId: z.ZodString;
|
|
57
87
|
benchmarkSha256: z.ZodString;
|
|
@@ -272,6 +302,169 @@ export declare const ClaimPackageSchema: z.ZodPreprocess<z.ZodObject<{
|
|
|
272
302
|
pending: z.ZodLiteral<true>;
|
|
273
303
|
}, z.core.$strict>]>]>;
|
|
274
304
|
}, z.core.$strict>>>;
|
|
305
|
+
disclosure: z.ZodOptional<z.ZodObject<{
|
|
306
|
+
recordSha256: z.ZodString;
|
|
307
|
+
specification: z.ZodLiteral<"https://spec.jinn.network/disclosure/six-variable/v1">;
|
|
308
|
+
subjectSha256: z.ZodString;
|
|
309
|
+
variables: z.ZodObject<{
|
|
310
|
+
"ingestion-model": z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
311
|
+
status: z.ZodLiteral<"measured-here">;
|
|
312
|
+
statement: z.ZodString;
|
|
313
|
+
evidence: z.ZodArray<z.ZodObject<{
|
|
314
|
+
role: z.ZodEnum<{
|
|
315
|
+
"pinned-configuration": "pinned-configuration";
|
|
316
|
+
"execution-observation": "execution-observation";
|
|
317
|
+
}>;
|
|
318
|
+
digest: z.ZodObject<{
|
|
319
|
+
sha256: z.ZodString;
|
|
320
|
+
}, z.core.$strict>;
|
|
321
|
+
}, z.core.$strict>>;
|
|
322
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
323
|
+
status: z.ZodLiteral<"disclosed-by-publisher">;
|
|
324
|
+
statement: z.ZodString;
|
|
325
|
+
sources: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
326
|
+
uri: z.ZodString;
|
|
327
|
+
}, z.core.$strict>>>;
|
|
328
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
329
|
+
status: z.ZodLiteral<"undisclosed">;
|
|
330
|
+
reason: z.ZodEnum<{
|
|
331
|
+
"not-stated": "not-stated";
|
|
332
|
+
"stated-without-identifiers": "stated-without-identifiers";
|
|
333
|
+
"outside-this-experiment": "outside-this-experiment";
|
|
334
|
+
}>;
|
|
335
|
+
}, z.core.$strict>], "status">;
|
|
336
|
+
"retrieval-config": z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
337
|
+
status: z.ZodLiteral<"measured-here">;
|
|
338
|
+
statement: z.ZodString;
|
|
339
|
+
evidence: z.ZodArray<z.ZodObject<{
|
|
340
|
+
role: z.ZodEnum<{
|
|
341
|
+
"pinned-configuration": "pinned-configuration";
|
|
342
|
+
"execution-observation": "execution-observation";
|
|
343
|
+
}>;
|
|
344
|
+
digest: z.ZodObject<{
|
|
345
|
+
sha256: z.ZodString;
|
|
346
|
+
}, z.core.$strict>;
|
|
347
|
+
}, z.core.$strict>>;
|
|
348
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
349
|
+
status: z.ZodLiteral<"disclosed-by-publisher">;
|
|
350
|
+
statement: z.ZodString;
|
|
351
|
+
sources: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
352
|
+
uri: z.ZodString;
|
|
353
|
+
}, z.core.$strict>>>;
|
|
354
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
355
|
+
status: z.ZodLiteral<"undisclosed">;
|
|
356
|
+
reason: z.ZodEnum<{
|
|
357
|
+
"not-stated": "not-stated";
|
|
358
|
+
"stated-without-identifiers": "stated-without-identifiers";
|
|
359
|
+
"outside-this-experiment": "outside-this-experiment";
|
|
360
|
+
}>;
|
|
361
|
+
}, z.core.$strict>], "status">;
|
|
362
|
+
"answer-model": z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
363
|
+
status: z.ZodLiteral<"measured-here">;
|
|
364
|
+
statement: z.ZodString;
|
|
365
|
+
evidence: z.ZodArray<z.ZodObject<{
|
|
366
|
+
role: z.ZodEnum<{
|
|
367
|
+
"pinned-configuration": "pinned-configuration";
|
|
368
|
+
"execution-observation": "execution-observation";
|
|
369
|
+
}>;
|
|
370
|
+
digest: z.ZodObject<{
|
|
371
|
+
sha256: z.ZodString;
|
|
372
|
+
}, z.core.$strict>;
|
|
373
|
+
}, z.core.$strict>>;
|
|
374
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
375
|
+
status: z.ZodLiteral<"disclosed-by-publisher">;
|
|
376
|
+
statement: z.ZodString;
|
|
377
|
+
sources: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
378
|
+
uri: z.ZodString;
|
|
379
|
+
}, z.core.$strict>>>;
|
|
380
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
381
|
+
status: z.ZodLiteral<"undisclosed">;
|
|
382
|
+
reason: z.ZodEnum<{
|
|
383
|
+
"not-stated": "not-stated";
|
|
384
|
+
"stated-without-identifiers": "stated-without-identifiers";
|
|
385
|
+
"outside-this-experiment": "outside-this-experiment";
|
|
386
|
+
}>;
|
|
387
|
+
}, z.core.$strict>], "status">;
|
|
388
|
+
"answer-prompt": z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
389
|
+
status: z.ZodLiteral<"measured-here">;
|
|
390
|
+
statement: z.ZodString;
|
|
391
|
+
evidence: z.ZodArray<z.ZodObject<{
|
|
392
|
+
role: z.ZodEnum<{
|
|
393
|
+
"pinned-configuration": "pinned-configuration";
|
|
394
|
+
"execution-observation": "execution-observation";
|
|
395
|
+
}>;
|
|
396
|
+
digest: z.ZodObject<{
|
|
397
|
+
sha256: z.ZodString;
|
|
398
|
+
}, z.core.$strict>;
|
|
399
|
+
}, z.core.$strict>>;
|
|
400
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
401
|
+
status: z.ZodLiteral<"disclosed-by-publisher">;
|
|
402
|
+
statement: z.ZodString;
|
|
403
|
+
sources: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
404
|
+
uri: z.ZodString;
|
|
405
|
+
}, z.core.$strict>>>;
|
|
406
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
407
|
+
status: z.ZodLiteral<"undisclosed">;
|
|
408
|
+
reason: z.ZodEnum<{
|
|
409
|
+
"not-stated": "not-stated";
|
|
410
|
+
"stated-without-identifiers": "stated-without-identifiers";
|
|
411
|
+
"outside-this-experiment": "outside-this-experiment";
|
|
412
|
+
}>;
|
|
413
|
+
}, z.core.$strict>], "status">;
|
|
414
|
+
"judge-model": z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
415
|
+
status: z.ZodLiteral<"measured-here">;
|
|
416
|
+
statement: z.ZodString;
|
|
417
|
+
evidence: z.ZodArray<z.ZodObject<{
|
|
418
|
+
role: z.ZodEnum<{
|
|
419
|
+
"pinned-configuration": "pinned-configuration";
|
|
420
|
+
"execution-observation": "execution-observation";
|
|
421
|
+
}>;
|
|
422
|
+
digest: z.ZodObject<{
|
|
423
|
+
sha256: z.ZodString;
|
|
424
|
+
}, z.core.$strict>;
|
|
425
|
+
}, z.core.$strict>>;
|
|
426
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
427
|
+
status: z.ZodLiteral<"disclosed-by-publisher">;
|
|
428
|
+
statement: z.ZodString;
|
|
429
|
+
sources: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
430
|
+
uri: z.ZodString;
|
|
431
|
+
}, z.core.$strict>>>;
|
|
432
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
433
|
+
status: z.ZodLiteral<"undisclosed">;
|
|
434
|
+
reason: z.ZodEnum<{
|
|
435
|
+
"not-stated": "not-stated";
|
|
436
|
+
"stated-without-identifiers": "stated-without-identifiers";
|
|
437
|
+
"outside-this-experiment": "outside-this-experiment";
|
|
438
|
+
}>;
|
|
439
|
+
}, z.core.$strict>], "status">;
|
|
440
|
+
"judge-prompt": z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
441
|
+
status: z.ZodLiteral<"measured-here">;
|
|
442
|
+
statement: z.ZodString;
|
|
443
|
+
evidence: z.ZodArray<z.ZodObject<{
|
|
444
|
+
role: z.ZodEnum<{
|
|
445
|
+
"pinned-configuration": "pinned-configuration";
|
|
446
|
+
"execution-observation": "execution-observation";
|
|
447
|
+
}>;
|
|
448
|
+
digest: z.ZodObject<{
|
|
449
|
+
sha256: z.ZodString;
|
|
450
|
+
}, z.core.$strict>;
|
|
451
|
+
}, z.core.$strict>>;
|
|
452
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
453
|
+
status: z.ZodLiteral<"disclosed-by-publisher">;
|
|
454
|
+
statement: z.ZodString;
|
|
455
|
+
sources: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
456
|
+
uri: z.ZodString;
|
|
457
|
+
}, z.core.$strict>>>;
|
|
458
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
459
|
+
status: z.ZodLiteral<"undisclosed">;
|
|
460
|
+
reason: z.ZodEnum<{
|
|
461
|
+
"not-stated": "not-stated";
|
|
462
|
+
"stated-without-identifiers": "stated-without-identifiers";
|
|
463
|
+
"outside-this-experiment": "outside-this-experiment";
|
|
464
|
+
}>;
|
|
465
|
+
}, z.core.$strict>], "status">;
|
|
466
|
+
}, z.core.$strict>;
|
|
467
|
+
}, z.core.$strict>>;
|
|
275
468
|
}, z.core.$strip>>;
|
|
276
469
|
export type ClaimPackage = z.infer<typeof ClaimPackageSchema>;
|
|
277
470
|
export interface BuildClaimPackageInput {
|
|
@@ -313,10 +506,16 @@ export interface BuildClaimPackageInput {
|
|
|
313
506
|
* here: this builder is pure, and the derivation needs the record bytes the caller already
|
|
314
507
|
* authenticated. */
|
|
315
508
|
readonly anchors?: readonly ClaimAnchor[];
|
|
509
|
+
/** disclosure-specification-record design §6.6: the projected disclosure section, already derived
|
|
510
|
+
* from the sealed record's exact bytes by the shared `deriveDisclosureSpecification`. Absent for
|
|
511
|
+
* every run with no declaration, which is what keeps every existing claim byte-identical. */
|
|
512
|
+
readonly disclosure?: ClaimDisclosureSection;
|
|
316
513
|
}
|
|
317
514
|
export declare const CLAIM_VERIFICATION_CHECKS: readonly string[];
|
|
318
515
|
/** The anchored closure's list: the six frozen checks plus `integrity-anchors` (§8). */
|
|
319
516
|
export declare const ANCHORED_CLAIM_VERIFICATION_CHECKS: readonly string[];
|
|
517
|
+
/** The disclosed closure's list: the anchored seven plus `disclosure-specification` (design §7). */
|
|
518
|
+
export declare const DISCLOSED_CLAIM_VERIFICATION_CHECKS: readonly string[];
|
|
320
519
|
export declare const PUBLIC_BUNDLE_VERIFICATION_COMMAND: "npx @colophon-claims/verify@0.1.0 <bundle-dir>";
|
|
321
520
|
/** The unconditional trust-root sentence, re-exported unchanged. It is DEFINED once beside its
|
|
322
521
|
* anchored replacement in `anchor-claims.ts`: one sentence written out twice, in two mirrored
|