@resolveio/server-lib 22.3.214 → 22.3.216

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@resolveio/server-lib",
3
- "version": "22.3.214",
3
+ "version": "22.3.216",
4
4
  "description": "",
5
5
  "scripts": {
6
6
  "package": "./build_package.sh",
@@ -130,7 +130,7 @@ function cleanListEntryText(value, max) {
130
130
  if (value && typeof value === 'object' && !Array.isArray(value)) {
131
131
  var source = value;
132
132
  var hypothesis = cleanListEntryText(source.hypothesis, Math.floor(max / 2));
133
- var whyRejected = cleanListEntryText(source.why_rejected || source.whyRejected || source.reason_rejected || source.reasonRejected || source.reason, Math.floor(max / 2));
133
+ var whyRejected = cleanListEntryText(source.why_rejected || source.whyRejected || source.reason_rejected || source.reasonRejected || source.rejection_reason || source.rejectionReason || source.reason, Math.floor(max / 2));
134
134
  if (hypothesis && whyRejected) {
135
135
  return "".concat(hypothesis, " rejected because ").concat(whyRejected).slice(0, max);
136
136
  }
@@ -148,13 +148,29 @@ function cleanListEntryText(value, max) {
148
148
  'source_file',
149
149
  'artifactPath',
150
150
  'artifact_path',
151
+ 'request_classification',
152
+ 'requestClassification',
153
+ 'classification_rationale',
154
+ 'classificationRationale',
155
+ 'behavior_type',
156
+ 'behaviorType',
151
157
  'summary',
152
158
  'detail',
153
159
  'message',
154
160
  'description',
161
+ 'rationale',
155
162
  'proof_required',
156
163
  'proofRequired',
164
+ 'reported',
165
+ 'verified',
166
+ 'reported_path',
167
+ 'reportedPath',
168
+ 'verified_path',
169
+ 'verifiedPath',
170
+ 'rejection_reason',
171
+ 'rejectionReason',
157
172
  'reason',
173
+ 'fact',
158
174
  'value',
159
175
  'label',
160
176
  'id'
@@ -934,6 +950,10 @@ function normalizeIssueClass(value) {
934
950
  customer_inquiry: 'missing_wrong_data',
935
951
  data_mismatch: 'missing_wrong_data',
936
952
  warehouse_mismatch: 'missing_wrong_data',
953
+ data_visibility_mapping: 'missing_wrong_data',
954
+ data_mapping: 'missing_wrong_data',
955
+ visibility_mapping: 'missing_wrong_data',
956
+ display_mapping: 'missing_wrong_data',
937
957
  route_auth: 'route_auth_hydration',
938
958
  auth_hydration: 'route_auth_hydration',
939
959
  route_auth_hydration: 'route_auth_hydration',
@@ -946,7 +966,13 @@ function normalizeIssueClass(value) {
946
966
  requested_behavior_change: 'missing_wrong_data',
947
967
  new_feature: 'missing_wrong_data'
948
968
  };
949
- return aliases[normalized] || '';
969
+ if (aliases[normalized]) {
970
+ return aliases[normalized];
971
+ }
972
+ if (/\b(data|field|value|visibility|mapping|display|warehouse|quantity|inventory)\b/i.test(normalized)) {
973
+ return 'missing_wrong_data';
974
+ }
975
+ return '';
950
976
  }
951
977
  function normalizeReproductionStatus(value) {
952
978
  var normalized = cleanText(value, 80).toLowerCase();
@@ -1047,7 +1073,7 @@ function normalizeSupportDiagnosisEvidence(values, ownerFiles) {
1047
1073
  .map(function (entry) {
1048
1074
  var type = cleanText(entry.type, 80).toLowerCase();
1049
1075
  var artifactPath = cleanText(entry.artifactPath || entry.artifact_path || entry.path || entry.file, 500);
1050
- var summary = cleanText(entry.summary || entry.detail || entry.message || entry.evidence || entry.reason || entry.fact || entry.description || entry.proof_required || entry.proofRequired, 1200)
1076
+ var summary = cleanText(entry.summary || entry.detail || entry.message || entry.evidence || entry.reason || entry.rejection_reason || entry.rejectionReason || entry.fact || entry.description || entry.proof_required || entry.proofRequired, 1200)
1051
1077
  || (artifactPath ? "Evidence from ".concat(artifactPath) : '');
1052
1078
  var evidenceText = [summary, artifactPath].filter(Boolean).join(' ');
1053
1079
  var inferredType = (function () {
@@ -1746,14 +1772,21 @@ function supportDiagnosisNarrativeText(value, max) {
1746
1772
  return '';
1747
1773
  }
1748
1774
  var hypothesis = cleanText(source.hypothesis, Math.floor(max / 2));
1749
- var whyRejected = cleanText(source.why_rejected || source.whyRejected || source.reason_rejected || source.reasonRejected || source.reason, Math.floor(max / 2));
1775
+ var whyRejected = cleanText(source.why_rejected || source.whyRejected || source.reason_rejected || source.reasonRejected || source.rejection_reason || source.rejectionReason || source.reason, Math.floor(max / 2));
1750
1776
  if (hypothesis && whyRejected) {
1751
1777
  return "".concat(hypothesis, " rejected because ").concat(whyRejected).slice(0, max);
1752
1778
  }
1753
1779
  var direct = pickText(source, [
1780
+ 'request_classification',
1781
+ 'requestClassification',
1782
+ 'classification_rationale',
1783
+ 'classificationRationale',
1784
+ 'behavior_type',
1785
+ 'behaviorType',
1754
1786
  'summary',
1755
1787
  'detail',
1756
1788
  'description',
1789
+ 'rationale',
1757
1790
  'statement',
1758
1791
  'issue_case',
1759
1792
  'issueCase',
@@ -1766,10 +1799,18 @@ function supportDiagnosisNarrativeText(value, max) {
1766
1799
  'route',
1767
1800
  'path_chain',
1768
1801
  'pathChain',
1802
+ 'reported',
1803
+ 'verified',
1804
+ 'reported_path',
1805
+ 'reportedPath',
1806
+ 'verified_path',
1807
+ 'verifiedPath',
1769
1808
  'assessment',
1770
1809
  'path',
1771
1810
  'proof_required',
1772
1811
  'proofRequired',
1812
+ 'rejection_reason',
1813
+ 'rejectionReason',
1773
1814
  'reason',
1774
1815
  'fact'
1775
1816
  ], max);
@@ -1779,7 +1820,24 @@ function supportDiagnosisNarrativeText(value, max) {
1779
1820
  var routeModulePermission = cleanText(source.route_module_permission_gate || source.routeModulePermissionGate, Math.floor(max / 2));
1780
1821
  var templateGate = cleanText(source.template_conditional_rendering_gate || source.templateConditionalRenderingGate, Math.floor(max / 2));
1781
1822
  var backingGate = cleanText(source.backing_role_group_config_publications_gate || source.backingRoleGroupConfigPublicationsGate, Math.floor(max / 2));
1782
- return [routeModulePermission, templateGate, backingGate].filter(Boolean).join(' | ').slice(0, max);
1823
+ var explicitGateText = [routeModulePermission, templateGate, backingGate].filter(Boolean).join(' | ').slice(0, max);
1824
+ if (explicitGateText) {
1825
+ return explicitGateText;
1826
+ }
1827
+ return Object.entries(source)
1828
+ .filter(function (_a) {
1829
+ var _b = __read(_a, 1), key = _b[0];
1830
+ return !/^(id|_id|type|status|updatedAt|updated_at|createdAt|created_at)$/i.test(key);
1831
+ })
1832
+ .map(function (_a) {
1833
+ var _b = __read(_a, 2), entry = _b[1];
1834
+ return cleanListEntryText(entry, Math.max(80, Math.floor(max / 4)));
1835
+ })
1836
+ .filter(Boolean)
1837
+ .join(' | ')
1838
+ .replace(/\s+/g, ' ')
1839
+ .trim()
1840
+ .slice(0, max);
1783
1841
  }
1784
1842
  function supportDiagnosisLooksLikeClassifiedFeatureRequest(source, issueCaseText, failingPathText, hypothesisText) {
1785
1843
  var classificationText = supportDiagnosisNarrativeText(source.classification || source.classification_reason || source.classificationReason, 700);
@@ -1855,12 +1913,86 @@ function normalizeSupportDiagnosisProofPlanRows(values) {
1855
1913
  data_assertion: proofRequired.join(' | ').slice(0, 1000)
1856
1914
  };
1857
1915
  }
1916
+ function collectSupportDiagnosisTextListFromValues(values, limit, max) {
1917
+ var e_8, _a, e_9, _b, e_10, _c, e_11, _d;
1918
+ if (limit === void 0) { limit = 10; }
1919
+ if (max === void 0) { max = 800; }
1920
+ var result = [];
1921
+ try {
1922
+ for (var values_5 = __values(values), values_5_1 = values_5.next(); !values_5_1.done; values_5_1 = values_5.next()) {
1923
+ var value = values_5_1.value;
1924
+ var direct = cleanList(value, limit, max);
1925
+ try {
1926
+ for (var direct_1 = (e_9 = void 0, __values(direct)), direct_1_1 = direct_1.next(); !direct_1_1.done; direct_1_1 = direct_1.next()) {
1927
+ var entry = direct_1_1.value;
1928
+ if (entry && !result.includes(entry)) {
1929
+ result.push(entry);
1930
+ }
1931
+ }
1932
+ }
1933
+ catch (e_9_1) { e_9 = { error: e_9_1 }; }
1934
+ finally {
1935
+ try {
1936
+ if (direct_1_1 && !direct_1_1.done && (_b = direct_1.return)) _b.call(direct_1);
1937
+ }
1938
+ finally { if (e_9) throw e_9.error; }
1939
+ }
1940
+ if (value && typeof value === 'object' && !Array.isArray(value)) {
1941
+ try {
1942
+ for (var _e = (e_10 = void 0, __values(Object.entries(value))), _f = _e.next(); !_f.done; _f = _e.next()) {
1943
+ var _g = __read(_f.value, 2), key = _g[0], nestedValue = _g[1];
1944
+ if (!/(evidence|proof|ref|source|code|artifact|fact)/i.test(key)) {
1945
+ continue;
1946
+ }
1947
+ var nestedEntries = Array.isArray(nestedValue)
1948
+ ? cleanList(nestedValue, limit, max)
1949
+ : [cleanListEntryText(nestedValue, max)].filter(Boolean);
1950
+ try {
1951
+ for (var nestedEntries_1 = (e_11 = void 0, __values(nestedEntries)), nestedEntries_1_1 = nestedEntries_1.next(); !nestedEntries_1_1.done; nestedEntries_1_1 = nestedEntries_1.next()) {
1952
+ var entry = nestedEntries_1_1.value;
1953
+ if (entry && !result.includes(entry)) {
1954
+ result.push(entry);
1955
+ }
1956
+ }
1957
+ }
1958
+ catch (e_11_1) { e_11 = { error: e_11_1 }; }
1959
+ finally {
1960
+ try {
1961
+ if (nestedEntries_1_1 && !nestedEntries_1_1.done && (_d = nestedEntries_1.return)) _d.call(nestedEntries_1);
1962
+ }
1963
+ finally { if (e_11) throw e_11.error; }
1964
+ }
1965
+ }
1966
+ }
1967
+ catch (e_10_1) { e_10 = { error: e_10_1 }; }
1968
+ finally {
1969
+ try {
1970
+ if (_f && !_f.done && (_c = _e.return)) _c.call(_e);
1971
+ }
1972
+ finally { if (e_10) throw e_10.error; }
1973
+ }
1974
+ }
1975
+ if (result.length >= limit) {
1976
+ break;
1977
+ }
1978
+ }
1979
+ }
1980
+ catch (e_8_1) { e_8 = { error: e_8_1 }; }
1981
+ finally {
1982
+ try {
1983
+ if (values_5_1 && !values_5_1.done && (_a = values_5.return)) _a.call(values_5);
1984
+ }
1985
+ finally { if (e_8) throw e_8.error; }
1986
+ }
1987
+ return result.slice(0, limit);
1988
+ }
1858
1989
  function normalizeOwnerFilePath(value) {
1859
- var e_8, _a;
1990
+ var e_12, _a;
1860
1991
  var normalized = cleanListEntryText(value, 500)
1861
1992
  .replace(/\\/g, '/')
1862
1993
  .replace(/^\.\/+/, '')
1863
1994
  .replace(/^\/+/, '')
1995
+ .replace(/:\d+(?:-\d+)?$/g, '')
1864
1996
  .replace(/\s+$/g, '');
1865
1997
  try {
1866
1998
  for (var _b = __values([
@@ -1881,12 +2013,12 @@ function normalizeOwnerFilePath(value) {
1881
2013
  }
1882
2014
  }
1883
2015
  }
1884
- catch (e_8_1) { e_8 = { error: e_8_1 }; }
2016
+ catch (e_12_1) { e_12 = { error: e_12_1 }; }
1885
2017
  finally {
1886
2018
  try {
1887
2019
  if (_c && !_c.done && (_a = _b.return)) _a.call(_b);
1888
2020
  }
1889
- finally { if (e_8) throw e_8.error; }
2021
+ finally { if (e_12) throw e_12.error; }
1890
2022
  }
1891
2023
  return normalized;
1892
2024
  }
@@ -1895,7 +2027,7 @@ function isResolveIOSupportGeneratedAngularWrapperPath(value) {
1895
2027
  return /(?:^|\/)angular\/app\/(?:methods|publications)\.ts$/i.test(normalized);
1896
2028
  }
1897
2029
  function ownerFileComparablePathKeys(value) {
1898
- var e_9, _a;
2030
+ var e_13, _a;
1899
2031
  var normalized = normalizeOwnerFilePath(value);
1900
2032
  if (!normalized) {
1901
2033
  return [];
@@ -1917,12 +2049,12 @@ function ownerFileComparablePathKeys(value) {
1917
2049
  }
1918
2050
  }
1919
2051
  }
1920
- catch (e_9_1) { e_9 = { error: e_9_1 }; }
2052
+ catch (e_13_1) { e_13 = { error: e_13_1 }; }
1921
2053
  finally {
1922
2054
  try {
1923
2055
  if (_c && !_c.done && (_a = _b.return)) _a.call(_b);
1924
2056
  }
1925
- finally { if (e_9) throw e_9.error; }
2057
+ finally { if (e_13) throw e_13.error; }
1926
2058
  }
1927
2059
  return Array.from(keys);
1928
2060
  }
@@ -2345,15 +2477,23 @@ function normalizeResolveIOSupportDiagnosisGate(value, now) {
2345
2477
  var ticketEvidenceText = ((_a = diagnosisEvidence.find(function (entry) { return entry.type === 'ticket'; })) === null || _a === void 0 ? void 0 : _a.summary) || '';
2346
2478
  var browserEvidenceText = ((_b = diagnosisEvidence.find(function (entry) { return entry.type === 'browser'; })) === null || _b === void 0 ? void 0 : _b.summary) || '';
2347
2479
  var rootCauseEvidenceText = ((_c = diagnosisEvidence.find(function (entry) { return SUPPORT_ROOT_CAUSE_EVIDENCE_TYPES.has(entry.type); })) === null || _c === void 0 ? void 0 : _c.summary) || '';
2480
+ var explicitCustomerComplaint = pickText(issueCaseSource, ['customer_complaint', 'customerComplaint', 'complaint', 'request', 'summary'], 1200);
2348
2481
  var customerIssueCaseText = (function () {
2482
+ if (explicitCustomerComplaint) {
2483
+ return explicitCustomerComplaint;
2484
+ }
2485
+ var evidenceCustomerText = cleanText([ticketEvidenceText, browserEvidenceText]
2486
+ .filter(Boolean)
2487
+ .join(' '), 1200);
2488
+ if (evidenceCustomerText) {
2489
+ return evidenceCustomerText;
2490
+ }
2349
2491
  var issueText = cleanText(issueCaseText, 1200);
2350
2492
  if (issueText && !supportDiagnosisTextLooksGeneric(issueText, 18)
2351
2493
  && !/\b(general inquiry|existing behavior|not a confirmed runtime failure)\b/i.test(issueText)) {
2352
2494
  return issueText;
2353
2495
  }
2354
- return cleanText([ticketEvidenceText, browserEvidenceText]
2355
- .filter(Boolean)
2356
- .join(' '), 1200);
2496
+ return '';
2357
2497
  })();
2358
2498
  var issueCasePrimaryText = customerIssueCaseText || cleanText([
2359
2499
  rootCauseEvidenceText,
@@ -2362,7 +2502,7 @@ function normalizeResolveIOSupportDiagnosisGate(value, now) {
2362
2502
  ].filter(Boolean).join(' '), 1200);
2363
2503
  var routeModule = pickText(issueCaseSource, ['route_module', 'routeModule', 'route', 'module', 'screen'], 500)
2364
2504
  || pickText(source, ['route_module', 'routeModule', 'module', 'screen'], 500)
2365
- || pickText(failingPathSource, ['route', 'module', 'path', 'description'], 500)
2505
+ || pickText(failingPathSource, ['route', 'module', 'path', 'description', 'reported', 'verified', 'reported_path', 'reportedPath', 'verified_path', 'verifiedPath'], 500)
2366
2506
  || failingPathText
2367
2507
  || (featureRequestClassified ? 'net-new support feature workflow' : '');
2368
2508
  var expectedResult = pickText(issueCaseSource, ['expected_result', 'expectedResult', 'expected'], 1000)
@@ -2379,9 +2519,19 @@ function normalizeResolveIOSupportDiagnosisGate(value, now) {
2379
2519
  || (featureRequestClassified ? 'Customer/account context from support ticket intake.' : '');
2380
2520
  var rawReproductionStatus = issueCaseSource.reproduction_status || issueCaseSource.reproductionStatus || source.reproduction_status;
2381
2521
  var hasRuntimeReproductionEvidence = diagnosisEvidence.some(function (entry) { return SUPPORT_REPRODUCTION_EVIDENCE_TYPES.has(entry.type); });
2522
+ var explicitHypothesisEvidence = collectSupportDiagnosisTextListFromValues([
2523
+ hypothesisSource.evidence,
2524
+ hypothesisSource.evidence_refs,
2525
+ hypothesisSource.evidenceRefs,
2526
+ hypothesisSource.code_evidence,
2527
+ hypothesisSource.codeEvidence,
2528
+ source.hypothesis_evidence,
2529
+ source.hypothesisEvidence,
2530
+ hypothesisSource
2531
+ ], 10, 800);
2382
2532
  var gate = {
2383
2533
  issue_case: {
2384
- customer_complaint: pickText(issueCaseSource, ['customer_complaint', 'customerComplaint', 'complaint', 'request', 'summary'], 1200) || customerIssueCaseText,
2534
+ customer_complaint: explicitCustomerComplaint || customerIssueCaseText,
2385
2535
  expected_result: expectedResult,
2386
2536
  observed_result: observedResult,
2387
2537
  route_module: routeModule,
@@ -2397,8 +2547,8 @@ function normalizeResolveIOSupportDiagnosisGate(value, now) {
2397
2547
  || hypothesisText,
2398
2548
  falsifiable_test: pickText(hypothesisSource, ['falsifiable_test', 'falsifiableTest', 'test', 'proof', 'falsifier'], 1000)
2399
2549
  || (failingPathText ? "Verify the accepted hypothesis against the failing path evidence: ".concat(failingPathText) : ''),
2400
- evidence: cleanList(hypothesisSource.evidence || source.hypothesis_evidence || source.hypothesisEvidence, 10, 800).length
2401
- ? cleanList(hypothesisSource.evidence || source.hypothesis_evidence || source.hypothesisEvidence, 10, 800)
2550
+ evidence: explicitHypothesisEvidence.length
2551
+ ? explicitHypothesisEvidence
2402
2552
  : diagnosisEvidence.map(function (entry) { return [entry.artifactPath, entry.summary].filter(Boolean).join(': '); }).filter(Boolean).slice(0, 10)
2403
2553
  },
2404
2554
  rejected_alternatives: normalizeSupportDiagnosisRejectedAlternatives(source.rejected_alternatives || source.rejectedAlternatives),
@@ -2407,7 +2557,7 @@ function normalizeResolveIOSupportDiagnosisGate(value, now) {
2407
2557
  backend: pickText(failingPathSource, ['backend', 'backend_path', 'backendPath', 'methodPublicationPath'], 700),
2408
2558
  shared_library: pickText(failingPathSource, ['shared_library', 'sharedLibrary', 'library', 'lib'], 700),
2409
2559
  data_query: pickText(failingPathSource, ['data_query', 'dataQuery', 'query'], 700),
2410
- description: pickText(failingPathSource, ['description', 'path_chain', 'pathChain', 'path', 'assessment', 'summary', 'route'], 1200) || failingPathText
2560
+ description: pickText(failingPathSource, ['description', 'path_chain', 'pathChain', 'reported', 'verified', 'reported_path', 'reportedPath', 'verified_path', 'verifiedPath', 'path', 'assessment', 'summary', 'route'], 1200) || failingPathText
2411
2561
  },
2412
2562
  owner_files: ownerFiles,
2413
2563
  proof_plan: {
@@ -2433,7 +2583,7 @@ function normalizeResolveIOSupportDiagnosisGate(value, now) {
2433
2583
  return gate;
2434
2584
  }
2435
2585
  function extractResolveIOSupportDiagnosisGateFromText(value, now) {
2436
- var e_10, _a;
2586
+ var e_14, _a;
2437
2587
  var text = String(value || '').trim();
2438
2588
  if (!text) {
2439
2589
  return undefined;
@@ -2461,12 +2611,12 @@ function extractResolveIOSupportDiagnosisGateFromText(value, now) {
2461
2611
  }
2462
2612
  }
2463
2613
  }
2464
- catch (e_10_1) { e_10 = { error: e_10_1 }; }
2614
+ catch (e_14_1) { e_14 = { error: e_14_1 }; }
2465
2615
  finally {
2466
2616
  try {
2467
2617
  if (candidates_1_1 && !candidates_1_1.done && (_a = candidates_1.return)) _a.call(candidates_1);
2468
2618
  }
2469
- finally { if (e_10) throw e_10.error; }
2619
+ finally { if (e_14) throw e_14.error; }
2470
2620
  }
2471
2621
  return undefined;
2472
2622
  }
@@ -2629,7 +2779,7 @@ function supportStatusLooksPassed(value) {
2629
2779
  return /\b(pass|passed|success|succeeded|complete|completed|ready|not_required|not required)\b/i.test(cleanText(value, 200));
2630
2780
  }
2631
2781
  function nestedObject(source) {
2632
- var e_11, _a;
2782
+ var e_15, _a;
2633
2783
  var keys = [];
2634
2784
  for (var _i = 1; _i < arguments.length; _i++) {
2635
2785
  keys[_i - 1] = arguments[_i];
@@ -2643,17 +2793,17 @@ function nestedObject(source) {
2643
2793
  }
2644
2794
  }
2645
2795
  }
2646
- catch (e_11_1) { e_11 = { error: e_11_1 }; }
2796
+ catch (e_15_1) { e_15 = { error: e_15_1 }; }
2647
2797
  finally {
2648
2798
  try {
2649
2799
  if (keys_1_1 && !keys_1_1.done && (_a = keys_1.return)) _a.call(keys_1);
2650
2800
  }
2651
- finally { if (e_11) throw e_11.error; }
2801
+ finally { if (e_15) throw e_15.error; }
2652
2802
  }
2653
2803
  return {};
2654
2804
  }
2655
2805
  function resolveSupportReplyReleaseGate(input) {
2656
- var e_12, _a;
2806
+ var e_16, _a;
2657
2807
  var _b;
2658
2808
  var releaseEvidence = cleanObject(input.releaseEvidence);
2659
2809
  var releaseStatus = cleanText(input.releaseStatus
@@ -2724,12 +2874,12 @@ function resolveSupportReplyReleaseGate(input) {
2724
2874
  blockers.push("missing_".concat(field));
2725
2875
  }
2726
2876
  }
2727
- catch (e_12_1) { e_12 = { error: e_12_1 }; }
2877
+ catch (e_16_1) { e_16 = { error: e_16_1 }; }
2728
2878
  finally {
2729
2879
  try {
2730
2880
  if (missingCommitProofFields_1_1 && !missingCommitProofFields_1_1.done && (_a = missingCommitProofFields_1.return)) _a.call(missingCommitProofFields_1);
2731
2881
  }
2732
- finally { if (e_12) throw e_12.error; }
2882
+ finally { if (e_16) throw e_16.error; }
2733
2883
  }
2734
2884
  var shouldEvaluateHotfix = statusBlocked || commitProofRequired || Object.keys(hotfixEvidence).length > 0;
2735
2885
  var hotfixContinuation = shouldEvaluateHotfix
@@ -2775,7 +2925,7 @@ function supportBusinessAssertionRouteOnly(value) {
2775
2925
  return /^(route_probe_pass|route_only_pass|route_pass|route_probe|route_loaded)$/i.test(cleanText(value, 80));
2776
2926
  }
2777
2927
  function normalizeSupportBusinessProofAssertions(input) {
2778
- var e_13, _a;
2928
+ var e_17, _a;
2779
2929
  var gate = normalizeResolveIOSupportDiagnosisGate(input.diagnosisGate);
2780
2930
  var proofPlan = gate === null || gate === void 0 ? void 0 : gate.proof_plan;
2781
2931
  var proofContract = proofPlan === null || proofPlan === void 0 ? void 0 : proofPlan.business_proof_contract;
@@ -2809,12 +2959,12 @@ function normalizeSupportBusinessProofAssertions(input) {
2809
2959
  });
2810
2960
  }
2811
2961
  }
2812
- catch (e_13_1) { e_13 = { error: e_13_1 }; }
2962
+ catch (e_17_1) { e_17 = { error: e_17_1 }; }
2813
2963
  finally {
2814
2964
  try {
2815
2965
  if (_c && !_c.done && (_a = _b.return)) _a.call(_b);
2816
2966
  }
2817
- finally { if (e_13) throw e_13.error; }
2967
+ finally { if (e_17) throw e_17.error; }
2818
2968
  }
2819
2969
  var status = cleanText(input.businessAssertionStatus || input.outcomeLabel, 80);
2820
2970
  if (!assertions.length && (supportBusinessAssertionPassed(status) || supportBusinessAssertionRouteOnly(status) || supportBusinessAssertionFailed(status))) {
@@ -2904,7 +3054,7 @@ function supportBusinessProofAssertionHasStructuredContractMapping(assertion, ga
2904
3054
  return routeMatches && actionMatches && expectedStateMatches && hasBusinessDataProof;
2905
3055
  }
2906
3056
  function supportBusinessProofAssertionMatchesContract(assertion, gate) {
2907
- var e_14, _a;
3057
+ var e_18, _a;
2908
3058
  if (!gate) {
2909
3059
  return false;
2910
3060
  }
@@ -2944,12 +3094,12 @@ function supportBusinessProofAssertionMatchesContract(assertion, gate) {
2944
3094
  }
2945
3095
  }
2946
3096
  }
2947
- catch (e_14_1) { e_14 = { error: e_14_1 }; }
3097
+ catch (e_18_1) { e_18 = { error: e_18_1 }; }
2948
3098
  finally {
2949
3099
  try {
2950
3100
  if (proofWords_1_1 && !proofWords_1_1.done && (_a = proofWords_1.return)) _a.call(proofWords_1);
2951
3101
  }
2952
- finally { if (e_14) throw e_14.error; }
3102
+ finally { if (e_18) throw e_18.error; }
2953
3103
  }
2954
3104
  return overlap >= Math.min(5, Math.max(3, Math.ceil(proofWords.size * 0.45)));
2955
3105
  }
@@ -4474,7 +4624,7 @@ function supportManagerRequiredResetEvidenceForContract(contract) {
4474
4624
  ], false))).slice(0, 16);
4475
4625
  }
4476
4626
  function validateResolveIOSupportNextActionContract(value) {
4477
- var e_15, _a;
4627
+ var e_19, _a;
4478
4628
  var _b, _c, _d, _e, _f;
4479
4629
  var contract = cleanObject(value);
4480
4630
  var blockers = [];
@@ -4496,12 +4646,12 @@ function validateResolveIOSupportNextActionContract(value) {
4496
4646
  }
4497
4647
  }
4498
4648
  }
4499
- catch (e_15_1) { e_15 = { error: e_15_1 }; }
4649
+ catch (e_19_1) { e_19 = { error: e_19_1 }; }
4500
4650
  finally {
4501
4651
  try {
4502
4652
  if (requiredStringFields_1_1 && !requiredStringFields_1_1.done && (_a = requiredStringFields_1.return)) _a.call(requiredStringFields_1);
4503
4653
  }
4504
- finally { if (e_15) throw e_15.error; }
4654
+ finally { if (e_19) throw e_19.error; }
4505
4655
  }
4506
4656
  if (!Array.isArray(contract.nextCommands) || !contract.nextCommands.length) {
4507
4657
  blockers.push('NextActionContract.nextCommands must include at least the primary command.');
@@ -5520,7 +5670,7 @@ function buildResolveIOSupportV5ScopeDigest(input) {
5520
5670
  return raw.slice(0, maxChars);
5521
5671
  }
5522
5672
  function buildResolveIOSupportV5MicrotaskLedger(input) {
5523
- var e_16, _a;
5673
+ var e_20, _a;
5524
5674
  var existing = Array.isArray(input.existing) ? input.existing : [];
5525
5675
  var completedByObjective = new Map();
5526
5676
  try {
@@ -5531,12 +5681,12 @@ function buildResolveIOSupportV5MicrotaskLedger(input) {
5531
5681
  }
5532
5682
  }
5533
5683
  }
5534
- catch (e_16_1) { e_16 = { error: e_16_1 }; }
5684
+ catch (e_20_1) { e_20 = { error: e_20_1 }; }
5535
5685
  finally {
5536
5686
  try {
5537
5687
  if (existing_1_1 && !existing_1_1.done && (_a = existing_1.return)) _a.call(existing_1);
5538
5688
  }
5539
- finally { if (e_16) throw e_16.error; }
5689
+ finally { if (e_20) throw e_20.error; }
5540
5690
  }
5541
5691
  var now = isoNow(input.now);
5542
5692
  var requirements = cleanList(input.requirements, 30, 240);
@@ -7340,7 +7490,7 @@ function buildResolveIOSupportV5MicrotaskPrompt(input) {
7340
7490
  };
7341
7491
  }
7342
7492
  function summarizeResolveIOSupportV5MicrotaskUsage(bundle) {
7343
- var e_17, _a, e_18, _b;
7493
+ var e_21, _a, e_22, _b;
7344
7494
  var byMicrotask = new Map();
7345
7495
  var bySection = new Map();
7346
7496
  var totalPromptTokenEstimate = 0;
@@ -7355,17 +7505,17 @@ function summarizeResolveIOSupportV5MicrotaskUsage(bundle) {
7355
7505
  existing.calls += 1;
7356
7506
  byMicrotask.set(usage.microtaskId, existing);
7357
7507
  try {
7358
- for (var _e = (e_18 = void 0, __values(usage.promptSections || [])), _f = _e.next(); !_f.done; _f = _e.next()) {
7508
+ for (var _e = (e_22 = void 0, __values(usage.promptSections || [])), _f = _e.next(); !_f.done; _f = _e.next()) {
7359
7509
  var section = _f.value;
7360
7510
  bySection.set(section.name, (bySection.get(section.name) || 0) + section.tokenEstimate);
7361
7511
  }
7362
7512
  }
7363
- catch (e_18_1) { e_18 = { error: e_18_1 }; }
7513
+ catch (e_22_1) { e_22 = { error: e_22_1 }; }
7364
7514
  finally {
7365
7515
  try {
7366
7516
  if (_f && !_f.done && (_b = _e.return)) _b.call(_e);
7367
7517
  }
7368
- finally { if (e_18) throw e_18.error; }
7518
+ finally { if (e_22) throw e_22.error; }
7369
7519
  }
7370
7520
  var hardCap = usage.lane === 'qa' ? promptBudget.qaMicrotaskHardCap : promptBudget.buildMicrotaskHardCap;
7371
7521
  if ((usage.promptTokenEstimate || 0) > hardCap) {
@@ -7373,12 +7523,12 @@ function summarizeResolveIOSupportV5MicrotaskUsage(bundle) {
7373
7523
  }
7374
7524
  }
7375
7525
  }
7376
- catch (e_17_1) { e_17 = { error: e_17_1 }; }
7526
+ catch (e_21_1) { e_21 = { error: e_21_1 }; }
7377
7527
  finally {
7378
7528
  try {
7379
7529
  if (_d && !_d.done && (_a = _c.return)) _a.call(_c);
7380
7530
  }
7381
- finally { if (e_17) throw e_17.error; }
7531
+ finally { if (e_21) throw e_21.error; }
7382
7532
  }
7383
7533
  return {
7384
7534
  totalPromptTokenEstimate: totalPromptTokenEstimate,