@wowok/agent-mcp 3.2.6 → 3.2.7

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 (222) hide show
  1. package/dist/chain-semantics/field-capability.js +1 -1
  2. package/dist/chain-semantics/freeze-map.js +1 -1
  3. package/dist/chain-semantics/object-graph.js +1 -1
  4. package/dist/communication/wts-attestation.js +1 -1
  5. package/dist/composition/audit.js +1 -1
  6. package/dist/composition/compile.d.ts +3 -2
  7. package/dist/composition/compile.js +1 -1
  8. package/dist/composition/inflight.d.ts +17 -0
  9. package/dist/composition/inflight.js +1 -0
  10. package/dist/config/config-audit.spec.js +1 -1
  11. package/dist/customer/account-events.js +1 -1
  12. package/dist/customer/order-monitor.js +1 -1
  13. package/dist/evaluation/builtins/graph-service.spec.js +1 -1
  14. package/dist/evaluation/engine.js +1 -1
  15. package/dist/experience/realtime-feedback.js +1 -1
  16. package/dist/extensions/constraint-registry.d.ts +6 -1
  17. package/dist/extensions/constraint-registry.js +1 -1
  18. package/dist/extensions/index.d.ts +1 -1
  19. package/dist/extensions/index.js +1 -1
  20. package/dist/extensions/industry-pack.d.ts +5 -0
  21. package/dist/extensions/industry-pack.js +1 -1
  22. package/dist/extensions/mode-evaluator.d.ts +3 -2
  23. package/dist/extensions/mode-evaluator.js +1 -1
  24. package/dist/extensions/modes.js +1 -1
  25. package/dist/graph/onchain/analyze.js +1 -1
  26. package/dist/graph/onchain/analyze.spec.js +1 -1
  27. package/dist/graph/onchain/anti-cheat.d.ts +32 -2
  28. package/dist/graph/onchain/anti-cheat.js +1 -1
  29. package/dist/graph/onchain/anti-cheat.spec.js +1 -1
  30. package/dist/graph/onchain/expand.js +1 -1
  31. package/dist/graph/onchain/exposure.js +1 -1
  32. package/dist/graph/onchain/extract.js +1 -1
  33. package/dist/graph/onchain/graph-policy.spec.js +1 -1
  34. package/dist/graph/onchain/index.d.ts +2 -2
  35. package/dist/graph/onchain/index.js +1 -1
  36. package/dist/graph/onchain/project-relationship.js +1 -1
  37. package/dist/graph/onchain/table-ledger.spec.js +1 -1
  38. package/dist/graph/onchain/types.d.ts +3 -0
  39. package/dist/harness/recover.js +1 -1
  40. package/dist/index.js +1 -1
  41. package/dist/knowledge/arbitration-venue-order.d.ts +25 -0
  42. package/dist/knowledge/arbitration-venue-order.js +1 -0
  43. package/dist/knowledge/audit-rules.d.ts +10 -0
  44. package/dist/knowledge/audit-rules.js +1 -1
  45. package/dist/knowledge/baselines/risk-baselines.spec.js +1 -1
  46. package/dist/knowledge/baselines/rules/graph.json +81 -0
  47. package/dist/knowledge/baselines/rules/machine.json +3 -3
  48. package/dist/knowledge/baselines/rules/plan.json +80 -2
  49. package/dist/knowledge/builtin-templates.d.ts +17 -2
  50. package/dist/knowledge/builtin-templates.js +1 -1
  51. package/dist/knowledge/discount-threshold.js +1 -1
  52. package/dist/knowledge/event-semantics.js +1 -1
  53. package/dist/knowledge/getting-started.js +1 -1
  54. package/dist/knowledge/guard-bindings.js +1 -1
  55. package/dist/knowledge/guard-design-patterns.js +1 -1
  56. package/dist/knowledge/guard-field-cognition.js +1 -1
  57. package/dist/knowledge/guard-ledger.js +1 -1
  58. package/dist/knowledge/guard-lint.d.ts +1 -0
  59. package/dist/knowledge/guard-lint.js +1 -1
  60. package/dist/knowledge/guard-node-gates.d.ts +4 -0
  61. package/dist/knowledge/guard-node-gates.js +1 -0
  62. package/dist/knowledge/guard-puzzle.js +1 -1
  63. package/dist/knowledge/guard-risk.js +1 -1
  64. package/dist/knowledge/guard-submission-prompt.d.ts +1 -0
  65. package/dist/knowledge/guard-submission-prompt.js +1 -1
  66. package/dist/knowledge/guard-templates.d.ts +2 -1
  67. package/dist/knowledge/guard-templates.js +1 -1
  68. package/dist/knowledge/guard-translation.js +1 -1
  69. package/dist/knowledge/index.d.ts +2 -2
  70. package/dist/knowledge/index.js +1 -1
  71. package/dist/knowledge/industry-registry.js +1 -1
  72. package/dist/knowledge/jsonrpc-enum.js +1 -1
  73. package/dist/knowledge/machine-topology.d.ts +6 -0
  74. package/dist/knowledge/machine-topology.js +1 -1
  75. package/dist/knowledge/reputation-rules.d.ts +3 -9
  76. package/dist/knowledge/reputation-rules.js +1 -1
  77. package/dist/knowledge/safety-rules.d.ts +10 -1
  78. package/dist/knowledge/safety-rules.js +1 -1
  79. package/dist/knowledge/scenario-modes.js +1 -1
  80. package/dist/knowledge/settlement-semantics.d.ts +1 -0
  81. package/dist/knowledge/settlement-semantics.js +1 -0
  82. package/dist/knowledge/template-loader.d.ts +22 -0
  83. package/dist/knowledge/template-loader.js +1 -1
  84. package/dist/knowledge/template-registry.js +1 -1
  85. package/dist/knowledge/template-scanner.d.ts +14 -0
  86. package/dist/knowledge/template-scanner.js +1 -1
  87. package/dist/knowledge/tools-reference.js +1 -1
  88. package/dist/knowledge/workflow-guidance.d.ts +1 -0
  89. package/dist/knowledge/workflow-guidance.js +1 -1
  90. package/dist/monitor/MonitorLoop.js +1 -1
  91. package/dist/participation/allocation-advice.js +1 -1
  92. package/dist/participation/customer-interest.js +1 -1
  93. package/dist/participation/radar-core.d.ts +6 -1
  94. package/dist/participation/radar-core.js +1 -1
  95. package/dist/playbooks/service-build/business-puzzle.js +1 -1
  96. package/dist/playbooks/service-build/machine-panorama.js +1 -1
  97. package/dist/playbooks/service-build/merchant-guide.d.ts +38 -15
  98. package/dist/playbooks/service-build/merchant-guide.js +1 -1
  99. package/dist/playbooks/service-build/migration-planner.d.ts +7 -0
  100. package/dist/playbooks/service-build/migration-planner.js +1 -1
  101. package/dist/playbooks/service-build/object-panorama.js +1 -1
  102. package/dist/playbooks/service-build/participation-radar.js +1 -1
  103. package/dist/playbooks/service-build/pipeline-actions.d.ts +1 -1
  104. package/dist/playbooks/service-build/pipeline-actions.js +1 -1
  105. package/dist/playbooks/service-build/relationship-profile.js +1 -1
  106. package/dist/playbooks/service-build/risk-aggregator.d.ts +1 -1
  107. package/dist/playbooks/service-build/risk-aggregator.js +1 -1
  108. package/dist/playbooks/service-build/service-panorama.js +1 -1
  109. package/dist/playbooks/service-build/service-quote.js +1 -1
  110. package/dist/playbooks/service-build/service-quote.spec.js +1 -1
  111. package/dist/relationship/derivation.d.ts +1 -0
  112. package/dist/review/index.js +1 -1
  113. package/dist/runtime/instance-registry.d.ts +8 -0
  114. package/dist/runtime/instance-registry.js +1 -0
  115. package/dist/safety/confirm-gate.js +1 -1
  116. package/dist/schema/benchmark-migration/index.d.ts +14 -0
  117. package/dist/schema/benchmark-migration/index.js +1 -1
  118. package/dist/schema/call/arbitration.js +1 -1
  119. package/dist/schema/call/base.d.ts +109 -0
  120. package/dist/schema/call/base.js +1 -1
  121. package/dist/schema/call/bridge.d.ts +14 -0
  122. package/dist/schema/call/contact.js +1 -1
  123. package/dist/schema/call/error-codes.d.ts +1 -1
  124. package/dist/schema/call/error-codes.js +1 -1
  125. package/dist/schema/call/guard.d.ts +7 -0
  126. package/dist/schema/call/guard.js +1 -1
  127. package/dist/schema/call/handler.js +1 -1
  128. package/dist/schema/call/machine.d.ts +7 -0
  129. package/dist/schema/call/machine.js +1 -1
  130. package/dist/schema/call/payment.js +1 -1
  131. package/dist/schema/call/permission-handler.js +1 -1
  132. package/dist/schema/call/progress.d.ts +46 -0
  133. package/dist/schema/call/progress.js +1 -1
  134. package/dist/schema/call/semantic.js +1 -1
  135. package/dist/schema/call/service.d.ts +8 -8
  136. package/dist/schema/call/service.js +1 -1
  137. package/dist/schema/common/index.js +1 -1
  138. package/dist/schema/goal/index.d.ts +11 -0
  139. package/dist/schema/goal/planning.d.ts +32 -1
  140. package/dist/schema/goal/planning.js +1 -1
  141. package/dist/schema/industry-pack/index.d.ts +40 -0
  142. package/dist/schema/industry-pack/index.js +1 -1
  143. package/dist/schema/keeper/index.d.ts +13 -0
  144. package/dist/schema/local/index.d.ts +75 -0
  145. package/dist/schema/local/index.js +1 -1
  146. package/dist/schema/messenger/index.d.ts +17 -0
  147. package/dist/schema/messenger/index.js +1 -1
  148. package/dist/schema/operations.d.ts +39 -2
  149. package/dist/schema/operations.js +1 -1
  150. package/dist/schema/query/bi.d.ts +64 -0
  151. package/dist/schema/query/bi.js +1 -1
  152. package/dist/schema/query/index.d.ts +94 -0
  153. package/dist/schema/query/index.js +1 -1
  154. package/dist/schema/schema-version.d.ts +1 -1
  155. package/dist/schema/schema-version.js +1 -1
  156. package/dist/schema/utils/permission-machine-check.js +1 -1
  157. package/dist/schema/workspace/index.d.ts +1 -1
  158. package/dist/schema-query-impl/index.js +1 -1
  159. package/dist/schemas/account_operation.output.json +45 -0
  160. package/dist/schemas/benchmark_migration_operation.output.json +24 -4
  161. package/dist/schemas/benchmark_migration_operation.schema.json +70 -0
  162. package/dist/schemas/bridge_operation.output.json +45 -0
  163. package/dist/schemas/goal_operation.schema.json +78 -0
  164. package/dist/schemas/guard2file.output.json +6 -1
  165. package/dist/schemas/guard2file.schema.json +9 -0
  166. package/dist/schemas/index.json +1 -1
  167. package/dist/schemas/industry_pack_operation.output.json +91 -0
  168. package/dist/schemas/industry_pack_operation.schema.json +19 -1
  169. package/dist/schemas/keeper_operation.output.json +44 -0
  170. package/dist/schemas/local_cache_operation.output.json +45 -0
  171. package/dist/schemas/local_history_operation.output.json +45 -0
  172. package/dist/schemas/local_info_operation.output.json +45 -0
  173. package/dist/schemas/local_mark_operation.output.json +45 -0
  174. package/dist/schemas/machineNode2file.output.json +6 -1
  175. package/dist/schemas/machineNode2file.schema.json +9 -0
  176. package/dist/schemas/messenger_operation.output.json +52 -0
  177. package/dist/schemas/monitor_events.output.json +44 -0
  178. package/dist/schemas/monitor_subscription.output.json +44 -0
  179. package/dist/schemas/onchain_events.output.json +44 -0
  180. package/dist/schemas/onchain_operations.output.json +133 -0
  181. package/dist/schemas/onchain_operations.schema.json +73 -16
  182. package/dist/schemas/onchain_operations_arbitration.schema.json +2 -1
  183. package/dist/schemas/onchain_operations_contact.schema.json +2 -2
  184. package/dist/schemas/onchain_operations_guard.schema.json +2 -2
  185. package/dist/schemas/onchain_operations_machine.schema.json +2 -2
  186. package/dist/schemas/onchain_operations_payment.schema.json +1 -1
  187. package/dist/schemas/onchain_operations_progress.schema.json +57 -0
  188. package/dist/schemas/onchain_operations_service.schema.json +7 -8
  189. package/dist/schemas/onchain_table_data.output.json +81 -13
  190. package/dist/schemas/onchain_table_data.schema.json +21 -21
  191. package/dist/schemas/query_toolkit.output.json +218 -9
  192. package/dist/schemas/query_toolkit.schema.json +50 -26
  193. package/dist/schemas/wowok_buildin_info.output.json +80 -1
  194. package/dist/schemas/wowok_buildin_info.schema.json +1 -1
  195. package/dist/tools/handlers/benchmark-migration.d.ts +1 -0
  196. package/dist/tools/handlers/benchmark-migration.js +1 -1
  197. package/dist/tools/handlers/config.js +1 -1
  198. package/dist/tools/handlers/file-export.js +1 -1
  199. package/dist/tools/handlers/industry-pack.js +1 -1
  200. package/dist/tools/handlers/messenger.js +1 -1
  201. package/dist/tools/handlers/onchain.js +1 -1
  202. package/dist/tools/handlers/review-chain.d.ts +22 -0
  203. package/dist/tools/handlers/review-chain.js +1 -0
  204. package/dist/tools/registry/agent.js +1 -1
  205. package/dist/tools/registry/business.js +1 -1
  206. package/dist/tools/registry/config.js +1 -1
  207. package/dist/tools/registry/evaluation.js +1 -1
  208. package/dist/tools/registry/files.js +1 -1
  209. package/dist/tools/registry/identity.js +1 -1
  210. package/dist/tools/registry/local.js +1 -1
  211. package/dist/tools/registry/messenger.js +1 -1
  212. package/dist/tools/registry/monitor.js +1 -1
  213. package/dist/tools/registry/onchain.js +1 -1
  214. package/dist/tools/registry/query.js +1 -1
  215. package/dist/tools/rules-hook.js +1 -1
  216. package/dist/tools/runtime-health.d.ts +10 -0
  217. package/dist/tools/runtime-health.js +1 -0
  218. package/dist/tools/upgrade-check.d.ts +10 -1
  219. package/dist/tools/upgrade-check.js +1 -1
  220. package/dist/tools/wrap.d.ts +3 -0
  221. package/dist/tools/wrap.js +1 -1
  222. package/package.json +2 -2
@@ -1 +1 @@
1
- import{describe,it,expect,vi,beforeEach}from'vitest';const {sdkMocks}=vi['hoisted'](()=>({'sdkMocks':{'network_get':vi['fn'](),'localMarkList':vi['fn'](),'query_objects':vi['fn'](),'query_serviceContext':vi['fn'](),'resolveAddress':vi['fn']()}}));vi['mock']('@wowok/wowok',async a=>{const b=await a();return{...b,'Config':{'Instance':()=>({'network_get':sdkMocks['network_get']})},'LocalMark':{'Instance':()=>({'list':sdkMocks['localMarkList']})},'query_objects':sdkMocks['query_objects'],'query_serviceContext':sdkMocks['query_serviceContext']};}),vi['mock']('../../tools/handlers/name-resolution.js',()=>({'resolveAddress':sdkMocks['resolveAddress']})),vi['mock']('./facet-money.js',()=>({'formatMoneyAnnotation':async a=>({'display':a})}));import{handleServiceQuote}from'./service-quote.js';const SVC='0x'+'1'['repeat'](0x40),COUPON='0x'+'2'['repeat'](0x40),OTHER_SVC='0x'+'3'['repeat'](0x40),FLEXIBLE='Flexible\x20—\x20canal\x20view\x20double',LIST_TOTAL=0x35a4e900n;function makeCoupon(a={}){const b=Date['now']();return{'object':COUPON,'name':'bk3t-promo15','discount_type':0x0,'off':0x5dc,'benchmark':null,'time_start':b-0x5265c00,'time_end':b+0x5265c00,'service':SVC,'transferable':![],...a};}function quoteInput(a={}){return{'query_type':'service_quote','service_address':'bk3t-canal-stay','items':[{'name':FLEXIBLE,'quantity':0x1}],'context_network':'mainnet',...a};}beforeEach(()=>{vi['clearAllMocks'](),sdkMocks['network_get']['mockResolvedValue']('mainnet'),sdkMocks['localMarkList']['mockResolvedValue']([{'name':'bk3t-canal-stay'}]),sdkMocks['query_serviceContext']['mockResolvedValue']({'service':{'type_raw':'Service<0x2::wow::WOW>','sales':[{'name':FLEXIBLE,'price':{'balance':LIST_TOTAL['toString']()},'suspension':![]}]}}),sdkMocks['resolveAddress']['mockImplementation'](async a=>{if(a==='bk3t-canal-stay')return SVC;if(a==='bk3t-promo15'||a===COUPON)return COUPON;throw new Error('unresolvable:\x20'+a);}),sdkMocks['query_objects']['mockResolvedValue']({'objects':[makeCoupon()]});}),describe('service_quote\x20discount\x20pricing\x20(F-10)',()=>{it('no\x20discount\x20requested\x20→\x20undiscounted\x20total,\x20discount\x20block\x20null\x20(pre-fix\x20behavior\x20preserved)',async()=>{const a=await handleServiceQuote(quoteInput());expect(a['discount'])['toBeNull'](),expect(a['total_pay']['balance'])['toBe'](LIST_TOTAL['toString']());}),it('RATES\x20coupon\x20applies\x20with\x20integer\x20floor\x20division\x20—\x20reproduces\x20the\x20live\x20order\x20C\x20number',async()=>{const a=await handleServiceQuote(quoteInput({'discount':'bk3t-promo15'}));expect(a['discount'])['not']['toBeNull'](),expect(a['discount']['type'])['toBe']('rates'),expect(a['discount']['applied'])['toBe'](!![]),expect(a['discount']['list_total'])['toBe']('900000000'),expect(a['discount']['final_total'])['toBe']('765000000'),expect(a['total_pay']['balance'])['toBe']('765000000'),expect(a['total_pay']['note'])['toContain']('Discounted\x20total');}),it('MINUS\x20coupon\x20subtracts\x20a\x20fixed\x20amount\x20and\x20clamps\x20at\x20zero',async()=>{sdkMocks['query_objects']['mockResolvedValue']({'objects':[makeCoupon({'discount_type':0x1,'off':0x5f5e100})]});const a=await handleServiceQuote(quoteInput({'discount':COUPON}));expect(a['discount']['type'])['toBe']('minus'),expect(a['discount']['final_total'])['toBe']('800000000'),sdkMocks['query_objects']['mockResolvedValue']({'objects':[makeCoupon({'discount_type':0x1,'off':0x77359400})]});const b=await handleServiceQuote(quoteInput({'discount':COUPON}));expect(b['discount']['final_total'])['toBe']('0');}),it('unmet\x20benchmark\x20→\x20applied:false\x20+\x20burn\x20warning,\x20total\x20stays\x20at\x20list\x20price\x20(NOT\x20thrown)',async()=>{sdkMocks['query_objects']['mockResolvedValue']({'objects':[makeCoupon({'benchmark':(LIST_TOTAL+0x1n)['toString']()})]});const a=await handleServiceQuote(quoteInput({'discount':COUPON}));expect(a['discount']['applied'])['toBe'](![]),expect(a['discount']['benchmark_met'])['toBe'](![]),expect(a['total_pay']['balance'])['toBe'](LIST_TOTAL['toString']()),expect(a['discount']['note'])['toContain']('destroyed');}),it('benchmark\x20exactly\x20met\x20→\x20applies\x20(chain\x20uses\x20>=)',async()=>{sdkMocks['query_objects']['mockResolvedValue']({'objects':[makeCoupon({'benchmark':LIST_TOTAL['toString']()})]});const a=await handleServiceQuote(quoteInput({'discount':COUPON}));expect(a['discount']['applied'])['toBe'](!![]),expect(a['discount']['final_total'])['toBe']('765000000');}),it('benchmark\x20None\x20always\x20applies\x20(corrected\x20old\x20docs\x20claim)',async()=>{const a=await handleServiceQuote(quoteInput({'discount':COUPON}));expect(a['discount']['benchmark'])['toBeNull'](),expect(a['discount']['applied'])['toBe'](!![]);}),it('coupon\x20bound\x20to\x20another\x20service\x20→\x20rejected\x20like\x20the\x20chain\x20abort\x20(E_SERVICE_DISCOUNT_NOT_MATCH)',async()=>{sdkMocks['query_objects']['mockResolvedValue']({'objects':[makeCoupon({'service':OTHER_SVC})]}),await expect(handleServiceQuote(quoteInput({'discount':COUPON})))['rejects']['toThrow'](/E_SERVICE_DISCOUNT_NOT_MATCH/);}),it('coupon\x20outside\x20its\x20time\x20window\x20→\x20rejected\x20like\x20the\x20chain\x20abort\x20(E_DISCOUNT_TIME_INVALID)',async()=>{const a=Date['now']();sdkMocks['query_objects']['mockResolvedValue']({'objects':[makeCoupon({'time_start':a+0x3e8,'time_end':a+0x186a0})]}),await expect(handleServiceQuote(quoteInput({'discount':COUPON})))['rejects']['toThrow'](/E_DISCOUNT_TIME_INVALID/);}),it('unknown\x20coupon\x20object\x20→\x20clear\x20rejection,\x20never\x20a\x20silent\x20full-price\x20quote',async()=>{sdkMocks['query_objects']['mockResolvedValue']({'objects':[]}),await expect(handleServiceQuote(quoteInput({'discount':COUPON})))['rejects']['toThrow'](/not found/);});});
1
+ import{describe,it,expect,vi,beforeEach}from'vitest';const {sdkMocks}=vi['hoisted'](()=>({'sdkMocks':{'network_get':vi['fn'](),'localMarkList':vi['fn'](),'query_objects':vi['fn'](),'query_serviceContext':vi['fn'](),'resolveAddress':vi['fn']()}}));vi['mock']('@wowok/wowok',async a=>{const b=await a();return{...b,'Config':{'Instance':()=>({'network_get':sdkMocks['network_get']})},'LocalMark':{'Instance':()=>({'list':sdkMocks['localMarkList']})},'query_objects':sdkMocks['query_objects'],'query_serviceContext':sdkMocks['query_serviceContext']};}),vi['mock']('../../tools/handlers/name-resolution.js',()=>({'resolveAddress':sdkMocks['resolveAddress']})),vi['mock']('./facet-money.js',()=>({'formatMoneyAnnotation':async a=>({'display':a})}));import{handleServiceQuote}from'./service-quote.js';const SVC='0x'+'1'['repeat'](0x40),COUPON='0x'+'2'['repeat'](0x40),OTHER_SVC='0x'+'3'['repeat'](0x40),FLEXIBLE='Flexible\x20—\x20canal\x20view\x20double',LIST_TOTAL=0x35a4e900n;function makeCoupon(a={}){const b=Date['now']();return{'object':COUPON,'name':'bk3t-promo15','discount_type':0x0,'off':0x5dc,'benchmark':null,'time_start':b-0x5265c00,'time_end':b+0x5265c00,'service':SVC,'transferable':![],...a};}function quoteInput(a={}){return{'query_type':'service_quote','service_address':'bk3t-canal-stay','items':[{'name':FLEXIBLE,'quantity':0x1}],'context_network':'mainnet',...a};}beforeEach(()=>{vi['clearAllMocks'](),sdkMocks['network_get']['mockResolvedValue']('mainnet'),sdkMocks['localMarkList']['mockResolvedValue']([{'name':'bk3t-canal-stay'}]),sdkMocks['query_serviceContext']['mockResolvedValue']({'service':{'type_raw':'Service<0x2::wow::WOW>','sales':[{'name':FLEXIBLE,'price':{'balance':LIST_TOTAL['toString']()},'suspension':![]}]}}),sdkMocks['resolveAddress']['mockImplementation'](async a=>{if(a==='bk3t-canal-stay')return SVC;if(a==='bk3t-promo15'||a===COUPON)return COUPON;throw new Error('unresolvable:\x20'+a);}),sdkMocks['query_objects']['mockResolvedValue']({'objects':[makeCoupon()]});}),describe('service_quote\x20discount\x20pricing\x20(F-10)',()=>{it('no\x20discount\x20requested\x20→\x20undiscounted\x20total,\x20discount\x20block\x20null\x20(pre-fix\x20behavior\x20preserved)',async()=>{const a=await handleServiceQuote(quoteInput());expect(a['discount'])['toBeNull'](),expect(a['total_pay']['balance'])['toBe'](LIST_TOTAL['toString']());}),it('RATES\x20coupon\x20applies\x20with\x20integer\x20floor\x20division\x20—\x20reproduces\x20the\x20live\x20order\x20C\x20number',async()=>{const a=await handleServiceQuote(quoteInput({'discount':'bk3t-promo15'}));expect(a['discount'])['not']['toBeNull'](),expect(a['discount']['type'])['toBe']('rates'),expect(a['discount']['applied'])['toBe'](!![]),expect(a['discount']['list_total'])['toBe']('900000000'),expect(a['discount']['final_total'])['toBe']('765000000'),expect(a['total_pay']['balance'])['toBe']('765000000'),expect(a['total_pay']['note'])['toContain']('Discounted\x20total');}),it('MINUS\x20coupon\x20subtracts\x20a\x20fixed\x20amount\x20and\x20clamps\x20at\x20zero',async()=>{sdkMocks['query_objects']['mockResolvedValue']({'objects':[makeCoupon({'discount_type':0x1,'off':0x5f5e100})]});const a=await handleServiceQuote(quoteInput({'discount':COUPON}));expect(a['discount']['type'])['toBe']('minus'),expect(a['discount']['final_total'])['toBe']('800000000'),sdkMocks['query_objects']['mockResolvedValue']({'objects':[makeCoupon({'discount_type':0x1,'off':0x77359400})]});const b=await handleServiceQuote(quoteInput({'discount':COUPON}));expect(b['discount']['final_total'])['toBe']('0');}),it('unmet\x20benchmark\x20→\x20applied:false\x20+\x20attach\x20warning,\x20total\x20stays\x20at\x20list\x20price\x20(NOT\x20thrown)',async()=>{sdkMocks['query_objects']['mockResolvedValue']({'objects':[makeCoupon({'benchmark':(LIST_TOTAL+0x1n)['toString']()})]});const a=await handleServiceQuote(quoteInput({'discount':COUPON}));expect(a['discount']['applied'])['toBe'](![]),expect(a['discount']['benchmark_met'])['toBe'](![]),expect(a['total_pay']['balance'])['toBe'](LIST_TOTAL['toString']()),expect(a['discount']['note'])['toContain']('REJECTS'),expect(a['discount']['note'])['toContain']('coupon\x20preserved');}),it('benchmark\x20exactly\x20met\x20→\x20applies\x20(chain\x20uses\x20>=)',async()=>{sdkMocks['query_objects']['mockResolvedValue']({'objects':[makeCoupon({'benchmark':LIST_TOTAL['toString']()})]});const a=await handleServiceQuote(quoteInput({'discount':COUPON}));expect(a['discount']['applied'])['toBe'](!![]),expect(a['discount']['final_total'])['toBe']('765000000');}),it('benchmark\x20None\x20always\x20applies\x20(corrected\x20old\x20docs\x20claim)',async()=>{const a=await handleServiceQuote(quoteInput({'discount':COUPON}));expect(a['discount']['benchmark'])['toBeNull'](),expect(a['discount']['applied'])['toBe'](!![]);}),it('coupon\x20bound\x20to\x20another\x20service\x20→\x20rejected\x20like\x20the\x20chain\x20abort\x20(E_SERVICE_DISCOUNT_NOT_MATCH)',async()=>{sdkMocks['query_objects']['mockResolvedValue']({'objects':[makeCoupon({'service':OTHER_SVC})]}),await expect(handleServiceQuote(quoteInput({'discount':COUPON})))['rejects']['toThrow'](/E_SERVICE_DISCOUNT_NOT_MATCH/);}),it('coupon\x20outside\x20its\x20time\x20window\x20→\x20rejected\x20like\x20the\x20chain\x20abort\x20(E_DISCOUNT_TIME_INVALID)',async()=>{const a=Date['now']();sdkMocks['query_objects']['mockResolvedValue']({'objects':[makeCoupon({'time_start':a+0x3e8,'time_end':a+0x186a0})]}),await expect(handleServiceQuote(quoteInput({'discount':COUPON})))['rejects']['toThrow'](/E_DISCOUNT_TIME_INVALID/);}),it('unknown\x20coupon\x20object\x20→\x20clear\x20rejection,\x20never\x20a\x20silent\x20full-price\x20quote',async()=>{sdkMocks['query_objects']['mockResolvedValue']({'objects':[]}),await expect(handleServiceQuote(quoteInput({'discount':COUPON})))['rejects']['toThrow'](/not found/);});});const REWARD='0x'+'4'['repeat'](0x40),CLAIM_GUARD='0x'+'5'['repeat'](0x40);function makeReward(a={}){return{'object':REWARD,'description':'5-star\x20review\x20reward','balance':'500000000','record_count':0x3,'guards':[{'guard':CLAIM_GUARD,'amount':{'type':0x1,'value':'100000000'},'expiration_time':Date['now']()+0x5265c00}],...a};}function svcWithRewards(...a){sdkMocks['query_serviceContext']['mockResolvedValue']({'service':{'type_raw':'Service<0x2::wow::WOW>','sales':[{'name':FLEXIBLE,'price':{'balance':LIST_TOTAL['toString']()},'suspension':![]}],'rewards':a}});}describe('service_quote\x20reward\x20terms\x20(review\x20component\x20b2-5)',()=>{it('no\x20rewards\x20on\x20the\x20Service\x20→\x20reward_terms\x20null',async()=>{const a=await handleServiceQuote(quoteInput());expect(a['reward_terms'])['toBeNull']();}),it('fixed\x20amount\x20+\x20live\x20window\x20→\x20terms\x20with\x20coverage\x20estimate,\x20expired:false,\x20no\x20gaps',async()=>{svcWithRewards(REWARD),sdkMocks['query_objects']['mockResolvedValue']({'objects':[makeReward()]});const a=await handleServiceQuote(quoteInput());expect(a['reward_terms'])['not']['toBeNull']();const b=a['reward_terms']['rewards'][0x0];expect(b['reward'])['toBe'](REWARD),expect(b['description'])['toBe']('5-star\x20review\x20reward'),expect(b['pool_balance'])['toBe']('500000000'),expect(b['record_count'])['toBe'](0x3),expect(b['claims'][0x0]['guard'])['toBe'](CLAIM_GUARD),expect(b['claims'][0x0]['amount_type'])['toBe']('fixed'),expect(b['claims'][0x0]['amount'])['toBe']('100000000'),expect(b['claims'][0x0]['expired'])['toBe'](![]),expect(b['coverage'])['toMatch'](/~5 further claim/),expect(a['reward_terms']['data_gaps'])['toEqual']([]),expect(a['total_pay']['balance'])['toBe'](LIST_TOTAL['toString']());}),it('empty\x20pool\x20→\x20EMPTY\x20coverage\x20warning;\x20expired\x20window\x20→\x20expired:true',async()=>{svcWithRewards(REWARD),sdkMocks['query_objects']['mockResolvedValue']({'objects':[makeReward({'balance':'0','guards':[{'guard':CLAIM_GUARD,'amount':{'type':0x1,'value':'100000000'},'expiration_time':Date['now']()-0x3e8}]})]});const a=await handleServiceQuote(quoteInput()),b=a['reward_terms']['rewards'][0x0];expect(b['claims'][0x0]['expired'])['toBe'](!![]),expect(b['coverage'])['toContain']('EMPTY'),expect(b['coverage'])['toContain']('E_INSUFFICIENT_BALANCE');}),it('guard_submission\x20amount\x20→\x20coverage\x20null\x20(guard-decided),\x20amount\x20carries\x20the\x20submission\x20identifier',async()=>{svcWithRewards(REWARD),sdkMocks['query_objects']['mockResolvedValue']({'objects':[makeReward({'guards':[{'guard':CLAIM_GUARD,'amount':{'type':0x0,'value':0x7}}]})]});const a=await handleServiceQuote(quoteInput()),b=a['reward_terms']['rewards'][0x0];expect(b['claims'][0x0]['amount_type'])['toBe']('guard_submission'),expect(b['claims'][0x0]['amount'])['toContain']('7'),expect(b['claims'][0x0]['amount_display'])['toBeNull'](),expect(b['coverage'])['toBeNull']();}),it('no\x20window\x20set\x20→\x20expiration\x20null\x20and\x20expired\x20null\x20(claimable\x20until\x20guard\x20removal)',async()=>{svcWithRewards(REWARD),sdkMocks['query_objects']['mockResolvedValue']({'objects':[makeReward({'guards':[{'guard':CLAIM_GUARD,'amount':{'type':0x1,'value':'100000000'}}]})]});const a=await handleServiceQuote(quoteInput()),b=a['reward_terms']['rewards'][0x0]['claims'][0x0];expect(b['expiration_time'])['toBeNull'](),expect(b['expiration_display'])['toBeNull'](),expect(b['expired'])['toBeNull']();}),it('unreadable\x20reward\x20object\x20→\x20data_gaps\x20note,\x20quote\x20still\x20succeeds\x20(fail-soft)',async()=>{svcWithRewards(REWARD),sdkMocks['query_objects']['mockResolvedValue']({'objects':[]});const a=await handleServiceQuote(quoteInput());expect(a['reward_terms'])['not']['toBeNull'](),expect(a['reward_terms']['rewards'])['toEqual']([]),expect(a['reward_terms']['data_gaps'][0x0])['toContain'](REWARD),expect(a['total_pay']['balance'])['toBe'](LIST_TOTAL['toString']());}),it('reward\x20lookup\x20throws\x20→\x20whole\x20lookup\x20degrades\x20to\x20one\x20gap\x20note,\x20never\x20thrown',async()=>{svcWithRewards(REWARD),sdkMocks['query_objects']['mockRejectedValue'](new Error('rpc\x20down'));const a=await handleServiceQuote(quoteInput());expect(a['reward_terms']['rewards'])['toEqual']([]),expect(a['reward_terms']['data_gaps'][0x0])['toContain']('rpc\x20down'),expect(a['total_pay']['balance'])['toBe'](LIST_TOTAL['toString']());});});
@@ -43,6 +43,7 @@ export interface DemandFacts {
43
43
  address: string;
44
44
  service?: string;
45
45
  acceptance_score?: number;
46
+ scoredAt?: number;
46
47
  }>;
47
48
  rewards?: string[];
48
49
  guards?: string[];
@@ -1 +1 @@
1
- import{objectTypeFromAddress,ObjectType}from'@wowok/wowok';import{resolveAddress as a350a}from'../tools/handlers/name-resolution.js';import{handleObjectPanorama}from'../playbooks/service-build/object-panorama.js';import{handleServicePanorama}from'../playbooks/service-build/service-panorama.js';import{handleMachinePanorama}from'../playbooks/service-build/machine-panorama.js';import{assembleOrderReview}from'./order.js';import{assembleServiceReview}from'./service.js';import{assembleMachineReview}from'./machine.js';import{assembleArbReview}from'./arb.js';import{assembleDemandReview}from'./demand.js';import{assembleRepositoryReview}from'./repository.js';import{assembleProgressReview}from'./progress.js';export const REVIEW_PACK_TYPES=['Order','Service','Arb','Demand','Repository','Progress','Machine'];export async function handleReviewPack(a){const b=a['object_address'];if(!b)throw new Error('\x27object_address\x27\x20is\x20required\x20for\x20review_pack');const c=await a350a(b,'object_address'),d=objectTypeFromAddress(c);if(d===ObjectType['Order']){const g=await handleObjectPanorama(a);if(g['object_type']!=='Order')throw new Error('review_pack:\x20expected\x20an\x20Order,\x20resolved\x20to\x20'+g['object_type']);return assembleOrderReview(g);}if(d===ObjectType['Service']){const h=await handleServicePanorama({...a,'service_address':c});return assembleServiceReview(h);}if(d===ObjectType['Machine']){const i=await handleMachinePanorama({...a,'object_address':c});if(i['machineAddress']?.['toLowerCase']()!==c['toLowerCase']())throw new Error('review_pack:\x20expected\x20a\x20Machine,\x20resolved\x20to\x20'+i['machineAddress']);return assembleMachineReview(i);}const e={[ObjectType['Arb']]:assembleArbReview,[ObjectType['Demand']]:assembleDemandReview,[ObjectType['Repository']]:assembleRepositoryReview,[ObjectType['Progress']]:assembleProgressReview},f=d?e[d]:undefined;if(f){const j=await handleObjectPanorama(a);if(j['object_type']!==d)throw new Error('review_pack:\x20expected\x20a\x20'+d+',\x20resolved\x20to\x20'+j['object_type']);return f(j);}throw new Error('review_pack:\x20unsupported\x20object\x20type\x20\x27'+(d??'unknown')+'\x27\x20—\x20supported:\x20'+REVIEW_PACK_TYPES['join'](',\x20')+'.\x20Other\x20types\x20keep\x20object_panorama\x20/\x20machine_panorama\x20/\x20service_panorama.');}
1
+ import{objectTypeFromAddress,ObjectType}from'@wowok/wowok';import{resolveAddress as a354a}from'../tools/handlers/name-resolution.js';import{handleObjectPanorama}from'../playbooks/service-build/object-panorama.js';import{handleServicePanorama}from'../playbooks/service-build/service-panorama.js';import{handleMachinePanorama}from'../playbooks/service-build/machine-panorama.js';import{assembleOrderReview}from'./order.js';import{assembleServiceReview}from'./service.js';import{assembleMachineReview}from'./machine.js';import{assembleArbReview}from'./arb.js';import{assembleDemandReview}from'./demand.js';import{assembleRepositoryReview}from'./repository.js';import{assembleProgressReview}from'./progress.js';export const REVIEW_PACK_TYPES=['Order','Service','Arb','Demand','Repository','Progress','Machine'];export async function handleReviewPack(a){const b=a['object_address'];if(!b)throw new Error('\x27object_address\x27\x20is\x20required\x20for\x20review_pack');const c=await a354a(b,'object_address'),d=objectTypeFromAddress(c);if(d===ObjectType['Order']){const g=await handleObjectPanorama(a);if(g['object_type']!=='Order')throw new Error('review_pack:\x20expected\x20an\x20Order,\x20resolved\x20to\x20'+g['object_type']);return assembleOrderReview(g);}if(d===ObjectType['Service']){const h=await handleServicePanorama({...a,'service_address':c});return assembleServiceReview(h);}if(d===ObjectType['Machine']){const i=await handleMachinePanorama({...a,'object_address':c});if(i['machineAddress']?.['toLowerCase']()!==c['toLowerCase']())throw new Error('review_pack:\x20expected\x20a\x20Machine,\x20resolved\x20to\x20'+i['machineAddress']);return assembleMachineReview(i);}const e={[ObjectType['Arb']]:assembleArbReview,[ObjectType['Demand']]:assembleDemandReview,[ObjectType['Repository']]:assembleRepositoryReview,[ObjectType['Progress']]:assembleProgressReview},f=d?e[d]:undefined;if(f){const j=await handleObjectPanorama(a);if(j['object_type']!==d)throw new Error('review_pack:\x20expected\x20a\x20'+d+',\x20resolved\x20to\x20'+j['object_type']);return f(j);}throw new Error('review_pack:\x20unsupported\x20object\x20type\x20\x27'+(d??'unknown')+'\x27\x20—\x20supported:\x20'+REVIEW_PACK_TYPES['join'](',\x20')+'.\x20Other\x20types\x20keep\x20object_panorama\x20/\x20machine_panorama\x20/\x20service_panorama.');}
@@ -0,0 +1,8 @@
1
+ export interface ServerInstancePin {
2
+ pid: number;
3
+ version: string;
4
+ entry: string;
5
+ started_at: string;
6
+ }
7
+ export declare function listLiveInstances(): ServerInstancePin[];
8
+ export declare function pinInstance(version: string, entry: string): string[];
@@ -0,0 +1 @@
1
+ import{readFileSync,writeFileSync,mkdirSync}from'fs';import{join}from'path';import{getWowokDataDir}from'@wowok/wowok';function registryPath(){return join(getWowokDataDir(),'server-instances.json');}function pidAlive(a){try{return process['kill'](a,0x0),!![];}catch(b){return b?.['code']==='EPERM';}}function readRegistry(){try{const a=JSON['parse'](readFileSync(registryPath(),'utf-8'));return a&&typeof a==='object'?a:{};}catch{return{};}}function writeRegistry(a){try{mkdirSync(getWowokDataDir(),{'recursive':!![]}),writeFileSync(registryPath(),JSON['stringify'](a,null,0x2),'utf-8');}catch{}}export function listLiveInstances(){const a=readRegistry(),b={};for(const [c,d]of Object['entries'](a)){if(pidAlive(Number(c)))b[c]=d;}return Object['values'](b);}export function pinInstance(a,b){const c=[];try{const d=readRegistry();for(const [e]of Object['entries'](d)){if(!pidAlive(Number(e)))delete d[e];}for(const [f,g]of Object['entries'](d)){if(Number(f)===process['pid'])continue;g['version']!==a&&c['push']('instance\x20drift:\x20pid\x20'+f+'\x20(v'+g['version']+',\x20'+g['entry']+',\x20started\x20'+g['started_at']+')\x20'+('serves\x20v'+g['version']+'\x20while\x20this\x20instance\x20serves\x20v'+a+'\x20—\x20a\x20call\x20routed\x20to\x20')+'the\x20older\x20pid\x20answers\x20with\x20stale\x20schemas/templates');}d[String(process['pid'])]={'pid':process['pid'],'version':a,'entry':b,'started_at':new Date()['toISOString']()},writeRegistry(d);}catch{}return c;}
@@ -1 +1 @@
1
- import{CONFIRMATION_RULES,resolveOverrideId}from'../knowledge/safety-rules.js';import{isEnabled as a364a}from'../config/index.js';import{isPlanPreapproved}from'../goal/plan-approval.js';export function isConfirmGateEnabled(){return a364a('confirm_gate');}const internalErrorCounts={};function logInternalError(a,b){const c=a;internalErrorCounts[c]=(internalErrorCounts[c]??0x0)+0x1;const d=internalErrorCounts[c];console['warn']('[ConfirmGate]\x20internal_error\x20context=\x22'+a+'\x22\x20count='+d+'\x20error='+(b instanceof Error?b['message']:String(b)));}export function getFailMode(a){switch(a){case'irreversible':case'publish':case'amount':return'closed';case'standard':case'none':default:return'open';}}function buildInternalErrorResult(a,b,c){const d=b instanceof Error?b['message']:b!==undefined?String(b):undefined;return{'pass':![],'level':'irreversible','preview':{'level':'irreversible','operation':a,'irreversible':!![],'warnings':[...c?['ConfirmGate\x20rule\x20\x27'+c+'\x27\x20matched\x20but\x20its\x20preview\x20could\x20not\x20be\x20generated.']:['An\x20error\x20occurred\x20while\x20matching\x20confirmation\x20rules.'],...d!==undefined?['Reason:\x20'+d]:[],'The\x20operation\x20was\x20NOT\x20executed.\x20Review\x20the\x20parameters\x20for\x20malformed\x20values\x20(e.g.\x20decimal\x20amounts\x20instead\x20of\x20smallest-unit\x20integers)\x20before\x20confirming.']},'rule_id':'internal_error'};}export function confirmGate(a,b,c,d,f,g){if(!isConfirmGateEnabled())return{'pass':!![]};if(c?.['confirmed']===!![])return{'pass':!![]};if(c?.['dry_run']===!![])return{'pass':!![]};let h,i=null;try{h=CONFIRMATION_RULES['find'](n=>{try{return n['when'](a,b,c);}catch(o){logInternalError('rule_when:'+n['id'],o);if(getFailMode(n['level'])==='closed')throw o;return![];}});}catch(n){i=n;}if(i)return logInternalError('rule_search',i),buildInternalErrorResult(a,i);if(!h)return{'pass':!![]};if(getFailMode(h['level'])==='open'&&isPlanPreapproved(c))return{'pass':!![]};const j=resolveOverrideId(h['id'],a),k=j?f?.[j]:undefined;if(k==='auto')return{'pass':!![]};const l=c?.['confirm_mode']==='quiet'||c?.['confirm_mode']==='streamlined'?c['confirm_mode']:'full';if(l!=='full'&&k!=='block'&&getFailMode(h['level'])==='open')return{'pass':!![]};if(k!=='block'&&g?.['intent_bypass']!==![]&&h['bypass_on_explicit_intent']&&d&&d['length']>0x0){const o=d['map'](q=>q['toLowerCase']()),p=h['bypass_on_explicit_intent']['some'](q=>o['some'](r=>r['includes'](q['toLowerCase']())));if(p)return{'pass':!![]};}let m;try{m=h['preview'](a,b,c);}catch(q){logInternalError('rule_preview:'+h['id'],q);if(getFailMode(h['level'])==='closed')return buildInternalErrorResult(a,q,h['id']);return{'pass':!![]};}return{'pass':![],'level':h['level'],'preview':m,'rule_id':h['id']};}export function isExplicitlyConfirmed(a){return a?.['confirmed']===!![];}
1
+ import{CONFIRMATION_RULES,resolveOverrideId}from'../knowledge/safety-rules.js';import{isEnabled as a369a}from'../config/index.js';import{isPlanPreapproved}from'../goal/plan-approval.js';export function isConfirmGateEnabled(){return a369a('confirm_gate');}const internalErrorCounts={};function logInternalError(a,b){const c=a;internalErrorCounts[c]=(internalErrorCounts[c]??0x0)+0x1;const d=internalErrorCounts[c];console['warn']('[ConfirmGate]\x20internal_error\x20context=\x22'+a+'\x22\x20count='+d+'\x20error='+(b instanceof Error?b['message']:String(b)));}export function getFailMode(a){switch(a){case'irreversible':case'publish':case'amount':return'closed';case'standard':case'none':default:return'open';}}function buildInternalErrorResult(a,b,c){const d=b instanceof Error?b['message']:b!==undefined?String(b):undefined;return{'pass':![],'level':'irreversible','preview':{'level':'irreversible','operation':a,'irreversible':!![],'warnings':[...c?['ConfirmGate\x20rule\x20\x27'+c+'\x27\x20matched\x20but\x20its\x20preview\x20could\x20not\x20be\x20generated.']:['An\x20error\x20occurred\x20while\x20matching\x20confirmation\x20rules.'],...d!==undefined?['Reason:\x20'+d]:[],'The\x20operation\x20was\x20NOT\x20executed.\x20Review\x20the\x20parameters\x20for\x20malformed\x20values\x20(e.g.\x20decimal\x20amounts\x20instead\x20of\x20smallest-unit\x20integers)\x20before\x20confirming.']},'rule_id':'internal_error'};}export function confirmGate(a,b,c,d,f,g){if(!isConfirmGateEnabled())return{'pass':!![]};if(c?.['confirmed']===!![])return{'pass':!![]};if(c?.['dry_run']===!![])return{'pass':!![]};let h,i=null;try{h=CONFIRMATION_RULES['find'](n=>{try{return n['when'](a,b,c);}catch(o){logInternalError('rule_when:'+n['id'],o);if(getFailMode(n['level'])==='closed')throw o;return![];}});}catch(n){i=n;}if(i)return logInternalError('rule_search',i),buildInternalErrorResult(a,i);if(!h)return{'pass':!![]};if(getFailMode(h['level'])==='open'&&isPlanPreapproved(c))return{'pass':!![]};const j=resolveOverrideId(h['id'],a),k=j?f?.[j]:undefined;if(k==='auto')return{'pass':!![]};const l=c?.['confirm_mode']==='quiet'||c?.['confirm_mode']==='streamlined'?c['confirm_mode']:'full';if(l!=='full'&&k!=='block'&&getFailMode(h['level'])==='open')return{'pass':!![]};if(k!=='block'&&g?.['intent_bypass']!==![]&&h['bypass_on_explicit_intent']&&d&&d['length']>0x0){const o=d['map'](q=>q['toLowerCase']()),p=h['bypass_on_explicit_intent']['some'](q=>o['some'](r=>r['includes'](q['toLowerCase']())));if(p)return{'pass':!![]};}let m;try{m=h['preview'](a,b,c);}catch(q){logInternalError('rule_preview:'+h['id'],q);if(getFailMode(h['level'])==='closed')return buildInternalErrorResult(a,q,h['id']);return{'pass':!![]};}return{'pass':![],'level':h['level'],'preview':m,'rule_id':h['id']};}export function isExplicitlyConfirmed(a){return a?.['confirmed']===!![];}
@@ -14,6 +14,16 @@ export declare const BenchmarkMigrationSchema: z.ZodObject<{
14
14
  description: z.ZodOptional<z.ZodString>;
15
15
  url: z.ZodOptional<z.ZodString>;
16
16
  fee_overrides: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodNumber, z.ZodString]>>>;
17
+ guard_resolutions: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodObject<{
18
+ kind: z.ZodLiteral<"template">;
19
+ template_id: z.ZodString;
20
+ params: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
21
+ }, z.core.$strict>, z.ZodObject<{
22
+ kind: z.ZodLiteral<"inline">;
23
+ description: z.ZodOptional<z.ZodString>;
24
+ table: z.ZodArray<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
25
+ root: z.ZodUnknown;
26
+ }, z.core.$strict>]>>>;
17
27
  log: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
18
28
  network: z.ZodOptional<z.ZodEnum<{
19
29
  testnet: "testnet";
@@ -75,6 +85,7 @@ export declare const BenchmarkMigrationOutputSchema: z.ZodObject<{
75
85
  red_flags: z.ZodArray<z.ZodString>;
76
86
  }, z.core.$strip>;
77
87
  plan: z.ZodRecord<z.ZodString, z.ZodUnknown>;
88
+ next_action: z.ZodString;
78
89
  }, z.core.$strip>, z.ZodObject<{
79
90
  action: z.ZodLiteral<"template_scan">;
80
91
  scan: z.ZodObject<{
@@ -143,6 +154,7 @@ export declare const BenchmarkMigrationOutputSchema: z.ZodObject<{
143
154
  mainnet: "mainnet";
144
155
  }>;
145
156
  }, z.core.$strip>;
157
+ next_action: z.ZodString;
146
158
  }, z.core.$strip>, z.ZodObject<{
147
159
  action: z.ZodLiteral<"migration_review">;
148
160
  log: z.ZodObject<{
@@ -192,6 +204,7 @@ export declare const BenchmarkMigrationOutputSchema: z.ZodObject<{
192
204
  manual_review_count: z.ZodNumber;
193
205
  risk_passed: z.ZodBoolean;
194
206
  }, z.core.$strip>;
207
+ next_action: z.ZodString;
195
208
  }, z.core.$strip>, z.ZodObject<{
196
209
  action: z.ZodLiteral<"migration_apply">;
197
210
  template_id: z.ZodString;
@@ -224,6 +237,7 @@ export declare const BenchmarkMigrationOutputSchema: z.ZodObject<{
224
237
  red_flags: z.ZodArray<z.ZodString>;
225
238
  }, z.core.$strip>;
226
239
  plan: z.ZodRecord<z.ZodString, z.ZodUnknown>;
240
+ next_action: z.ZodString;
227
241
  }, z.core.$strip>], "action">;
228
242
  }, z.core.$strict>;
229
243
  export type BenchmarkMigrationOutput = z.infer<typeof BenchmarkMigrationOutputSchema>;
@@ -1 +1 @@
1
- import{z}from'zod';const TemplateSummarySchema=z['object']({'id':z['string']()['describe']('Template\x20id\x20\x27<industry>/<variant>\x27,\x20e.g.\x20\x27retail/scale-marketplace\x27.'),'industry':z['string']()['describe']('Industry\x20vertical.'),'variant':z['string']()['describe']('Business-model\x20variant\x20slug.'),'product_ref':z['string']()['optional']()['describe']('Benchmark\x20product\x20slug\x20this\x20archetype\x20models\x20(e.g.\x20\x27amazon\x27).\x20The\x20only\x20sanctioned\x20company\x20name;\x20users\x20can\x20pick\x20a\x20template\x20by\x20naming\x20the\x20incumbent\x20product.'),'archetype':z['enum'](['leader','challenger']),'key_risk':z['string']()['describe']('Primary\x20risk\x20this\x20template\x20mitigates.'),'node_count':z['number']()['describe']('Machine\x20node\x20count.'),'guard_count':z['number']()['describe']('Guard\x20template\x20count.'),'recommended_role':z['enum'](['merchant','supplier','both'])})['describe']('Compact\x20template\x20listing\x20row.'),TemplateScanFindingSchema=z['object']({'rule_id':z['string']()['optional']()['describe']('Rule\x20id\x20when\x20known\x20(e.g.\x20\x27R-M3-01\x27,\x20\x27R1\x27).'),'severity':z['enum'](['low','medium','high','critical']),'title':z['string'](),'detail':z['string'](),'suggestion':z['string']()})['describe']('One\x20pre-deploy\x20risk\x20finding.'),MigrationEntrySchema=z['object']({'source_element':z['string']()['describe']('Competitor-side\x20element.'),'target_object':z['string']()['optional']()['describe']('WoWok\x20object/mechanism\x20it\x20maps\x20to.'),'mapping_note':z['string']()['describe']('One-line\x20mapping\x20explanation.'),'reason':z['string']()['optional']()['describe']('Why\x20it\x20cannot\x20be\x20migrated,\x20or\x20why\x20it\x20needs\x20a\x20decision.')})['describe']('One\x20competitor\x20element\x20and\x20its\x20WoWok\x20mapping\x20outcome.'),MigrationLogSchema=z['object']({'source':z['object']({'url':z['string']()['optional'](),'description':z['string'](),'detected_industry':z['string'](),'matched_template':z['string']()['describe']('Matched\x20template\x20id\x20\x27<industry>/<variant>\x27.')})['describe']('Migration\x20source\x20provenance.'),'mapped':z['array'](MigrationEntrySchema)['describe']('Elements\x20that\x20map\x20cleanly\x20to\x20WoWok\x20objects.'),'unmapped':z['array'](MigrationEntrySchema)['describe']('Elements\x20that\x20cannot\x20be\x20migrated,\x20with\x20reasons.'),'manual_review':z['array'](MigrationEntrySchema)['describe']('Elements\x20requiring\x20an\x20explicit\x20user\x20decision.'),'wowok_advantages':z['array'](z['string']())['describe']('WoWok\x20platform\x20advantages\x20surfaced\x20during\x20migration.'),'customizable_modules':z['array'](z['string']())['describe']('Business-module\x20ids\x20the\x20user\x20can\x20customize.'),'role_assessment':z['object']({'recommended':z['string'](),'rationale':z['string'](),'alternatives':z['array'](z['string']())})['describe']('Merchant\x20vs\x20supplier\x20role\x20assessment.'),'risk_check':z['object']({'passed':z['boolean'](),'findings':z['array'](z['string']())})['describe']('Dry-run\x20risk\x20check\x20against\x20the\x20matched\x20template.'),'network':z['enum'](['testnet','mainnet'])['describe']('Target\x20network\x20(default\x20testnet).')})['describe']('Structured\x20competitor-migration\x20log.');export const BenchmarkMigrationSchema=z['object']({'action':z['enum'](['template_list','template_get','template_generate','template_scan','migration_import','migration_review','migration_apply'])['describe']('Action:\x20\x27template_list\x27\x20=\x20list\x20the\x20loaded\x20MD\x20industry\x20templates\x20(optional\x20industry\x20filter);\x20'+'\x27template_get\x27\x20=\x20fetch\x20one\x20template\x20by\x20id\x20(template_id\x20required);\x20'+'\x27template_generate\x27\x20=\x20generate\x20a\x20creation\x20plan\x20from\x20a\x20template\x20via\x20the\x20merchant-guide\x20'+'pipeline\x20(template_id\x20required;\x20scan-first\x20—\x20CRITICAL\x20findings\x20block;\x20never\x20executes\x20on-chain);\x20'+'\x27template_scan\x27\x20=\x20pre-deploy\x20risk\x20scan\x20of\x20one\x20template\x20(template_id\x20required;\x20returns\x20'+'risk_level/findings/red_flags;\x20CRITICAL\x20blocks\x20generation/apply);\x20'+'\x27migration_import\x27\x20=\x20competitor\x20URL/description\x20→\x20migration\x20plan\x20+\x20MigrationLog\x20'+'(description\x20required);\x20'+'\x27migration_review\x27\x20=\x20surface\x20the\x20MigrationLog\x20for\x20user\x20confirmation\x20(log\x20required);\x20'+'\x27migration_apply\x27\x20=\x20run\x20the\x20approved\x20template\x20through\x20the\x20merchant-guide\x20pipeline\x20'+'(template_id\x20required;\x20scan-first\x20—\x20CRITICAL\x20findings\x20block;\x20default\x20network\x20testnet).'),'template_id':z['string']()['optional']()['describe']('Template\x20id\x20\x27<industry>/<variant>\x27\x20(required\x20for\x20template_get\x20/\x20template_generate\x20/\x20template_scan\x20/\x20migration_apply),\x20e.g.\x20\x27retail/scale-marketplace\x27.'),'industry':z['string']()['optional']()['describe']('Industry\x20filter\x20for\x20template_list;\x20industry\x20hint\x20for\x20migration_import.\x20'+'Any\x20registered\x20industry\x20is\x20accepted\x20(builtin:\x20freelance,\x20rental,\x20education,\x20'+'travel,\x20subscription,\x20retail;\x20plus\x20custom\x20industries\x20registered\x20via\x20industry\x20packs).\x20'+'Aliases\x20are\x20resolved\x20(e.g.\x20\x27ecommerce\x27\x20→\x20\x27retail\x27).'),'description':z['string']()['optional']()['describe']('Natural-language\x20business/competitor\x20description\x20(required\x20for\x20migration_import;\x20used\x20by\x20template_generate\x20as\x20the\x20intent\x20text).'),'url':z['string']()['optional']()['describe']('Competitor\x20store/profile\x20URL\x20for\x20migration_import\x20(recorded\x20as\x20provenance\x20only).'),'fee_overrides':z['record'](z['string'](),z['union']([z['number'](),z['string']()]))['optional']()['describe']('Template\x20fee-parameter\x20overrides\x20for\x20template_generate\x20(e.g.\x20commission_rate_bps).'),'log':z['record'](z['string'](),z['unknown']())['optional']()['describe']('A\x20prior\x20MigrationLog\x20(required\x20for\x20migration_review).'),'network':z['enum'](['testnet','mainnet'])['optional']()['describe']('Target\x20network\x20for\x20migration_import\x20/\x20migration_apply\x20(default\x20testnet;\x20mainnet\x20requires\x20explicit\x20user\x20confirmation).')})['strict']();const ScanSummarySchema=z['object']({'risk_level':z['enum'](['low','medium','high','critical']),'passed':z['boolean'](),'finding_count':z['number'](),'findings_by_severity':z['record'](z['string'](),z['number']())['describe']('Finding\x20count\x20keyed\x20by\x20severity.'),'findings':z['array'](TemplateScanFindingSchema)['describe']('Every\x20finding\x20with\x20its\x20rule\x20id,\x20detail\x20and\x20suggestion.'),'red_flags':z['array'](z['string']())})['describe']('Pre-deploy\x20scan\x20summary\x20(generation/apply\x20only\x20runs\x20when\x20passed).');export const BenchmarkMigrationOutputSchema=z['object']({'result':z['discriminatedUnion']('action',[z['object']({'action':z['literal']('template_list'),'count':z['number']()['describe']('Number\x20of\x20templates\x20returned.'),'templates':z['array'](TemplateSummarySchema)['describe']('Template\x20listing\x20rows.'),'load_errors':z['array'](z['string']())['describe']('Template\x20files\x20that\x20failed\x20to\x20load/validate\x20(never\x20silently\x20dropped).')}),z['object']({'action':z['literal']('template_get'),'template':z['record'](z['string'](),z['unknown']())['describe']('Full\x20template\x20object\x20(machine_shape/guards/allocator/fee_params/body/...).')}),z['object']({'action':z['literal']('template_generate'),'template_id':z['string'](),'scan':ScanSummarySchema,'plan':z['record'](z['string'](),z['unknown']())['describe']('Creation\x20plan\x20from\x20the\x20merchant-guide\x20pipeline\x20(never\x20executed\x20on-chain).')}),z['object']({'action':z['literal']('template_scan'),'scan':z['object']({'template_id':z['string'](),'risk_level':z['enum'](['low','medium','high','critical']),'passed':z['boolean'](),'findings':z['array'](TemplateScanFindingSchema),'red_flags':z['array'](z['string']())})['describe']('Full\x20pre-deploy\x20scan\x20result.')}),z['object']({'action':z['literal']('migration_import'),'log':MigrationLogSchema['describe']('The\x20structured\x20migration\x20log.')}),z['object']({'action':z['literal']('migration_review'),'log':MigrationLogSchema['describe']('The\x20migration\x20log\x20under\x20review.'),'review_summary':z['object']({'mapped_count':z['number'](),'unmapped_count':z['number'](),'manual_review_count':z['number'](),'risk_passed':z['boolean']()})['describe']('Counts\x20+\x20risk\x20status\x20for\x20the\x20confirmation\x20screen.')}),z['object']({'action':z['literal']('migration_apply'),'template_id':z['string'](),'network':z['enum'](['testnet','mainnet']),'scan':ScanSummarySchema,'plan':z['record'](z['string'](),z['unknown']())['describe']('Creation\x20plan\x20from\x20the\x20merchant-guide\x20pipeline\x20(never\x20executed\x20on-chain).')})])})['strict']();
1
+ import{z}from'zod';import{GuardResolutionInputSchema}from'../goal/planning.js';const TemplateSummarySchema=z['object']({'id':z['string']()['describe']('Template\x20id\x20\x27<industry>/<variant>\x27,\x20e.g.\x20\x27retail/scale-marketplace\x27.'),'industry':z['string']()['describe']('Industry\x20vertical.'),'variant':z['string']()['describe']('Business-model\x20variant\x20slug.'),'product_ref':z['string']()['optional']()['describe']('Benchmark\x20product\x20slug\x20this\x20archetype\x20models\x20(e.g.\x20\x27amazon\x27).\x20The\x20only\x20sanctioned\x20company\x20name;\x20users\x20can\x20pick\x20a\x20template\x20by\x20naming\x20the\x20incumbent\x20product.'),'archetype':z['enum'](['leader','challenger']),'key_risk':z['string']()['describe']('Primary\x20risk\x20this\x20template\x20mitigates.'),'node_count':z['number']()['describe']('Machine\x20node\x20count.'),'guard_count':z['number']()['describe']('Guard\x20template\x20count.'),'recommended_role':z['enum'](['merchant','supplier','both'])})['describe']('Compact\x20template\x20listing\x20row.'),TemplateScanFindingSchema=z['object']({'rule_id':z['string']()['optional']()['describe']('Rule\x20id\x20when\x20known\x20(e.g.\x20\x27R-M3-01\x27,\x20\x27R1\x27).'),'severity':z['enum'](['low','medium','high','critical']),'title':z['string'](),'detail':z['string'](),'suggestion':z['string']()})['describe']('One\x20pre-deploy\x20risk\x20finding.'),MigrationEntrySchema=z['object']({'source_element':z['string']()['describe']('Competitor-side\x20element.'),'target_object':z['string']()['optional']()['describe']('WoWok\x20object/mechanism\x20it\x20maps\x20to.'),'mapping_note':z['string']()['describe']('One-line\x20mapping\x20explanation.'),'reason':z['string']()['optional']()['describe']('Why\x20it\x20cannot\x20be\x20migrated,\x20or\x20why\x20it\x20needs\x20a\x20decision.')})['describe']('One\x20competitor\x20element\x20and\x20its\x20WoWok\x20mapping\x20outcome.'),MigrationLogSchema=z['object']({'source':z['object']({'url':z['string']()['optional'](),'description':z['string'](),'detected_industry':z['string'](),'matched_template':z['string']()['describe']('Matched\x20template\x20id\x20\x27<industry>/<variant>\x27.')})['describe']('Migration\x20source\x20provenance.'),'mapped':z['array'](MigrationEntrySchema)['describe']('Elements\x20that\x20map\x20cleanly\x20to\x20WoWok\x20objects.'),'unmapped':z['array'](MigrationEntrySchema)['describe']('Elements\x20that\x20cannot\x20be\x20migrated,\x20with\x20reasons.'),'manual_review':z['array'](MigrationEntrySchema)['describe']('Elements\x20requiring\x20an\x20explicit\x20user\x20decision.'),'wowok_advantages':z['array'](z['string']())['describe']('WoWok\x20platform\x20advantages\x20surfaced\x20during\x20migration.'),'customizable_modules':z['array'](z['string']())['describe']('Business-module\x20ids\x20the\x20user\x20can\x20customize.'),'role_assessment':z['object']({'recommended':z['string'](),'rationale':z['string'](),'alternatives':z['array'](z['string']())})['describe']('Merchant\x20vs\x20supplier\x20role\x20assessment.'),'risk_check':z['object']({'passed':z['boolean'](),'findings':z['array'](z['string']())})['describe']('Dry-run\x20risk\x20check\x20against\x20the\x20matched\x20template.'),'network':z['enum'](['testnet','mainnet'])['describe']('Target\x20network\x20(default\x20testnet).')})['describe']('Structured\x20competitor-migration\x20log.');export const BenchmarkMigrationSchema=z['object']({'action':z['enum'](['template_list','template_get','template_generate','template_scan','migration_import','migration_review','migration_apply'])['describe']('Action:\x20\x27template_list\x27\x20=\x20list\x20the\x20loaded\x20MD\x20industry\x20templates\x20(optional\x20industry\x20filter);\x20'+'\x27template_get\x27\x20=\x20fetch\x20one\x20template\x20by\x20id\x20(template_id\x20required);\x20'+'\x27template_generate\x27\x20=\x20generate\x20a\x20creation\x20plan\x20from\x20a\x20template\x20via\x20the\x20merchant-guide\x20'+'pipeline\x20(template_id\x20required;\x20scan-first\x20—\x20CRITICAL\x20findings\x20block;\x20never\x20executes\x20on-chain);\x20'+'\x27template_scan\x27\x20=\x20pre-deploy\x20risk\x20scan\x20of\x20one\x20template\x20(template_id\x20required;\x20returns\x20'+'risk_level/findings/red_flags;\x20CRITICAL\x20blocks\x20generation/apply);\x20'+'\x27migration_import\x27\x20=\x20competitor\x20URL/description\x20→\x20migration\x20plan\x20+\x20MigrationLog\x20'+'(description\x20required);\x20'+'\x27migration_review\x27\x20=\x20surface\x20the\x20MigrationLog\x20for\x20user\x20confirmation\x20(log\x20required);\x20'+'\x27migration_apply\x27\x20=\x20run\x20the\x20approved\x20template\x20through\x20the\x20merchant-guide\x20pipeline\x20'+'(template_id\x20required;\x20scan-first\x20—\x20CRITICAL\x20findings\x20block;\x20default\x20network\x20testnet).'),'template_id':z['string']()['optional']()['describe']('Template\x20id\x20\x27<industry>/<variant>\x27\x20(required\x20for\x20template_get\x20/\x20template_generate\x20/\x20template_scan\x20/\x20migration_apply),\x20e.g.\x20\x27retail/scale-marketplace\x27.'),'industry':z['string']()['optional']()['describe']('Industry\x20filter\x20for\x20template_list;\x20industry\x20hint\x20for\x20migration_import.\x20'+'Any\x20registered\x20industry\x20is\x20accepted\x20(builtin:\x20freelance,\x20rental,\x20education,\x20'+'travel,\x20subscription,\x20retail;\x20plus\x20custom\x20industries\x20registered\x20via\x20industry\x20packs).\x20'+'Aliases\x20are\x20resolved\x20(e.g.\x20\x27ecommerce\x27\x20→\x20\x27retail\x27).'),'description':z['string']()['optional']()['describe']('Natural-language\x20business/competitor\x20description\x20(required\x20for\x20migration_import;\x20used\x20by\x20template_generate\x20as\x20the\x20intent\x20text).'),'url':z['string']()['optional']()['describe']('Competitor\x20store/profile\x20URL\x20for\x20migration_import\x20(recorded\x20as\x20provenance\x20only).'),'fee_overrides':z['record'](z['string'](),z['union']([z['number'](),z['string']()]))['optional']()['describe']('Template\x20fee-parameter\x20overrides\x20for\x20template_generate\x20(e.g.\x20commission_rate_bps).'),'guard_resolutions':z['record'](z['string'](),GuardResolutionInputSchema)['optional']()['describe']('Judgment-layer\x20resolutions\x20for\x20pending\x20guard\x20designs\x20(C6-DEEP),\x20keyed\x20by\x20plan.pending_guard_designs[].key.\x20'+'A\x20blocked\x20migration_apply/template_generate\x20lists\x20every\x20unresolved\x20design\x20—\x20resolve\x20each\x20here\x20'+'(kind\x20\x27inline\x27\x20with\x20the\x20Guard\x20table+root,\x20or\x20kind\x20\x27template\x27\x20with\x20a\x20tpl_*\x20id)\x20and\x20re-run\x20the\x20action.\x20'+'The\x20audit\x20freeze\x20gate\x20still\x20decides:\x20resolutions\x20only\x20unblock\x20a\x20plan\x20whose\x20closed\x20audit\x20is\x20clean.'),'log':z['record'](z['string'](),z['unknown']())['optional']()['describe']('A\x20prior\x20MigrationLog\x20(required\x20for\x20migration_review).'),'network':z['enum'](['testnet','mainnet'])['optional']()['describe']('Target\x20network\x20for\x20migration_import\x20/\x20migration_apply\x20(default\x20testnet;\x20mainnet\x20requires\x20explicit\x20user\x20confirmation).')})['strict']();const ScanSummarySchema=z['object']({'risk_level':z['enum'](['low','medium','high','critical']),'passed':z['boolean'](),'finding_count':z['number'](),'findings_by_severity':z['record'](z['string'](),z['number']())['describe']('Finding\x20count\x20keyed\x20by\x20severity.'),'findings':z['array'](TemplateScanFindingSchema)['describe']('Every\x20finding\x20with\x20its\x20rule\x20id,\x20detail\x20and\x20suggestion.'),'red_flags':z['array'](z['string']())})['describe']('Pre-deploy\x20scan\x20summary\x20(generation/apply\x20only\x20runs\x20when\x20passed).');export const BenchmarkMigrationOutputSchema=z['object']({'result':z['discriminatedUnion']('action',[z['object']({'action':z['literal']('template_list'),'count':z['number']()['describe']('Number\x20of\x20templates\x20returned.'),'templates':z['array'](TemplateSummarySchema)['describe']('Template\x20listing\x20rows.'),'load_errors':z['array'](z['string']())['describe']('Template\x20files\x20that\x20failed\x20to\x20load/validate\x20(never\x20silently\x20dropped).')}),z['object']({'action':z['literal']('template_get'),'template':z['record'](z['string'](),z['unknown']())['describe']('Full\x20template\x20object\x20(machine_shape/guards/allocator/fee_params/body/...).')}),z['object']({'action':z['literal']('template_generate'),'template_id':z['string'](),'scan':ScanSummarySchema,'plan':z['record'](z['string'](),z['unknown']())['describe']('Creation\x20plan\x20from\x20the\x20merchant-guide\x20pipeline\x20(never\x20executed\x20on-chain).'),'next_action':z['string']()['describe']('Top-level\x20forwarding\x20of\x20the\x20materialization\x20contract\x20(C6):\x20the\x20guide\x27s\x20\x27Plan\x20ready.\x20Materialize:\x20...\x27\x20text\x20verbatim\x20when\x20the\x20audit\x20is\x20clean;\x20a\x20BLOCKED\x20reroute\x20back\x20to\x20this\x20action\x20otherwise.')}),z['object']({'action':z['literal']('template_scan'),'scan':z['object']({'template_id':z['string'](),'risk_level':z['enum'](['low','medium','high','critical']),'passed':z['boolean'](),'findings':z['array'](TemplateScanFindingSchema),'red_flags':z['array'](z['string']())})['describe']('Full\x20pre-deploy\x20scan\x20result.')}),z['object']({'action':z['literal']('migration_import'),'log':MigrationLogSchema['describe']('The\x20structured\x20migration\x20log.'),'next_action':z['string']()['describe']('Next\x20chain\x20step:\x20run\x20migration_review\x20with\x20this\x20log\x20(C6\x20—\x20the\x20chain\x20is\x20self-describing,\x20no\x20agent\x20re-exploration).')}),z['object']({'action':z['literal']('migration_review'),'log':MigrationLogSchema['describe']('The\x20migration\x20log\x20under\x20review.'),'review_summary':z['object']({'mapped_count':z['number'](),'unmapped_count':z['number'](),'manual_review_count':z['number'](),'risk_passed':z['boolean']()})['describe']('Counts\x20+\x20risk\x20status\x20for\x20the\x20confirmation\x20screen.'),'next_action':z['string']()['describe']('Next\x20chain\x20step:\x20migration_apply\x20with\x20the\x20matched\x20template\x20when\x20the\x20review\x20is\x20clean;\x20surface\x20the\x20unmapped/manual_review\x20items\x20for\x20a\x20user\x20decision\x20otherwise.')}),z['object']({'action':z['literal']('migration_apply'),'template_id':z['string'](),'network':z['enum'](['testnet','mainnet']),'scan':ScanSummarySchema,'plan':z['record'](z['string'](),z['unknown']())['describe']('Creation\x20plan\x20from\x20the\x20merchant-guide\x20pipeline\x20(never\x20executed\x20on-chain).'),'next_action':z['string']()['describe']('Top-level\x20forwarding\x20of\x20the\x20materialization\x20contract\x20(C6):\x20the\x20guide\x27s\x20\x27Plan\x20ready.\x20Materialize:\x20...\x27\x20text\x20verbatim\x20when\x20the\x20audit\x20is\x20clean;\x20a\x20BLOCKED\x20reroute\x20back\x20to\x20this\x20action\x20otherwise.')})])})['strict']();
@@ -1 +1 @@
1
- import{z}from'zod';import{TypedPermissionObjectSchema,CoinParamSchema,NamedObjectSchema,CallEnvSchema,SubmissionCallSchema}from'./base.js';import{VotingGuardSchema}from'../query/index.js';import{BalanceTypeSchema,DescriptionSchema,LongNameSchema,NameOrAddressSchema,NameSchema,ReceivedObjectsOrRecentlySchema,RECEIVE_FORMAT_BLOCK_OBJECTS}from'../common/index.js';const ARB_CASE_FIELD=NameOrAddressSchema['describe']('Arb\x20CASE\x20object\x20—\x20the\x20single\x20dispute\x20case\x20created\x20by\x20`dispute`\x20(the\x20object\x20you\x20may\x20have\x20named\x20via\x20`namedArb`).\x20'+'NOT\x20the\x20arbitrator\x20registration\x20object:\x20that\x20one\x20goes\x20in\x20the\x20ROOT\x20`object`\x20field,\x20while\x20every\x20case-scoped\x20'+'operation\x20(confirm\x20/\x20voting_deadline_change\x20/\x20vote\x20/\x20feedback\x20/\x20arbitration\x20/\x20reset\x20/\x20arb_withdraw)\x20addresses\x20'+'the\x20case\x20through\x20THIS\x20field.\x20Accepts\x20the\x20Arb\x27s\x200x\x20address\x20or\x20its\x20LocalMark\x20name.');export const DisputeSchema=z['object']({'order':NameOrAddressSchema['describe']('Order\x20ID\x20or\x20name.'),'description':DescriptionSchema['optional']()['describe']('Dispute\x20description.'),'proposition':z['array'](LongNameSchema)['describe']('List\x20of\x20dispute\x20propositions.'),'fee':CoinParamSchema['describe']('Dispute\x20processing\x20fee.\x20FORMAT:\x20{balance:\x20<amount_in_smallest_unit>}\x20—\x20field\x20name\x20is\x20\x27balance\x27\x20(NOT\x20\x27amount\x27).\x20'+'The\x20token\x20type\x20and\x20precision\x20are\x20determined\x20by\x20the\x20Arbitration\x20object\x27s\x20type_parameter\x20(the\x20generic\x20type\x20set\x20when\x20the\x20Arbitration\x20was\x20created).\x20'+'For\x20WOW\x20(9\x20decimals):\x20{balance:\x2050000000}\x20=\x200.05\x20WOW.\x20'+'For\x20tokens\x20with\x20different\x20decimals,\x20adjust\x20accordingly\x20(e.g.\x20USDC\x20has\x206\x20decimals,\x20so\x20{balance:\x2050000}\x20=\x200.05\x20USDC).\x20'+'docs#45:\x20the\x20fee\x20does\x20NOT\x20return\x20to\x20the\x20filer\x20on\x20a\x20win\x20—\x20it\x20stays\x20in\x20the\x20Arbitration\x20object\x20and\x20is\x20withdrawable\x20by\x20the\x20arbitrator.'),'namedArb':NamedObjectSchema['optional']()['describe']('RECOMMENDED:\x20Set\x20a\x20local\x20name\x20for\x20the\x20newly\x20created\x20Arb\x20(arbitration\x20case)\x20object.\x20'+'Without\x20this,\x20the\x20Arb\x20is\x20only\x20referenceable\x20by\x20its\x20on-chain\x20address.\x20'+'Example:\x20{name:\x20\x27my_dispute_v1\x27}\x20allows\x20subsequent\x20vote/feedback\x20operations\x20to\x20use\x20\x27my_dispute_v1\x27.')})['strict']();export const ConfirmSchema=z['object']({'arb':ARB_CASE_FIELD,'voting_deadline':z['union']([z['number']()['int']()['min'](0x0),z['null']()])['default'](null)['describe']('Voting\x20deadline\x20as\x20Unix\x20timestamp\x20in\x20MILLISECONDS\x20(ms).\x20SEMANTICS\x20OF\x20SPECIAL\x20VALUES:\x20'+'null\x20(DEFAULT\x20when\x20omitted)\x20=\x20open-ended\x20voting,\x20no\x20deadline;\x20parties\x20may\x20vote\x20at\x20any\x20time\x20and\x20the\x20arbitrator\x20may\x20deliver\x20the\x20verdict\x20immediately\x20(arb.move\x20skips\x20the\x20deadline\x20assert\x20when\x20the\x20Option\x20is\x20none)\x20—\x20this\x20is\x20the\x20SAFE\x20default;\x20'+'a\x20future\x20timestamp\x20=\x20normal\x20bounded\x20voting\x20window\x20(recommended:\x20now\x20+\x20at\x20least\x2086400000\x20ms\x20=\x2024\x20hours);\x20'+'0\x20=\x20deadline\x20already\x20passed\x20→\x20voting\x20is\x20IMPOSSIBLE\x20(every\x20vote\x20aborts\x20E_VOTING_DEADLINE_PASSED)\x20and\x20only\x20a\x20direct\x20verdict\x20is\x20possible.\x20Only\x20pass\x200\x20deliberately\x20when\x20you\x20truly\x20want\x20a\x20no-vote\x20verdict.\x20'+'COMMON\x20MISTAKE:\x20using\x20seconds\x20instead\x20of\x20milliseconds\x20(multiply\x20by\x201000).\x20'+'Example:\x20Date.now()\x20+\x20259200000\x20for\x203\x20days\x20from\x20now.')})['strict']();export const VotingDeadlineChangeSchema=z['object']({'arb':ARB_CASE_FIELD,'voting_deadline':z['union']([z['number'](),z['null']()])['describe']('New\x20voting\x20deadline\x20as\x20Unix\x20timestamp\x20in\x20MILLISECONDS\x20(ms).\x20SEMANTICS\x20OF\x20SPECIAL\x20VALUES:\x20'+'0\x20=\x20deadline\x20already\x20passed\x20→\x20voting\x20is\x20IMPOSSIBLE\x20and\x20the\x20arbitrator\x20may\x20deliver\x20the\x20verdict\x20immediately;\x20'+'null\x20=\x20open-ended\x20voting\x20with\x20no\x20deadline\x20(verdict\x20allowed\x20anytime);\x20'+'a\x20future\x20timestamp\x20=\x20normal\x20voting\x20window\x20(recommended:\x20now\x20+\x20at\x20least\x2086400000\x20ms\x20=\x2024\x20hours).\x20'+'COMMON\x20MISTAKE:\x20using\x20seconds\x20instead\x20of\x20milliseconds\x20(multiply\x20by\x201000).\x20'+'Example:\x20Date.now()\x20+\x20259200000\x20for\x203\x20days\x20from\x20now.')})['strict']();export const VoteSchema=z['object']({'arb':ARB_CASE_FIELD,'votes':z['array'](z['number']()['int']()['min'](0x0)['max'](0xff))['describe']('Proposition\x20INDICES\x20(0-based,\x20u8)\x20the\x20voter\x20agrees\x20with\x20—\x20e.g.\x20[0]\x20votes\x20for\x20the\x20first\x20proposition.\x20'+'Re-voting\x20REPLACES\x20the\x20voter\x27s\x20previous\x20vote\x20(old\x20weight\x20removed,\x20new\x20applied).\x20'+'Out-of-range\x20index\x20aborts\x20with\x20E_PROPOSITION_NOT_FOUND.'),'voting_guard':NameOrAddressSchema['optional']()['describe']('Voting\x20Guard\x20for\x20WEIGHTED\x20voting.\x20DECISION\x20RULE\x20(contract-enforced):\x0a'+'(A)\x20Arbitration\x20HAS\x20a\x20non-empty\x20voting_guard\x20list\x20→\x20plain\x20vote\x20is\x20REJECTED\x20on-chain\x20with\x20E_VOTING_GUARD_USED\x20(abort\x202).\x20'+'You\x20MUST\x20provide\x20this\x20field\x20set\x20to\x20ONE\x20guard\x20from\x20the\x20Arbitration\x27s\x20voting_guard\x20list,\x20and\x20fill\x20its\x20submission:\x20'+'when\x20the\x20guard\x27s\x20vote_weight\x20is\x20{GuardIdentifier:\x20pos},\x20the\x20number\x20you\x20submit\x20at\x20that\x20table\x20position\x20IS\x20the\x20vote\x20weight;\x20'+'when\x20it\x20is\x20{FixedValue:\x20v},\x20no\x20submission\x20is\x20needed\x20(weight\x20is\x20fixed).\x20The\x20SDK\x20then\x20routes\x20the\x20call\x20through\x20the\x20Guard-weighted\x20vote\x20path\x20via\x20a\x20Passport.\x20'+'Omitting\x20this\x20field\x20on\x20such\x20an\x20Arbitration\x20now\x20fails\x20fast\x20pre-call\x20with\x20the\x20list\x20of\x20valid\x20guards.\x0a'+'(B)\x20Arbitration\x20has\x20NO\x20voting_guard\x20→\x20omit\x20this\x20field;\x20the\x20SDK\x20uses\x20plain\x20vote\x20(weight\x201,\x20permission-gated),\x20or\x20the\x20passport-gated\x20vote\x20path\x20when\x20other\x20guards\x20require\x20it.\x0a'+'BOTH\x20(B)\x20paths\x20still\x20assert\x20ARBITRATION_VOTE=358\x20on-chain\x20(the\x20SDK\x20now\x20pre-checks\x20358\x20and\x20fails\x20fast\x20with\x20\x27Missing\x20permissions\x20358\x27).\x20'+'An\x20empty\x20voting_guard\x20means\x20EQUAL\x20WEIGHT\x20(1\x20person\x201\x20vote),\x20NOT\x20permissionless\x20—\x20there\x20is\x20no\x20permission-free\x20vote\x20entry.\x20'+'For\x20genuinely\x20open\x20voting,\x20configure\x20a\x20public\x20voting_guard\x20(op=\x22set\x22)\x20and\x20vote\x20via\x20path\x20(A):\x20the\x20weighted\x20passport\x20path\x20authorizes\x20by\x20the\x20guard\x20and\x20does\x20NOT\x20require\x20358.\x0a'+'The\x20Guard\x20(when\x20provided)\x20MUST\x20be\x20in\x20the\x20Arbitration\x27s\x20voting_guard\x20list\x20—\x20an\x20unlisted\x20guard\x20aborts\x20with\x20E_VOTING_GUARD_NOT_FOUND.')})['strict']();export const FeedbackSchema=z['object']({'arb':ARB_CASE_FIELD,'feedback':DescriptionSchema['describe']('Arbitration\x20feedback.')})['strict']();export const ArbitrationActionSchema=z['object']({'arb':ARB_CASE_FIELD,'feedback':DescriptionSchema['describe']('Arbitration\x20feedback.'),'indemnity':z['number']()['int']()['min'](0x0)})['strict']();export const ResetSchema=z['object']({'arb':ARB_CASE_FIELD,'feedback':DescriptionSchema['describe']('Arbitration\x20feedback.')})['strict']();export const ArbWithdrawSchema=z['object']({'arb':ARB_CASE_FIELD})['strict']();export const FeesTransferToSchema=z['union']([z['object']({'allocation':NameOrAddressSchema['describe']('Allocation\x20object\x20ID\x20or\x20name.')})['strict'](),z['object']({'treasury':NameOrAddressSchema['describe']('Treasury\x20object\x20ID\x20or\x20name.\x20NOTE:\x20the\x20transferred\x20funds\x20arrive\x20as\x20a\x20CoinWrapper\x20owned\x20by\x20the\x20Treasury\x20and\x20only\x20count\x20'+'after\x20the\x20Treasury\x20intakes\x20them\x20—\x20call\x20treasury\x20receive:\x20\x22recently\x22\x20(requires\x20permission\x20253\x20TREASURY_RECEIVE\x20on\x20the\x20Treasury).')})['strict']()]);export const FeesTransferSchema=z['object']({'to':FeesTransferToSchema['describe']('Transfer\x20arbitration\x20fees\x20to\x20the\x20specified\x20Allocation\x20object\x20or\x20Treasury\x20object.'),'payment_remark':NameSchema['describe']('Payment\x20remark.'),'payment_index':z['number']()['int']()['min'](0x0)['describe']('0-based\x20index\x20of\x20the\x20fee\x20payment\x20inside\x20the\x20Arb\x20case\x27s\x20fees\x20table\x20(query\x20the\x20Arb\x20case\x20with\x20onchain_operations\x20type\x20\x27q\x27\x20/\x20onchain_table_data\x20to\x20list\x20its\x20fees\x20and\x20their\x20indices).\x20REQUIRED\x20—\x20without\x20it\x20the\x20transfer\x20cannot\x20name\x20which\x20fee\x20record\x20to\x20move.'),'newPayment':NamedObjectSchema['optional']()['describe']('Name\x20for\x20the\x20newly\x20created\x20payment\x20object.')})['strict']();export const VotingGuardActionSchema=z['discriminatedUnion']('op',[z['object']({'op':z['enum'](['add','set']),'guards':z['array'](VotingGuardSchema)})['strict'](),z['object']({'op':z['literal']('remove'),'guards':z['array'](NameOrAddressSchema)})['strict'](),z['object']({'op':z['literal']('clear')})['strict']()]);export const CallArbitration_DataSchema=z['object']({'object':TypedPermissionObjectSchema,'dispute':DisputeSchema['optional']()['describe']('Create\x20a\x20new\x20Arb\x20object\x20for\x20the\x20order;\x20the\x20case\x20lands\x20directly\x20in\x20state\x201\x20(Arbitrator_confirming)\x20—\x20the\x20customer\x20does\x20not\x20confirm\x20at\x20filing\x20time.\x20FILING\x20IS\x20SERVICE-BOUND:\x20the\x20SDK\x20resolves\x20the\x20order\x27s\x20Service\x20and\x20files\x20through\x20its\x20Service-side\x20dispute\x20entry\x20points,\x20which\x20enforce\x20the\x20merchant\x27s\x20arbitrator\x20allowlist,\x20the\x20service-arbitration\x20neutrality\x20rule\x20and\x20the\x20order\x20binding\x20before\x20the\x20case\x20is\x20minted\x20(venues\x20gated\x20by\x20a\x20usage_guard\x20require\x20the\x20passport\x20path,\x20verified\x20in\x20the\x20same\x20transaction).\x20Direct\x20calls\x20to\x20the\x20removed\x20arbitration-side\x20dispute\x20entries\x20abort\x20with\x20arbitration:10'),'description':DescriptionSchema['optional']()['describe']('Introduction\x20of\x20the\x20Arbitration\x20object.'),'location':LongNameSchema['optional']()['describe']('Arbitration\x20location.'),'fee':BalanceTypeSchema['optional']()['describe']('Arbitration\x20filing\x20fee.\x20FORMAT:\x20a\x20direct\x20amount\x20value\x20—\x20NOT\x20wrapped\x20in\x20'+'{balance:\x20...}\x20(that\x20CoinParam\x20shape\x20is\x20only\x20for\x20dispute.fee,\x20which\x20pays\x20a\x20coin\x20object).\x20'+'Accepted:\x20smallest-unit\x20number\x20or\x20string\x20(e.g.\x2050000000\x20=\x200.05\x20WOW\x20at\x209\x20decimals),\x20or\x20'+'display\x20format\x20with\x20the\x20token\x20symbol\x20(e.g.\x20\x220.05WOW\x22)\x20—\x20the\x20Fund\x20Processing\x20Layer\x20'+'converts\x20it\x20using\x20the\x20Arbitration\x20object\x27s\x20own\x20token\x20decimals.\x20'+'Default\x200\x20on\x20creation:\x20disputes\x20are\x20then\x20free\x20(the\x20filer\x27s\x20coin\x20is\x20fully\x20refunded\x20on\x20'+'filing)\x20and\x20the\x20arbitrator\x20earns\x20no\x20per-case\x20fee.'),'pause':z['boolean']()['optional']()['describe']('Whether\x20to\x20pause\x20arbitration.'),'confirm':ConfirmSchema['optional']()['describe']('ARBITRATOR-side\x20material\x20confirmation\x20(from\x20state\x201):\x20moves\x20the\x20case\x20to\x20state\x202\x20(Voting).\x20'+'Customers\x20cannot\x20call\x20this\x20—\x20the\x20customer-side\x20step\x20is\x20order.arb_confirm\x20(state\x200\x20to\x201).'),'voting_deadline_change':VotingDeadlineChangeSchema['optional']()['describe']('Change\x20the\x20voting\x20deadline.'),'vote':VoteSchema['optional']()['describe']('Vote\x20on\x20user\x20propositions.'),'feedback':FeedbackSchema['optional']()['describe']('Arbitration\x20feedback\x20for\x20the\x20Arb\x20object.'),'arbitration':ArbitrationActionSchema['optional']()['describe']('Provide\x20a\x20definitive\x20arbitration\x20result.'),'reset':ResetSchema['optional']()['describe']('ARBITRATOR-side\x20reset\x20(arbitration\x20permission\x20holder;\x20valid\x20from\x20state\x204\x20Objectionable\x20or\x20state\x201):\x20voids\x20the\x20ruling,\x20'+'clears\x20the\x20indemnity\x20and\x20returns\x20the\x20case\x20to\x20state\x200\x20(Principal_confirming).\x20After\x20a\x20reset\x20ONLY\x20the\x20customer\x20can\x20advance\x20the\x20case\x20'+'again\x20via\x20order.arb_confirm\x20—\x20state\x200\x20has\x20no\x20timeout\x20and\x20the\x20fee\x20stays\x20locked\x20until\x20the\x20customer\x20re-confirms.'),'arb_withdraw':ArbWithdrawSchema['optional']()['describe']('Withdraw\x20arbitration\x20fees\x20from\x20the\x20Arb\x20object\x20(arbitrator).\x20Immediately\x20from\x20state\x205\x20(Finished);\x20from\x20state\x203\x20only\x20after\x2030\x20days\x20'+'from\x20the\x20ruling\x20time\x20(no\x20objection\x20filed\x20—\x20silence\x20=\x20acceptance);\x20rejected\x20in\x20states\x200/1/2.\x20'+'State\x204\x20(Objectionable)\x20can\x20NEVER\x20withdraw\x20(protocol\x20141):\x20a\x20contested\x20case\x20keeps\x20its\x20fee\x20escrowed\x20until\x20the\x20customer\x20'+'closes\x20the\x20objection\x20cycle\x20—\x20reset\x20→\x20order.arb_confirm\x20→\x20new\x20ruling\x20→\x20unchallenged\x20(or\x20accepted\x20via\x20finish).\x20'+'⚠️\x20TWO-STAGE\x20FEE\x20CASH-OUT\x20(verified\x20on\x20testnet):\x20this\x20call\x20does\x20NOT\x20pay\x20the\x20arbitrator\x27s\x20wallet\x20—\x20it\x20moves\x20the\x20case\x20fee\x20'+'into\x20the\x20Arbitration\x20(Registration)\x20object\x27s\x20own\x20balance\x20pool.\x20To\x20actually\x20receive\x20the\x20money:\x20'+'fees_transfer\x20(to\x20a\x20treasury\x20or\x20allocation)\x20→\x20treasury\x20receive:\x20\x22recently\x22\x20(permission\x20253)\x20→\x20treasury\x20withdraw\x20→\x20'+'recipient\x20payment\x20receive.\x20A\x20successful\x20arb_withdraw\x20with\x20no\x20wallet\x20balance\x20change\x20is\x20EXPECTED,\x20not\x20a\x20failure.'),'fees_transfer':FeesTransferSchema['optional']()['describe']('Distribute\x20the\x20withdrawn\x20arbitration\x20fees.\x20Moves\x20the\x20Arbitration\x27s\x20ENTIRE\x20balance\x20in\x20ONE\x20call\x20—\x20there\x20is\x20NO\x20amount\x20parameter.\x20'+'The\x20balance\x20leaves\x20as\x20a\x20CoinWrapper\x20owned\x20by\x20the\x20target\x20(allocation\x20or\x20treasury);\x20for\x20a\x20treasury\x20target,\x20intake\x20it\x20with\x20'+'treasury\x20receive:\x20\x22recently\x22\x20(permission\x20253)\x20—\x20see\x20the\x20\x27to\x27\x20field\x20description.'),'usage_guard':z['union']([NameOrAddressSchema,z['null']()])['optional']()['describe']('Set\x20Guard\x20for\x20verification\x20when\x20users\x20apply\x20for\x20arbitration;\x20if\x20Guard\x20verification\x20fails,\x20users\x20will\x20not\x20be\x20able\x20to\x20apply\x20for\x20arbitration.'),'voting_guard':VotingGuardActionSchema['optional']()['describe']('Set\x20Guard\x20for\x20verification\x20during\x20arbitration\x20voting;\x20if\x20Guard\x20verification\x20fails,\x20arbitration\x20voting\x20will\x20fail.'),'owner_receive':ReceivedObjectsOrRecentlySchema['optional']()['describe']('Unwrap\x20CoinWrapper\x20objects\x20and\x20other\x20objects\x20received\x20by\x20this\x20Arbitration\x20object\x20and\x20send\x20them\x20to\x20the\x20owner\x20of\x20its\x20Permission\x20object.'+RECEIVE_FORMAT_BLOCK_OBJECTS),'um':z['union']([NameOrAddressSchema,z['null']()])['optional']()['describe']('Contact\x20object\x20ID\x20or\x20name.')})['strict']()['describe']('On-chain\x20Arbitration\x20operations.\x20TWO\x20OBJECT\x20KINDS\x20—\x20do\x20not\x20confuse\x20them\x20(§5.9):\x20the\x20ROOT\x20\x27object\x27\x20field\x20is\x20the\x20Arbitration\x20(arbitrator\x20REGISTRATION)\x20object;\x20the\x20Arb\x20(single\x20CASE)\x20created\x20by\x20\x27dispute\x27\x20is\x20addressed\x20via\x20each\x20case\x20operation\x27s\x20\x27arb\x27\x20field.\x20USAGE:\x20(1)\x20CREATE\x20NEW:\x20Set\x20\x27object\x27\x20field\x20with\x20OBJECT\x20format\x20{name,\x20type_parameter,\x20permission,\x20...}\x20to\x20create\x20an\x20Arbitration.\x20NOTE:\x27name\x27\x20goes\x20INSIDE\x20\x27object\x27,\x20NOT\x20at\x20the\x20data\x20root\x20level.\x20\x27permission\x27\x20can\x20be\x20a\x20new\x20Permission\x20object\x20or\x20reference\x20an\x20existing\x20one\x20-\x20check\x20\x27object\x27\x20field\x20description\x20for\x20details.\x20⚠️\x20PERMISSION\x20RULE\x20(contract-enforced):\x20the\x20Arbitration\x27s\x20permission\x20MUST\x20be\x20DIFFERENT\x20from\x20the\x20permission\x20of\x20any\x20Service\x20it\x20will\x20be\x20bound\x20to\x20—\x20binding\x20an\x20Arbitration\x20that\x20SHARES\x20the\x20Service\x27s\x20Permission\x20aborts\x20with\x20E_ARBITRATION_PERMISSION_CONFLICT\x20(error\x2033).\x20Always\x20create\x20a\x20DEDICATED\x20Permission\x20object\x20for\x20each\x20Arbitration.\x20(2)\x20OPERATE\x20EXISTING:\x20Set\x20\x27object\x27\x20field\x20with\x20STRING\x20format\x20(object\x20ID\x20or\x20name).\x20The\x20\x27object\x27\x20field\x20is\x20CRITICAL\x20and\x20REQUIRED\x20in\x20both\x20cases.\x20STRING\x20for\x20existing,\x20OBJECT\x20for\x20new\x20creation.');export const CallArbitration_InputSchema=z['object']({'data':CallArbitration_DataSchema,'env':CallEnvSchema['optional'](),'submission':SubmissionCallSchema['optional']()})['strict']();
1
+ import{z}from'zod';import{TypedPermissionObjectSchema,CoinParamSchema,NamedObjectSchema,CallEnvSchema,SubmissionCallSchema}from'./base.js';import{VotingGuardSchema}from'../query/index.js';import{BalanceTypeSchema,DescriptionSchema,LongNameSchema,NameOrAddressSchema,NameSchema,ReceivedObjectsOrRecentlySchema,RECEIVE_FORMAT_BLOCK_OBJECTS}from'../common/index.js';const ARB_CASE_FIELD=NameOrAddressSchema['describe']('Arb\x20CASE\x20object\x20—\x20the\x20single\x20dispute\x20case\x20created\x20by\x20`dispute`\x20(the\x20object\x20you\x20may\x20have\x20named\x20via\x20`namedArb`).\x20'+'NOT\x20the\x20arbitrator\x20registration\x20object:\x20that\x20one\x20goes\x20in\x20the\x20ROOT\x20`object`\x20field,\x20while\x20every\x20case-scoped\x20'+'operation\x20(confirm\x20/\x20voting_deadline_change\x20/\x20vote\x20/\x20feedback\x20/\x20arbitration\x20/\x20reset\x20/\x20arb_withdraw)\x20addresses\x20'+'the\x20case\x20through\x20THIS\x20field.\x20Accepts\x20the\x20Arb\x27s\x200x\x20address\x20or\x20its\x20LocalMark\x20name.');export const DisputeSchema=z['object']({'order':NameOrAddressSchema['describe']('Order\x20ID\x20or\x20name.'),'description':DescriptionSchema['optional']()['describe']('Dispute\x20description.'),'proposition':z['array'](LongNameSchema)['describe']('List\x20of\x20dispute\x20propositions.'),'fee':CoinParamSchema['describe']('Dispute\x20processing\x20fee.\x20FORMAT:\x20{balance:\x20<amount_in_smallest_unit>}\x20—\x20field\x20name\x20is\x20\x27balance\x27\x20(NOT\x20\x27amount\x27).\x20'+'The\x20token\x20type\x20and\x20precision\x20are\x20determined\x20by\x20the\x20Arbitration\x20object\x27s\x20type_parameter\x20(the\x20generic\x20type\x20set\x20when\x20the\x20Arbitration\x20was\x20created).\x20'+'For\x20WOW\x20(9\x20decimals):\x20{balance:\x2050000000}\x20=\x200.05\x20WOW.\x20'+'For\x20tokens\x20with\x20different\x20decimals,\x20adjust\x20accordingly\x20(e.g.\x20USDC\x20has\x206\x20decimals,\x20so\x20{balance:\x2050000}\x20=\x200.05\x20USDC).\x20'+'docs#45:\x20the\x20fee\x20does\x20NOT\x20return\x20to\x20the\x20filer\x20on\x20a\x20win\x20—\x20it\x20stays\x20in\x20the\x20Arbitration\x20object\x20and\x20is\x20withdrawable\x20by\x20the\x20arbitrator.'),'namedArb':NamedObjectSchema['optional']()['describe']('RECOMMENDED:\x20Set\x20a\x20local\x20name\x20for\x20the\x20newly\x20created\x20Arb\x20(arbitration\x20case)\x20object.\x20'+'Without\x20this,\x20the\x20Arb\x20is\x20only\x20referenceable\x20by\x20its\x20on-chain\x20address.\x20'+'Example:\x20{name:\x20\x27my_dispute_v1\x27}\x20allows\x20subsequent\x20vote/feedback\x20operations\x20to\x20use\x20\x27my_dispute_v1\x27.')})['strict']();export const ConfirmSchema=z['object']({'arb':ARB_CASE_FIELD,'voting_deadline':z['union']([z['number']()['int']()['min'](0x0),z['null']()])['default'](null)['describe']('Voting\x20deadline\x20as\x20Unix\x20timestamp\x20in\x20MILLISECONDS\x20(ms).\x20SEMANTICS\x20OF\x20SPECIAL\x20VALUES:\x20'+'null\x20(DEFAULT\x20when\x20omitted)\x20=\x20open-ended\x20voting,\x20no\x20deadline;\x20parties\x20may\x20vote\x20at\x20any\x20time\x20and\x20the\x20arbitrator\x20may\x20deliver\x20the\x20verdict\x20immediately\x20(arb.move\x20skips\x20the\x20deadline\x20assert\x20when\x20the\x20Option\x20is\x20none)\x20—\x20this\x20is\x20the\x20SAFE\x20default;\x20'+'a\x20future\x20timestamp\x20=\x20normal\x20bounded\x20voting\x20window\x20(recommended:\x20now\x20+\x20at\x20least\x2086400000\x20ms\x20=\x2024\x20hours);\x20'+'0\x20=\x20deadline\x20already\x20passed\x20→\x20voting\x20is\x20IMPOSSIBLE\x20(every\x20vote\x20aborts\x20E_VOTING_DEADLINE_PASSED)\x20and\x20only\x20a\x20direct\x20verdict\x20is\x20possible.\x20Only\x20pass\x200\x20deliberately\x20when\x20you\x20truly\x20want\x20a\x20no-vote\x20verdict.\x20'+'COMMON\x20MISTAKE:\x20using\x20seconds\x20instead\x20of\x20milliseconds\x20(multiply\x20by\x201000).\x20'+'Example:\x20Date.now()\x20+\x20259200000\x20for\x203\x20days\x20from\x20now.')})['strict']();export const VotingDeadlineChangeSchema=z['object']({'arb':ARB_CASE_FIELD,'voting_deadline':z['union']([z['number'](),z['null']()])['describe']('New\x20voting\x20deadline\x20as\x20Unix\x20timestamp\x20in\x20MILLISECONDS\x20(ms).\x20SEMANTICS\x20OF\x20SPECIAL\x20VALUES:\x20'+'0\x20=\x20deadline\x20already\x20passed\x20→\x20voting\x20is\x20IMPOSSIBLE\x20and\x20the\x20arbitrator\x20may\x20deliver\x20the\x20verdict\x20immediately;\x20'+'null\x20=\x20open-ended\x20voting\x20with\x20no\x20deadline\x20(verdict\x20allowed\x20anytime);\x20'+'a\x20future\x20timestamp\x20=\x20normal\x20voting\x20window\x20(recommended:\x20now\x20+\x20at\x20least\x2086400000\x20ms\x20=\x2024\x20hours).\x20'+'COMMON\x20MISTAKE:\x20using\x20seconds\x20instead\x20of\x20milliseconds\x20(multiply\x20by\x201000).\x20'+'Example:\x20Date.now()\x20+\x20259200000\x20for\x203\x20days\x20from\x20now.')})['strict']();export const VoteSchema=z['object']({'arb':ARB_CASE_FIELD,'votes':z['array'](z['number']()['int']()['min'](0x0)['max'](0xff))['describe']('Proposition\x20INDICES\x20(0-based,\x20u8)\x20the\x20voter\x20agrees\x20with\x20—\x20e.g.\x20[0]\x20votes\x20for\x20the\x20first\x20proposition.\x20'+'Re-voting\x20REPLACES\x20the\x20voter\x27s\x20previous\x20vote\x20(old\x20weight\x20removed,\x20new\x20applied).\x20'+'Out-of-range\x20index\x20aborts\x20with\x20E_PROPOSITION_NOT_FOUND.'),'voting_guard':NameOrAddressSchema['optional']()['describe']('Voting\x20Guard\x20for\x20WEIGHTED\x20voting.\x20DECISION\x20RULE\x20(contract-enforced):\x0a'+'(A)\x20Arbitration\x20HAS\x20a\x20non-empty\x20voting_guard\x20list\x20→\x20plain\x20vote\x20is\x20REJECTED\x20on-chain\x20with\x20E_VOTING_GUARD_USED\x20(abort\x202).\x20'+'You\x20MUST\x20provide\x20this\x20field\x20set\x20to\x20ONE\x20guard\x20from\x20the\x20Arbitration\x27s\x20voting_guard\x20list,\x20and\x20fill\x20its\x20submission:\x20'+'when\x20the\x20guard\x27s\x20vote_weight\x20is\x20{GuardIdentifier:\x20pos},\x20the\x20number\x20you\x20submit\x20at\x20that\x20table\x20position\x20IS\x20the\x20vote\x20weight;\x20'+'when\x20it\x20is\x20{FixedValue:\x20v},\x20no\x20submission\x20is\x20needed\x20(weight\x20is\x20fixed).\x20The\x20SDK\x20then\x20routes\x20the\x20call\x20through\x20the\x20Guard-weighted\x20vote\x20path\x20via\x20a\x20Passport.\x20'+'Omitting\x20this\x20field\x20on\x20such\x20an\x20Arbitration\x20now\x20fails\x20fast\x20pre-call\x20with\x20the\x20list\x20of\x20valid\x20guards.\x0a'+'(B)\x20Arbitration\x20has\x20NO\x20voting_guard\x20→\x20omit\x20this\x20field;\x20the\x20SDK\x20uses\x20plain\x20vote\x20(weight\x201,\x20permission-gated),\x20or\x20the\x20passport-gated\x20vote\x20path\x20when\x20other\x20guards\x20require\x20it.\x0a'+'BOTH\x20(B)\x20paths\x20still\x20assert\x20ARBITRATION_VOTE=358\x20on-chain\x20(the\x20SDK\x20now\x20pre-checks\x20358\x20and\x20fails\x20fast\x20with\x20\x27Missing\x20permissions\x20358\x27).\x20'+'An\x20empty\x20voting_guard\x20means\x20EQUAL\x20WEIGHT\x20(1\x20person\x201\x20vote),\x20NOT\x20permissionless\x20—\x20there\x20is\x20no\x20permission-free\x20vote\x20entry.\x20'+'For\x20genuinely\x20open\x20voting,\x20configure\x20a\x20public\x20voting_guard\x20(op=\x22set\x22)\x20and\x20vote\x20via\x20path\x20(A):\x20the\x20weighted\x20passport\x20path\x20authorizes\x20by\x20the\x20guard\x20and\x20does\x20NOT\x20require\x20358.\x0a'+'The\x20Guard\x20(when\x20provided)\x20MUST\x20be\x20in\x20the\x20Arbitration\x27s\x20voting_guard\x20list\x20—\x20an\x20unlisted\x20guard\x20aborts\x20with\x20E_VOTING_GUARD_NOT_FOUND.')})['strict']();export const FeedbackSchema=z['object']({'arb':ARB_CASE_FIELD,'feedback':DescriptionSchema['describe']('Arbitration\x20feedback.')})['strict']();export const ArbitrationActionSchema=z['object']({'arb':ARB_CASE_FIELD,'feedback':DescriptionSchema['describe']('Arbitration\x20feedback.'),'indemnity':z['number']()['int']()['min'](0x0)['describe']('Awarded\x20compensation\x20in\x20integer\x20smallest\x20units\x20(0\x20=\x20a\x20denial\x20ruling\x20that\x20pays\x20nothing).\x20'+'Hard-capped\x20at\x203x\x20the\x20disputed\x20order\x20amount\x20on\x20chain.\x20Funded\x20from\x20the\x20Service\x27s\x20merchant-prepaid\x20'+'compensation\x20fund\x20—\x20an\x20award\x20larger\x20than\x20the\x20fund\x20balance\x20aborts\x20the\x20later\x20payout\x20until\x20the\x20'+'merchant\x20tops\x20up.\x20A\x20non-zero\x20award\x20consumes\x20the\x20order\x27s\x20one-shot\x20compensation\x20latch:\x20refund\x20rails\x20'+'gated\x20on\x20\x27no\x20award\x20paid\x27\x20can\x20never\x20fire\x20afterwards,\x20so\x20pair\x20them\x20with\x20a\x20merchant-recovery\x20rail\x20at\x20build\x20time.')})['strict']();export const ResetSchema=z['object']({'arb':ARB_CASE_FIELD,'feedback':DescriptionSchema['describe']('Arbitration\x20feedback.')})['strict']();export const ArbWithdrawSchema=z['object']({'arb':ARB_CASE_FIELD})['strict']();export const FeesTransferToSchema=z['union']([z['object']({'allocation':NameOrAddressSchema['describe']('Allocation\x20object\x20ID\x20or\x20name.')})['strict'](),z['object']({'treasury':NameOrAddressSchema['describe']('Treasury\x20object\x20ID\x20or\x20name.\x20NOTE:\x20the\x20transferred\x20funds\x20arrive\x20as\x20a\x20CoinWrapper\x20owned\x20by\x20the\x20Treasury\x20and\x20only\x20count\x20'+'after\x20the\x20Treasury\x20intakes\x20them\x20—\x20call\x20treasury\x20receive:\x20\x22recently\x22\x20(requires\x20permission\x20253\x20TREASURY_RECEIVE\x20on\x20the\x20Treasury).')})['strict']()]);export const FeesTransferSchema=z['object']({'to':FeesTransferToSchema['describe']('Transfer\x20arbitration\x20fees\x20to\x20the\x20specified\x20Allocation\x20object\x20or\x20Treasury\x20object.'),'payment_remark':NameSchema['describe']('Payment\x20remark.'),'payment_index':z['number']()['int']()['min'](0x0)['describe']('0-based\x20index\x20of\x20the\x20fee\x20payment\x20inside\x20the\x20Arb\x20case\x27s\x20fees\x20table\x20(query\x20the\x20Arb\x20case\x20with\x20onchain_operations\x20type\x20\x27q\x27\x20/\x20onchain_table_data\x20to\x20list\x20its\x20fees\x20and\x20their\x20indices).\x20REQUIRED\x20—\x20without\x20it\x20the\x20transfer\x20cannot\x20name\x20which\x20fee\x20record\x20to\x20move.'),'newPayment':NamedObjectSchema['optional']()['describe']('Name\x20for\x20the\x20newly\x20created\x20payment\x20object.')})['strict']();export const VotingGuardActionSchema=z['discriminatedUnion']('op',[z['object']({'op':z['enum'](['add','set']),'guards':z['array'](VotingGuardSchema)})['strict'](),z['object']({'op':z['literal']('remove'),'guards':z['array'](NameOrAddressSchema)})['strict'](),z['object']({'op':z['literal']('clear')})['strict']()]);export const CallArbitration_DataSchema=z['object']({'object':TypedPermissionObjectSchema,'dispute':DisputeSchema['optional']()['describe']('Create\x20a\x20new\x20Arb\x20object\x20for\x20the\x20order;\x20the\x20case\x20lands\x20directly\x20in\x20state\x201\x20(Arbitrator_confirming)\x20—\x20the\x20customer\x20does\x20not\x20confirm\x20at\x20filing\x20time.\x20FILING\x20IS\x20SERVICE-BOUND:\x20the\x20SDK\x20resolves\x20the\x20order\x27s\x20Service\x20and\x20files\x20through\x20its\x20Service-side\x20dispute\x20entry\x20points,\x20which\x20enforce\x20the\x20merchant\x27s\x20arbitrator\x20allowlist,\x20the\x20service-arbitration\x20neutrality\x20rule\x20and\x20the\x20order\x20binding\x20before\x20the\x20case\x20is\x20minted\x20(venues\x20gated\x20by\x20a\x20usage_guard\x20require\x20the\x20passport\x20path,\x20verified\x20in\x20the\x20same\x20transaction).\x20Direct\x20calls\x20to\x20the\x20removed\x20arbitration-side\x20dispute\x20entries\x20abort\x20with\x20arbitration:10'),'description':DescriptionSchema['optional']()['describe']('Introduction\x20of\x20the\x20Arbitration\x20object.'),'location':LongNameSchema['optional']()['describe']('Arbitration\x20location.'),'fee':BalanceTypeSchema['optional']()['describe']('Arbitration\x20filing\x20fee.\x20FORMAT:\x20a\x20direct\x20amount\x20value\x20—\x20NOT\x20wrapped\x20in\x20'+'{balance:\x20...}\x20(that\x20CoinParam\x20shape\x20is\x20only\x20for\x20dispute.fee,\x20which\x20pays\x20a\x20coin\x20object).\x20'+'Accepted:\x20smallest-unit\x20number\x20or\x20string\x20(e.g.\x2050000000\x20=\x200.05\x20WOW\x20at\x209\x20decimals),\x20or\x20'+'display\x20format\x20with\x20the\x20token\x20symbol\x20(e.g.\x20\x220.05WOW\x22)\x20—\x20the\x20Fund\x20Processing\x20Layer\x20'+'converts\x20it\x20using\x20the\x20Arbitration\x20object\x27s\x20own\x20token\x20decimals.\x20'+'Default\x200\x20on\x20creation:\x20disputes\x20are\x20then\x20free\x20(the\x20filer\x27s\x20coin\x20is\x20fully\x20refunded\x20on\x20'+'filing)\x20and\x20the\x20arbitrator\x20earns\x20no\x20per-case\x20fee.'),'pause':z['boolean']()['optional']()['describe']('Whether\x20to\x20pause\x20arbitration.'),'confirm':ConfirmSchema['optional']()['describe']('ARBITRATOR-side\x20material\x20confirmation\x20(from\x20state\x201):\x20moves\x20the\x20case\x20to\x20state\x202\x20(Voting).\x20'+'Customers\x20cannot\x20call\x20this\x20—\x20the\x20customer-side\x20step\x20is\x20order.arb_confirm\x20(state\x200\x20to\x201).'),'voting_deadline_change':VotingDeadlineChangeSchema['optional']()['describe']('Change\x20the\x20voting\x20deadline.'),'vote':VoteSchema['optional']()['describe']('Vote\x20on\x20user\x20propositions.'),'feedback':FeedbackSchema['optional']()['describe']('Arbitration\x20feedback\x20for\x20the\x20Arb\x20object.'),'arbitration':ArbitrationActionSchema['optional']()['describe']('Provide\x20a\x20definitive\x20arbitration\x20result.'),'reset':ResetSchema['optional']()['describe']('ARBITRATOR-side\x20reset\x20(arbitration\x20permission\x20holder;\x20valid\x20from\x20state\x204\x20Objectionable\x20or\x20state\x201):\x20voids\x20the\x20ruling,\x20'+'clears\x20the\x20indemnity\x20and\x20returns\x20the\x20case\x20to\x20state\x200\x20(Principal_confirming).\x20After\x20a\x20reset\x20ONLY\x20the\x20customer\x20can\x20advance\x20the\x20case\x20'+'again\x20via\x20order.arb_confirm\x20—\x20state\x200\x20has\x20no\x20timeout\x20and\x20the\x20fee\x20stays\x20locked\x20until\x20the\x20customer\x20re-confirms.'),'arb_withdraw':ArbWithdrawSchema['optional']()['describe']('Withdraw\x20arbitration\x20fees\x20from\x20the\x20Arb\x20object\x20(arbitrator).\x20Immediately\x20from\x20state\x205\x20(Finished);\x20from\x20state\x203\x20only\x20after\x2030\x20days\x20'+'from\x20the\x20ruling\x20time\x20(no\x20objection\x20filed\x20—\x20silence\x20=\x20acceptance);\x20rejected\x20in\x20states\x200/1/2.\x20'+'State\x204\x20(Objectionable)\x20can\x20NEVER\x20withdraw\x20(protocol\x20141):\x20a\x20contested\x20case\x20keeps\x20its\x20fee\x20escrowed\x20until\x20the\x20customer\x20'+'closes\x20the\x20objection\x20cycle\x20—\x20reset\x20→\x20order.arb_confirm\x20→\x20new\x20ruling\x20→\x20unchallenged\x20(or\x20accepted\x20via\x20finish).\x20'+'⚠️\x20TWO-STAGE\x20FEE\x20CASH-OUT\x20(verified\x20on\x20testnet):\x20this\x20call\x20does\x20NOT\x20pay\x20the\x20arbitrator\x27s\x20wallet\x20—\x20it\x20moves\x20the\x20case\x20fee\x20'+'into\x20the\x20Arbitration\x20(Registration)\x20object\x27s\x20own\x20balance\x20pool.\x20To\x20actually\x20receive\x20the\x20money:\x20'+'fees_transfer\x20(to\x20a\x20treasury\x20or\x20allocation)\x20→\x20treasury\x20receive:\x20\x22recently\x22\x20(permission\x20253)\x20→\x20treasury\x20withdraw\x20→\x20'+'recipient\x20payment\x20receive.\x20A\x20successful\x20arb_withdraw\x20with\x20no\x20wallet\x20balance\x20change\x20is\x20EXPECTED,\x20not\x20a\x20failure.'),'fees_transfer':FeesTransferSchema['optional']()['describe']('Distribute\x20the\x20withdrawn\x20arbitration\x20fees.\x20Moves\x20the\x20Arbitration\x27s\x20ENTIRE\x20balance\x20in\x20ONE\x20call\x20—\x20there\x20is\x20NO\x20amount\x20parameter.\x20'+'The\x20balance\x20leaves\x20as\x20a\x20CoinWrapper\x20owned\x20by\x20the\x20target\x20(allocation\x20or\x20treasury);\x20for\x20a\x20treasury\x20target,\x20intake\x20it\x20with\x20'+'treasury\x20receive:\x20\x22recently\x22\x20(permission\x20253)\x20—\x20see\x20the\x20\x27to\x27\x20field\x20description.'),'usage_guard':z['union']([NameOrAddressSchema,z['null']()])['optional']()['describe']('Set\x20Guard\x20for\x20verification\x20when\x20users\x20apply\x20for\x20arbitration;\x20if\x20Guard\x20verification\x20fails,\x20users\x20will\x20not\x20be\x20able\x20to\x20apply\x20for\x20arbitration.'),'voting_guard':VotingGuardActionSchema['optional']()['describe']('Set\x20Guard\x20for\x20verification\x20during\x20arbitration\x20voting;\x20if\x20Guard\x20verification\x20fails,\x20arbitration\x20voting\x20will\x20fail.'),'owner_receive':ReceivedObjectsOrRecentlySchema['optional']()['describe']('Unwrap\x20CoinWrapper\x20objects\x20and\x20other\x20objects\x20received\x20by\x20this\x20Arbitration\x20object\x20and\x20send\x20them\x20to\x20the\x20owner\x20of\x20its\x20Permission\x20object.'+RECEIVE_FORMAT_BLOCK_OBJECTS),'um':z['union']([NameOrAddressSchema,z['null']()])['optional']()['describe']('Contact\x20object\x20ID\x20or\x20name.')})['strict']()['describe']('On-chain\x20Arbitration\x20operations.\x20TWO\x20OBJECT\x20KINDS\x20—\x20do\x20not\x20confuse\x20them\x20(§5.9):\x20the\x20ROOT\x20\x27object\x27\x20field\x20is\x20the\x20Arbitration\x20(arbitrator\x20REGISTRATION)\x20object;\x20the\x20Arb\x20(single\x20CASE)\x20created\x20by\x20\x27dispute\x27\x20is\x20addressed\x20via\x20each\x20case\x20operation\x27s\x20\x27arb\x27\x20field.\x20USAGE:\x20(1)\x20CREATE\x20NEW:\x20Set\x20\x27object\x27\x20field\x20with\x20OBJECT\x20format\x20{name,\x20type_parameter,\x20permission,\x20...}\x20to\x20create\x20an\x20Arbitration.\x20NOTE:\x27name\x27\x20goes\x20INSIDE\x20\x27object\x27,\x20NOT\x20at\x20the\x20data\x20root\x20level.\x20\x27permission\x27\x20can\x20be\x20a\x20new\x20Permission\x20object\x20or\x20reference\x20an\x20existing\x20one\x20-\x20check\x20\x27object\x27\x20field\x20description\x20for\x20details.\x20⚠️\x20PERMISSION\x20RULE\x20(contract-enforced):\x20the\x20Arbitration\x27s\x20permission\x20MUST\x20be\x20DIFFERENT\x20from\x20the\x20permission\x20of\x20any\x20Service\x20it\x20will\x20be\x20bound\x20to\x20—\x20binding\x20an\x20Arbitration\x20that\x20SHARES\x20the\x20Service\x27s\x20Permission\x20aborts\x20with\x20E_ARBITRATION_PERMISSION_CONFLICT\x20(error\x2033).\x20Always\x20create\x20a\x20DEDICATED\x20Permission\x20object\x20for\x20each\x20Arbitration.\x20(2)\x20OPERATE\x20EXISTING:\x20Set\x20\x27object\x27\x20field\x20with\x20STRING\x20format\x20(object\x20ID\x20or\x20name).\x20The\x20\x27object\x27\x20field\x20is\x20CRITICAL\x20and\x20REQUIRED\x20in\x20both\x20cases.\x20STRING\x20for\x20existing,\x20OBJECT\x20for\x20new\x20creation.');export const CallArbitration_InputSchema=z['object']({'data':CallArbitration_DataSchema,'env':CallEnvSchema['optional'](),'submission':SubmissionCallSchema['optional']()})['strict']();
@@ -568,6 +568,19 @@ export declare const WorkflowReceiptSchema: z.ZodObject<{
568
568
  }, z.core.$strict>>;
569
569
  note: z.ZodOptional<z.ZodString>;
570
570
  }, z.core.$strict>;
571
+ export declare const ReviewChainStepSchema: z.ZodObject<{
572
+ step: z.ZodEnum<{
573
+ repository_write: "repository_write";
574
+ reward_claim: "reward_claim";
575
+ }>;
576
+ status: z.ZodEnum<{
577
+ success: "success";
578
+ failed: "failed";
579
+ }>;
580
+ detail: z.ZodString;
581
+ digest: z.ZodOptional<z.ZodString>;
582
+ error: z.ZodOptional<z.ZodString>;
583
+ }, z.core.$strict>;
571
584
  export declare const SemanticSummarySchema: z.ZodObject<{
572
585
  intent: z.ZodString;
573
586
  status: z.ZodEnum<{
@@ -935,6 +948,19 @@ export declare const SemanticSummarySchema: z.ZodObject<{
935
948
  }, z.core.$strict>>;
936
949
  note: z.ZodOptional<z.ZodString>;
937
950
  }, z.core.$strict>>;
951
+ review_steps: z.ZodOptional<z.ZodArray<z.ZodObject<{
952
+ step: z.ZodEnum<{
953
+ repository_write: "repository_write";
954
+ reward_claim: "reward_claim";
955
+ }>;
956
+ status: z.ZodEnum<{
957
+ success: "success";
958
+ failed: "failed";
959
+ }>;
960
+ detail: z.ZodString;
961
+ digest: z.ZodOptional<z.ZodString>;
962
+ error: z.ZodOptional<z.ZodString>;
963
+ }, z.core.$strict>>>;
938
964
  }, z.core.$strict>;
939
965
  export declare const CallResponseErrorSchema: z.ZodObject<{
940
966
  type: z.ZodLiteral<"error">;
@@ -962,6 +988,7 @@ export declare const CallResponseErrorSchema: z.ZodObject<{
962
988
  wip_verification_failed: "wip_verification_failed";
963
989
  wip_storage_unavailable: "wip_storage_unavailable";
964
990
  submission_unknown: "submission_unknown";
991
+ move_abort_unmapped: "move_abort_unmapped";
965
992
  }>>;
966
993
  retryable: z.ZodOptional<z.ZodBoolean>;
967
994
  recovery_hint: z.ZodOptional<z.ZodString>;
@@ -1892,6 +1919,7 @@ export declare const CallResultSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
1892
1919
  wip_verification_failed: "wip_verification_failed";
1893
1920
  wip_storage_unavailable: "wip_storage_unavailable";
1894
1921
  submission_unknown: "submission_unknown";
1922
+ move_abort_unmapped: "move_abort_unmapped";
1895
1923
  }>>;
1896
1924
  retryable: z.ZodOptional<z.ZodBoolean>;
1897
1925
  recovery_hint: z.ZodOptional<z.ZodString>;
@@ -2794,6 +2822,19 @@ export declare const CallOutputExecutedSchema: z.ZodObject<{
2794
2822
  }, z.core.$strict>>;
2795
2823
  note: z.ZodOptional<z.ZodString>;
2796
2824
  }, z.core.$strict>>;
2825
+ review_steps: z.ZodOptional<z.ZodArray<z.ZodObject<{
2826
+ step: z.ZodEnum<{
2827
+ repository_write: "repository_write";
2828
+ reward_claim: "reward_claim";
2829
+ }>;
2830
+ status: z.ZodEnum<{
2831
+ success: "success";
2832
+ failed: "failed";
2833
+ }>;
2834
+ detail: z.ZodString;
2835
+ digest: z.ZodOptional<z.ZodString>;
2836
+ error: z.ZodOptional<z.ZodString>;
2837
+ }, z.core.$strict>>>;
2797
2838
  }, z.core.$strict>>;
2798
2839
  schema_warning: z.ZodOptional<z.ZodObject<{
2799
2840
  compatible: z.ZodBoolean;
@@ -3260,6 +3301,19 @@ export declare const CallOutputPendingInputSchema: z.ZodObject<{
3260
3301
  }, z.core.$strict>>;
3261
3302
  note: z.ZodOptional<z.ZodString>;
3262
3303
  }, z.core.$strict>>;
3304
+ review_steps: z.ZodOptional<z.ZodArray<z.ZodObject<{
3305
+ step: z.ZodEnum<{
3306
+ repository_write: "repository_write";
3307
+ reward_claim: "reward_claim";
3308
+ }>;
3309
+ status: z.ZodEnum<{
3310
+ success: "success";
3311
+ failed: "failed";
3312
+ }>;
3313
+ detail: z.ZodString;
3314
+ digest: z.ZodOptional<z.ZodString>;
3315
+ error: z.ZodOptional<z.ZodString>;
3316
+ }, z.core.$strict>>>;
3263
3317
  }, z.core.$strict>>;
3264
3318
  schema_warning: z.ZodOptional<z.ZodObject<{
3265
3319
  compatible: z.ZodBoolean;
@@ -3299,6 +3353,7 @@ export declare const CallOutputFailedSchema: z.ZodObject<{
3299
3353
  wip_verification_failed: "wip_verification_failed";
3300
3354
  wip_storage_unavailable: "wip_storage_unavailable";
3301
3355
  submission_unknown: "submission_unknown";
3356
+ move_abort_unmapped: "move_abort_unmapped";
3302
3357
  }>>;
3303
3358
  retryable: z.ZodOptional<z.ZodBoolean>;
3304
3359
  recovery_hint: z.ZodOptional<z.ZodString>;
@@ -3672,6 +3727,19 @@ export declare const CallOutputFailedSchema: z.ZodObject<{
3672
3727
  }, z.core.$strict>>;
3673
3728
  note: z.ZodOptional<z.ZodString>;
3674
3729
  }, z.core.$strict>>;
3730
+ review_steps: z.ZodOptional<z.ZodArray<z.ZodObject<{
3731
+ step: z.ZodEnum<{
3732
+ repository_write: "repository_write";
3733
+ reward_claim: "reward_claim";
3734
+ }>;
3735
+ status: z.ZodEnum<{
3736
+ success: "success";
3737
+ failed: "failed";
3738
+ }>;
3739
+ detail: z.ZodString;
3740
+ digest: z.ZodOptional<z.ZodString>;
3741
+ error: z.ZodOptional<z.ZodString>;
3742
+ }, z.core.$strict>>>;
3675
3743
  }, z.core.$strict>>;
3676
3744
  recovery: z.ZodObject<{
3677
3745
  strategy: z.ZodEnum<{
@@ -4454,6 +4522,19 @@ export declare const CallOutputSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
4454
4522
  }, z.core.$strict>>;
4455
4523
  note: z.ZodOptional<z.ZodString>;
4456
4524
  }, z.core.$strict>>;
4525
+ review_steps: z.ZodOptional<z.ZodArray<z.ZodObject<{
4526
+ step: z.ZodEnum<{
4527
+ repository_write: "repository_write";
4528
+ reward_claim: "reward_claim";
4529
+ }>;
4530
+ status: z.ZodEnum<{
4531
+ success: "success";
4532
+ failed: "failed";
4533
+ }>;
4534
+ detail: z.ZodString;
4535
+ digest: z.ZodOptional<z.ZodString>;
4536
+ error: z.ZodOptional<z.ZodString>;
4537
+ }, z.core.$strict>>>;
4457
4538
  }, z.core.$strict>>;
4458
4539
  schema_warning: z.ZodOptional<z.ZodObject<{
4459
4540
  compatible: z.ZodBoolean;
@@ -4919,6 +5000,19 @@ export declare const CallOutputSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
4919
5000
  }, z.core.$strict>>;
4920
5001
  note: z.ZodOptional<z.ZodString>;
4921
5002
  }, z.core.$strict>>;
5003
+ review_steps: z.ZodOptional<z.ZodArray<z.ZodObject<{
5004
+ step: z.ZodEnum<{
5005
+ repository_write: "repository_write";
5006
+ reward_claim: "reward_claim";
5007
+ }>;
5008
+ status: z.ZodEnum<{
5009
+ success: "success";
5010
+ failed: "failed";
5011
+ }>;
5012
+ detail: z.ZodString;
5013
+ digest: z.ZodOptional<z.ZodString>;
5014
+ error: z.ZodOptional<z.ZodString>;
5015
+ }, z.core.$strict>>>;
4922
5016
  }, z.core.$strict>>;
4923
5017
  schema_warning: z.ZodOptional<z.ZodObject<{
4924
5018
  compatible: z.ZodBoolean;
@@ -4957,6 +5051,7 @@ export declare const CallOutputSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
4957
5051
  wip_verification_failed: "wip_verification_failed";
4958
5052
  wip_storage_unavailable: "wip_storage_unavailable";
4959
5053
  submission_unknown: "submission_unknown";
5054
+ move_abort_unmapped: "move_abort_unmapped";
4960
5055
  }>>;
4961
5056
  retryable: z.ZodOptional<z.ZodBoolean>;
4962
5057
  recovery_hint: z.ZodOptional<z.ZodString>;
@@ -5330,6 +5425,19 @@ export declare const CallOutputSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
5330
5425
  }, z.core.$strict>>;
5331
5426
  note: z.ZodOptional<z.ZodString>;
5332
5427
  }, z.core.$strict>>;
5428
+ review_steps: z.ZodOptional<z.ZodArray<z.ZodObject<{
5429
+ step: z.ZodEnum<{
5430
+ repository_write: "repository_write";
5431
+ reward_claim: "reward_claim";
5432
+ }>;
5433
+ status: z.ZodEnum<{
5434
+ success: "success";
5435
+ failed: "failed";
5436
+ }>;
5437
+ detail: z.ZodString;
5438
+ digest: z.ZodOptional<z.ZodString>;
5439
+ error: z.ZodOptional<z.ZodString>;
5440
+ }, z.core.$strict>>>;
5333
5441
  }, z.core.$strict>>;
5334
5442
  recovery: z.ZodObject<{
5335
5443
  strategy: z.ZodEnum<{
@@ -5428,6 +5536,7 @@ export type WorkflowRecommendation = z.infer<typeof WorkflowRecommendationSchema
5428
5536
  export type WorkflowGuidance = z.infer<typeof WorkflowGuidanceSchema>;
5429
5537
  export type WorkflowWaiting = z.infer<typeof WorkflowWaitingSchema>;
5430
5538
  export type WorkflowReceipt = z.infer<typeof WorkflowReceiptSchema>;
5539
+ export type ReviewChainStep = z.infer<typeof ReviewChainStepSchema>;
5431
5540
  export type VerifyMismatch = z.infer<typeof VerifyMismatchSchema>;
5432
5541
  export type VerifyReport = z.infer<typeof VerifyReportSchema>;
5433
5542
  export type RecoveryAction = z.infer<typeof RecoveryActionSchema>;