@riddledc/riddle-proof 0.5.45 → 0.5.46

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 (44) hide show
  1. package/README.md +17 -0
  2. package/dist/checkpoint.cjs +204 -1
  3. package/dist/checkpoint.d.cts +16 -1
  4. package/dist/checkpoint.d.ts +16 -1
  5. package/dist/checkpoint.js +4 -2
  6. package/dist/{chunk-W7VTDN4T.js → chunk-DUFDZJOF.js} +1 -0
  7. package/dist/{chunk-7S7O3NKF.js → chunk-JTNMEH57.js} +6 -1
  8. package/dist/{chunk-MRSYJMF4.js → chunk-L26NTZOU.js} +2 -2
  9. package/dist/chunk-NOBFZDZG.js +754 -0
  10. package/dist/chunk-PLSGW2GI.js +161 -0
  11. package/dist/{chunk-LXE5YUYY.js → chunk-R6SCWJCI.js} +204 -2
  12. package/dist/{chunk-CHRYLX6N.js → chunk-X3AQ2WUM.js} +128 -15
  13. package/dist/cli.cjs +6129 -0
  14. package/dist/cli.d.cts +1 -0
  15. package/dist/cli.d.ts +1 -0
  16. package/dist/cli.js +160 -0
  17. package/dist/codex-exec-agent.cjs +790 -0
  18. package/dist/codex-exec-agent.d.cts +91 -0
  19. package/dist/codex-exec-agent.d.ts +91 -0
  20. package/dist/codex-exec-agent.js +10 -0
  21. package/dist/engine-harness.cjs +740 -279
  22. package/dist/engine-harness.js +5 -4
  23. package/dist/index.cjs +1469 -247
  24. package/dist/index.d.cts +4 -2
  25. package/dist/index.d.ts +4 -2
  26. package/dist/index.js +33 -17
  27. package/dist/openclaw.js +4 -2
  28. package/dist/proof-run-engine.d.cts +3 -3
  29. package/dist/proof-run-engine.d.ts +3 -3
  30. package/dist/result.cjs +1 -0
  31. package/dist/result.js +1 -1
  32. package/dist/run-card.cjs +212 -0
  33. package/dist/run-card.d.cts +10 -0
  34. package/dist/run-card.d.ts +10 -0
  35. package/dist/run-card.js +10 -0
  36. package/dist/runner.cjs +2 -0
  37. package/dist/runner.js +5 -3
  38. package/dist/state.cjs +174 -5
  39. package/dist/state.d.cts +2 -1
  40. package/dist/state.d.ts +2 -1
  41. package/dist/state.js +4 -2
  42. package/dist/types.d.cts +63 -2
  43. package/dist/types.d.ts +63 -2
  44. package/package.json +15 -2
package/README.md CHANGED
@@ -56,6 +56,23 @@ adapters are exposed through subpaths such as
56
56
  `@riddledc/riddle-proof/openclaw`, so wrappers can reuse the mapping logic
57
57
  without depending on another plugin runtime.
58
58
 
59
+ ## Durable Loop CLI
60
+
61
+ The package publishes `riddle-proof-loop` as a host-agnostic runner surface for
62
+ Codex/CLI-style testing:
63
+
64
+ ```sh
65
+ riddle-proof-loop run --request-json request.json --checkpoint-mode yield
66
+ riddle-proof-loop status --state-path /tmp/riddle-proof-run.json
67
+ riddle-proof-loop respond --state-path /tmp/riddle-proof-run.json --response-json response.json
68
+ riddle-proof-loop doctor codex_exec
69
+ ```
70
+
71
+ In yield mode, the harness returns portable checkpoint packets for recon,
72
+ authoring, implementation, proof assessment, and evidence recovery. A host can
73
+ answer those packets with `riddle-proof.checkpoint_response.v1` JSON without
74
+ needing OpenClaw-specific proof semantics.
75
+
59
76
  ## Runner Harness
60
77
 
61
78
  `runRiddleProof` is the reusable idea-to-PR workflow driver. It does not ship
@@ -36,6 +36,7 @@ __export(checkpoint_exports, {
36
36
  buildAuthorCheckpointPacket: () => buildAuthorCheckpointPacket,
37
37
  buildCheckpointPacketForEngineResult: () => buildCheckpointPacketForEngineResult,
38
38
  buildProofAssessmentCheckpointPacket: () => buildProofAssessmentCheckpointPacket,
39
+ buildStageCheckpointPacket: () => buildStageCheckpointPacket,
39
40
  checkpointResponseIdentity: () => checkpointResponseIdentity,
40
41
  checkpointSummaryFromState: () => checkpointSummaryFromState,
41
42
  isDuplicateCheckpointResponse: () => isDuplicateCheckpointResponse,
@@ -174,6 +175,102 @@ function responseSchemaForProofAssessmentPacket() {
174
175
  }
175
176
  };
176
177
  }
178
+ function responseSchemaForReconPacket() {
179
+ return {
180
+ type: "object",
181
+ required: ["version", "run_id", "checkpoint", "decision", "summary", "created_at"],
182
+ additionalProperties: false,
183
+ properties: {
184
+ version: { const: RIDDLE_PROOF_CHECKPOINT_RESPONSE_VERSION },
185
+ run_id: { type: "string" },
186
+ checkpoint: { type: "string" },
187
+ resume_token: { type: "string" },
188
+ decision: {
189
+ type: "string",
190
+ enum: ["ready_for_author", "retry_recon", "recon_stuck", "needs_recon", "blocked", "human_review"]
191
+ },
192
+ summary: { type: "string" },
193
+ payload: {
194
+ type: "object",
195
+ description: "Optional recon assessment details such as baseline_understanding, refined_inputs, reasons, or diagnostic blocker context."
196
+ },
197
+ reasons: { type: "array", items: { type: "string" } },
198
+ continue_with_stage: { type: "string", enum: ["recon", "author"] },
199
+ source: {
200
+ type: "object",
201
+ properties: {
202
+ kind: { type: "string" },
203
+ session_id: { type: "string" },
204
+ user_id: { type: "string" }
205
+ }
206
+ },
207
+ created_at: { type: "string" }
208
+ }
209
+ };
210
+ }
211
+ function responseSchemaForImplementationPacket() {
212
+ return {
213
+ type: "object",
214
+ required: ["version", "run_id", "checkpoint", "decision", "summary", "created_at"],
215
+ additionalProperties: false,
216
+ properties: {
217
+ version: { const: RIDDLE_PROOF_CHECKPOINT_RESPONSE_VERSION },
218
+ run_id: { type: "string" },
219
+ checkpoint: { type: "string" },
220
+ resume_token: { type: "string" },
221
+ decision: {
222
+ type: "string",
223
+ enum: ["implementation_complete", "needs_author", "needs_recon", "blocked", "human_review"]
224
+ },
225
+ summary: { type: "string" },
226
+ payload: {
227
+ type: "object",
228
+ description: "Implementation details such as changed_files, tests_run, and implementation_notes. The changed worktree must contain a real git diff before verify can advance."
229
+ },
230
+ reasons: { type: "array", items: { type: "string" } },
231
+ continue_with_stage: { type: "string", enum: ["implement", "verify", "author", "recon"] },
232
+ source: {
233
+ type: "object",
234
+ properties: {
235
+ kind: { type: "string" },
236
+ session_id: { type: "string" },
237
+ user_id: { type: "string" }
238
+ }
239
+ },
240
+ created_at: { type: "string" }
241
+ }
242
+ };
243
+ }
244
+ function responseSchemaForAdvancePacket(stage) {
245
+ return {
246
+ type: "object",
247
+ required: ["version", "run_id", "checkpoint", "decision", "summary", "created_at"],
248
+ additionalProperties: false,
249
+ properties: {
250
+ version: { const: RIDDLE_PROOF_CHECKPOINT_RESPONSE_VERSION },
251
+ run_id: { type: "string" },
252
+ checkpoint: { type: "string" },
253
+ resume_token: { type: "string" },
254
+ decision: {
255
+ type: "string",
256
+ enum: ["continue_stage", "retry_stage", "needs_recon", "needs_implementation", "blocked", "human_review"]
257
+ },
258
+ summary: { type: "string" },
259
+ payload: { type: "object" },
260
+ reasons: { type: "array", items: { type: "string" } },
261
+ continue_with_stage: { type: "string", enum: ["recon", "author", "implement", "verify", "ship", stage] },
262
+ source: {
263
+ type: "object",
264
+ properties: {
265
+ kind: { type: "string" },
266
+ session_id: { type: "string" },
267
+ user_id: { type: "string" }
268
+ }
269
+ },
270
+ created_at: { type: "string" }
271
+ }
272
+ };
273
+ }
177
274
  function resumeTokenFor(input) {
178
275
  const hash = import_node_crypto.default.createHash("sha256").update(JSON.stringify(input)).digest("hex").slice(0, 24);
179
276
  return `rpchk_${hash}`;
@@ -201,6 +298,106 @@ function artifactsFromState(state) {
201
298
  }
202
299
  return artifacts.slice(0, 16);
203
300
  }
301
+ function stageFromCheckpoint(checkpoint) {
302
+ if (checkpoint.startsWith("recon_")) return "recon";
303
+ if (checkpoint.startsWith("author_")) return "author";
304
+ if (checkpoint.startsWith("implement_")) return "implement";
305
+ if (checkpoint.startsWith("verify_")) return "verify";
306
+ if (checkpoint.startsWith("ship_")) return "ship";
307
+ if (checkpoint.startsWith("pr_sync_")) return "notify";
308
+ if (checkpoint.includes("capture")) return "prove";
309
+ return "setup";
310
+ }
311
+ function allowedDecisionsForStage(stage, checkpoint) {
312
+ if (stage === "recon") return ["ready_for_author", "retry_recon", "recon_stuck", "blocked", "human_review"];
313
+ if (stage === "implement") return ["implementation_complete", "needs_author", "needs_recon", "blocked", "human_review"];
314
+ if (stage === "ship") return ["continue_stage", "needs_implementation", "needs_recon", "blocked", "human_review"];
315
+ if (checkpoint === "awaiting_stage_advance") return ["continue_stage", "retry_stage", "blocked", "human_review"];
316
+ return ["continue_stage", "needs_recon", "needs_implementation", "blocked", "human_review"];
317
+ }
318
+ function packetKindForStage(stage, checkpoint) {
319
+ if (stage === "recon") return "assess_recon";
320
+ if (stage === "implement") return "implement_change";
321
+ if (checkpoint.includes("human")) return "human_review";
322
+ return "advance_decision";
323
+ }
324
+ function responseSchemaForStage(stage, checkpoint) {
325
+ if (stage === "recon") return responseSchemaForReconPacket();
326
+ if (stage === "implement") return responseSchemaForImplementationPacket();
327
+ return responseSchemaForAdvancePacket(stage);
328
+ }
329
+ function questionForStage(stage, checkpoint) {
330
+ if (stage === "recon") {
331
+ return "Assess the baseline/recon evidence. Return ready_for_author only when the baseline is trustworthy; otherwise choose retry_recon, recon_stuck, blocked, or human_review.";
332
+ }
333
+ if (stage === "implement") {
334
+ return "Implement the requested change in the after worktree, leave a real git diff, then return implementation_complete with changed_files/tests_run/implementation_notes. Choose blocked or human_review if implementation cannot honestly advance.";
335
+ }
336
+ if (stage === "ship") {
337
+ return "Assess whether the ship gate can continue. Return continue_stage only if proof, PR, and policy gates are satisfied; otherwise route to the appropriate earlier stage or block with a concrete reason.";
338
+ }
339
+ return "Choose the next Riddle Proof stage for this durable run, or block with a concrete reason if the run cannot honestly advance.";
340
+ }
341
+ function buildStageCheckpointPacket(input) {
342
+ const checkpoint = nonEmptyString(input.engineResult.checkpoint) || "stage_checkpoint";
343
+ const stage = nonEmptyString(input.engineResult.stage) || stageFromCheckpoint(checkpoint);
344
+ const runId = input.runState.run_id || "unknown";
345
+ const fullState = input.fullRiddleState || {};
346
+ const decisionDetails = recordValue(input.engineResult.decisionRequest?.details);
347
+ const checkpointContract = recordValue(input.engineResult.checkpointContract);
348
+ const summary = nonEmptyString(input.engineResult.summary) || nonEmptyString(fullState.stage_summary) || `${stage} checkpoint needs a supervising decision.`;
349
+ const kind = packetKindForStage(stage, checkpoint);
350
+ return {
351
+ version: RIDDLE_PROOF_CHECKPOINT_PACKET_VERSION,
352
+ run_id: runId,
353
+ state_path: input.runState.state_path,
354
+ stage,
355
+ checkpoint,
356
+ kind,
357
+ summary,
358
+ question: questionForStage(stage, checkpoint),
359
+ change_request: input.request.change_request || nonEmptyString(fullState.change_request) || "",
360
+ context: input.request.context,
361
+ artifacts: artifactsFromState(fullState),
362
+ state_excerpt: compactRecord({
363
+ repo: input.request.repo || fullState.repo,
364
+ branch: input.request.branch || fullState.branch,
365
+ after_worktree: fullState.after_worktree || input.runState.worktree_path,
366
+ verification_mode: input.request.verification_mode || fullState.verification_mode,
367
+ reference: input.request.reference || fullState.reference,
368
+ server_path: fullState.server_path,
369
+ wait_for_selector: fullState.wait_for_selector,
370
+ recon_status: fullState.recon_status,
371
+ author_status: fullState.author_status,
372
+ implementation_status: fullState.implementation_status,
373
+ verify_status: fullState.verify_status,
374
+ stage_decision_request: jsonCloneRecord(fullState.stage_decision_request)
375
+ }),
376
+ evidence_excerpt: compactRecord({
377
+ before_cdn: fullState.before_cdn || null,
378
+ prod_cdn: fullState.prod_cdn || null,
379
+ after_cdn: fullState.after_cdn || null,
380
+ recon_results: jsonCloneRecord(fullState.recon_results),
381
+ checkpoint_contract: jsonCloneRecord(checkpointContract),
382
+ decision_details: jsonCloneRecord(decisionDetails)
383
+ }),
384
+ allowed_decisions: allowedDecisionsForStage(stage, checkpoint),
385
+ response_schema: responseSchemaForStage(stage, checkpoint),
386
+ routing_hint: {
387
+ suggested_role: stage === "implement" ? "builder_agent" : checkpoint.includes("human") ? "human" : "main_agent",
388
+ visibility: input.visibility || "quiet",
389
+ urgency: stage === "ship" ? "high" : "normal",
390
+ can_auto_answer: input.visibility !== "manual"
391
+ },
392
+ resume_token: resumeTokenFor({
393
+ runId,
394
+ statePath: input.engineResult.state_path || input.request.engine_state_path || null,
395
+ checkpoint,
396
+ stage
397
+ }),
398
+ created_at: input.created_at || timestamp()
399
+ };
400
+ }
204
401
  function buildAuthorCheckpointPacket(input) {
205
402
  const checkpoint = nonEmptyString(input.engineResult.checkpoint) || "author_supervisor_judgment";
206
403
  const stage = "author";
@@ -373,7 +570,12 @@ function buildCheckpointPacketForEngineResult(input) {
373
570
  if (checkpoint === "verify_supervisor_judgment" || checkpoint === "verify_supervisor_judgment_required" || checkpoint === "verify_human_escalation") {
374
571
  return buildProofAssessmentCheckpointPacket(input);
375
572
  }
376
- return buildAuthorCheckpointPacket(input);
573
+ const resume = recordValue(input.engineResult.checkpointContract?.resume);
574
+ const continueStage = nonEmptyString(resume?.continue_with_stage);
575
+ if (checkpoint === "author_supervisor_judgment" || checkpoint === "verify_capture_retry" || checkpoint === "verify_agent_retry" && continueStage === "author") {
576
+ return buildAuthorCheckpointPacket(input);
577
+ }
578
+ return buildStageCheckpointPacket(input);
377
579
  }
378
580
  function normalizeCheckpointResponse(value) {
379
581
  const record = recordValue(value);
@@ -497,6 +699,7 @@ function proofContractFromAuthorCheckpointResponse(response, packet, payload) {
497
699
  buildAuthorCheckpointPacket,
498
700
  buildCheckpointPacketForEngineResult,
499
701
  buildProofAssessmentCheckpointPacket,
702
+ buildStageCheckpointPacket,
500
703
  checkpointResponseIdentity,
501
704
  checkpointSummaryFromState,
502
705
  isDuplicateCheckpointResponse,
@@ -3,6 +3,21 @@ import { RiddleProofCheckpointResponse, RiddleProofRunParams, RiddleProofRunStat
3
3
  declare const RIDDLE_PROOF_CHECKPOINT_PACKET_VERSION: "riddle-proof.checkpoint.v1";
4
4
  declare const RIDDLE_PROOF_CHECKPOINT_RESPONSE_VERSION: "riddle-proof.checkpoint_response.v1";
5
5
  declare function statePathsForRunState(state: RiddleProofRunState, engineStatePath?: string | null): RiddleProofStatePaths;
6
+ declare function buildStageCheckpointPacket(input: {
7
+ request: RiddleProofRunParams;
8
+ runState: RiddleProofRunState;
9
+ engineResult: {
10
+ state_path?: string | null;
11
+ checkpoint?: string | null;
12
+ checkpointContract?: Record<string, unknown> | null;
13
+ decisionRequest?: Record<string, unknown> | null;
14
+ summary?: string;
15
+ stage?: string | null;
16
+ };
17
+ fullRiddleState?: Record<string, unknown> | null;
18
+ visibility?: "liveblog" | "quiet" | "terminal_only" | "manual" | string;
19
+ created_at?: string;
20
+ }): RiddleProofCheckpointPacket;
6
21
  declare function buildAuthorCheckpointPacket(input: {
7
22
  request: RiddleProofRunParams;
8
23
  runState: RiddleProofRunState;
@@ -52,4 +67,4 @@ declare function checkpointResponseIdentity(response: RiddleProofCheckpointRespo
52
67
  declare function authorPacketPayloadFromCheckpointResponse(response: RiddleProofCheckpointResponse): Record<string, unknown> | null;
53
68
  declare function proofContractFromAuthorCheckpointResponse(response: RiddleProofCheckpointResponse, packet: RiddleProofCheckpointPacket, payload: Record<string, unknown>): RiddleProofProofContract;
54
69
 
55
- export { RIDDLE_PROOF_CHECKPOINT_PACKET_VERSION, RIDDLE_PROOF_CHECKPOINT_RESPONSE_VERSION, authorPacketPayloadFromCheckpointResponse, buildAuthorCheckpointPacket, buildCheckpointPacketForEngineResult, buildProofAssessmentCheckpointPacket, checkpointResponseIdentity, checkpointSummaryFromState, isDuplicateCheckpointResponse, normalizeCheckpointResponse, proofContractFromAuthorCheckpointResponse, statePathsForRunState };
70
+ export { RIDDLE_PROOF_CHECKPOINT_PACKET_VERSION, RIDDLE_PROOF_CHECKPOINT_RESPONSE_VERSION, authorPacketPayloadFromCheckpointResponse, buildAuthorCheckpointPacket, buildCheckpointPacketForEngineResult, buildProofAssessmentCheckpointPacket, buildStageCheckpointPacket, checkpointResponseIdentity, checkpointSummaryFromState, isDuplicateCheckpointResponse, normalizeCheckpointResponse, proofContractFromAuthorCheckpointResponse, statePathsForRunState };
@@ -3,6 +3,21 @@ import { RiddleProofCheckpointResponse, RiddleProofRunParams, RiddleProofRunStat
3
3
  declare const RIDDLE_PROOF_CHECKPOINT_PACKET_VERSION: "riddle-proof.checkpoint.v1";
4
4
  declare const RIDDLE_PROOF_CHECKPOINT_RESPONSE_VERSION: "riddle-proof.checkpoint_response.v1";
5
5
  declare function statePathsForRunState(state: RiddleProofRunState, engineStatePath?: string | null): RiddleProofStatePaths;
6
+ declare function buildStageCheckpointPacket(input: {
7
+ request: RiddleProofRunParams;
8
+ runState: RiddleProofRunState;
9
+ engineResult: {
10
+ state_path?: string | null;
11
+ checkpoint?: string | null;
12
+ checkpointContract?: Record<string, unknown> | null;
13
+ decisionRequest?: Record<string, unknown> | null;
14
+ summary?: string;
15
+ stage?: string | null;
16
+ };
17
+ fullRiddleState?: Record<string, unknown> | null;
18
+ visibility?: "liveblog" | "quiet" | "terminal_only" | "manual" | string;
19
+ created_at?: string;
20
+ }): RiddleProofCheckpointPacket;
6
21
  declare function buildAuthorCheckpointPacket(input: {
7
22
  request: RiddleProofRunParams;
8
23
  runState: RiddleProofRunState;
@@ -52,4 +67,4 @@ declare function checkpointResponseIdentity(response: RiddleProofCheckpointRespo
52
67
  declare function authorPacketPayloadFromCheckpointResponse(response: RiddleProofCheckpointResponse): Record<string, unknown> | null;
53
68
  declare function proofContractFromAuthorCheckpointResponse(response: RiddleProofCheckpointResponse, packet: RiddleProofCheckpointPacket, payload: Record<string, unknown>): RiddleProofProofContract;
54
69
 
55
- export { RIDDLE_PROOF_CHECKPOINT_PACKET_VERSION, RIDDLE_PROOF_CHECKPOINT_RESPONSE_VERSION, authorPacketPayloadFromCheckpointResponse, buildAuthorCheckpointPacket, buildCheckpointPacketForEngineResult, buildProofAssessmentCheckpointPacket, checkpointResponseIdentity, checkpointSummaryFromState, isDuplicateCheckpointResponse, normalizeCheckpointResponse, proofContractFromAuthorCheckpointResponse, statePathsForRunState };
70
+ export { RIDDLE_PROOF_CHECKPOINT_PACKET_VERSION, RIDDLE_PROOF_CHECKPOINT_RESPONSE_VERSION, authorPacketPayloadFromCheckpointResponse, buildAuthorCheckpointPacket, buildCheckpointPacketForEngineResult, buildProofAssessmentCheckpointPacket, buildStageCheckpointPacket, checkpointResponseIdentity, checkpointSummaryFromState, isDuplicateCheckpointResponse, normalizeCheckpointResponse, proofContractFromAuthorCheckpointResponse, statePathsForRunState };
@@ -5,14 +5,15 @@ import {
5
5
  buildAuthorCheckpointPacket,
6
6
  buildCheckpointPacketForEngineResult,
7
7
  buildProofAssessmentCheckpointPacket,
8
+ buildStageCheckpointPacket,
8
9
  checkpointResponseIdentity,
9
10
  checkpointSummaryFromState,
10
11
  isDuplicateCheckpointResponse,
11
12
  normalizeCheckpointResponse,
12
13
  proofContractFromAuthorCheckpointResponse,
13
14
  statePathsForRunState
14
- } from "./chunk-LXE5YUYY.js";
15
- import "./chunk-W7VTDN4T.js";
15
+ } from "./chunk-R6SCWJCI.js";
16
+ import "./chunk-DUFDZJOF.js";
16
17
  export {
17
18
  RIDDLE_PROOF_CHECKPOINT_PACKET_VERSION,
18
19
  RIDDLE_PROOF_CHECKPOINT_RESPONSE_VERSION,
@@ -20,6 +21,7 @@ export {
20
21
  buildAuthorCheckpointPacket,
21
22
  buildCheckpointPacketForEngineResult,
22
23
  buildProofAssessmentCheckpointPacket,
24
+ buildStageCheckpointPacket,
23
25
  checkpointResponseIdentity,
24
26
  checkpointSummaryFromState,
25
27
  isDuplicateCheckpointResponse,
@@ -206,6 +206,7 @@ function createRunResult(input) {
206
206
  checkpoint_summary: state.checkpoint_summary,
207
207
  state_paths: state.state_paths,
208
208
  proof_contract: state.proof_contract,
209
+ run_card: state.run_card,
209
210
  proof_session: state.proof_session,
210
211
  evidence_bundle: input.evidence_bundle,
211
212
  raw: input.raw
@@ -1,9 +1,12 @@
1
+ import {
2
+ createRiddleProofRunCard
3
+ } from "./chunk-PLSGW2GI.js";
1
4
  import {
2
5
  compactRecord,
3
6
  isTerminalStatus,
4
7
  nonEmptyString,
5
8
  recordValue
6
- } from "./chunk-W7VTDN4T.js";
9
+ } from "./chunk-DUFDZJOF.js";
7
10
 
8
11
  // src/state.ts
9
12
  var RIDDLE_PROOF_RUN_STATE_VERSION = "riddle-proof.run-state.v1";
@@ -131,6 +134,7 @@ function createRunState(input) {
131
134
  checkpoint_summary: input.checkpoint_summary,
132
135
  state_paths: input.state_paths,
133
136
  proof_contract: input.proof_contract,
137
+ run_card: input.run_card,
134
138
  checkpoint_history: input.checkpoint_history,
135
139
  events: input.events ? [...input.events] : []
136
140
  });
@@ -209,6 +213,7 @@ function createRunStatusSnapshot(state, at = timestamp()) {
209
213
  checkpoint_summary: state.checkpoint_summary,
210
214
  state_paths: state.state_paths,
211
215
  proof_contract: state.proof_contract,
216
+ run_card: createRiddleProofRunCard(state, { at }),
212
217
  latest_event: latestEvent
213
218
  });
214
219
  }
@@ -3,10 +3,10 @@ import {
3
3
  appendStageHeartbeat,
4
4
  createRunState,
5
5
  setRunStatus
6
- } from "./chunk-7S7O3NKF.js";
6
+ } from "./chunk-JTNMEH57.js";
7
7
  import {
8
8
  createRunResult
9
- } from "./chunk-W7VTDN4T.js";
9
+ } from "./chunk-DUFDZJOF.js";
10
10
 
11
11
  // src/runner.ts
12
12
  function errorDetails(error) {