agentskeptic 4.2.0 → 6.0.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/dist/actionableFailure.remediationExhaustive.test.js +1 -1
- package/dist/bootstrap/runBootstrapSubcommand.js +1 -1
- package/dist/ciLock.js +1 -1
- package/dist/ciLock.js.map +1 -1
- package/dist/cli.js +2 -2
- package/dist/commercial/trustDecisionRecord.d.ts.map +1 -1
- package/dist/commercial/trustDecisionRecord.js +7 -3
- package/dist/commercial/trustDecisionRecord.js.map +1 -1
- package/dist/commercial/trustDecisionRecord.schema.test.js +24 -2
- package/dist/commercial/trustDecisionRecord.schema.test.js.map +1 -1
- package/dist/commercial/verifyOutcomeBeaconBody.d.ts.map +1 -1
- package/dist/commercial/verifyOutcomeBeaconBody.js +2 -1
- package/dist/commercial/verifyOutcomeBeaconBody.js.map +1 -1
- package/dist/compare.acceptance.test.js +1 -1
- package/dist/decisionBlocker.d.ts +1 -11
- package/dist/decisionBlocker.d.ts.map +1 -1
- package/dist/decisionBlocker.js +1 -41
- package/dist/decisionBlocker.js.map +1 -1
- package/dist/decisionEvidenceBundle/validateDecisionEvidenceBundle.js +1 -1
- package/dist/decisionEvidenceBundle/writeDecisionEvidenceBundle.js +2 -2
- package/dist/decisionEvidenceBundle.test.js +50 -3
- package/dist/decisionEvidenceBundle.test.js.map +1 -1
- package/dist/decisionGate.assertSafe.test.js +1 -1
- package/dist/decisionGate.assertSafe.test.js.map +1 -1
- package/dist/decisionGate.js +1 -1
- package/dist/enforceStateful.js +2 -2
- package/dist/enforceStateful.js.map +1 -1
- package/dist/evidenceCompleteness.d.ts +54 -0
- package/dist/evidenceCompleteness.d.ts.map +1 -0
- package/dist/evidenceCompleteness.js +263 -0
- package/dist/evidenceCompleteness.js.map +1 -0
- package/dist/execution-identity.v1.json +1 -1
- package/dist/failureSpine.d.ts +37 -0
- package/dist/failureSpine.d.ts.map +1 -0
- package/dist/failureSpine.js +218 -0
- package/dist/failureSpine.js.map +1 -0
- package/dist/failureSpine.test.d.ts +2 -0
- package/dist/failureSpine.test.d.ts.map +1 -0
- package/dist/failureSpine.test.js +28 -0
- package/dist/failureSpine.test.js.map +1 -0
- package/dist/formatEvidenceCompletenessHuman.d.ts +12 -0
- package/dist/formatEvidenceCompletenessHuman.d.ts.map +1 -0
- package/dist/formatEvidenceCompletenessHuman.js +47 -0
- package/dist/formatEvidenceCompletenessHuman.js.map +1 -0
- package/dist/formatFailureSpineHuman.d.ts +4 -0
- package/dist/formatFailureSpineHuman.d.ts.map +1 -0
- package/dist/formatFailureSpineHuman.js +18 -0
- package/dist/formatFailureSpineHuman.js.map +1 -0
- package/dist/governanceEvidence.d.ts +9 -3
- package/dist/governanceEvidence.d.ts.map +1 -1
- package/dist/governanceEvidence.js +10 -5
- package/dist/governanceEvidence.js.map +1 -1
- package/dist/governanceEvidence.test.js +31 -4
- package/dist/governanceEvidence.test.js.map +1 -1
- package/dist/index.d.ts +7 -3
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +5 -2
- package/dist/index.js.map +1 -1
- package/dist/langGraphCheckpointTrustGate.js +1 -1
- package/dist/langGraphCheckpointTrustIneligibleCertificate.js +1 -1
- package/dist/loop/loopOutput.d.ts +0 -4
- package/dist/loop/loopOutput.d.ts.map +1 -1
- package/dist/loop/loopOutput.js +3 -6
- package/dist/loop/loopOutput.js.map +1 -1
- package/dist/loop/runLoopSubcommand.d.ts.map +1 -1
- package/dist/loop/runLoopSubcommand.js +0 -2
- package/dist/loop/runLoopSubcommand.js.map +1 -1
- package/dist/outcomeCertificate.d.ts +20 -10
- package/dist/outcomeCertificate.d.ts.map +1 -1
- package/dist/outcomeCertificate.js +85 -8
- package/dist/outcomeCertificate.js.map +1 -1
- package/dist/outcomeCertificate.test.js +1 -1
- package/dist/publicDistribution.generated.d.ts +1 -1
- package/dist/publicDistribution.generated.js +1 -1
- package/dist/quickVerify/formatQuickVerifyHumanReport.test.js +8 -3
- package/dist/quickVerify/formatQuickVerifyHumanReport.test.js.map +1 -1
- package/dist/quickVerify/quickParamPointerNegatives.test.js +5 -2
- package/dist/quickVerify/quickParamPointerNegatives.test.js.map +1 -1
- package/dist/quickVerify/quickParamPointerPromotionGoldens.test.js +7 -4
- package/dist/quickVerify/quickParamPointerPromotionGoldens.test.js.map +1 -1
- package/dist/quickVerify/runQuickVerify.d.ts +3 -1
- package/dist/quickVerify/runQuickVerify.d.ts.map +1 -1
- package/dist/quickVerify/runQuickVerify.js +24 -3
- package/dist/quickVerify/runQuickVerify.js.map +1 -1
- package/dist/redactEvidenceString.d.ts +5 -0
- package/dist/redactEvidenceString.d.ts.map +1 -0
- package/dist/redactEvidenceString.js +17 -0
- package/dist/redactEvidenceString.js.map +1 -0
- package/dist/remediationConsumptionGuard.test.js +3 -0
- package/dist/remediationConsumptionGuard.test.js.map +1 -1
- package/dist/remediationMessage.d.ts +6 -0
- package/dist/remediationMessage.d.ts.map +1 -0
- package/dist/remediationMessage.js +30 -0
- package/dist/remediationMessage.js.map +1 -0
- package/dist/remediationWireSurfaceGuard.test.js +3 -0
- package/dist/remediationWireSurfaceGuard.test.js.map +1 -1
- package/dist/schemaLoad.d.ts +1 -1
- package/dist/schemaLoad.d.ts.map +1 -1
- package/dist/schemaLoad.js +25 -1
- package/dist/schemaLoad.js.map +1 -1
- package/dist/sdk/_generated/openapi-types.d.ts +25 -15
- package/dist/sdk/_generated/openapi-types.d.ts.map +1 -1
- package/dist/shareReport/postPublicVerificationReport.d.ts +3 -3
- package/dist/shareReport/postPublicVerificationReport.js +1 -1
- package/dist/shareReport/postPublicVerificationReport.js.map +1 -1
- package/dist/standardVerifyWorkflowCli.d.ts +7 -7
- package/dist/standardVerifyWorkflowCli.js +3 -3
- package/dist/trustDecision.d.ts +7 -2
- package/dist/trustDecision.d.ts.map +1 -1
- package/dist/trustDecision.js +14 -7
- package/dist/trustDecision.js.map +1 -1
- package/dist/verify/batchVerifyTelemetrySubcommand.js +2 -2
- package/package.json +4 -3
- package/schemas/decision-evidence-exit-v1.schema.json +1 -1
- package/schemas/evidence-completeness-v1.schema.json +87 -0
- package/schemas/failure-spine-v1.schema.json +38 -0
- package/schemas/material-truth-v2.schema.json +83 -0
- package/schemas/openapi-commercial-v1.in.yaml +46 -21
- package/schemas/openapi-commercial-v1.yaml +47 -22
- package/schemas/outcome-certificate-v2.schema.json +93 -0
- package/schemas/outcome-certificate-v3.schema.json +97 -0
- package/schemas/public-verification-report-v3.schema.json +15 -0
- package/schemas/quick-verify-report.schema.json +6 -2
- package/schemas/regression-artifact-v1.schema.json +1 -1
- package/schemas/trust-decision-record-v1.schema.json +3 -3
- package/scripts/discovery-payload.lib.cjs +140 -18
- package/dist/decisionBlocker.contract.test.d.ts +0 -2
- package/dist/decisionBlocker.contract.test.d.ts.map +0 -1
- package/dist/decisionBlocker.contract.test.js +0 -51
- package/dist/decisionBlocker.contract.test.js.map +0 -1
- package/dist/loop/failureHints.d.ts +0 -6
- package/dist/loop/failureHints.d.ts.map +0 -1
- package/dist/loop/failureHints.js +0 -36
- package/dist/loop/failureHints.js.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"trustDecision.d.ts","sourceRoot":"","sources":["../src/trustDecision.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,
|
|
1
|
+
{"version":3,"file":"trustDecision.d.ts","sourceRoot":"","sources":["../src/trustDecision.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,oCAAoC,EACpC,yBAAyB,EACzB,+BAA+B,EAC/B,oBAAoB,EACrB,MAAM,yBAAyB,CAAC;AAEjC,8DAA8D;AAC9D,MAAM,MAAM,aAAa,GAAG,MAAM,GAAG,QAAQ,GAAG,SAAS,CAAC;AAE1D,wBAAgB,+BAA+B,CAAC,MAAM,EAAE;IACtD,OAAO,EAAE,yBAAyB,CAAC;IACnC,aAAa,EAAE,+BAA+B,CAAC;IAC/C,kBAAkB,EAAE,oCAAoC,CAAC;CAC1D,GAAG,aAAa,CAKhB;AAED;;GAEG;AACH,wBAAgB,4BAA4B,CAAC,WAAW,EAAE,oBAAoB,GAAG,aAAa,CAM7F"}
|
package/dist/trustDecision.js
CHANGED
|
@@ -1,13 +1,20 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
*/
|
|
4
|
-
export function trustDecisionFromCertificate(certificate) {
|
|
5
|
-
if (certificate.runKind === "quick_preview")
|
|
1
|
+
export function trustDecisionFromRelianceFields(params) {
|
|
2
|
+
if (params.runKind === "quick_preview")
|
|
6
3
|
return "unknown";
|
|
7
|
-
if (
|
|
4
|
+
if (params.highStakesReliance === "permitted")
|
|
8
5
|
return "safe";
|
|
9
|
-
if (
|
|
6
|
+
if (params.stateRelation === "does_not_match")
|
|
10
7
|
return "unsafe";
|
|
11
8
|
return "unknown";
|
|
12
9
|
}
|
|
10
|
+
/**
|
|
11
|
+
* Derive trust from Outcome Certificate v1 (normative: quick_preview is never high-stakes safe).
|
|
12
|
+
*/
|
|
13
|
+
export function trustDecisionFromCertificate(certificate) {
|
|
14
|
+
return trustDecisionFromRelianceFields({
|
|
15
|
+
runKind: certificate.runKind,
|
|
16
|
+
stateRelation: certificate.stateRelation,
|
|
17
|
+
highStakesReliance: certificate.highStakesReliance,
|
|
18
|
+
});
|
|
19
|
+
}
|
|
13
20
|
//# sourceMappingURL=trustDecision.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"trustDecision.js","sourceRoot":"","sources":["../src/trustDecision.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"trustDecision.js","sourceRoot":"","sources":["../src/trustDecision.ts"],"names":[],"mappings":"AAUA,MAAM,UAAU,+BAA+B,CAAC,MAI/C;IACC,IAAI,MAAM,CAAC,OAAO,KAAK,eAAe;QAAE,OAAO,SAAS,CAAC;IACzD,IAAI,MAAM,CAAC,kBAAkB,KAAK,WAAW;QAAE,OAAO,MAAM,CAAC;IAC7D,IAAI,MAAM,CAAC,aAAa,KAAK,gBAAgB;QAAE,OAAO,QAAQ,CAAC;IAC/D,OAAO,SAAS,CAAC;AACnB,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,4BAA4B,CAAC,WAAiC;IAC5E,OAAO,+BAA+B,CAAC;QACrC,OAAO,EAAE,WAAW,CAAC,OAAO;QAC5B,aAAa,EAAE,WAAW,CAAC,aAAa;QACxC,kBAAkB,EAAE,WAAW,CAAC,kBAAkB;KACnD,CAAC,CAAC;AACL,CAAC"}
|
|
@@ -208,7 +208,7 @@ export async function runBatchVerifyWithTelemetrySubcommand(batchArgs, opts) {
|
|
|
208
208
|
const shareOrigin = parsedBatch.shareReportOrigin;
|
|
209
209
|
if (shareOrigin !== undefined) {
|
|
210
210
|
const shareRes = await postPublicVerificationReport(shareOrigin, {
|
|
211
|
-
schemaVersion:
|
|
211
|
+
schemaVersion: 3,
|
|
212
212
|
certificate,
|
|
213
213
|
});
|
|
214
214
|
if (!shareRes.ok) {
|
|
@@ -329,7 +329,7 @@ export async function runBatchVerifyWithTelemetrySubcommand(batchArgs, opts) {
|
|
|
329
329
|
throw new TruthLayerError(CLI_OPERATIONAL_CODES.WORKFLOW_RESULT_SCHEMA_INVALID, JSON.stringify(validateWf.errors ?? []));
|
|
330
330
|
}
|
|
331
331
|
const certificate = buildOutcomeCertificateLangGraphCheckpointTrustFromWorkflowResult(workflowResult);
|
|
332
|
-
const validateCert = loadSchemaValidator("outcome-certificate-
|
|
332
|
+
const validateCert = loadSchemaValidator("outcome-certificate-v3");
|
|
333
333
|
if (!validateCert(certificate)) {
|
|
334
334
|
throw new TruthLayerError(CLI_OPERATIONAL_CODES.WORKFLOW_RESULT_SCHEMA_INVALID, JSON.stringify(validateCert.errors ?? []));
|
|
335
335
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "agentskeptic",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "6.0.0",
|
|
4
4
|
"description": "Structured tool activity vs downstream state at verify time: SQL (SQLite, Postgres, MySQL), HTTP witnesses, supported vector indexes, MongoDB documents, and S3-compatible objects when configured—deterministic verdict artifacts (see verification-state-stores.md).",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -24,9 +24,9 @@
|
|
|
24
24
|
},
|
|
25
25
|
"scripts": {
|
|
26
26
|
"prepublishOnly": "node scripts/build-commercial.mjs",
|
|
27
|
-
"codegen:types": "openapi-typescript schemas/openapi-commercial-v1.yaml -o src/sdk/_generated/openapi-types.ts",
|
|
27
|
+
"codegen:types": "node ./node_modules/openapi-typescript/bin/cli.js schemas/openapi-commercial-v1.yaml -o src/sdk/_generated/openapi-types.ts",
|
|
28
28
|
"codegen:error-codes": "node scripts/generate-agentskeptic-error-codes.mjs",
|
|
29
|
-
"build": "node scripts/materialize-first-five-minutes.mjs && node scripts/write-commercial-build-flags.mjs --oss && node scripts/sync-failure-origin-from-schema.mjs && tsc && node scripts/write-execution-identity.mjs && node scripts/copy-cli-init-assets.mjs && node scripts/copy-debug-ui.mjs && node scripts/write-discovery-payload.mjs",
|
|
29
|
+
"build": "node scripts/materialize-first-five-minutes.mjs && node scripts/write-commercial-build-flags.mjs --oss && node scripts/sync-failure-origin-from-schema.mjs && node ./node_modules/typescript/bin/tsc && node scripts/write-execution-identity.mjs && node scripts/copy-cli-init-assets.mjs && node scripts/copy-debug-ui.mjs && node scripts/write-discovery-payload.mjs",
|
|
30
30
|
"build:commercial": "node scripts/build-commercial.mjs",
|
|
31
31
|
"start": "npm run build && node scripts/demo.mjs",
|
|
32
32
|
"dev": "npm run dev -w agentskeptic-web",
|
|
@@ -109,6 +109,7 @@
|
|
|
109
109
|
"openapi-typescript": "^7.10.1",
|
|
110
110
|
"semantic-release": "^25.0.0",
|
|
111
111
|
"stripe": "^17.5.0",
|
|
112
|
+
"tsx": "^4.21.0",
|
|
112
113
|
"typescript": "^5.7.2",
|
|
113
114
|
"vitest": "^4.1.4"
|
|
114
115
|
},
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$id": "https://agentskeptic.com/schemas/evidence-completeness-v1.schema.json",
|
|
3
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4
|
+
"title": "EvidenceCompletenessV1",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": [
|
|
8
|
+
"schemaVersion",
|
|
9
|
+
"blockerCategory",
|
|
10
|
+
"quickSignal",
|
|
11
|
+
"verifiedClaims",
|
|
12
|
+
"unverifiedClaims",
|
|
13
|
+
"missingInputs",
|
|
14
|
+
"nextActions"
|
|
15
|
+
],
|
|
16
|
+
"properties": {
|
|
17
|
+
"schemaVersion": { "type": "integer", "const": 1 },
|
|
18
|
+
"blockerCategory": {
|
|
19
|
+
"type": "string",
|
|
20
|
+
"enum": [
|
|
21
|
+
"none",
|
|
22
|
+
"preview_lane",
|
|
23
|
+
"ingest_empty",
|
|
24
|
+
"ingest_unstructured",
|
|
25
|
+
"registry_unknown_tool",
|
|
26
|
+
"registry_resolution",
|
|
27
|
+
"database_access",
|
|
28
|
+
"timing_or_window",
|
|
29
|
+
"witness_unavailable",
|
|
30
|
+
"state_mismatch",
|
|
31
|
+
"verification_incomplete",
|
|
32
|
+
"event_sequence",
|
|
33
|
+
"control_flow_context",
|
|
34
|
+
"unclassified"
|
|
35
|
+
]
|
|
36
|
+
},
|
|
37
|
+
"quickSignal": {
|
|
38
|
+
"type": "string",
|
|
39
|
+
"enum": [
|
|
40
|
+
"na",
|
|
41
|
+
"no_actions",
|
|
42
|
+
"no_structured_activity",
|
|
43
|
+
"no_sql_candidates",
|
|
44
|
+
"sql_ran_uncertain",
|
|
45
|
+
"sql_ran_failed",
|
|
46
|
+
"sql_ran_passed"
|
|
47
|
+
]
|
|
48
|
+
},
|
|
49
|
+
"verifiedClaims": {
|
|
50
|
+
"type": "array",
|
|
51
|
+
"maxItems": 24,
|
|
52
|
+
"items": { "type": "string", "minLength": 1, "maxLength": 160 }
|
|
53
|
+
},
|
|
54
|
+
"unverifiedClaims": {
|
|
55
|
+
"type": "array",
|
|
56
|
+
"maxItems": 24,
|
|
57
|
+
"items": { "type": "string", "minLength": 1, "maxLength": 160 }
|
|
58
|
+
},
|
|
59
|
+
"missingInputs": {
|
|
60
|
+
"type": "array",
|
|
61
|
+
"maxItems": 8,
|
|
62
|
+
"items": {
|
|
63
|
+
"type": "object",
|
|
64
|
+
"additionalProperties": false,
|
|
65
|
+
"required": ["code", "hint"],
|
|
66
|
+
"properties": {
|
|
67
|
+
"code": { "type": "string", "minLength": 1, "maxLength": 72 },
|
|
68
|
+
"hint": { "type": "string", "minLength": 1, "maxLength": 400 }
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
},
|
|
72
|
+
"nextActions": {
|
|
73
|
+
"type": "array",
|
|
74
|
+
"minItems": 1,
|
|
75
|
+
"maxItems": 3,
|
|
76
|
+
"items": {
|
|
77
|
+
"type": "object",
|
|
78
|
+
"additionalProperties": false,
|
|
79
|
+
"required": ["id", "text"],
|
|
80
|
+
"properties": {
|
|
81
|
+
"id": { "type": "string", "minLength": 1, "maxLength": 64, "pattern": "^[a-z][a-z0-9_]{0,63}$" },
|
|
82
|
+
"text": { "type": "string", "minLength": 1, "maxLength": 500 }
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$id": "https://agentskeptic.com/schemas/failure-spine-v1.schema.json",
|
|
3
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4
|
+
"title": "FailureSpineV1",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": [
|
|
8
|
+
"schemaVersion",
|
|
9
|
+
"trustDecision",
|
|
10
|
+
"summary",
|
|
11
|
+
"actionableFailure",
|
|
12
|
+
"primaryCodes",
|
|
13
|
+
"rerunGuidance",
|
|
14
|
+
"source"
|
|
15
|
+
],
|
|
16
|
+
"properties": {
|
|
17
|
+
"schemaVersion": { "type": "integer", "const": 1 },
|
|
18
|
+
"trustDecision": {
|
|
19
|
+
"type": "string",
|
|
20
|
+
"enum": ["safe", "unsafe", "unknown"]
|
|
21
|
+
},
|
|
22
|
+
"summary": { "type": "string", "minLength": 1, "maxLength": 2048 },
|
|
23
|
+
"actionableFailure": {
|
|
24
|
+
"$ref": "https://agentskeptic.com/schemas/workflow-truth-report.schema.json#/$defs/actionableFailure"
|
|
25
|
+
},
|
|
26
|
+
"primaryCodes": {
|
|
27
|
+
"type": "array",
|
|
28
|
+
"minItems": 1,
|
|
29
|
+
"maxItems": 24,
|
|
30
|
+
"items": { "type": "string", "minLength": 1, "maxLength": 256 }
|
|
31
|
+
},
|
|
32
|
+
"rerunGuidance": { "type": "string", "minLength": 1, "maxLength": 512 },
|
|
33
|
+
"source": {
|
|
34
|
+
"type": "string",
|
|
35
|
+
"enum": ["workflow", "quick", "ineligible_langgraph"]
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
}
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$id": "https://agentskeptic.com/schemas/material-truth-v2.schema.json",
|
|
3
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
4
|
+
"title": "MaterialTruthV2",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": [
|
|
8
|
+
"schemaVersion",
|
|
9
|
+
"workflowId",
|
|
10
|
+
"runKind",
|
|
11
|
+
"stateRelation",
|
|
12
|
+
"reasonCodes",
|
|
13
|
+
"steps",
|
|
14
|
+
"checkpointVerdicts",
|
|
15
|
+
"evidenceGapPrimary"
|
|
16
|
+
],
|
|
17
|
+
"properties": {
|
|
18
|
+
"schemaVersion": { "type": "integer", "const": 2 },
|
|
19
|
+
"workflowId": { "type": "string", "minLength": 1, "maxLength": 512 },
|
|
20
|
+
"runKind": {
|
|
21
|
+
"type": "string",
|
|
22
|
+
"enum": ["contract_sql", "contract_sql_langgraph_checkpoint_trust", "quick_preview"]
|
|
23
|
+
},
|
|
24
|
+
"stateRelation": {
|
|
25
|
+
"type": "string",
|
|
26
|
+
"enum": ["matches_expectations", "does_not_match", "not_established"]
|
|
27
|
+
},
|
|
28
|
+
"reasonCodes": {
|
|
29
|
+
"type": "array",
|
|
30
|
+
"items": { "type": "string", "minLength": 1, "maxLength": 256 }
|
|
31
|
+
},
|
|
32
|
+
"evidenceGapPrimary": {
|
|
33
|
+
"type": "string",
|
|
34
|
+
"enum": [
|
|
35
|
+
"none",
|
|
36
|
+
"preview_lane",
|
|
37
|
+
"ingest_empty",
|
|
38
|
+
"ingest_unstructured",
|
|
39
|
+
"registry_unknown_tool",
|
|
40
|
+
"registry_resolution",
|
|
41
|
+
"database_access",
|
|
42
|
+
"timing_or_window",
|
|
43
|
+
"witness_unavailable",
|
|
44
|
+
"state_mismatch",
|
|
45
|
+
"verification_incomplete",
|
|
46
|
+
"event_sequence",
|
|
47
|
+
"control_flow_context",
|
|
48
|
+
"unclassified"
|
|
49
|
+
]
|
|
50
|
+
},
|
|
51
|
+
"steps": {
|
|
52
|
+
"type": "array",
|
|
53
|
+
"items": {
|
|
54
|
+
"type": "object",
|
|
55
|
+
"additionalProperties": false,
|
|
56
|
+
"required": ["seq", "toolId", "declaredAction", "expectedOutcome", "observedOutcome"],
|
|
57
|
+
"properties": {
|
|
58
|
+
"seq": { "type": "integer", "minimum": 0 },
|
|
59
|
+
"toolId": { "type": "string", "maxLength": 512 },
|
|
60
|
+
"declaredAction": { "type": "string", "minLength": 1, "maxLength": 4096 },
|
|
61
|
+
"expectedOutcome": { "type": "string", "minLength": 1, "maxLength": 4096 },
|
|
62
|
+
"observedOutcome": { "type": "string", "minLength": 1, "maxLength": 8192 }
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
},
|
|
66
|
+
"checkpointVerdicts": {
|
|
67
|
+
"type": "array",
|
|
68
|
+
"items": {
|
|
69
|
+
"type": "object",
|
|
70
|
+
"additionalProperties": false,
|
|
71
|
+
"required": ["checkpointKey", "verdict", "seqs"],
|
|
72
|
+
"properties": {
|
|
73
|
+
"checkpointKey": { "type": "string", "minLength": 1, "maxLength": 2048 },
|
|
74
|
+
"verdict": { "type": "string", "enum": ["verified", "inconsistent", "incomplete"] },
|
|
75
|
+
"seqs": {
|
|
76
|
+
"type": "array",
|
|
77
|
+
"items": { "type": "integer", "minimum": 0 }
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
}
|
|
@@ -12,7 +12,7 @@ info:
|
|
|
12
12
|
url: __CONTRACT_URL__
|
|
13
13
|
version: __CONTRACT_VERSION__
|
|
14
14
|
manifestSha256: __CONTRACT_SHA__
|
|
15
|
-
description: "__IDENTITY_ONE_LINER__\n\nMachine-readable contract for license preflight used by the published npm CLI.\nBase URL is your deployed app origin (same as NEXT_PUBLIC_APP_URL).\n\nEvery path in this document returns an `x-request-id` response header on all status codes (echo a valid client `x-request-id` when supplied; otherwise server-generated). Non-2xx JSON bodies follow RFC 7807-style Problem Details (`type`, `title`, `status`, `detail`, optional `code`, `instance`) unless noted; `POST /api/v1/usage/reserve` denials additionally include legacy `allowed`, `code`, `message`, and optional `upgrade_url` for backward compatibility.\n"
|
|
15
|
+
description: "__IDENTITY_ONE_LINER__\n\nMachine-readable contract for license preflight used by the published npm CLI.\nBase URL is your deployed app origin (same as NEXT_PUBLIC_APP_URL).\n\nEvery path in this document returns an `x-request-id` response header on all status codes (echo a valid client `x-request-id` when supplied; otherwise server-generated). Non-2xx JSON bodies follow RFC 7807-style Problem Details (`type`, `title`, `status`, `detail`, optional `code`, `instance`) unless noted; `POST /api/v1/usage/reserve` denials additionally include legacy `allowed`, `code`, `message`, and optional `upgrade_url` for backward compatibility.\n\n**Breaking (agentskeptic 5.x):** Hosted enforcement ingestion uses `schema_version` 3 with `outcome_certificate` (Outcome Certificate v3 inner JSON, including `failureSpine`). Legacy `schema_version` 2 payloads with `outcome_certificate_v1` are rejected. `POST /api/v1/funnel/verify-outcome` requires `schema_version` 3 and `evidence_gap_primary`. `POST /api/public/verification-reports` accepts envelope `schemaVersion` 3 only. **HTTP 4xx/5xx** responses are **not** `failure-spine-v1` and are **not** Outcome Certificate-shaped; operational CLI errors use `cli-error-envelope` on stderr only.\n"
|
|
16
16
|
externalDocs:
|
|
17
17
|
description: "First-run integration guide"
|
|
18
18
|
url: __DISTRIBUTION_INTEGRATE_URL__
|
|
@@ -125,7 +125,7 @@ paths:
|
|
|
125
125
|
content:
|
|
126
126
|
application/json:
|
|
127
127
|
schema:
|
|
128
|
-
$ref: "#/components/schemas/
|
|
128
|
+
$ref: "#/components/schemas/EnforcementEvidenceRequestV3"
|
|
129
129
|
responses:
|
|
130
130
|
"200":
|
|
131
131
|
description: Lifecycle transition completed
|
|
@@ -162,7 +162,7 @@ paths:
|
|
|
162
162
|
content:
|
|
163
163
|
application/json:
|
|
164
164
|
schema:
|
|
165
|
-
$ref: "#/components/schemas/
|
|
165
|
+
$ref: "#/components/schemas/EnforcementEvidenceRequestV3"
|
|
166
166
|
responses:
|
|
167
167
|
"200":
|
|
168
168
|
description: Check completed (match, open drift, rerun pass/fail, etc.)
|
|
@@ -187,7 +187,7 @@ paths:
|
|
|
187
187
|
content:
|
|
188
188
|
application/json:
|
|
189
189
|
schema:
|
|
190
|
-
$ref: "#/components/schemas/
|
|
190
|
+
$ref: "#/components/schemas/EnforcementAcceptEvidenceRequestV3"
|
|
191
191
|
responses:
|
|
192
192
|
"200":
|
|
193
193
|
description: Baseline updated; rerun POST /check required before returning to trusted-only posture
|
|
@@ -315,7 +315,7 @@ paths:
|
|
|
315
315
|
summary: Licensed verify-outcome beacon (idempotent per API key + run_id)
|
|
316
316
|
description: >
|
|
317
317
|
POST after a successful `POST /api/v1/usage/reserve` for the same `run_id`. Success is HTTP 204 with an empty body.
|
|
318
|
-
Requires Bearer API key. Body
|
|
318
|
+
Requires Bearer API key. Body `schema_version` must be 3 (`VerifyOutcomeRequestV3`). `evidence_gap_primary` duplicates `certificate.evidenceCompleteness.blockerCategory` at CLI emission time.
|
|
319
319
|
security:
|
|
320
320
|
- bearerAuth: []
|
|
321
321
|
requestBody:
|
|
@@ -323,7 +323,7 @@ paths:
|
|
|
323
323
|
content:
|
|
324
324
|
application/json:
|
|
325
325
|
schema:
|
|
326
|
-
$ref: "#/components/schemas/
|
|
326
|
+
$ref: "#/components/schemas/VerifyOutcomeRequestV3"
|
|
327
327
|
responses:
|
|
328
328
|
"204":
|
|
329
329
|
description: Beacon accepted (or duplicate ignored)
|
|
@@ -556,27 +556,28 @@ components:
|
|
|
556
556
|
scheme: bearer
|
|
557
557
|
bearerFormat: API key
|
|
558
558
|
schemas:
|
|
559
|
-
|
|
559
|
+
EnforcementEvidenceRequestV3:
|
|
560
560
|
type: object
|
|
561
|
-
required: [schema_version, run_id, workflow_id,
|
|
561
|
+
required: [schema_version, run_id, workflow_id, outcome_certificate, material_truth_sha256, certificate_sha256]
|
|
562
562
|
properties:
|
|
563
563
|
schema_version:
|
|
564
564
|
type: integer
|
|
565
|
-
const:
|
|
565
|
+
const: 3
|
|
566
566
|
run_id:
|
|
567
567
|
type: string
|
|
568
568
|
workflow_id:
|
|
569
569
|
type: string
|
|
570
|
-
|
|
570
|
+
outcome_certificate:
|
|
571
571
|
type: object
|
|
572
572
|
additionalProperties: true
|
|
573
|
+
description: Outcome Certificate v2 JSON (schemaVersion 2) including evidenceCompleteness
|
|
573
574
|
material_truth_sha256:
|
|
574
575
|
type: string
|
|
575
576
|
certificate_sha256:
|
|
576
577
|
type: string
|
|
577
578
|
EnforcementFsmEnvelopeV2:
|
|
578
579
|
type: object
|
|
579
|
-
description: Hosted enforcement lifecycle
|
|
580
|
+
description: Hosted enforcement lifecycle response envelope for POST /check | /baselines | /accept (schema_version 2 on responses; distinct from evidence ingestion schema_version 3).
|
|
580
581
|
required: [schema_version, code]
|
|
581
582
|
properties:
|
|
582
583
|
schema_version:
|
|
@@ -587,9 +588,9 @@ components:
|
|
|
587
588
|
quota_enforced_via_reserve:
|
|
588
589
|
type: boolean
|
|
589
590
|
additionalProperties: true
|
|
590
|
-
|
|
591
|
+
EnforcementAcceptEvidenceRequestV3:
|
|
591
592
|
allOf:
|
|
592
|
-
- $ref: "#/components/schemas/
|
|
593
|
+
- $ref: "#/components/schemas/EnforcementEvidenceRequestV3"
|
|
593
594
|
- type: object
|
|
594
595
|
required: [expected_projection_hash, lifecycle_state_version]
|
|
595
596
|
properties:
|
|
@@ -715,13 +716,14 @@ components:
|
|
|
715
716
|
type: string
|
|
716
717
|
code:
|
|
717
718
|
type: string
|
|
718
|
-
|
|
719
|
+
VerifyOutcomeRequestV3:
|
|
719
720
|
type: object
|
|
720
721
|
required:
|
|
721
722
|
- schema_version
|
|
722
723
|
- run_id
|
|
723
724
|
- workflow_id
|
|
724
725
|
- trust_decision
|
|
726
|
+
- evidence_gap_primary
|
|
725
727
|
- reason_codes
|
|
726
728
|
- terminal_status
|
|
727
729
|
- workload_class
|
|
@@ -729,7 +731,7 @@ components:
|
|
|
729
731
|
properties:
|
|
730
732
|
schema_version:
|
|
731
733
|
type: integer
|
|
732
|
-
const:
|
|
734
|
+
const: 3
|
|
733
735
|
run_id:
|
|
734
736
|
type: string
|
|
735
737
|
maxLength: 256
|
|
@@ -739,6 +741,24 @@ components:
|
|
|
739
741
|
trust_decision:
|
|
740
742
|
type: string
|
|
741
743
|
enum: [safe, unsafe, unknown]
|
|
744
|
+
evidence_gap_primary:
|
|
745
|
+
type: string
|
|
746
|
+
enum:
|
|
747
|
+
- "none"
|
|
748
|
+
- "preview_lane"
|
|
749
|
+
- "ingest_empty"
|
|
750
|
+
- "ingest_unstructured"
|
|
751
|
+
- "registry_unknown_tool"
|
|
752
|
+
- "registry_resolution"
|
|
753
|
+
- "database_access"
|
|
754
|
+
- "timing_or_window"
|
|
755
|
+
- "witness_unavailable"
|
|
756
|
+
- "state_mismatch"
|
|
757
|
+
- "verification_incomplete"
|
|
758
|
+
- "event_sequence"
|
|
759
|
+
- "control_flow_context"
|
|
760
|
+
- "unclassified"
|
|
761
|
+
description: Mirrors Outcome Certificate evidenceCompleteness.blockerCategory at CLI emission time
|
|
742
762
|
reason_codes:
|
|
743
763
|
type: array
|
|
744
764
|
maxItems: 8
|
|
@@ -752,7 +772,12 @@ components:
|
|
|
752
772
|
enum: [bundled_examples, non_bundled]
|
|
753
773
|
subcommand:
|
|
754
774
|
type: string
|
|
755
|
-
enum: [batch_verify, quick_verify, verify_integrator_owned]
|
|
775
|
+
enum: [batch_verify, quick_verify, verify_integrator_owned, activate]
|
|
776
|
+
activation:
|
|
777
|
+
description: Present only when subcommand is activate (mirrors ActivationManifest-derived wire)
|
|
778
|
+
type: object
|
|
779
|
+
nullable: true
|
|
780
|
+
additionalProperties: true
|
|
756
781
|
TrustDecisionRecordRequestV1:
|
|
757
782
|
type: object
|
|
758
783
|
additionalProperties: false
|
|
@@ -792,8 +817,8 @@ components:
|
|
|
792
817
|
$ref: "#/components/schemas/TrustCertificateSnapshotRequestV1"
|
|
793
818
|
human_blocker_lines:
|
|
794
819
|
type: array
|
|
795
|
-
minItems:
|
|
796
|
-
maxItems:
|
|
820
|
+
minItems: 1
|
|
821
|
+
maxItems: 48
|
|
797
822
|
items:
|
|
798
823
|
type: string
|
|
799
824
|
TrustCertificateSnapshotRequestV1:
|
|
@@ -907,8 +932,8 @@ components:
|
|
|
907
932
|
additionalProperties: false
|
|
908
933
|
PublicVerificationReportCreate:
|
|
909
934
|
description: >
|
|
910
|
-
POST accepts schemaVersion
|
|
911
|
-
schemas/public-verification-report-
|
|
935
|
+
POST accepts schemaVersion 3 only: { "schemaVersion": 3, "certificate": <OutcomeCertificateV2> } per
|
|
936
|
+
schemas/public-verification-report-v3.schema.json. Legacy envelope POST bodies return HTTP 400.
|
|
912
937
|
type: object
|
|
913
938
|
additionalProperties: true
|
|
914
939
|
PublicVerificationReportCreated:
|
|
@@ -921,7 +946,7 @@ components:
|
|
|
921
946
|
properties:
|
|
922
947
|
schemaVersion:
|
|
923
948
|
type: integer
|
|
924
|
-
const:
|
|
949
|
+
const: 3
|
|
925
950
|
id:
|
|
926
951
|
type: string
|
|
927
952
|
format: uuid
|