@wowok/agent-mcp 2.7.1 → 2.7.2

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 (375) hide show
  1. package/dist/config/index.js +1 -1
  2. package/dist/config/runtime.js +1 -238
  3. package/dist/customer/customer-advice.js +1 -130
  4. package/dist/customer/index.js +1 -11
  5. package/dist/customer/industry-risks.js +1 -438
  6. package/dist/customer/info-puzzle.js +1 -681
  7. package/dist/customer/order-monitor.js +1 -328
  8. package/dist/customer/order-strategy.js +1 -373
  9. package/dist/customer/post-purchase.js +1 -351
  10. package/dist/customer/preorder-compare.js +1 -34
  11. package/dist/customer/reminder-system.js +1 -316
  12. package/dist/customer/risk-assessment.js +1 -397
  13. package/dist/customer/types.js +1 -13
  14. package/dist/customer/user-preferences.js +1 -460
  15. package/dist/evaluation/arbitration-game.d.ts +9 -2
  16. package/dist/evaluation/arbitration-game.js +1 -48
  17. package/dist/evaluation/builtins/demand-match.js +1 -153
  18. package/dist/evaluation/builtins/index.js +1 -10
  19. package/dist/evaluation/builtins/service-risk.js +1 -55
  20. package/dist/evaluation/capability.js +1 -13
  21. package/dist/evaluation/composer.js +1 -40
  22. package/dist/evaluation/engine.js +1 -175
  23. package/dist/evaluation/extract.js +1 -115
  24. package/dist/evaluation/game-strategy.d.ts +27 -0
  25. package/dist/evaluation/game-strategy.js +1 -0
  26. package/dist/evaluation/gap.js +1 -100
  27. package/dist/evaluation/index.d.ts +1 -0
  28. package/dist/evaluation/index.js +1 -11
  29. package/dist/evaluation/node-game.d.ts +31 -3
  30. package/dist/evaluation/node-game.js +1 -57
  31. package/dist/evaluation/region.js +1 -36
  32. package/dist/evaluation/types.d.ts +1 -0
  33. package/dist/evaluation/types.js +1 -1
  34. package/dist/evaluation/user-injection.js +1 -27
  35. package/dist/experience/experience-reuse.js +1 -103
  36. package/dist/experience/index.js +1 -5
  37. package/dist/experience/intent-distill.js +1 -83
  38. package/dist/experience/realtime-feedback.js +1 -94
  39. package/dist/experience/types.js +1 -1
  40. package/dist/experience/user-profile.js +1 -171
  41. package/dist/extensions/business-modules.js +1 -287
  42. package/dist/extensions/capability-manifest.js +1 -781
  43. package/dist/extensions/constraint-registry.js +1 -198
  44. package/dist/extensions/index.js +1 -6
  45. package/dist/extensions/metric-registry.js +1 -257
  46. package/dist/extensions/mode-evaluator.js +1 -170
  47. package/dist/extensions/modes.js +1 -499
  48. package/dist/extensions/registry.js +1 -717
  49. package/dist/extensions/types.js +1 -1
  50. package/dist/harness/auto-escalation.js +1 -68
  51. package/dist/harness/checkpoint.js +1 -129
  52. package/dist/harness/index.js +1 -78
  53. package/dist/harness/plan.js +1 -315
  54. package/dist/harness/recover.js +1 -139
  55. package/dist/harness/types.js +1 -1
  56. package/dist/harness/verify.js +1 -237
  57. package/dist/index.js +1 -273
  58. package/dist/intent/enrich.js +1 -67
  59. package/dist/intent/index.js +1 -60
  60. package/dist/intent/matcher.js +1 -81
  61. package/dist/intent/store.js +1 -55
  62. package/dist/intent/types.js +1 -10
  63. package/dist/knowledge/acquisition-flywheel.js +1 -192
  64. package/dist/knowledge/allocation-confirm.js +1 -534
  65. package/dist/knowledge/allocation-context.js +1 -249
  66. package/dist/knowledge/allocation-ledger.js +1 -463
  67. package/dist/knowledge/allocation-puzzle.js +1 -298
  68. package/dist/knowledge/allocation-risk.js +1 -568
  69. package/dist/knowledge/allocation-templates.js +1 -970
  70. package/dist/knowledge/allocation-translation.js +1 -585
  71. package/dist/knowledge/arb-risk.js +1 -210
  72. package/dist/knowledge/arbitration-confirm.js +1 -559
  73. package/dist/knowledge/arbitration-context.js +1 -505
  74. package/dist/knowledge/arbitration-ledger.js +1 -521
  75. package/dist/knowledge/arbitration-puzzle.js +1 -304
  76. package/dist/knowledge/arbitration-risk.js +1 -423
  77. package/dist/knowledge/arbitration-templates.js +1 -276
  78. package/dist/knowledge/arbitration-translation.js +1 -487
  79. package/dist/knowledge/arbitration-trust.js +1 -117
  80. package/dist/knowledge/audit-rules.js +1 -141
  81. package/dist/knowledge/bridge-risk.js +1 -263
  82. package/dist/knowledge/contact-risk.js +1 -200
  83. package/dist/knowledge/contact-templates.js +1 -60
  84. package/dist/knowledge/demand-confirm.js +1 -206
  85. package/dist/knowledge/demand-matching.js +1 -132
  86. package/dist/knowledge/demand-risk.js +1 -240
  87. package/dist/knowledge/demand-translation.js +1 -354
  88. package/dist/knowledge/deployment-scanner.js +1 -823
  89. package/dist/knowledge/dynamic-pricing.js +1 -87
  90. package/dist/knowledge/examples-scanner-cli.js +1 -26
  91. package/dist/knowledge/examples-scanner.js +1 -843
  92. package/dist/knowledge/flywheel-loop.js +1 -404
  93. package/dist/knowledge/fund-layer.js +1 -973
  94. package/dist/knowledge/glossary.js +1 -211
  95. package/dist/knowledge/guard-confirm.js +1 -406
  96. package/dist/knowledge/guard-context.js +1 -287
  97. package/dist/knowledge/guard-design-patterns.js +1 -360
  98. package/dist/knowledge/guard-ledger.js +1 -260
  99. package/dist/knowledge/guard-lint.js +1 -670
  100. package/dist/knowledge/guard-migration.js +1 -228
  101. package/dist/knowledge/guard-puzzle.js +1 -805
  102. package/dist/knowledge/guard-render.js +1 -700
  103. package/dist/knowledge/guard-risk.js +1 -1879
  104. package/dist/knowledge/guard-submission-prompt.js +1 -171
  105. package/dist/knowledge/guard-templates.js +1 -1105
  106. package/dist/knowledge/guard-translation.js +1 -1119
  107. package/dist/knowledge/index.js +1 -436
  108. package/dist/knowledge/industry-evolution.js +1 -323
  109. package/dist/knowledge/industry-generalizer.js +1 -381
  110. package/dist/knowledge/industry-registry.js +1 -174
  111. package/dist/knowledge/intent-metrics.d.ts +4 -3
  112. package/dist/knowledge/intent-metrics.js +1 -566
  113. package/dist/knowledge/machine-confirm.js +1 -559
  114. package/dist/knowledge/machine-context.js +1 -833
  115. package/dist/knowledge/machine-ledger.js +1 -338
  116. package/dist/knowledge/machine-puzzle.js +1 -494
  117. package/dist/knowledge/machine-render.js +1 -565
  118. package/dist/knowledge/machine-risk.js +1 -669
  119. package/dist/knowledge/machine-templates.js +1 -1597
  120. package/dist/knowledge/machine-topology.js +1 -234
  121. package/dist/knowledge/machine-translation.js +1 -513
  122. package/dist/knowledge/mcp-schema-audit-cli.js +1 -45
  123. package/dist/knowledge/mcp-schema-audit.js +1 -777
  124. package/dist/knowledge/onchain-constants.js +1 -35
  125. package/dist/knowledge/order-confirm.js +1 -573
  126. package/dist/knowledge/order-context.js +1 -390
  127. package/dist/knowledge/order-ledger.js +1 -341
  128. package/dist/knowledge/order-puzzle.js +1 -255
  129. package/dist/knowledge/order-risk.js +1 -653
  130. package/dist/knowledge/order-templates.js +1 -368
  131. package/dist/knowledge/order-translation.js +1 -550
  132. package/dist/knowledge/overrides-loader.js +1 -65
  133. package/dist/knowledge/passport-confirm.js +1 -531
  134. package/dist/knowledge/passport-context.js +1 -306
  135. package/dist/knowledge/passport-ledger.js +1 -282
  136. package/dist/knowledge/passport-puzzle.js +1 -333
  137. package/dist/knowledge/passport-risk.js +1 -450
  138. package/dist/knowledge/passport-templates.js +1 -568
  139. package/dist/knowledge/passport-translation.js +1 -516
  140. package/dist/knowledge/payment-risk.js +1 -249
  141. package/dist/knowledge/permission-confirm.js +1 -426
  142. package/dist/knowledge/permission-context.js +1 -224
  143. package/dist/knowledge/permission-ledger.js +1 -403
  144. package/dist/knowledge/permission-puzzle.js +1 -173
  145. package/dist/knowledge/permission-risk.js +1 -411
  146. package/dist/knowledge/permission-templates.js +1 -234
  147. package/dist/knowledge/permission-translation.js +1 -350
  148. package/dist/knowledge/personal-risk.js +1 -212
  149. package/dist/knowledge/process-model.js +1 -160
  150. package/dist/knowledge/progress-confirm.js +1 -456
  151. package/dist/knowledge/progress-context.js +1 -452
  152. package/dist/knowledge/progress-ledger.js +1 -330
  153. package/dist/knowledge/progress-puzzle.js +1 -219
  154. package/dist/knowledge/progress-risk.js +1 -461
  155. package/dist/knowledge/progress-templates.js +1 -228
  156. package/dist/knowledge/progress-translation.js +1 -405
  157. package/dist/knowledge/proof-confirm.js +1 -187
  158. package/dist/knowledge/proof-risk.js +1 -207
  159. package/dist/knowledge/proof-translation.js +1 -283
  160. package/dist/knowledge/registrar-risk.js +1 -217
  161. package/dist/knowledge/repository-confirm.js +1 -286
  162. package/dist/knowledge/repository-risk.js +1 -373
  163. package/dist/knowledge/repository-translation.js +1 -445
  164. package/dist/knowledge/reputation-rules.js +1 -99
  165. package/dist/knowledge/resource-risk.js +1 -157
  166. package/dist/knowledge/reward-confirm.js +1 -526
  167. package/dist/knowledge/reward-context.js +1 -504
  168. package/dist/knowledge/reward-ledger.js +1 -502
  169. package/dist/knowledge/reward-puzzle.js +1 -300
  170. package/dist/knowledge/reward-risk.js +1 -627
  171. package/dist/knowledge/reward-templates.js +1 -197
  172. package/dist/knowledge/reward-translation.js +1 -501
  173. package/dist/knowledge/safety-rules.js +1 -404
  174. package/dist/knowledge/scenario-modes.js +1 -321
  175. package/dist/knowledge/service-confirm.js +1 -807
  176. package/dist/knowledge/service-context.js +1 -403
  177. package/dist/knowledge/service-ledger.js +1 -609
  178. package/dist/knowledge/service-puzzle.js +1 -236
  179. package/dist/knowledge/service-risk.js +1 -651
  180. package/dist/knowledge/service-templates.js +1 -456
  181. package/dist/knowledge/service-translation.js +1 -622
  182. package/dist/knowledge/template-registry.js +1 -353
  183. package/dist/knowledge/tool-constraints.js +1 -195
  184. package/dist/knowledge/tools-reference.js +1 -178
  185. package/dist/knowledge/treasury-confirm.js +1 -512
  186. package/dist/knowledge/treasury-context.js +1 -363
  187. package/dist/knowledge/treasury-ledger.js +1 -300
  188. package/dist/knowledge/treasury-puzzle.js +1 -216
  189. package/dist/knowledge/treasury-risk.js +1 -440
  190. package/dist/knowledge/treasury-templates.js +1 -358
  191. package/dist/knowledge/treasury-translation.js +1 -498
  192. package/dist/knowledge/trust-metrics.js +1 -198
  193. package/dist/knowledge/util-risk.js +1 -135
  194. package/dist/loop-engineering/aggregate.js +1 -132
  195. package/dist/loop-engineering/context-collect.js +1 -83
  196. package/dist/loop-engineering/diagnose.js +1 -273
  197. package/dist/loop-engineering/improve.js +1 -405
  198. package/dist/loop-engineering/index.js +1 -4
  199. package/dist/loop-engineering/pipeline.js +1 -56
  200. package/dist/mode-market/index.js +1 -3
  201. package/dist/mode-market/registry.js +1 -124
  202. package/dist/mode-market/review.js +1 -214
  203. package/dist/mode-market/submission.js +1 -85
  204. package/dist/participation/collaborator-interest.d.ts +23 -0
  205. package/dist/participation/collaborator-interest.js +1 -0
  206. package/dist/participation/customer-interest.d.ts +25 -0
  207. package/dist/participation/customer-interest.js +1 -0
  208. package/dist/participation/merchant-interest.js +1 -100
  209. package/dist/participation/radar-core.d.ts +13 -3
  210. package/dist/participation/radar-core.js +1 -269
  211. package/dist/participation/supplier-interest.d.ts +25 -0
  212. package/dist/participation/supplier-interest.js +1 -0
  213. package/dist/persona/analyzer.js +1 -66
  214. package/dist/persona/bridge.js +1 -86
  215. package/dist/persona/defaults.js +1 -195
  216. package/dist/persona/experience-bridge.js +1 -23
  217. package/dist/persona/index.js +1 -71
  218. package/dist/persona/model.js +1 -111
  219. package/dist/persona/store.js +1 -62
  220. package/dist/persona/types.d.ts +3 -1
  221. package/dist/persona/types.js +1 -5
  222. package/dist/project/business-puzzle.js +1 -383
  223. package/dist/project/context-assembly.js +1 -254
  224. package/dist/project/deployment-bridge.js +1 -120
  225. package/dist/project/deployment-doc.js +1 -1126
  226. package/dist/project/edit-planner.js +1 -1342
  227. package/dist/project/evaluation.js +1 -2011
  228. package/dist/project/game-theory.js +1 -177
  229. package/dist/project/graph-builder.js +1 -656
  230. package/dist/project/graph.js +1 -340
  231. package/dist/project/handlers.js +1 -1784
  232. package/dist/project/index.d.ts +1 -0
  233. package/dist/project/index.js +1 -301
  234. package/dist/project/intent-analyzer.js +1 -149
  235. package/dist/project/machine-nodes.js +1 -36
  236. package/dist/project/merchant-guide.js +1 -264
  237. package/dist/project/migration.js +1 -125
  238. package/dist/project/mode-actions.js +1 -309
  239. package/dist/project/namespace.js +1 -206
  240. package/dist/project/participation-radar.js +1 -428
  241. package/dist/project/pipeline-actions.js +1 -109
  242. package/dist/project/project-store.js +1 -422
  243. package/dist/project/query.js +1 -153
  244. package/dist/project/reverse-mapping.d.ts +34 -0
  245. package/dist/project/reverse-mapping.js +1 -0
  246. package/dist/project/risk-aggregator.js +1 -295
  247. package/dist/project/rollback-policy.js +1 -290
  248. package/dist/project/semantic-assembler.js +1 -345
  249. package/dist/project/semantic-graph.js +1 -292
  250. package/dist/project/stage-gate.js +1 -369
  251. package/dist/project/substep-trace.js +1 -332
  252. package/dist/project/task-tracker.js +1 -78
  253. package/dist/role/derivation.d.ts +18 -0
  254. package/dist/role/derivation.js +1 -0
  255. package/dist/role/index.d.ts +5 -0
  256. package/dist/role/index.js +1 -0
  257. package/dist/role/model.d.ts +8 -0
  258. package/dist/role/model.js +1 -0
  259. package/dist/role/resolution.d.ts +11 -0
  260. package/dist/role/resolution.js +1 -0
  261. package/dist/role/types.d.ts +11 -0
  262. package/dist/role/types.js +1 -0
  263. package/dist/rules.js +1 -52
  264. package/dist/safety/confirm-gate.js +1 -88
  265. package/dist/safety/index.js +1 -3
  266. package/dist/safety/preview.js +1 -52
  267. package/dist/schema/call/allocation.js +1 -34
  268. package/dist/schema/call/arbitration.js +1 -113
  269. package/dist/schema/call/base.d.ts +15 -15
  270. package/dist/schema/call/base.js +1 -370
  271. package/dist/schema/call/bridge-handler.js +1 -265
  272. package/dist/schema/call/bridge.d.ts +7 -7
  273. package/dist/schema/call/bridge.js +1 -458
  274. package/dist/schema/call/contact.js +1 -37
  275. package/dist/schema/call/demand.js +1 -47
  276. package/dist/schema/call/guard.js +1 -161
  277. package/dist/schema/call/handler.js +1 -322
  278. package/dist/schema/call/index.js +1 -20
  279. package/dist/schema/call/machine.js +1 -193
  280. package/dist/schema/call/order.js +1 -35
  281. package/dist/schema/call/payment.js +1 -37
  282. package/dist/schema/call/permission-handler.js +1 -54
  283. package/dist/schema/call/permission.js +1 -105
  284. package/dist/schema/call/personal.js +1 -78
  285. package/dist/schema/call/progress.js +1 -47
  286. package/dist/schema/call/proof.js +1 -33
  287. package/dist/schema/call/repository.js +1 -77
  288. package/dist/schema/call/reward.js +1 -30
  289. package/dist/schema/call/semantic.js +1 -1679
  290. package/dist/schema/call/service.js +1 -184
  291. package/dist/schema/call/treasury.js +1 -71
  292. package/dist/schema/common/index.js +1 -407
  293. package/dist/schema/config/index.js +1 -68
  294. package/dist/schema/evaluation/index.d.ts +213 -16
  295. package/dist/schema/evaluation/index.js +1 -356
  296. package/dist/schema/index.js +1 -17
  297. package/dist/schema/intent-radar/index.d.ts +13 -13
  298. package/dist/schema/intent-radar/index.js +1 -89
  299. package/dist/schema/local/index.d.ts +21 -21
  300. package/dist/schema/local/index.js +1 -927
  301. package/dist/schema/local/wip.js +1 -187
  302. package/dist/schema/messenger/index.d.ts +7 -7
  303. package/dist/schema/messenger/index.js +1 -475
  304. package/dist/schema/operations.d.ts +7 -7
  305. package/dist/schema/operations.js +1 -520
  306. package/dist/schema/persona/index.d.ts +54 -54
  307. package/dist/schema/persona/index.js +1 -148
  308. package/dist/schema/project/index.d.ts +94 -48
  309. package/dist/schema/project/index.js +1 -2057
  310. package/dist/schema/query/index.d.ts +423 -7
  311. package/dist/schema/query/index.js +1 -1646
  312. package/dist/schema/schema-query/index.js +1 -104
  313. package/dist/schema/schema-version.js +1 -76
  314. package/dist/schema/sync-layer4.js +1 -286
  315. package/dist/schema/task-status.js +1 -36
  316. package/dist/schema/trust/index.js +1 -314
  317. package/dist/schema/utils/guard-parser.js +1 -419
  318. package/dist/schema/utils/guard-query-utils.js +1 -46
  319. package/dist/schema/utils/node-parser.js +1 -369
  320. package/dist/schema/utils/object-type-utils.js +1 -35
  321. package/dist/schema/utils/permission-index-utils.js +1 -7
  322. package/dist/schema/utils/permission-machine-check.js +1 -121
  323. package/dist/schema/utils/skills-recommendation.js +1 -77
  324. package/dist/schema-query/index.js +1 -810
  325. package/dist/schemas/account_operation.output.json +5 -2
  326. package/dist/schemas/bridge_operation.output.json +5 -2
  327. package/dist/schemas/evaluation_operation.output.json +112 -7
  328. package/dist/schemas/evaluation_operation.schema.json +93 -6
  329. package/dist/schemas/index.json +1 -1
  330. package/dist/schemas/intent_radar.output.json +4 -1
  331. package/dist/schemas/intent_radar.schema.json +4 -1
  332. package/dist/schemas/local_info_operation.output.json +5 -2
  333. package/dist/schemas/local_mark_operation.output.json +5 -2
  334. package/dist/schemas/messenger_operation.output.json +5 -2
  335. package/dist/schemas/onchain_events.output.json +5 -2
  336. package/dist/schemas/onchain_operations.output.json +5 -2
  337. package/dist/schemas/onchain_operations.schema.json +4 -4
  338. package/dist/schemas/onchain_operations_allocation.schema.json +1 -1
  339. package/dist/schemas/onchain_operations_machine.schema.json +2 -2
  340. package/dist/schemas/onchain_operations_service.schema.json +1 -1
  341. package/dist/schemas/onchain_table_data.output.json +6 -3
  342. package/dist/schemas/persona_operation.output.json +4 -1
  343. package/dist/schemas/persona_operation.schema.json +4 -1
  344. package/dist/schemas/project_operation.output.json +28 -8
  345. package/dist/schemas/query_toolkit.output.json +8 -5
  346. package/dist/schemas/wowok_buildin_info.output.json +132 -0
  347. package/dist/schemas/wowok_buildin_info.schema.json +14 -0
  348. package/dist/telemetry/index.js +1 -112
  349. package/dist/telemetry/redact.js +1 -23
  350. package/dist/telemetry/storage.js +1 -80
  351. package/dist/tools/handlers/bridge.js +1 -1
  352. package/dist/tools/handlers/config.js +1 -74
  353. package/dist/tools/handlers/evaluation.js +1 -123
  354. package/dist/tools/handlers/file-export.js +1 -90
  355. package/dist/tools/handlers/intent-radar.js +1 -76
  356. package/dist/tools/handlers/local.js +1 -53
  357. package/dist/tools/handlers/messenger.js +1 -188
  358. package/dist/tools/handlers/onchain.js +1 -1180
  359. package/dist/tools/handlers/persona.js +1 -89
  360. package/dist/tools/handlers/project.js +1 -211
  361. package/dist/tools/handlers/query.js +1 -434
  362. package/dist/tools/handlers/schema-query.js +1 -176
  363. package/dist/tools/handlers/task-status.js +1 -26
  364. package/dist/tools/handlers/trust.js +1 -380
  365. package/dist/tools/handlers/wip.js +1 -90
  366. package/dist/tools/index.js +1 -1382
  367. package/dist/tools/retry.js +1 -85
  368. package/dist/tools/rules-hook.js +1 -23
  369. package/dist/tools/shared.js +1 -130
  370. package/dist/tools/types.js +1 -1
  371. package/dist/tools/upgrade-check.d.ts +19 -0
  372. package/dist/tools/upgrade-check.js +1 -0
  373. package/dist/tools/wip-deploy-assist.js +1 -306
  374. package/dist/tools/wrap.js +1 -500
  375. package/package.json +4 -2
@@ -1,88 +1 @@
1
- import { CONFIRMATION_RULES, } from "../knowledge/safety-rules.js";
2
- import { isEnabled as isRuntimeEnabled } from "../config/index.js";
3
- export function isConfirmGateEnabled() {
4
- return isRuntimeEnabled("confirm_gate");
5
- }
6
- const internalErrorCounts = {};
7
- function logInternalError(context, error) {
8
- const key = context;
9
- internalErrorCounts[key] = (internalErrorCounts[key] ?? 0) + 1;
10
- const count = internalErrorCounts[key];
11
- console.warn(`[ConfirmGate] internal_error context="${context}" count=${count} error=${error instanceof Error ? error.message : String(error)}`);
12
- }
13
- export function getFailMode(level) {
14
- switch (level) {
15
- case "irreversible":
16
- case "publish":
17
- case "amount":
18
- return "closed";
19
- case "standard":
20
- case "none":
21
- default:
22
- return "open";
23
- }
24
- }
25
- function buildInternalErrorResult() {
26
- return {
27
- pass: false,
28
- level: "irreversible",
29
- preview: {
30
- level: "irreversible",
31
- operation: "unknown",
32
- irreversible: true,
33
- },
34
- rule_id: "internal_error",
35
- };
36
- }
37
- export function confirmGate(operation_type, data, env, userIntentPhrases) {
38
- if (!isConfirmGateEnabled())
39
- return { pass: true };
40
- if (env?.confirmed === true)
41
- return { pass: true };
42
- let matched;
43
- let ruleSearchError = null;
44
- try {
45
- matched = CONFIRMATION_RULES.find((r) => {
46
- try {
47
- return r.when(operation_type, data, env);
48
- }
49
- catch (e) {
50
- logInternalError(`rule_when:${r.id}`, e);
51
- if (getFailMode(r.level) === "closed") {
52
- throw e;
53
- }
54
- return false;
55
- }
56
- });
57
- }
58
- catch (e) {
59
- ruleSearchError = e;
60
- }
61
- if (ruleSearchError) {
62
- logInternalError("rule_search", ruleSearchError);
63
- return buildInternalErrorResult();
64
- }
65
- if (!matched)
66
- return { pass: true };
67
- if (matched.bypass_on_explicit_intent && userIntentPhrases && userIntentPhrases.length > 0) {
68
- const lower = userIntentPhrases.map((p) => p.toLowerCase());
69
- const bypass = matched.bypass_on_explicit_intent.some((p) => lower.some((u) => u.includes(p.toLowerCase())));
70
- if (bypass)
71
- return { pass: true };
72
- }
73
- let preview;
74
- try {
75
- preview = matched.preview(operation_type, data, env);
76
- }
77
- catch (e) {
78
- logInternalError(`rule_preview:${matched.id}`, e);
79
- if (getFailMode(matched.level) === "closed") {
80
- return buildInternalErrorResult();
81
- }
82
- return { pass: true };
83
- }
84
- return { pass: false, level: matched.level, preview, rule_id: matched.id };
85
- }
86
- export function isExplicitlyConfirmed(env) {
87
- return env?.confirmed === true;
88
- }
1
+ import{CONFIRMATION_RULES}from'../knowledge/safety-rules.js';import{isEnabled as a245a}from'../config/index.js';export function isConfirmGateEnabled(){return a245a('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(){return{'pass':![],'level':'irreversible','preview':{'level':'irreversible','operation':'unknown','irreversible':!![]},'rule_id':'internal_error'};}export function confirmGate(a,b,c,d){if(!isConfirmGateEnabled())return{'pass':!![]};if(c?.['confirmed']===!![])return{'pass':!![]};let f,g=null;try{f=CONFIRMATION_RULES['find'](i=>{try{return i['when'](a,b,c);}catch(j){logInternalError('rule_when:'+i['id'],j);if(getFailMode(i['level'])==='closed')throw j;return![];}});}catch(i){g=i;}if(g)return logInternalError('rule_search',g),buildInternalErrorResult();if(!f)return{'pass':!![]};if(f['bypass_on_explicit_intent']&&d&&d['length']>0x0){const j=d['map'](l=>l['toLowerCase']()),k=f['bypass_on_explicit_intent']['some'](l=>j['some'](m=>m['includes'](l['toLowerCase']())));if(k)return{'pass':!![]};}let h;try{h=f['preview'](a,b,c);}catch(l){logInternalError('rule_preview:'+f['id'],l);if(getFailMode(f['level'])==='closed')return buildInternalErrorResult();return{'pass':!![]};}return{'pass':![],'level':f['level'],'preview':h,'rule_id':f['id']};}export function isExplicitlyConfirmed(a){return a?.['confirmed']===!![];}
@@ -1,3 +1 @@
1
- export { confirmGate, isConfirmGateEnabled, isExplicitlyConfirmed, } from "./confirm-gate.js";
2
- export { renderPreview } from "./preview.js";
3
- export { CONFIRMATION_RULES, DEFAULT_VALUE_WARNINGS, DEFAULT_AMOUNT_THRESHOLD, getAmountThreshold, formatAmount, collectDefaultWarnings, SAFETY_RULES_VERSION, } from "../knowledge/safety-rules.js";
1
+ export{confirmGate,isConfirmGateEnabled,isExplicitlyConfirmed}from'./confirm-gate.js';export{renderPreview}from'./preview.js';export{CONFIRMATION_RULES,DEFAULT_VALUE_WARNINGS,DEFAULT_AMOUNT_THRESHOLD,getAmountThreshold,formatAmount,collectDefaultWarnings,SAFETY_RULES_VERSION}from'../knowledge/safety-rules.js';
@@ -1,52 +1 @@
1
- const LEVEL_LABEL = {
2
- none: "none",
3
- standard: "Standard confirmation",
4
- amount: "Amount confirmation",
5
- publish: "Publish confirmation (irreversible lock)",
6
- irreversible: "Irreversible operation confirmation",
7
- };
8
- const CONFIRMATION_REQUIRED_OPERATIONS = [
9
- "guard (CREATE — immutable, cannot be edited or deleted)",
10
- "service (publish=true — locks machine/order_allocators)",
11
- "machine (publish=true — locks nodes/pairs/forwards)",
12
- "arbitration (verdict — irreversible)",
13
- "payment (send — irreversible)",
14
- "treasury (withdraw/external_withdraw/external_deposit — irreversible)",
15
- "reward / treasury / service.compensation_fund_add (amount-sensitive)",
16
- "gen_passport (gas-consuming test)",
17
- ];
18
- export function renderPreview(p) {
19
- const lines = [];
20
- lines.push(`⚠️ Confirmation required — ${LEVEL_LABEL[p.level]}`);
21
- lines.push(` Operation: ${p.operation}`);
22
- if (p.object)
23
- lines.push(` Object: ${p.object}`);
24
- if (p.network)
25
- lines.push(` Network: ${p.network}`);
26
- if (p.account !== undefined)
27
- lines.push(` Account: ${p.account === "" ? "(default)" : p.account}`);
28
- if (p.amount) {
29
- lines.push(` Amount: ${p.amount.human_readable} (${p.amount.value} smallest unit)` +
30
- (p.amount.recipient ? ` → ${p.amount.recipient}` : ""));
31
- }
32
- if (p.immutable_after && p.immutable_after.length > 0) {
33
- lines.push(` Fields becoming immutable: ${p.immutable_after.join(", ")}`);
34
- }
35
- if (p.warnings && p.warnings.length > 0) {
36
- lines.push(" Warnings:");
37
- for (const w of p.warnings)
38
- lines.push(` - ${w}`);
39
- }
40
- if (p.irreversible) {
41
- lines.push(" ⛔ This operation is IRREVERSIBLE. It cannot be undone.");
42
- }
43
- lines.push("");
44
- lines.push("Confirm by re-calling with env.confirmed=true, or modify/cancel.");
45
- lines.push("");
46
- lines.push("Operations that require env.confirmed=true:");
47
- for (const op of CONFIRMATION_REQUIRED_OPERATIONS) {
48
- lines.push(` - ${op}`);
49
- }
50
- lines.push('Example: {"env": {"account": "...", "network": "testnet", "confirmed": true}}');
51
- return lines.join("\n");
52
- }
1
+ const LEVEL_LABEL={'none':'none','standard':'Standard\x20confirmation','amount':'Amount\x20confirmation','publish':'Publish\x20confirmation\x20(irreversible\x20lock)','irreversible':'Irreversible\x20operation\x20confirmation'},CONFIRMATION_REQUIRED_OPERATIONS=['guard\x20(CREATE\x20—\x20immutable,\x20cannot\x20be\x20edited\x20or\x20deleted)','service\x20(publish=true\x20—\x20locks\x20machine/order_allocators)','machine\x20(publish=true\x20—\x20locks\x20nodes/pairs/forwards)','arbitration\x20(verdict\x20—\x20irreversible)','payment\x20(send\x20—\x20irreversible)','treasury\x20(withdraw/external_withdraw/external_deposit\x20—\x20irreversible)','reward\x20/\x20treasury\x20/\x20service.compensation_fund_add\x20(amount-sensitive)','gen_passport\x20(gas-consuming\x20test)'];export function renderPreview(a){const b=[];b['push']('⚠️\x20\x20Confirmation\x20required\x20—\x20'+LEVEL_LABEL[a['level']]),b['push']('\x20\x20Operation:\x20'+a['operation']);if(a['object'])b['push']('\x20\x20Object:\x20'+a['object']);if(a['network'])b['push']('\x20\x20Network:\x20'+a['network']);if(a['account']!==undefined)b['push']('\x20\x20Account:\x20'+(a['account']===''?'(default)':a['account']));a['amount']&&b['push']('\x20\x20Amount:\x20'+a['amount']['human_readable']+'\x20('+a['amount']['value']+'\x20smallest\x20unit)'+(a['amount']['recipient']?'\x20→\x20'+a['amount']['recipient']:''));a['immutable_after']&&a['immutable_after']['length']>0x0&&b['push']('\x20\x20Fields\x20becoming\x20immutable:\x20'+a['immutable_after']['join'](',\x20'));if(a['warnings']&&a['warnings']['length']>0x0){b['push']('\x20\x20Warnings:');for(const c of a['warnings'])b['push']('\x20\x20\x20\x20-\x20'+c);}a['irreversible']&&b['push']('\x20\x20⛔\x20This\x20operation\x20is\x20IRREVERSIBLE.\x20It\x20cannot\x20be\x20undone.');b['push'](''),b['push']('Confirm\x20by\x20re-calling\x20with\x20env.confirmed=true,\x20or\x20modify/cancel.'),b['push'](''),b['push']('Operations\x20that\x20require\x20env.confirmed=true:');for(const d of CONFIRMATION_REQUIRED_OPERATIONS){b['push']('\x20\x20-\x20'+d);}return b['push']('Example:\x20{\x22env\x22:\x20{\x22account\x22:\x20\x22...\x22,\x20\x22network\x22:\x20\x22testnet\x22,\x20\x22confirmed\x22:\x20true}}'),b['join']('\x0a');}
@@ -1,34 +1 @@
1
- import { z } from "zod";
2
- import { CoinParamSchema, CallEnvSchema, SubmissionCallSchema, TypeNamedObjectSchema } from "./base.js";
3
- import { AllocatorsSchema, PaymentInfoSchema } from "../query/index.js";
4
- import { NameOrAddressSchema, ReceivedBalanceOrRecentlySchema, RECEIVE_FORMAT_BLOCK_BALANCE } from "../common/index.js";
5
- export const CallAllocation_CreateSchema = z.object({
6
- object: TypeNamedObjectSchema.describe("REQUIRED for creating new object. Provide {name: 'yourName', type: 'Allocation'} to create and name the new Allocation object."),
7
- allocators: AllocatorsSchema,
8
- coin: CoinParamSchema,
9
- payment_info: PaymentInfoSchema
10
- }).strict().describe("Create a new Allocation object. Set 'object' field with {name: 'yourName', type: 'Allocation'} to name the new object. Notice:'name' goes INSIDE 'object', NOT at the data root level.");
11
- export const CallAllocation_OperateSchema = z.object({
12
- object: NameOrAddressSchema.describe("REQUIRED for operating existing object. Provide the Allocation object ID or existing name to reference the target object."),
13
- received_coins: ReceivedBalanceOrRecentlySchema.optional().describe("Unwrap the CoinWrapper objects received by the Allocation object and deposit them into the pending allocation balance." + RECEIVE_FORMAT_BLOCK_BALANCE),
14
- alloc_by_guard: NameOrAddressSchema.optional().describe("Verify the specified Guard and execute the corresponding fund allocation. " +
15
- "POST-ALLOCATION CLAIM (required step): each recipient receives a CoinWrapper object (NOT spendable coins). " +
16
- "Recipient address resolution (allocation.move): Entity recipients receive it at the Entity's address; " +
17
- "Signer recipients receive it at the transaction sender's address; " +
18
- "GuardIdentifier n recipients receive it at the ADDRESS SUBMITTED for identifier n in this call's submission " +
19
- "(resolved via passport::submission_get) — conventionally the Order OBJECT address (escrow pattern), " +
20
- "in which case the order owner claims it via operation_type='order' {object:'<order_id>', receive:'recently'}. " +
21
- "Claim paths by holder: EOA wallet → operation_type='payment' RECEIVE mode {object:'<coinwrapper_id>', receive:true} (type_parameter optional, auto-derived from the CoinWrapper type); " +
22
- "Order object → order receive; Treasury object → treasury receive. " +
23
- "Find pending CoinWrappers via query_toolkit query_type='onchain_received'. " +
24
- "Verify the distribution via the immutable Payment object created by this call (allocation.payment array).")
25
- }).strict().describe("Operate on an existing Allocation object. Set 'object' field with the object ID or existing name to specify the target.");
26
- export const CallAllocation_DataSchema = z.union([
27
- CallAllocation_CreateSchema,
28
- CallAllocation_OperateSchema
29
- ]).describe("On-chain Allocation operations. USAGE: (1) CREATE NEW: Use CallAllocation_CreateSchema by setting 'object' with OBJECT format {name, type_parameter, ...}. (2) OPERATE EXISTING: Use CallAllocation_OperateSchema by setting 'object' with STRING format (object ID or name). The 'object' field is CRITICAL and REQUIRED in both cases. ");
30
- export const CallAllocation_InputSchema = z.object({
31
- data: CallAllocation_DataSchema,
32
- env: CallEnvSchema.optional(),
33
- submission: SubmissionCallSchema.optional(),
34
- }).strict();
1
+ import{z}from'zod';import{CoinParamSchema,CallEnvSchema,SubmissionCallSchema,TypeNamedObjectSchema}from'./base.js';import{AllocatorsSchema,PaymentInfoSchema}from'../query/index.js';import{NameOrAddressSchema,ReceivedBalanceOrRecentlySchema,RECEIVE_FORMAT_BLOCK_BALANCE}from'../common/index.js';export const CallAllocation_CreateSchema=z['object']({'object':TypeNamedObjectSchema['describe']('REQUIRED\x20for\x20creating\x20new\x20object.\x20Provide\x20{name:\x20\x27yourName\x27,\x20type:\x20\x27Allocation\x27}\x20to\x20create\x20and\x20name\x20the\x20new\x20Allocation\x20object.'),'allocators':AllocatorsSchema,'coin':CoinParamSchema,'payment_info':PaymentInfoSchema})['strict']()['describe']('Create\x20a\x20new\x20Allocation\x20object.\x20Set\x20\x27object\x27\x20field\x20with\x20{name:\x20\x27yourName\x27,\x20type:\x20\x27Allocation\x27}\x20to\x20name\x20the\x20new\x20object.\x20Notice:\x27name\x27\x20goes\x20INSIDE\x20\x27object\x27,\x20NOT\x20at\x20the\x20data\x20root\x20level.');export const CallAllocation_OperateSchema=z['object']({'object':NameOrAddressSchema['describe']('REQUIRED\x20for\x20operating\x20existing\x20object.\x20Provide\x20the\x20Allocation\x20object\x20ID\x20or\x20existing\x20name\x20to\x20reference\x20the\x20target\x20object.'),'received_coins':ReceivedBalanceOrRecentlySchema['optional']()['describe']('Unwrap\x20the\x20CoinWrapper\x20objects\x20received\x20by\x20the\x20Allocation\x20object\x20and\x20deposit\x20them\x20into\x20the\x20pending\x20allocation\x20balance.'+RECEIVE_FORMAT_BLOCK_BALANCE),'alloc_by_guard':NameOrAddressSchema['optional']()['describe']('Verify\x20the\x20specified\x20Guard\x20and\x20execute\x20the\x20corresponding\x20fund\x20allocation.\x20'+'POST-ALLOCATION\x20CLAIM\x20(required\x20step):\x20each\x20recipient\x20receives\x20a\x20CoinWrapper\x20object\x20(NOT\x20spendable\x20coins).\x20'+'Recipient\x20address\x20resolution\x20(allocation.move):\x20Entity\x20recipients\x20receive\x20it\x20at\x20the\x20Entity\x27s\x20address;\x20'+'Signer\x20recipients\x20receive\x20it\x20at\x20the\x20transaction\x20sender\x27s\x20address;\x20'+'GuardIdentifier\x20n\x20recipients\x20receive\x20it\x20at\x20the\x20ADDRESS\x20SUBMITTED\x20for\x20identifier\x20n\x20in\x20this\x20call\x27s\x20submission\x20'+'(resolved\x20via\x20passport::submission_get)\x20—\x20conventionally\x20the\x20Order\x20OBJECT\x20address\x20(escrow\x20pattern),\x20'+'in\x20which\x20case\x20the\x20order\x20owner\x20claims\x20it\x20via\x20operation_type=\x27order\x27\x20{object:\x27<order_id>\x27,\x20receive:\x27recently\x27}.\x20'+'Claim\x20paths\x20by\x20holder:\x20EOA\x20wallet\x20→\x20operation_type=\x27payment\x27\x20RECEIVE\x20mode\x20{object:\x27<coinwrapper_id>\x27,\x20receive:true}\x20(type_parameter\x20optional,\x20auto-derived\x20from\x20the\x20CoinWrapper\x20type);\x20'+'Order\x20object\x20→\x20order\x20receive;\x20Treasury\x20object\x20→\x20treasury\x20receive.\x20'+'Find\x20pending\x20CoinWrappers\x20via\x20query_toolkit\x20query_type=\x27onchain_received\x27.\x20'+'Verify\x20the\x20distribution\x20via\x20the\x20immutable\x20Payment\x20object\x20created\x20by\x20this\x20call\x20(allocation.payment\x20array).')})['strict']()['describe']('Operate\x20on\x20an\x20existing\x20Allocation\x20object.\x20Set\x20\x27object\x27\x20field\x20with\x20the\x20object\x20ID\x20or\x20existing\x20name\x20to\x20specify\x20the\x20target.');export const CallAllocation_DataSchema=z['union']([CallAllocation_CreateSchema,CallAllocation_OperateSchema])['describe']('On-chain\x20Allocation\x20operations.\x20USAGE:\x20(1)\x20CREATE\x20NEW:\x20Use\x20CallAllocation_CreateSchema\x20by\x20setting\x20\x27object\x27\x20with\x20OBJECT\x20format\x20{name,\x20type_parameter,\x20...}.\x20(2)\x20OPERATE\x20EXISTING:\x20Use\x20CallAllocation_OperateSchema\x20by\x20setting\x20\x27object\x27\x20with\x20STRING\x20format\x20(object\x20ID\x20or\x20name).\x20The\x20\x27object\x27\x20field\x20is\x20CRITICAL\x20and\x20REQUIRED\x20in\x20both\x20cases.\x20');export const CallAllocation_InputSchema=z['object']({'data':CallAllocation_DataSchema,'env':CallEnvSchema['optional'](),'submission':SubmissionCallSchema['optional']()})['strict']();
@@ -1,113 +1 @@
1
- import { z } from "zod";
2
- import { TypedPermissionObjectSchema, CoinParamSchema, NamedObjectSchema, CallEnvSchema, SubmissionCallSchema } from "./base.js";
3
- import { VotingGuardSchema } from "../query/index.js";
4
- import { BalanceTypeSchema, DescriptionSchema, LongNameSchema, NameOrAddressSchema, NameSchema, ReceivedObjectsOrRecentlySchema, RECEIVE_FORMAT_BLOCK_OBJECTS } from "../common/index.js";
5
- export const DisputeSchema = z.object({
6
- order: NameOrAddressSchema.describe("Order ID or name."),
7
- description: DescriptionSchema.optional().describe("Dispute description."),
8
- proposition: z.array(LongNameSchema).describe("List of dispute propositions."),
9
- fee: CoinParamSchema.describe("Dispute processing fee. FORMAT: {balance: <amount_in_smallest_unit>} — field name is 'balance' (NOT 'amount'). " +
10
- "The token type and precision are determined by the Arbitration object's type_parameter (the generic type set when the Arbitration was created). " +
11
- "For WOW (9 decimals): {balance: 50000000} = 0.05 WOW. For SUI (9 decimals): {balance: 50000000} = 0.05 SUI. " +
12
- "For tokens with different decimals, adjust accordingly (e.g. USDC has 6 decimals, so {balance: 50000} = 0.05 USDC)."),
13
- namedArb: NamedObjectSchema.optional().describe("RECOMMENDED: Set a local name for the newly created Arb (arbitration case) object. " +
14
- "Without this, the Arb is only referenceable by its on-chain address. " +
15
- "Example: {name: 'my_dispute_v1'} allows subsequent vote/feedback operations to use 'my_dispute_v1'.")
16
- }).strict();
17
- export const ConfirmSchema = z.object({
18
- arb: NameOrAddressSchema,
19
- voting_deadline: z.union([z.number().int().min(0), z.null()]).describe("Voting deadline as Unix timestamp in MILLISECONDS (ms). SEMANTICS OF SPECIAL VALUES: " +
20
- "0 = deadline already passed → voting is IMPOSSIBLE and the arbitrator may deliver the verdict immediately (direct-verdict flow); " +
21
- "null = open-ended voting with no deadline (verdict allowed anytime); " +
22
- "a future timestamp = normal voting window (recommended: now + at least 86400000 ms = 24 hours). " +
23
- "COMMON MISTAKE: using seconds instead of milliseconds (multiply by 1000). " +
24
- "Example: Date.now() + 259200000 for 3 days from now.")
25
- }).strict();
26
- export const VotingDeadlineChangeSchema = z.object({
27
- arb: NameOrAddressSchema,
28
- voting_deadline: z.union([z.number(), z.null()]).describe("New voting deadline as Unix timestamp in MILLISECONDS (ms). SEMANTICS OF SPECIAL VALUES: " +
29
- "0 = deadline already passed → voting is IMPOSSIBLE and the arbitrator may deliver the verdict immediately; " +
30
- "null = open-ended voting with no deadline (verdict allowed anytime); " +
31
- "a future timestamp = normal voting window (recommended: now + at least 86400000 ms = 24 hours). " +
32
- "COMMON MISTAKE: using seconds instead of milliseconds (multiply by 1000). " +
33
- "Example: Date.now() + 259200000 for 3 days from now.")
34
- }).strict();
35
- export const VoteSchema = z.object({
36
- arb: NameOrAddressSchema,
37
- votes: z.array(z.number().int().min(0).max(255)).describe("Proposition INDICES (0-based, u8) the voter agrees with — e.g. [0] votes for the first proposition. " +
38
- "Re-voting REPLACES the voter's previous vote (old weight removed, new applied). " +
39
- "Out-of-range index aborts with E_PROPOSITION_NOT_FOUND."),
40
- voting_guard: NameOrAddressSchema.optional().describe("Optional Voting Guard for weighted voting. THREE PATHS are supported by the SDK and Move contract: " +
41
- "(1) voting_guard PROVIDED → vote_with_voting_guard (Guard verifies voter + determines vote weight via VoteWeight config); " +
42
- "(2) voting_guard OMITTED but other guards trigger passport creation (e.g. env.permission_guard or usage_guard) → vote_with_passport (permission-only via passport); " +
43
- "(3) voting_guard OMITTED and no passport context → vote (plain permission-only vote, no Guard). " +
44
- "The Guard (when provided) must be in the Arbitration's voting_guard list."),
45
- }).strict();
46
- export const FeedbackSchema = z.object({
47
- arb: NameOrAddressSchema,
48
- feedback: DescriptionSchema.describe("Arbitration feedback."),
49
- }).strict();
50
- export const ArbitrationActionSchema = z.object({
51
- arb: NameOrAddressSchema,
52
- feedback: DescriptionSchema.describe("Arbitration feedback."),
53
- indemnity: z.number().int().min(0)
54
- }).strict();
55
- export const ResetSchema = z.object({
56
- arb: NameOrAddressSchema,
57
- feedback: DescriptionSchema.describe("Arbitration feedback."),
58
- }).strict();
59
- export const ArbWithdrawSchema = z.object({
60
- arb: NameOrAddressSchema,
61
- }).strict();
62
- export const FeesTransferToSchema = z.union([
63
- z.object({
64
- allocation: NameOrAddressSchema.describe("Allocation object ID or name.")
65
- }).strict(),
66
- z.object({
67
- treasury: NameOrAddressSchema.describe("Treasury object ID or name.")
68
- }).strict()
69
- ]);
70
- export const FeesTransferSchema = z.object({
71
- to: FeesTransferToSchema.describe("Transfer arbitration fees to the specified Allocation object or Treasury object."),
72
- payment_remark: NameSchema.describe("Payment remark."),
73
- payment_index: z.number().int().min(0).describe("Payment index."),
74
- newPayment: NamedObjectSchema.optional().describe("Name for the newly created payment object.")
75
- }).strict();
76
- export const VotingGuardActionSchema = z.discriminatedUnion("op", [
77
- z.object({
78
- op: z.enum(["add", "set"]),
79
- guards: z.array(VotingGuardSchema)
80
- }).strict(),
81
- z.object({
82
- op: z.literal("remove"),
83
- guards: z.array(NameOrAddressSchema)
84
- }).strict(),
85
- z.object({
86
- op: z.literal("clear")
87
- }).strict()
88
- ]);
89
- export const CallArbitration_DataSchema = z.object({
90
- object: TypedPermissionObjectSchema,
91
- dispute: DisputeSchema.optional().describe("Create a new Arb object for the order."),
92
- description: DescriptionSchema.optional().describe("Introduction of the Arbitration object."),
93
- location: LongNameSchema.optional().describe("Arbitration location."),
94
- fee: BalanceTypeSchema.optional().describe("Arbitration fee."),
95
- pause: z.boolean().optional().describe("Whether to pause arbitration."),
96
- confirm: ConfirmSchema.optional().describe("Confirm the materials submitted by the user for arbitration."),
97
- voting_deadline_change: VotingDeadlineChangeSchema.optional().describe("Change the voting deadline."),
98
- vote: VoteSchema.optional().describe("Vote on user propositions."),
99
- feedback: FeedbackSchema.optional().describe("Arbitration feedback for the Arb object."),
100
- arbitration: ArbitrationActionSchema.optional().describe("Provide a definitive arbitration result."),
101
- reset: ResetSchema.optional().describe("User applies to resubmit materials and restart arbitration."),
102
- arb_withdraw: ArbWithdrawSchema.optional().describe("Withdraw arbitration fees from the Arb object."),
103
- fees_transfer: FeesTransferSchema.optional().describe("Distribute the withdrawn arbitration fees."),
104
- usage_guard: z.union([NameOrAddressSchema, z.null()]).optional().describe("Set Guard for verification when users apply for arbitration; if Guard verification fails, users will not be able to apply for arbitration."),
105
- voting_guard: VotingGuardActionSchema.optional().describe("Set Guard for verification during arbitration voting; if Guard verification fails, arbitration voting will fail."),
106
- owner_receive: ReceivedObjectsOrRecentlySchema.optional().describe("Unwrap CoinWrapper objects and other objects received by this Arbitration object and send them to the owner of its Permission object." + RECEIVE_FORMAT_BLOCK_OBJECTS),
107
- um: z.union([NameOrAddressSchema, z.null()]).optional().describe("Contact object ID or name.")
108
- }).strict().describe("On-chain Arbitration operations. USAGE: (1) CREATE NEW: Set 'object' field with OBJECT format {name, type_parameter, permission, ...} to create an Arbitration. NOTE:'name' goes INSIDE 'object', NOT at the data root level. 'permission' can be a new Permission object or reference an existing one - check 'object' field description for details. ⚠️ PERMISSION RULE (contract-enforced, service.move arbitration_add_imp): the Arbitration's permission MUST be DIFFERENT from the permission of any Service it will be bound to — binding an Arbitration that SHARES the Service's Permission aborts with E_ARBITRATION_PERMISSION_CONFLICT (error 33). Always create a DEDICATED Permission object for each Arbitration. (2) OPERATE EXISTING: Set 'object' field with STRING format (object ID or name). The 'object' field is CRITICAL and REQUIRED in both cases. STRING for existing, OBJECT for new creation.");
109
- export const CallArbitration_InputSchema = z.object({
110
- data: CallArbitration_DataSchema,
111
- env: CallEnvSchema.optional(),
112
- submission: SubmissionCallSchema.optional(),
113
- }).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';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.\x20For\x20SUI\x20(9\x20decimals):\x20{balance:\x2050000000}\x20=\x200.05\x20SUI.\x20'+'For\x20tokens\x20with\x20different\x20decimals,\x20adjust\x20accordingly\x20(e.g.\x20USDC\x20has\x206\x20decimals,\x20so\x20{balance:\x2050000}\x20=\x200.05\x20USDC).'),'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':NameOrAddressSchema,'voting_deadline':z['union']([z['number']()['int']()['min'](0x0),z['null']()])['describe']('Voting\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(direct-verdict\x20flow);\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 VotingDeadlineChangeSchema=z['object']({'arb':NameOrAddressSchema,'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':NameOrAddressSchema,'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']('Optional\x20Voting\x20Guard\x20for\x20weighted\x20voting.\x20THREE\x20PATHS\x20are\x20supported\x20by\x20the\x20SDK\x20and\x20Move\x20contract:\x20'+'(1)\x20voting_guard\x20PROVIDED\x20→\x20vote_with_voting_guard\x20(Guard\x20verifies\x20voter\x20+\x20determines\x20vote\x20weight\x20via\x20VoteWeight\x20config);\x20'+'(2)\x20voting_guard\x20OMITTED\x20but\x20other\x20guards\x20trigger\x20passport\x20creation\x20(e.g.\x20env.permission_guard\x20or\x20usage_guard)\x20→\x20vote_with_passport\x20(permission-only\x20via\x20passport);\x20'+'(3)\x20voting_guard\x20OMITTED\x20and\x20no\x20passport\x20context\x20→\x20vote\x20(plain\x20permission-only\x20vote,\x20no\x20Guard).\x20'+'The\x20Guard\x20(when\x20provided)\x20must\x20be\x20in\x20the\x20Arbitration\x27s\x20voting_guard\x20list.')})['strict']();export const FeedbackSchema=z['object']({'arb':NameOrAddressSchema,'feedback':DescriptionSchema['describe']('Arbitration\x20feedback.')})['strict']();export const ArbitrationActionSchema=z['object']({'arb':NameOrAddressSchema,'feedback':DescriptionSchema['describe']('Arbitration\x20feedback.'),'indemnity':z['number']()['int']()['min'](0x0)})['strict']();export const ResetSchema=z['object']({'arb':NameOrAddressSchema,'feedback':DescriptionSchema['describe']('Arbitration\x20feedback.')})['strict']();export const ArbWithdrawSchema=z['object']({'arb':NameOrAddressSchema})['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.')})['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']('Payment\x20index.'),'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.'),'description':DescriptionSchema['optional']()['describe']('Introduction\x20of\x20the\x20Arbitration\x20object.'),'location':LongNameSchema['optional']()['describe']('Arbitration\x20location.'),'fee':BalanceTypeSchema['optional']()['describe']('Arbitration\x20fee.'),'pause':z['boolean']()['optional']()['describe']('Whether\x20to\x20pause\x20arbitration.'),'confirm':ConfirmSchema['optional']()['describe']('Confirm\x20the\x20materials\x20submitted\x20by\x20the\x20user\x20for\x20arbitration.'),'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']('User\x20applies\x20to\x20resubmit\x20materials\x20and\x20restart\x20arbitration.'),'arb_withdraw':ArbWithdrawSchema['optional']()['describe']('Withdraw\x20arbitration\x20fees\x20from\x20the\x20Arb\x20object.'),'fees_transfer':FeesTransferSchema['optional']()['describe']('Distribute\x20the\x20withdrawn\x20arbitration\x20fees.'),'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.\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,\x20service.move\x20arbitration_add_imp):\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']();
@@ -705,11 +705,11 @@ export declare const EvolutionContextSchema: z.ZodObject<{
705
705
  pending_suggestions: z.ZodOptional<z.ZodNumber>;
706
706
  intent: z.ZodOptional<z.ZodEnum<["default", "growth", "retention", "compliance", "efficiency", "trust_building", "custom"]>>;
707
707
  role_advice: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
708
- role: z.ZodOptional<z.ZodEnum<["user", "merchant", "arbitrator"]>>;
708
+ role: z.ZodOptional<z.ZodEnum<["merchant", "customer", "prospect", "supplier", "collaborator", "arbitrator"]>>;
709
709
  }, "strict", z.ZodTypeAny, {
710
710
  confidence: number;
711
711
  intent?: "custom" | "default" | "growth" | "retention" | "compliance" | "efficiency" | "trust_building" | undefined;
712
- role?: "user" | "merchant" | "arbitrator" | undefined;
712
+ role?: "merchant" | "customer" | "prospect" | "supplier" | "collaborator" | "arbitrator" | undefined;
713
713
  industry_signal?: string | undefined;
714
714
  evolution_advice?: string | undefined;
715
715
  health_score?: number | undefined;
@@ -718,7 +718,7 @@ export declare const EvolutionContextSchema: z.ZodObject<{
718
718
  }, {
719
719
  confidence: number;
720
720
  intent?: "custom" | "default" | "growth" | "retention" | "compliance" | "efficiency" | "trust_building" | undefined;
721
- role?: "user" | "merchant" | "arbitrator" | undefined;
721
+ role?: "merchant" | "customer" | "prospect" | "supplier" | "collaborator" | "arbitrator" | undefined;
722
722
  industry_signal?: string | undefined;
723
723
  evolution_advice?: string | undefined;
724
724
  health_score?: number | undefined;
@@ -1164,11 +1164,11 @@ export declare const SemanticSummarySchema: z.ZodObject<{
1164
1164
  pending_suggestions: z.ZodOptional<z.ZodNumber>;
1165
1165
  intent: z.ZodOptional<z.ZodEnum<["default", "growth", "retention", "compliance", "efficiency", "trust_building", "custom"]>>;
1166
1166
  role_advice: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
1167
- role: z.ZodOptional<z.ZodEnum<["user", "merchant", "arbitrator"]>>;
1167
+ role: z.ZodOptional<z.ZodEnum<["merchant", "customer", "prospect", "supplier", "collaborator", "arbitrator"]>>;
1168
1168
  }, "strict", z.ZodTypeAny, {
1169
1169
  confidence: number;
1170
1170
  intent?: "custom" | "default" | "growth" | "retention" | "compliance" | "efficiency" | "trust_building" | undefined;
1171
- role?: "user" | "merchant" | "arbitrator" | undefined;
1171
+ role?: "merchant" | "customer" | "prospect" | "supplier" | "collaborator" | "arbitrator" | undefined;
1172
1172
  industry_signal?: string | undefined;
1173
1173
  evolution_advice?: string | undefined;
1174
1174
  health_score?: number | undefined;
@@ -1177,7 +1177,7 @@ export declare const SemanticSummarySchema: z.ZodObject<{
1177
1177
  }, {
1178
1178
  confidence: number;
1179
1179
  intent?: "custom" | "default" | "growth" | "retention" | "compliance" | "efficiency" | "trust_building" | undefined;
1180
- role?: "user" | "merchant" | "arbitrator" | undefined;
1180
+ role?: "merchant" | "customer" | "prospect" | "supplier" | "collaborator" | "arbitrator" | undefined;
1181
1181
  industry_signal?: string | undefined;
1182
1182
  evolution_advice?: string | undefined;
1183
1183
  health_score?: number | undefined;
@@ -1425,7 +1425,7 @@ export declare const SemanticSummarySchema: z.ZodObject<{
1425
1425
  evolution_context?: {
1426
1426
  confidence: number;
1427
1427
  intent?: "custom" | "default" | "growth" | "retention" | "compliance" | "efficiency" | "trust_building" | undefined;
1428
- role?: "user" | "merchant" | "arbitrator" | undefined;
1428
+ role?: "merchant" | "customer" | "prospect" | "supplier" | "collaborator" | "arbitrator" | undefined;
1429
1429
  industry_signal?: string | undefined;
1430
1430
  evolution_advice?: string | undefined;
1431
1431
  health_score?: number | undefined;
@@ -1547,7 +1547,7 @@ export declare const SemanticSummarySchema: z.ZodObject<{
1547
1547
  evolution_context?: {
1548
1548
  confidence: number;
1549
1549
  intent?: "custom" | "default" | "growth" | "retention" | "compliance" | "efficiency" | "trust_building" | undefined;
1550
- role?: "user" | "merchant" | "arbitrator" | undefined;
1550
+ role?: "merchant" | "customer" | "prospect" | "supplier" | "collaborator" | "arbitrator" | undefined;
1551
1551
  industry_signal?: string | undefined;
1552
1552
  evolution_advice?: string | undefined;
1553
1553
  health_score?: number | undefined;
@@ -8119,11 +8119,11 @@ export declare const CallOutputSchema: z.ZodObject<{
8119
8119
  pending_suggestions: z.ZodOptional<z.ZodNumber>;
8120
8120
  intent: z.ZodOptional<z.ZodEnum<["default", "growth", "retention", "compliance", "efficiency", "trust_building", "custom"]>>;
8121
8121
  role_advice: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
8122
- role: z.ZodOptional<z.ZodEnum<["user", "merchant", "arbitrator"]>>;
8122
+ role: z.ZodOptional<z.ZodEnum<["merchant", "customer", "prospect", "supplier", "collaborator", "arbitrator"]>>;
8123
8123
  }, "strict", z.ZodTypeAny, {
8124
8124
  confidence: number;
8125
8125
  intent?: "custom" | "default" | "growth" | "retention" | "compliance" | "efficiency" | "trust_building" | undefined;
8126
- role?: "user" | "merchant" | "arbitrator" | undefined;
8126
+ role?: "merchant" | "customer" | "prospect" | "supplier" | "collaborator" | "arbitrator" | undefined;
8127
8127
  industry_signal?: string | undefined;
8128
8128
  evolution_advice?: string | undefined;
8129
8129
  health_score?: number | undefined;
@@ -8132,7 +8132,7 @@ export declare const CallOutputSchema: z.ZodObject<{
8132
8132
  }, {
8133
8133
  confidence: number;
8134
8134
  intent?: "custom" | "default" | "growth" | "retention" | "compliance" | "efficiency" | "trust_building" | undefined;
8135
- role?: "user" | "merchant" | "arbitrator" | undefined;
8135
+ role?: "merchant" | "customer" | "prospect" | "supplier" | "collaborator" | "arbitrator" | undefined;
8136
8136
  industry_signal?: string | undefined;
8137
8137
  evolution_advice?: string | undefined;
8138
8138
  health_score?: number | undefined;
@@ -8380,7 +8380,7 @@ export declare const CallOutputSchema: z.ZodObject<{
8380
8380
  evolution_context?: {
8381
8381
  confidence: number;
8382
8382
  intent?: "custom" | "default" | "growth" | "retention" | "compliance" | "efficiency" | "trust_building" | undefined;
8383
- role?: "user" | "merchant" | "arbitrator" | undefined;
8383
+ role?: "merchant" | "customer" | "prospect" | "supplier" | "collaborator" | "arbitrator" | undefined;
8384
8384
  industry_signal?: string | undefined;
8385
8385
  evolution_advice?: string | undefined;
8386
8386
  health_score?: number | undefined;
@@ -8502,7 +8502,7 @@ export declare const CallOutputSchema: z.ZodObject<{
8502
8502
  evolution_context?: {
8503
8503
  confidence: number;
8504
8504
  intent?: "custom" | "default" | "growth" | "retention" | "compliance" | "efficiency" | "trust_building" | undefined;
8505
- role?: "user" | "merchant" | "arbitrator" | undefined;
8505
+ role?: "merchant" | "customer" | "prospect" | "supplier" | "collaborator" | "arbitrator" | undefined;
8506
8506
  industry_signal?: string | undefined;
8507
8507
  evolution_advice?: string | undefined;
8508
8508
  health_score?: number | undefined;
@@ -9194,7 +9194,7 @@ export declare const CallOutputSchema: z.ZodObject<{
9194
9194
  evolution_context?: {
9195
9195
  confidence: number;
9196
9196
  intent?: "custom" | "default" | "growth" | "retention" | "compliance" | "efficiency" | "trust_building" | undefined;
9197
- role?: "user" | "merchant" | "arbitrator" | undefined;
9197
+ role?: "merchant" | "customer" | "prospect" | "supplier" | "collaborator" | "arbitrator" | undefined;
9198
9198
  industry_signal?: string | undefined;
9199
9199
  evolution_advice?: string | undefined;
9200
9200
  health_score?: number | undefined;
@@ -9770,7 +9770,7 @@ export declare const CallOutputSchema: z.ZodObject<{
9770
9770
  evolution_context?: {
9771
9771
  confidence: number;
9772
9772
  intent?: "custom" | "default" | "growth" | "retention" | "compliance" | "efficiency" | "trust_building" | undefined;
9773
- role?: "user" | "merchant" | "arbitrator" | undefined;
9773
+ role?: "merchant" | "customer" | "prospect" | "supplier" | "collaborator" | "arbitrator" | undefined;
9774
9774
  industry_signal?: string | undefined;
9775
9775
  evolution_advice?: string | undefined;
9776
9776
  health_score?: number | undefined;