@riddledc/riddle-proof 0.7.215 → 0.7.217

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 (3) hide show
  1. package/dist/cli.cjs +120 -9
  2. package/dist/cli.js +120 -9
  3. package/package.json +1 -1
package/dist/cli.cjs CHANGED
@@ -17231,6 +17231,72 @@ function profileHasRecoveredStateReceipt(receipts) {
17231
17231
  return hasRecoveredState || success || hasValid && hasInvalid === false || leftTerminalState && retrySurfaceReady;
17232
17232
  });
17233
17233
  }
17234
+ function profileHasSequenceInputReceipt(receipts) {
17235
+ let hasSequenceContract = false;
17236
+ let hasInputReadyState = false;
17237
+ let hasSequenceOutcome = false;
17238
+ for (const receipt of receipts) {
17239
+ const storedTo = cliString(receipt.return_stored_to) || "";
17240
+ const label = cliString(receipt.label) || "";
17241
+ const path7 = cliString(receipt.path) || cliString(receipt.function_name) || "";
17242
+ const slot = profileLowerSummaryValue(receipt, ["slot", "phase", "state"]);
17243
+ const statusText = profileLowerSummaryValue(receipt, ["statusText", "status", "message"]);
17244
+ const summary = cliReturnSummaryLabel(receipt.return_summary) || "";
17245
+ const haystack = `${storedTo} ${label} ${path7} ${slot} ${statusText} ${summary}`.toLowerCase();
17246
+ const sequenceText = [
17247
+ "expectedSequence",
17248
+ "expectedLevel2Sequence",
17249
+ "inputSequence",
17250
+ "targetSequence",
17251
+ "sequence",
17252
+ "pattern"
17253
+ ].map((name) => cliString(setupReturnSummaryValue(receipt, [name]))?.toLowerCase()).find(Boolean) || "";
17254
+ const sequenceArray = [
17255
+ setupReturnSummaryValue(receipt, ["expectedSequence"]),
17256
+ setupReturnSummaryValue(receipt, ["expectedLevel2Sequence"]),
17257
+ setupReturnSummaryValue(receipt, ["inputSequence"]),
17258
+ setupReturnSummaryValue(receipt, ["targetSequence"]),
17259
+ setupReturnSummaryValue(receipt, ["sequence"])
17260
+ ].some((value) => Array.isArray(value) && value.length > 0);
17261
+ const mentionsSequence = Boolean(sequenceArray || sequenceText) || haystack.includes("sequence") || haystack.includes("short-long") || haystack.includes("short,long") || haystack.includes("short long") || haystack.includes("long-short") || haystack.includes("long,short") || haystack.includes("long short");
17262
+ if (mentionsSequence) hasSequenceContract = true;
17263
+ const level = cliFiniteNumber(setupReturnSummaryValue(receipt, ["level"]));
17264
+ const expectedSteps = cliFiniteNumber(setupReturnSummaryValue(receipt, ["expectedSteps", "stepCount", "sequenceLength"]));
17265
+ const controlsEnabled = setupReturnSummaryValue(receipt, ["controlsEnabled", "inputControlsEnabled", "inputEnabled", "canInput"]) === true || setupReturnSummaryValue(receipt, ["shortDisabled"]) === false || setupReturnSummaryValue(receipt, ["longDisabled"]) === false;
17266
+ const inputReady = haystack.includes("input") || statusText.includes("your turn") || statusText.includes("ready");
17267
+ if (inputReady && (controlsEnabled || level !== void 0 || expectedSteps !== void 0)) {
17268
+ hasInputReadyState = true;
17269
+ }
17270
+ const success = setupReturnSummaryValue(receipt, ["success", "passed"]) === true || statusText.includes("perfect") || statusText.includes("success");
17271
+ const failure = statusText.includes("miss") || statusText.includes("failure") || setupReturnSummaryValue(receipt, ["failed"]) === true;
17272
+ const streak = cliFiniteNumber(setupReturnSummaryValue(receipt, ["streak"]));
17273
+ const best = cliFiniteNumber(setupReturnSummaryValue(receipt, ["best"]));
17274
+ if (mentionsSequence && (success || failure || streak !== void 0 || best !== void 0)) {
17275
+ hasSequenceOutcome = true;
17276
+ }
17277
+ }
17278
+ return hasSequenceContract && (hasInputReadyState || hasSequenceOutcome);
17279
+ }
17280
+ function profileHasRestartReadyReceipt(receipts) {
17281
+ return receipts.some((receipt) => {
17282
+ const storedTo = cliString(receipt.return_stored_to) || "";
17283
+ const label = cliString(receipt.label) || "";
17284
+ const path7 = cliString(receipt.path) || cliString(receipt.function_name) || "";
17285
+ const slot = profileLowerSummaryValue(receipt, ["slot", "phase", "state"]);
17286
+ const statusText = profileLowerSummaryValue(receipt, ["statusText", "status", "message"]);
17287
+ const summary = cliReturnSummaryLabel(receipt.return_summary) || "";
17288
+ const haystack = `${storedTo} ${label} ${path7} ${slot} ${statusText} ${summary}`.toLowerCase();
17289
+ const labelsRestart = haystack.includes("restart") || haystack.includes("play again") || haystack.includes("play-again") || haystack.includes("playagain") || haystack.includes("retry");
17290
+ if (!labelsRestart) return false;
17291
+ const ok = receipt.ok !== false && setupReturnSummaryValue(receipt, ["ok"]) !== false;
17292
+ const controlsEnabled = setupReturnSummaryValue(receipt, ["controlsEnabled", "inputControlsEnabled", "inputEnabled", "canInput"]) === true || setupReturnSummaryValue(receipt, ["shortDisabled"]) === false && setupReturnSummaryValue(receipt, ["longDisabled"]) === false;
17293
+ const level = cliFiniteNumber(setupReturnSummaryValue(receipt, ["level"]));
17294
+ const streak = cliFiniteNumber(setupReturnSummaryValue(receipt, ["streak"]));
17295
+ const best = cliFiniteNumber(setupReturnSummaryValue(receipt, ["best"]));
17296
+ const readyState = statusText.includes("your turn") || statusText.includes("ready") || setupReturnSummaryValue(receipt, ["ready", "restartReady", "restart_ready"]) === true;
17297
+ return ok && controlsEnabled && (readyState || level !== void 0 || streak !== void 0 || best !== void 0);
17298
+ });
17299
+ }
17234
17300
  function profileMetadataHasGeneratedOutputContract(metadata) {
17235
17301
  const contract = cliRecord(metadata.declared_state_contract);
17236
17302
  if (!contract) return false;
@@ -17279,6 +17345,7 @@ function profilePackReceiptStatus(result, metadata, receipt) {
17279
17345
  const valueReceipts = [
17280
17346
  ...setupViewports.flatMap((viewport) => setupReceiptArray(viewport, "window_eval")),
17281
17347
  ...setupViewports.flatMap((viewport) => setupReceiptArray(viewport, "window_call")),
17348
+ ...setupViewports.flatMap((viewport) => setupReceiptArray(viewport, "window_call_until")),
17282
17349
  ...setupActionValueReceipts
17283
17350
  ].filter((item) => item.ok !== false);
17284
17351
  const clickCount = setupViewports.reduce((sum, viewport) => sum + (cliFiniteNumber(viewport.clicked_total) || 0), 0) + profileSetupReceiptTotal(setupViewports, "click") + profileSetupReceiptTotal(setupViewports, "click_count");
@@ -17336,6 +17403,34 @@ function profilePackReceiptStatus(result, metadata, receipt) {
17336
17403
  const after = cliFiniteNumber(setupReturnSummaryValue(item, ["after", "afterCount", "itemCount", "count"]));
17337
17404
  return before !== void 0 && after !== void 0 && after > before;
17338
17405
  });
17406
+ const stateGrowthMetricNames = [
17407
+ "best",
17408
+ "streak",
17409
+ "score",
17410
+ "level",
17411
+ "progress",
17412
+ "coins",
17413
+ "totalCoins",
17414
+ "totalEarned",
17415
+ "saveTotalCoins",
17416
+ "saveTotalClicks",
17417
+ "perClick",
17418
+ "perSecond",
17419
+ "clickPowerLevel",
17420
+ "autoClickerLevel"
17421
+ ];
17422
+ const hasPositiveStateGrowthMetric = valueReceipts.some((item) => stateGrowthMetricNames.some((name) => {
17423
+ const storedTo = cliString(item.return_stored_to) || "";
17424
+ const label = cliString(item.label) || "";
17425
+ const path7 = cliString(item.path) || cliString(item.function_name) || "";
17426
+ const slot = profileLowerSummaryValue(item, ["slot", "phase", "state"]);
17427
+ const statusText = profileLowerSummaryValue(item, ["statusText", "status", "message"]);
17428
+ const haystack = `${storedTo} ${label} ${path7} ${slot} ${statusText}`.toLowerCase();
17429
+ const stateGrowthOutcome = haystack.includes("growth") || haystack.includes("success") || haystack.includes("after") || haystack.includes("add") || haystack.includes("upgrade") || haystack.includes("bought") || haystack.includes("perfect") || setupReturnSummaryValue(item, ["success", "passed"]) === true;
17430
+ if (!stateGrowthOutcome) return false;
17431
+ const value = cliFiniteNumber(setupReturnSummaryValue(item, [name]));
17432
+ return value !== void 0 && value > 0;
17433
+ }));
17339
17434
  const hasReachability = profileReachabilitySummaryMarkdown(result).length > 0 || result.checks.some((check) => check.type === "selector_visible" && Boolean(cliRecord(check.evidence)?.selector));
17340
17435
  const hasOverflowEvidence = result.checks.some((check) => check.type === "no_horizontal_overflow" || check.type === "no_mobile_horizontal_overflow" || check.type === "frame_no_horizontal_overflow") || evidenceViewports.some((viewport) => (cliFiniteNumber(viewport.overflow_px) || 0) > 0 || (cliFiniteNumber(viewport.bounds_overflow_px) || 0) > 0 || Boolean(viewport.overflow_offenders?.length));
17341
17436
  const hasConsoleAccounting = profileHasCheck(result, ["no_console_warnings", "no_fatal_console_errors"]) || Boolean(result.evidence?.console || result.evidence?.page_errors);
@@ -17422,6 +17517,8 @@ function profilePackReceiptStatus(result, metadata, receipt) {
17422
17517
  const hasControlledSuccessLaunchReceipt = profileHasControlledLaunchReceipt(valueReceipts, "success");
17423
17518
  const hasRouteContinuationReceipt = profileHasRouteContinuationReceipt(valueReceipts);
17424
17519
  const hasRecoveredStateReceipt = profileHasRecoveredStateReceipt(valueReceipts);
17520
+ const hasSequenceInputReceipt = profileHasSequenceInputReceipt(valueReceipts) && (inputDispatchCount > 0 || hasNaturalInput);
17521
+ const hasRestartReadyReceipt = profileHasRestartReadyReceipt(valueReceipts);
17425
17522
  const hasGeneratedOutputContract = profileMetadataHasGeneratedOutputContract(metadata);
17426
17523
  const hasGeneratedOutputReceipt = profileHasGeneratedOutputReceipt(valueReceipts);
17427
17524
  const failedCleanupInventoryReason = profileFailedCleanupInventoryReason(setupViewports);
@@ -17589,6 +17686,28 @@ function profilePackReceiptStatus(result, metadata, receipt) {
17589
17686
  "visible cleanup affordance receipt missing"
17590
17687
  );
17591
17688
  }
17689
+ if (text.includes("screenshot")) {
17690
+ const needsBoundaryScreenshots = text.includes("each") || text.includes("before and after") || text.includes("state boundary");
17691
+ return profileReceiptSignalStatus(
17692
+ needsBoundaryScreenshots ? screenshotCount >= 2 : screenshotCount > 0,
17693
+ needsBoundaryScreenshots ? "multiple screenshots present" : "screenshot evidence present",
17694
+ needsBoundaryScreenshots ? "multiple screenshots missing" : "screenshot evidence missing"
17695
+ );
17696
+ }
17697
+ if (text.includes("input") && (text.includes("sequence") || text.includes("short-long") || text.includes("short long") || text.includes("long-short") || text.includes("long long") || text.includes("long short"))) {
17698
+ return profileReceiptSignalStatus(
17699
+ hasSequenceInputReceipt,
17700
+ "sequence input receipt present",
17701
+ "sequence input receipt missing"
17702
+ );
17703
+ }
17704
+ if (text.includes("restart") && (text.includes("receipt") || text.includes("ready") || text.includes("re-enabled") || text.includes("controls"))) {
17705
+ return profileReceiptSignalStatus(
17706
+ hasRestartReadyReceipt,
17707
+ "restart-ready receipt present",
17708
+ "restart-ready receipt missing"
17709
+ );
17710
+ }
17592
17711
  if (text.includes("retry") || text.includes("repair") || text.includes("reset") || text.includes("affordance")) {
17593
17712
  return profileReceiptSignalStatus(hasStateContract || clickCount > 0, "affordance or transition receipt present", "affordance receipt missing");
17594
17713
  }
@@ -17599,7 +17718,7 @@ function profilePackReceiptStatus(result, metadata, receipt) {
17599
17718
  return profileReceiptSignalStatus(hasTextVisibility || screenshotCount > 0, "initial visible-state evidence present", "initial state evidence missing");
17600
17719
  }
17601
17720
  if (text.includes("state-growth") || text.includes("state growth") || text.includes("growth receipt") || text.includes("grid grows") || text.includes("state") && text.includes("after the click")) {
17602
- return profileReceiptSignalStatus(hasStateGrowthReceipt, "state-growth receipt present", "state-growth receipt missing");
17721
+ return profileReceiptSignalStatus(hasStateGrowthReceipt || hasPositiveStateGrowthMetric, "state-growth receipt present", "state-growth receipt missing");
17603
17722
  }
17604
17723
  if (text.includes("visible grid") || text.includes("control evidence") || text.includes("grid") && text.includes("control")) {
17605
17724
  return profileReceiptSignalStatus(
@@ -17637,14 +17756,6 @@ function profilePackReceiptStatus(result, metadata, receipt) {
17637
17756
  "before/after state evidence missing"
17638
17757
  );
17639
17758
  }
17640
- if (text.includes("screenshot")) {
17641
- const needsBoundaryScreenshots = text.includes("each") || text.includes("before and after") || text.includes("state boundary");
17642
- return profileReceiptSignalStatus(
17643
- needsBoundaryScreenshots ? screenshotCount >= 2 : screenshotCount > 0,
17644
- needsBoundaryScreenshots ? "multiple screenshots present" : "screenshot evidence present",
17645
- needsBoundaryScreenshots ? "multiple screenshots missing" : "screenshot evidence missing"
17646
- );
17647
- }
17648
17759
  if (text.includes("input") && (text.includes("playability") || text.includes("moving") || text.includes("steering") || text.includes("real") || text.includes("natural"))) {
17649
17760
  const needsAcceptedInput = text.includes("steering") || text.includes("accepted");
17650
17761
  const hasInputDispatch = inputDispatchCount > 0 || hasNaturalInput;
package/dist/cli.js CHANGED
@@ -991,6 +991,72 @@ function profileHasRecoveredStateReceipt(receipts) {
991
991
  return hasRecoveredState || success || hasValid && hasInvalid === false || leftTerminalState && retrySurfaceReady;
992
992
  });
993
993
  }
994
+ function profileHasSequenceInputReceipt(receipts) {
995
+ let hasSequenceContract = false;
996
+ let hasInputReadyState = false;
997
+ let hasSequenceOutcome = false;
998
+ for (const receipt of receipts) {
999
+ const storedTo = cliString(receipt.return_stored_to) || "";
1000
+ const label = cliString(receipt.label) || "";
1001
+ const path2 = cliString(receipt.path) || cliString(receipt.function_name) || "";
1002
+ const slot = profileLowerSummaryValue(receipt, ["slot", "phase", "state"]);
1003
+ const statusText = profileLowerSummaryValue(receipt, ["statusText", "status", "message"]);
1004
+ const summary = cliReturnSummaryLabel(receipt.return_summary) || "";
1005
+ const haystack = `${storedTo} ${label} ${path2} ${slot} ${statusText} ${summary}`.toLowerCase();
1006
+ const sequenceText = [
1007
+ "expectedSequence",
1008
+ "expectedLevel2Sequence",
1009
+ "inputSequence",
1010
+ "targetSequence",
1011
+ "sequence",
1012
+ "pattern"
1013
+ ].map((name) => cliString(setupReturnSummaryValue(receipt, [name]))?.toLowerCase()).find(Boolean) || "";
1014
+ const sequenceArray = [
1015
+ setupReturnSummaryValue(receipt, ["expectedSequence"]),
1016
+ setupReturnSummaryValue(receipt, ["expectedLevel2Sequence"]),
1017
+ setupReturnSummaryValue(receipt, ["inputSequence"]),
1018
+ setupReturnSummaryValue(receipt, ["targetSequence"]),
1019
+ setupReturnSummaryValue(receipt, ["sequence"])
1020
+ ].some((value) => Array.isArray(value) && value.length > 0);
1021
+ const mentionsSequence = Boolean(sequenceArray || sequenceText) || haystack.includes("sequence") || haystack.includes("short-long") || haystack.includes("short,long") || haystack.includes("short long") || haystack.includes("long-short") || haystack.includes("long,short") || haystack.includes("long short");
1022
+ if (mentionsSequence) hasSequenceContract = true;
1023
+ const level = cliFiniteNumber(setupReturnSummaryValue(receipt, ["level"]));
1024
+ const expectedSteps = cliFiniteNumber(setupReturnSummaryValue(receipt, ["expectedSteps", "stepCount", "sequenceLength"]));
1025
+ const controlsEnabled = setupReturnSummaryValue(receipt, ["controlsEnabled", "inputControlsEnabled", "inputEnabled", "canInput"]) === true || setupReturnSummaryValue(receipt, ["shortDisabled"]) === false || setupReturnSummaryValue(receipt, ["longDisabled"]) === false;
1026
+ const inputReady = haystack.includes("input") || statusText.includes("your turn") || statusText.includes("ready");
1027
+ if (inputReady && (controlsEnabled || level !== void 0 || expectedSteps !== void 0)) {
1028
+ hasInputReadyState = true;
1029
+ }
1030
+ const success = setupReturnSummaryValue(receipt, ["success", "passed"]) === true || statusText.includes("perfect") || statusText.includes("success");
1031
+ const failure = statusText.includes("miss") || statusText.includes("failure") || setupReturnSummaryValue(receipt, ["failed"]) === true;
1032
+ const streak = cliFiniteNumber(setupReturnSummaryValue(receipt, ["streak"]));
1033
+ const best = cliFiniteNumber(setupReturnSummaryValue(receipt, ["best"]));
1034
+ if (mentionsSequence && (success || failure || streak !== void 0 || best !== void 0)) {
1035
+ hasSequenceOutcome = true;
1036
+ }
1037
+ }
1038
+ return hasSequenceContract && (hasInputReadyState || hasSequenceOutcome);
1039
+ }
1040
+ function profileHasRestartReadyReceipt(receipts) {
1041
+ return receipts.some((receipt) => {
1042
+ const storedTo = cliString(receipt.return_stored_to) || "";
1043
+ const label = cliString(receipt.label) || "";
1044
+ const path2 = cliString(receipt.path) || cliString(receipt.function_name) || "";
1045
+ const slot = profileLowerSummaryValue(receipt, ["slot", "phase", "state"]);
1046
+ const statusText = profileLowerSummaryValue(receipt, ["statusText", "status", "message"]);
1047
+ const summary = cliReturnSummaryLabel(receipt.return_summary) || "";
1048
+ const haystack = `${storedTo} ${label} ${path2} ${slot} ${statusText} ${summary}`.toLowerCase();
1049
+ const labelsRestart = haystack.includes("restart") || haystack.includes("play again") || haystack.includes("play-again") || haystack.includes("playagain") || haystack.includes("retry");
1050
+ if (!labelsRestart) return false;
1051
+ const ok = receipt.ok !== false && setupReturnSummaryValue(receipt, ["ok"]) !== false;
1052
+ const controlsEnabled = setupReturnSummaryValue(receipt, ["controlsEnabled", "inputControlsEnabled", "inputEnabled", "canInput"]) === true || setupReturnSummaryValue(receipt, ["shortDisabled"]) === false && setupReturnSummaryValue(receipt, ["longDisabled"]) === false;
1053
+ const level = cliFiniteNumber(setupReturnSummaryValue(receipt, ["level"]));
1054
+ const streak = cliFiniteNumber(setupReturnSummaryValue(receipt, ["streak"]));
1055
+ const best = cliFiniteNumber(setupReturnSummaryValue(receipt, ["best"]));
1056
+ const readyState = statusText.includes("your turn") || statusText.includes("ready") || setupReturnSummaryValue(receipt, ["ready", "restartReady", "restart_ready"]) === true;
1057
+ return ok && controlsEnabled && (readyState || level !== void 0 || streak !== void 0 || best !== void 0);
1058
+ });
1059
+ }
994
1060
  function profileMetadataHasGeneratedOutputContract(metadata) {
995
1061
  const contract = cliRecord(metadata.declared_state_contract);
996
1062
  if (!contract) return false;
@@ -1039,6 +1105,7 @@ function profilePackReceiptStatus(result, metadata, receipt) {
1039
1105
  const valueReceipts = [
1040
1106
  ...setupViewports.flatMap((viewport) => setupReceiptArray(viewport, "window_eval")),
1041
1107
  ...setupViewports.flatMap((viewport) => setupReceiptArray(viewport, "window_call")),
1108
+ ...setupViewports.flatMap((viewport) => setupReceiptArray(viewport, "window_call_until")),
1042
1109
  ...setupActionValueReceipts
1043
1110
  ].filter((item) => item.ok !== false);
1044
1111
  const clickCount = setupViewports.reduce((sum, viewport) => sum + (cliFiniteNumber(viewport.clicked_total) || 0), 0) + profileSetupReceiptTotal(setupViewports, "click") + profileSetupReceiptTotal(setupViewports, "click_count");
@@ -1096,6 +1163,34 @@ function profilePackReceiptStatus(result, metadata, receipt) {
1096
1163
  const after = cliFiniteNumber(setupReturnSummaryValue(item, ["after", "afterCount", "itemCount", "count"]));
1097
1164
  return before !== void 0 && after !== void 0 && after > before;
1098
1165
  });
1166
+ const stateGrowthMetricNames = [
1167
+ "best",
1168
+ "streak",
1169
+ "score",
1170
+ "level",
1171
+ "progress",
1172
+ "coins",
1173
+ "totalCoins",
1174
+ "totalEarned",
1175
+ "saveTotalCoins",
1176
+ "saveTotalClicks",
1177
+ "perClick",
1178
+ "perSecond",
1179
+ "clickPowerLevel",
1180
+ "autoClickerLevel"
1181
+ ];
1182
+ const hasPositiveStateGrowthMetric = valueReceipts.some((item) => stateGrowthMetricNames.some((name) => {
1183
+ const storedTo = cliString(item.return_stored_to) || "";
1184
+ const label = cliString(item.label) || "";
1185
+ const path2 = cliString(item.path) || cliString(item.function_name) || "";
1186
+ const slot = profileLowerSummaryValue(item, ["slot", "phase", "state"]);
1187
+ const statusText = profileLowerSummaryValue(item, ["statusText", "status", "message"]);
1188
+ const haystack = `${storedTo} ${label} ${path2} ${slot} ${statusText}`.toLowerCase();
1189
+ const stateGrowthOutcome = haystack.includes("growth") || haystack.includes("success") || haystack.includes("after") || haystack.includes("add") || haystack.includes("upgrade") || haystack.includes("bought") || haystack.includes("perfect") || setupReturnSummaryValue(item, ["success", "passed"]) === true;
1190
+ if (!stateGrowthOutcome) return false;
1191
+ const value = cliFiniteNumber(setupReturnSummaryValue(item, [name]));
1192
+ return value !== void 0 && value > 0;
1193
+ }));
1099
1194
  const hasReachability = profileReachabilitySummaryMarkdown(result).length > 0 || result.checks.some((check) => check.type === "selector_visible" && Boolean(cliRecord(check.evidence)?.selector));
1100
1195
  const hasOverflowEvidence = result.checks.some((check) => check.type === "no_horizontal_overflow" || check.type === "no_mobile_horizontal_overflow" || check.type === "frame_no_horizontal_overflow") || evidenceViewports.some((viewport) => (cliFiniteNumber(viewport.overflow_px) || 0) > 0 || (cliFiniteNumber(viewport.bounds_overflow_px) || 0) > 0 || Boolean(viewport.overflow_offenders?.length));
1101
1196
  const hasConsoleAccounting = profileHasCheck(result, ["no_console_warnings", "no_fatal_console_errors"]) || Boolean(result.evidence?.console || result.evidence?.page_errors);
@@ -1182,6 +1277,8 @@ function profilePackReceiptStatus(result, metadata, receipt) {
1182
1277
  const hasControlledSuccessLaunchReceipt = profileHasControlledLaunchReceipt(valueReceipts, "success");
1183
1278
  const hasRouteContinuationReceipt = profileHasRouteContinuationReceipt(valueReceipts);
1184
1279
  const hasRecoveredStateReceipt = profileHasRecoveredStateReceipt(valueReceipts);
1280
+ const hasSequenceInputReceipt = profileHasSequenceInputReceipt(valueReceipts) && (inputDispatchCount > 0 || hasNaturalInput);
1281
+ const hasRestartReadyReceipt = profileHasRestartReadyReceipt(valueReceipts);
1185
1282
  const hasGeneratedOutputContract = profileMetadataHasGeneratedOutputContract(metadata);
1186
1283
  const hasGeneratedOutputReceipt = profileHasGeneratedOutputReceipt(valueReceipts);
1187
1284
  const failedCleanupInventoryReason = profileFailedCleanupInventoryReason(setupViewports);
@@ -1349,6 +1446,28 @@ function profilePackReceiptStatus(result, metadata, receipt) {
1349
1446
  "visible cleanup affordance receipt missing"
1350
1447
  );
1351
1448
  }
1449
+ if (text.includes("screenshot")) {
1450
+ const needsBoundaryScreenshots = text.includes("each") || text.includes("before and after") || text.includes("state boundary");
1451
+ return profileReceiptSignalStatus(
1452
+ needsBoundaryScreenshots ? screenshotCount >= 2 : screenshotCount > 0,
1453
+ needsBoundaryScreenshots ? "multiple screenshots present" : "screenshot evidence present",
1454
+ needsBoundaryScreenshots ? "multiple screenshots missing" : "screenshot evidence missing"
1455
+ );
1456
+ }
1457
+ if (text.includes("input") && (text.includes("sequence") || text.includes("short-long") || text.includes("short long") || text.includes("long-short") || text.includes("long long") || text.includes("long short"))) {
1458
+ return profileReceiptSignalStatus(
1459
+ hasSequenceInputReceipt,
1460
+ "sequence input receipt present",
1461
+ "sequence input receipt missing"
1462
+ );
1463
+ }
1464
+ if (text.includes("restart") && (text.includes("receipt") || text.includes("ready") || text.includes("re-enabled") || text.includes("controls"))) {
1465
+ return profileReceiptSignalStatus(
1466
+ hasRestartReadyReceipt,
1467
+ "restart-ready receipt present",
1468
+ "restart-ready receipt missing"
1469
+ );
1470
+ }
1352
1471
  if (text.includes("retry") || text.includes("repair") || text.includes("reset") || text.includes("affordance")) {
1353
1472
  return profileReceiptSignalStatus(hasStateContract || clickCount > 0, "affordance or transition receipt present", "affordance receipt missing");
1354
1473
  }
@@ -1359,7 +1478,7 @@ function profilePackReceiptStatus(result, metadata, receipt) {
1359
1478
  return profileReceiptSignalStatus(hasTextVisibility || screenshotCount > 0, "initial visible-state evidence present", "initial state evidence missing");
1360
1479
  }
1361
1480
  if (text.includes("state-growth") || text.includes("state growth") || text.includes("growth receipt") || text.includes("grid grows") || text.includes("state") && text.includes("after the click")) {
1362
- return profileReceiptSignalStatus(hasStateGrowthReceipt, "state-growth receipt present", "state-growth receipt missing");
1481
+ return profileReceiptSignalStatus(hasStateGrowthReceipt || hasPositiveStateGrowthMetric, "state-growth receipt present", "state-growth receipt missing");
1363
1482
  }
1364
1483
  if (text.includes("visible grid") || text.includes("control evidence") || text.includes("grid") && text.includes("control")) {
1365
1484
  return profileReceiptSignalStatus(
@@ -1397,14 +1516,6 @@ function profilePackReceiptStatus(result, metadata, receipt) {
1397
1516
  "before/after state evidence missing"
1398
1517
  );
1399
1518
  }
1400
- if (text.includes("screenshot")) {
1401
- const needsBoundaryScreenshots = text.includes("each") || text.includes("before and after") || text.includes("state boundary");
1402
- return profileReceiptSignalStatus(
1403
- needsBoundaryScreenshots ? screenshotCount >= 2 : screenshotCount > 0,
1404
- needsBoundaryScreenshots ? "multiple screenshots present" : "screenshot evidence present",
1405
- needsBoundaryScreenshots ? "multiple screenshots missing" : "screenshot evidence missing"
1406
- );
1407
- }
1408
1519
  if (text.includes("input") && (text.includes("playability") || text.includes("moving") || text.includes("steering") || text.includes("real") || text.includes("natural"))) {
1409
1520
  const needsAcceptedInput = text.includes("steering") || text.includes("accepted");
1410
1521
  const hasInputDispatch = inputDispatchCount > 0 || hasNaturalInput;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@riddledc/riddle-proof",
3
- "version": "0.7.215",
3
+ "version": "0.7.217",
4
4
  "description": "Reusable Riddle Proof contracts and helpers for evidence-backed agent changes.",
5
5
  "license": "MIT",
6
6
  "author": "RiddleDC",