@wowok/agent-mcp 2.7.7 → 2.7.10

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 (441) hide show
  1. package/README.md +2 -2
  2. package/dist/config/runtime.d.ts +1 -1
  3. package/dist/config/runtime.js +1 -1
  4. package/dist/customer/index.d.ts +3 -4
  5. package/dist/customer/index.js +1 -1
  6. package/dist/customer/info-puzzle.js +1 -1
  7. package/dist/customer/order-monitor.d.ts +0 -9
  8. package/dist/customer/order-monitor.js +1 -1
  9. package/dist/customer/order-strategy.d.ts +0 -19
  10. package/dist/customer/order-strategy.js +1 -1
  11. package/dist/customer/reminder-system.d.ts +0 -5
  12. package/dist/customer/reminder-system.js +1 -1
  13. package/dist/evaluation/game-strategy.js +1 -1
  14. package/dist/evaluation/injection.d.ts +6 -0
  15. package/dist/evaluation/injection.js +1 -0
  16. package/dist/evaluation/node-game.js +1 -1
  17. package/dist/examples/machine-multisig-threshold.json +1 -0
  18. package/dist/examples/rental-ziroom-machine-create.json +1 -2
  19. package/dist/examples/rental-ziroom-permission-create.json +1 -2
  20. package/dist/examples/rental-ziroom-service-create.json +1 -2
  21. package/dist/experience/experience-reuse.js +1 -1
  22. package/dist/experience/index.d.ts +2 -1
  23. package/dist/experience/index.js +1 -1
  24. package/dist/experience/persistence-config.d.ts +6 -0
  25. package/dist/experience/persistence-config.js +1 -0
  26. package/dist/experience/persistence.d.ts +21 -0
  27. package/dist/experience/persistence.js +1 -0
  28. package/dist/experience/realtime-feedback.js +1 -1
  29. package/dist/experience/user-profile.js +1 -1
  30. package/dist/extensions/business-modules.d.ts +1 -1
  31. package/dist/extensions/capability-manifest.d.ts +1 -1
  32. package/dist/extensions/types.d.ts +1 -1
  33. package/dist/goal/GoalClassifier.d.ts +17 -0
  34. package/dist/goal/GoalClassifier.js +1 -0
  35. package/dist/goal/GoalEngine.d.ts +120 -0
  36. package/dist/goal/GoalEngine.js +1 -0
  37. package/dist/goal/GoalStore.d.ts +27 -0
  38. package/dist/goal/GoalStore.js +1 -0
  39. package/dist/goal/plan-approval.d.ts +5 -0
  40. package/dist/goal/plan-approval.js +1 -0
  41. package/dist/goal/types.d.ts +76 -0
  42. package/dist/goal/types.js +1 -0
  43. package/dist/harness/index.d.ts +2 -7
  44. package/dist/harness/index.js +1 -1
  45. package/dist/harness/plan.d.ts +1 -1
  46. package/dist/harness/recover.js +1 -1
  47. package/dist/harness/types.d.ts +1 -36
  48. package/dist/harness/verify.js +1 -1
  49. package/dist/index.js +1 -1
  50. package/dist/intent/enrich.js +1 -1
  51. package/dist/intent/matcher.js +1 -1
  52. package/dist/intent/types.d.ts +1 -1
  53. package/dist/intent/types.js +1 -1
  54. package/dist/knowledge/account-marks.d.ts +35 -0
  55. package/dist/knowledge/account-marks.js +1 -0
  56. package/dist/knowledge/arbitration-ledger.js +1 -1
  57. package/dist/knowledge/audit-rules.d.ts +3 -1
  58. package/dist/knowledge/audit-rules.js +1 -1
  59. package/dist/knowledge/contract-invariants.d.ts +53 -0
  60. package/dist/knowledge/contract-invariants.js +1 -0
  61. package/dist/knowledge/dynamic-pricing.d.ts +0 -2
  62. package/dist/knowledge/dynamic-pricing.js +1 -1
  63. package/dist/knowledge/event-semantics.d.ts +20 -0
  64. package/dist/knowledge/event-semantics.js +1 -0
  65. package/dist/knowledge/examples-scanner-cli.js +1 -1
  66. package/dist/knowledge/examples-scanner.js +1 -1
  67. package/dist/knowledge/glossary.js +1 -1
  68. package/dist/knowledge/goal-completion.d.ts +19 -0
  69. package/dist/knowledge/goal-completion.js +1 -0
  70. package/dist/knowledge/guard-submission-prompt.js +1 -1
  71. package/dist/knowledge/guard-translation.js +1 -1
  72. package/dist/knowledge/immutability.d.ts +11 -0
  73. package/dist/knowledge/immutability.js +1 -0
  74. package/dist/knowledge/index.d.ts +13 -6
  75. package/dist/knowledge/index.js +1 -1
  76. package/dist/knowledge/industry-registry.js +1 -1
  77. package/dist/knowledge/intent-metrics.d.ts +1 -1
  78. package/dist/knowledge/jsonrpc-enum.d.ts +37 -0
  79. package/dist/knowledge/jsonrpc-enum.js +1 -0
  80. package/dist/knowledge/machine-confirm.js +1 -1
  81. package/dist/knowledge/machine-risk.js +1 -1
  82. package/dist/knowledge/machine-topology.d.ts +11 -0
  83. package/dist/knowledge/machine-topology.js +1 -1
  84. package/dist/knowledge/machine-translation.js +1 -1
  85. package/dist/knowledge/market-metrics.d.ts +11 -0
  86. package/dist/knowledge/market-metrics.js +1 -1
  87. package/dist/knowledge/mcp-schema-audit-cli.js +1 -1
  88. package/dist/knowledge/mcp-schema-audit.d.ts +1 -0
  89. package/dist/knowledge/mcp-schema-audit.js +1 -1
  90. package/dist/knowledge/messenger-guard-guidance.d.ts +17 -0
  91. package/dist/knowledge/messenger-guard-guidance.js +1 -0
  92. package/dist/knowledge/operation-dictionary.d.ts +18 -0
  93. package/dist/knowledge/operation-dictionary.js +1 -0
  94. package/dist/knowledge/passport-confirm.js +1 -1
  95. package/dist/knowledge/passport-puzzle.js +1 -1
  96. package/dist/knowledge/passport-translation.js +1 -1
  97. package/dist/knowledge/proof-risk.js +1 -1
  98. package/dist/knowledge/safety-rules.js +1 -1
  99. package/dist/knowledge/service-ledger.js +1 -1
  100. package/dist/knowledge/service-risk.js +1 -1
  101. package/dist/knowledge/service-translation.js +1 -1
  102. package/dist/knowledge/supply-chain.d.ts +24 -0
  103. package/dist/knowledge/supply-chain.js +1 -0
  104. package/dist/knowledge/template-registry.js +1 -1
  105. package/dist/knowledge/tools-reference.js +1 -1
  106. package/dist/knowledge/trust-metrics.d.ts +27 -2
  107. package/dist/knowledge/trust-metrics.js +1 -1
  108. package/dist/knowledge/workflow-guidance.d.ts +22 -0
  109. package/dist/knowledge/workflow-guidance.js +1 -1
  110. package/dist/knowledge/workspace-lists.d.ts +56 -0
  111. package/dist/knowledge/workspace-lists.js +1 -0
  112. package/dist/loop-engineering/context-collect.d.ts +1 -1
  113. package/dist/monitor/EventRouter.d.ts +10 -0
  114. package/dist/monitor/EventRouter.js +1 -0
  115. package/dist/monitor/EventStore.d.ts +98 -0
  116. package/dist/monitor/EventStore.js +1 -0
  117. package/dist/monitor/MonitorLoop.d.ts +79 -0
  118. package/dist/monitor/MonitorLoop.js +1 -0
  119. package/dist/monitor/ProblemBridge.d.ts +32 -0
  120. package/dist/monitor/ProblemBridge.js +1 -0
  121. package/dist/monitor/ScopeResolver.d.ts +59 -0
  122. package/dist/monitor/ScopeResolver.js +1 -0
  123. package/dist/monitor/SubscriptionStore.d.ts +13 -0
  124. package/dist/monitor/SubscriptionStore.js +1 -0
  125. package/dist/monitor/normalize.d.ts +8 -0
  126. package/dist/monitor/normalize.js +1 -0
  127. package/dist/monitor/types.d.ts +89 -0
  128. package/dist/monitor/types.js +1 -0
  129. package/dist/participation/radar-core.d.ts +0 -1
  130. package/dist/participation/radar-core.js +1 -1
  131. package/dist/persona/address-format.d.ts +6 -0
  132. package/dist/persona/address-format.js +1 -0
  133. package/dist/persona/analyzer.js +1 -1
  134. package/dist/persona/distill-goal.d.ts +20 -0
  135. package/dist/persona/distill-goal.js +1 -0
  136. package/dist/persona/index.d.ts +5 -0
  137. package/dist/persona/index.js +1 -1
  138. package/dist/persona/model.js +1 -1
  139. package/dist/persona/types.d.ts +1 -1
  140. package/dist/persona/types.js +1 -1
  141. package/dist/playbooks/service-build/business-puzzle.js +1 -0
  142. package/dist/{project → playbooks/service-build}/context-assembly.d.ts +9 -4
  143. package/dist/playbooks/service-build/context-assembly.js +1 -0
  144. package/dist/{project → playbooks/service-build}/game-theory.d.ts +1 -1
  145. package/dist/playbooks/service-build/index.d.ts +14 -0
  146. package/dist/playbooks/service-build/index.js +1 -0
  147. package/dist/{project → playbooks/service-build}/intent-analyzer.d.ts +1 -1
  148. package/dist/playbooks/service-build/intent-analyzer.js +1 -0
  149. package/dist/playbooks/service-build/machine-nodes.d.ts +25 -0
  150. package/dist/playbooks/service-build/machine-nodes.js +1 -0
  151. package/dist/playbooks/service-build/machine-panorama.d.ts +43 -0
  152. package/dist/playbooks/service-build/machine-panorama.js +1 -0
  153. package/dist/{project → playbooks/service-build}/merchant-guide.d.ts +1 -1
  154. package/dist/playbooks/service-build/merchant-guide.js +1 -0
  155. package/dist/{project → playbooks/service-build}/mode-actions.d.ts +2 -2
  156. package/dist/playbooks/service-build/mode-actions.js +1 -0
  157. package/dist/playbooks/service-build/namespace.d.ts +2 -0
  158. package/dist/playbooks/service-build/namespace.js +1 -0
  159. package/dist/playbooks/service-build/object-panorama.d.ts +178 -0
  160. package/dist/playbooks/service-build/object-panorama.js +1 -0
  161. package/dist/playbooks/service-build/object-type.d.ts +1 -0
  162. package/dist/playbooks/service-build/object-type.js +1 -0
  163. package/dist/{project → playbooks/service-build}/participation-radar.d.ts +4 -5
  164. package/dist/playbooks/service-build/participation-radar.js +1 -0
  165. package/dist/{project → playbooks/service-build}/pipeline-actions.d.ts +9 -9
  166. package/dist/playbooks/service-build/pipeline-actions.js +1 -0
  167. package/dist/playbooks/service-build/process.d.ts +6 -0
  168. package/dist/playbooks/service-build/process.js +1 -0
  169. package/dist/playbooks/service-build/risk-aggregator.js +1 -0
  170. package/dist/{project → playbooks/service-build}/semantic-graph.d.ts +2 -2
  171. package/dist/playbooks/service-build/service-panorama.d.ts +164 -0
  172. package/dist/playbooks/service-build/service-panorama.js +1 -0
  173. package/dist/review/arb.d.ts +6 -0
  174. package/dist/review/arb.js +1 -0
  175. package/dist/review/demand.d.ts +3 -0
  176. package/dist/review/demand.js +1 -0
  177. package/dist/review/index.d.ts +3 -0
  178. package/dist/review/index.js +1 -0
  179. package/dist/review/machine.d.ts +3 -0
  180. package/dist/review/machine.js +1 -0
  181. package/dist/review/order.d.ts +9 -0
  182. package/dist/review/order.js +1 -0
  183. package/dist/review/progress.d.ts +3 -0
  184. package/dist/review/progress.js +1 -0
  185. package/dist/review/repository.d.ts +3 -0
  186. package/dist/review/repository.js +1 -0
  187. package/dist/review/service.d.ts +5 -0
  188. package/dist/review/service.js +1 -0
  189. package/dist/review/types.d.ts +156 -0
  190. package/dist/review/types.js +1 -0
  191. package/dist/role/derivation.d.ts +19 -2
  192. package/dist/role/derivation.js +1 -1
  193. package/dist/role/index.d.ts +2 -2
  194. package/dist/role/index.js +1 -1
  195. package/dist/role/model.js +1 -1
  196. package/dist/role/resolution.d.ts +16 -0
  197. package/dist/role/resolution.js +1 -1
  198. package/dist/role/types.d.ts +1 -1
  199. package/dist/role/types.js +1 -1
  200. package/dist/rules.d.ts +2 -2
  201. package/dist/rules.js +1 -1
  202. package/dist/safety/confirm-gate.js +1 -1
  203. package/dist/safety/index.d.ts +1 -1
  204. package/dist/safety/index.js +1 -1
  205. package/dist/safety/preview.d.ts +1 -0
  206. package/dist/safety/preview.js +1 -1
  207. package/dist/schema/call/allocation.d.ts +2 -1
  208. package/dist/schema/call/arbitration.d.ts +5 -4
  209. package/dist/schema/call/arbitration.js +1 -1
  210. package/dist/schema/call/base.d.ts +17 -1
  211. package/dist/schema/call/base.js +1 -1
  212. package/dist/schema/call/bridge.d.ts +11 -4
  213. package/dist/schema/call/contact.d.ts +2 -1
  214. package/dist/schema/call/contact.js +1 -1
  215. package/dist/schema/call/demand.d.ts +2 -1
  216. package/dist/schema/call/demand.js +1 -1
  217. package/dist/schema/call/guard.d.ts +6 -3
  218. package/dist/schema/call/handler.d.ts +0 -3
  219. package/dist/schema/call/handler.js +1 -1
  220. package/dist/schema/call/machine.d.ts +4 -2
  221. package/dist/schema/call/machine.js +1 -1
  222. package/dist/schema/call/order.d.ts +2 -1
  223. package/dist/schema/call/payment.d.ts +2 -1
  224. package/dist/schema/call/permission.d.ts +2 -1
  225. package/dist/schema/call/personal.d.ts +39 -1
  226. package/dist/schema/call/personal.js +1 -1
  227. package/dist/schema/call/progress.d.ts +2 -1
  228. package/dist/schema/call/proof.d.ts +4 -2
  229. package/dist/schema/call/repository.d.ts +6 -5
  230. package/dist/schema/call/repository.js +1 -1
  231. package/dist/schema/call/reward.d.ts +2 -13
  232. package/dist/schema/call/reward.js +1 -1
  233. package/dist/schema/call/semantic.d.ts +3 -2
  234. package/dist/schema/call/semantic.js +1 -1
  235. package/dist/schema/call/service.d.ts +2 -1
  236. package/dist/schema/call/service.js +1 -1
  237. package/dist/schema/call/treasury.d.ts +2 -1
  238. package/dist/schema/common/index.js +1 -1
  239. package/dist/schema/evaluation/index.d.ts +146 -0
  240. package/dist/schema/evaluation/index.js +1 -1
  241. package/dist/schema/goal/index.d.ts +317 -0
  242. package/dist/schema/goal/index.js +1 -0
  243. package/dist/schema/goal/planning.d.ts +465 -0
  244. package/dist/schema/goal/planning.js +1 -0
  245. package/dist/schema/index.d.ts +2 -2
  246. package/dist/schema/index.js +1 -1
  247. package/dist/schema/industry-pack/index.d.ts +265 -1
  248. package/dist/schema/industry-pack/index.js +1 -1
  249. package/dist/schema/industry-pack/modes.d.ts +268 -0
  250. package/dist/schema/industry-pack/modes.js +1 -0
  251. package/dist/schema/intent-radar/index.d.ts +30 -3
  252. package/dist/schema/intent-radar/index.js +1 -1
  253. package/dist/schema/local/index.d.ts +9 -0
  254. package/dist/schema/local/index.js +1 -1
  255. package/dist/schema/messenger/index.d.ts +54 -0
  256. package/dist/schema/messenger/index.js +1 -1
  257. package/dist/schema/operations.d.ts +1147 -94
  258. package/dist/schema/operations.js +1 -1
  259. package/dist/schema/permission/index.d.ts +18 -0
  260. package/dist/schema/permission/index.js +1 -1
  261. package/dist/schema/persona/index.d.ts +40 -0
  262. package/dist/schema/persona/index.js +1 -1
  263. package/dist/schema/query/bi.d.ts +783 -0
  264. package/dist/schema/query/bi.js +1 -0
  265. package/dist/schema/query/index.d.ts +1471 -208
  266. package/dist/schema/query/index.js +1 -1
  267. package/dist/schema/schema-version.js +1 -1
  268. package/dist/schema/trust/index.d.ts +17 -0
  269. package/dist/schema/trust/index.js +1 -1
  270. package/dist/schema/utils/skills-recommendation.d.ts +0 -1
  271. package/dist/schema/utils/skills-recommendation.js +1 -1
  272. package/dist/schema/watch/index.d.ts +204 -0
  273. package/dist/schema/watch/index.js +1 -0
  274. package/dist/schema/workflow/index.d.ts +301 -0
  275. package/dist/schema/workflow/index.js +1 -1
  276. package/dist/schema-query-impl/index.js +1 -1
  277. package/dist/schemas/account_operation.output.json +8 -5
  278. package/dist/schemas/account_operation.schema.json +2 -2
  279. package/dist/schemas/bridge_operation.output.json +7 -4
  280. package/dist/schemas/bridge_operation.schema.json +37 -21
  281. package/dist/schemas/config_operation.output.json +1 -1
  282. package/dist/schemas/config_operation.schema.json +1 -1
  283. package/dist/schemas/evaluation_operation.output.json +276 -1
  284. package/dist/schemas/evaluation_operation.schema.json +307 -0
  285. package/dist/schemas/goal_operation.schema.json +1016 -0
  286. package/dist/schemas/guard2file.schema.json +9 -5
  287. package/dist/schemas/index.json +22 -11
  288. package/dist/schemas/industry_pack_operation.output.json +898 -0
  289. package/dist/schemas/industry_pack_operation.schema.json +217 -2
  290. package/dist/schemas/intent_radar.output.json +20 -2
  291. package/dist/schemas/intent_radar.schema.json +10 -1
  292. package/dist/schemas/local_info_operation.output.json +7 -4
  293. package/dist/schemas/local_mark_operation.output.json +7 -4
  294. package/dist/schemas/machineNode2file.schema.json +9 -5
  295. package/dist/schemas/messenger_operation.output.json +107 -4
  296. package/dist/schemas/messenger_operation.schema.json +98 -0
  297. package/dist/schemas/monitor_events.output.json +1435 -0
  298. package/dist/schemas/monitor_events.schema.json +85 -0
  299. package/dist/schemas/monitor_subscription.output.json +1462 -0
  300. package/dist/schemas/monitor_subscription.schema.json +327 -0
  301. package/dist/schemas/onchain_events.output.json +241 -18
  302. package/dist/schemas/onchain_events.schema.json +20 -0
  303. package/dist/schemas/onchain_operations.output.json +12 -7
  304. package/dist/schemas/onchain_operations.schema.json +570 -478
  305. package/dist/schemas/onchain_operations_allocation.schema.json +14 -10
  306. package/dist/schemas/onchain_operations_arbitration.schema.json +17 -12
  307. package/dist/schemas/onchain_operations_contact.schema.json +13 -9
  308. package/dist/schemas/onchain_operations_demand.schema.json +13 -9
  309. package/dist/schemas/onchain_operations_gen_passport.schema.json +9 -5
  310. package/dist/schemas/onchain_operations_gen_proof.schema.json +9 -5
  311. package/dist/schemas/onchain_operations_guard.schema.json +9 -5
  312. package/dist/schemas/onchain_operations_machine.schema.json +17 -13
  313. package/dist/schemas/onchain_operations_order.schema.json +12 -8
  314. package/dist/schemas/onchain_operations_payment.schema.json +10 -6
  315. package/dist/schemas/onchain_operations_permission.schema.json +12 -8
  316. package/dist/schemas/onchain_operations_personal.schema.json +47 -5
  317. package/dist/schemas/onchain_operations_progress.schema.json +12 -8
  318. package/dist/schemas/onchain_operations_proof.schema.json +9 -5
  319. package/dist/schemas/onchain_operations_repository.schema.json +295 -310
  320. package/dist/schemas/onchain_operations_reward.schema.json +17 -13
  321. package/dist/schemas/onchain_operations_service.schema.json +21 -17
  322. package/dist/schemas/onchain_operations_treasury.schema.json +17 -13
  323. package/dist/schemas/onchain_table_data.output.json +4125 -239
  324. package/dist/schemas/onchain_table_data.schema.json +326 -15
  325. package/dist/schemas/permission_operation.output.json +32 -0
  326. package/dist/schemas/permission_operation.schema.json +6 -2
  327. package/dist/schemas/persona_operation.output.json +145 -0
  328. package/dist/schemas/persona_operation.schema.json +28 -2
  329. package/dist/schemas/query_toolkit.output.json +3384 -2040
  330. package/dist/schemas/query_toolkit.schema.json +548 -9
  331. package/dist/schemas/trust_score.output.json +38 -0
  332. package/dist/schemas/trust_score.schema.json +32 -0
  333. package/dist/schemas/watch_operation.output.json +827 -0
  334. package/dist/schemas/watch_operation.schema.json +145 -0
  335. package/dist/schemas/workflow_operation.output.json +263 -5
  336. package/dist/schemas/workflow_operation.schema.json +599 -4
  337. package/dist/task/ProcessStore.d.ts +81 -0
  338. package/dist/task/ProcessStore.js +1 -0
  339. package/dist/task/playbook.d.ts +11 -0
  340. package/dist/task/playbook.js +1 -0
  341. package/dist/task/stage-gate.d.ts +22 -0
  342. package/dist/task/stage-gate.js +1 -0
  343. package/dist/{project → task}/substep-trace.d.ts +6 -45
  344. package/dist/task/types.d.ts +120 -0
  345. package/dist/task/types.js +1 -0
  346. package/dist/tools/handlers/config.js +1 -1
  347. package/dist/tools/handlers/evaluation.js +1 -1
  348. package/dist/tools/handlers/goal.d.ts +4 -0
  349. package/dist/tools/handlers/goal.js +1 -0
  350. package/dist/tools/handlers/industry-pack.js +1 -1
  351. package/dist/tools/handlers/intent-radar.js +1 -1
  352. package/dist/tools/handlers/messenger.js +1 -1
  353. package/dist/tools/handlers/monitor.d.ts +26 -0
  354. package/dist/tools/handlers/monitor.js +1 -0
  355. package/dist/tools/handlers/network.d.ts +1 -0
  356. package/dist/tools/handlers/network.js +1 -0
  357. package/dist/tools/handlers/onchain.js +1 -1
  358. package/dist/tools/handlers/permission.js +1 -1
  359. package/dist/tools/handlers/persona.js +1 -1
  360. package/dist/tools/handlers/query.js +1 -1
  361. package/dist/tools/handlers/trust.d.ts +14 -0
  362. package/dist/tools/handlers/trust.js +1 -1
  363. package/dist/tools/handlers/watch.d.ts +2 -0
  364. package/dist/tools/handlers/watch.js +1 -0
  365. package/dist/tools/handlers/workflow.js +1 -1
  366. package/dist/tools/index.d.ts +4 -0
  367. package/dist/tools/index.js +1 -1
  368. package/dist/tools/shared.js +1 -1
  369. package/dist/tools/wrap.js +1 -1
  370. package/package.json +5 -4
  371. package/dist/customer/post-purchase.d.ts +0 -44
  372. package/dist/customer/post-purchase.js +0 -1
  373. package/dist/harness/checkpoint.d.ts +0 -8
  374. package/dist/harness/checkpoint.js +0 -1
  375. package/dist/knowledge/deployment-scanner.d.ts +0 -66
  376. package/dist/knowledge/deployment-scanner.js +0 -1
  377. package/dist/project/business-puzzle.js +0 -1
  378. package/dist/project/context-assembly.js +0 -1
  379. package/dist/project/deployment-bridge.d.ts +0 -5
  380. package/dist/project/deployment-bridge.js +0 -1
  381. package/dist/project/deployment-doc.d.ts +0 -190
  382. package/dist/project/deployment-doc.js +0 -1
  383. package/dist/project/edit-planner.d.ts +0 -123
  384. package/dist/project/edit-planner.js +0 -1
  385. package/dist/project/evaluation-fix.spec.d.ts +0 -1
  386. package/dist/project/evaluation-fix.spec.js +0 -1
  387. package/dist/project/evaluation.d.ts +0 -127
  388. package/dist/project/evaluation.js +0 -1
  389. package/dist/project/graph-builder.d.ts +0 -51
  390. package/dist/project/graph-builder.js +0 -1
  391. package/dist/project/graph.d.ts +0 -70
  392. package/dist/project/graph.js +0 -1
  393. package/dist/project/handlers.d.ts +0 -540
  394. package/dist/project/handlers.js +0 -1
  395. package/dist/project/index.d.ts +0 -91
  396. package/dist/project/index.js +0 -1
  397. package/dist/project/intent-analyzer.js +0 -1
  398. package/dist/project/machine-nodes.d.ts +0 -2
  399. package/dist/project/machine-nodes.js +0 -1
  400. package/dist/project/merchant-guide.js +0 -1
  401. package/dist/project/migration.d.ts +0 -22
  402. package/dist/project/migration.js +0 -1
  403. package/dist/project/mode-actions.js +0 -1
  404. package/dist/project/namespace.d.ts +0 -72
  405. package/dist/project/namespace.js +0 -1
  406. package/dist/project/participation-radar.js +0 -1
  407. package/dist/project/pipeline-actions.js +0 -1
  408. package/dist/project/project-store.d.ts +0 -110
  409. package/dist/project/project-store.js +0 -1
  410. package/dist/project/query.d.ts +0 -43
  411. package/dist/project/query.js +0 -1
  412. package/dist/project/risk-aggregator.js +0 -1
  413. package/dist/project/rollback-policy.d.ts +0 -45
  414. package/dist/project/rollback-policy.js +0 -1
  415. package/dist/project/semantic-assembler.d.ts +0 -93
  416. package/dist/project/semantic-assembler.js +0 -1
  417. package/dist/project/stage-gate.d.ts +0 -53
  418. package/dist/project/stage-gate.js +0 -1
  419. package/dist/project/task-tracker.d.ts +0 -26
  420. package/dist/project/task-tracker.js +0 -1
  421. package/dist/schema/project/index.d.ts +0 -2015
  422. package/dist/schema/project/index.js +0 -1
  423. package/dist/schema/task-status.d.ts +0 -62
  424. package/dist/schema/task-status.js +0 -1
  425. package/dist/schemas/project_operation.output.json +0 -7877
  426. package/dist/schemas/project_operation.schema.json +0 -1133
  427. package/dist/schemas/query_task_status.output.json +0 -211
  428. package/dist/schemas/query_task_status.schema.json +0 -18
  429. package/dist/tools/handlers/project.d.ts +0 -2
  430. package/dist/tools/handlers/project.js +0 -1
  431. package/dist/tools/handlers/task-status.d.ts +0 -2
  432. package/dist/tools/handlers/task-status.js +0 -1
  433. /package/dist/{project → playbooks/service-build}/business-puzzle.d.ts +0 -0
  434. /package/dist/{project → playbooks/service-build}/game-theory.js +0 -0
  435. /package/dist/{project → playbooks/service-build}/reverse-mapping.d.ts +0 -0
  436. /package/dist/{project → playbooks/service-build}/reverse-mapping.js +0 -0
  437. /package/dist/{project → playbooks/service-build}/risk-aggregator.d.ts +0 -0
  438. /package/dist/{project → playbooks/service-build}/semantic-graph.js +0 -0
  439. /package/dist/{project → playbooks/service-build}/workflow-design-assessment.d.ts +0 -0
  440. /package/dist/{project → playbooks/service-build}/workflow-design-assessment.js +0 -0
  441. /package/dist/{project → task}/substep-trace.js +0 -0
@@ -1,1133 +0,0 @@
1
- {
2
- "$schema": "http://json-schema.org/draft-07/schema#",
3
- "$id": "https://wowok.net/schemas/project_operation.json",
4
- "title": "Project - Entity Management & Evaluation",
5
- "description": "Project management service — manage projects as first-class entities with SQLite persistence, rigid project-object relationships, three-pathway graph construction, and a dual rule-based + LLM-assisted evaluation engine. Actions: list_projects, create_project, create_project_from_onchain, update_project, get_project_detail, add_object, remove_object, create_version, build_graph, get_graph, evaluate_project, save_evaluation, compare_projects, refresh_objects, get_object_diff, assemble_context.",
6
- "type": "object",
7
- "properties": {
8
- "action": {
9
- "type": "string",
10
- "enum": [
11
- "list_projects",
12
- "create_project",
13
- "create_project_from_onchain",
14
- "update_project",
15
- "get_project_detail",
16
- "add_object",
17
- "remove_object",
18
- "update_object",
19
- "create_version",
20
- "build_graph",
21
- "get_graph",
22
- "evaluate_project",
23
- "save_evaluation",
24
- "compare_projects",
25
- "refresh_objects",
26
- "get_object_diff",
27
- "delete_project",
28
- "assemble_context",
29
- "reverse_map",
30
- "get_machine_graph",
31
- "get_guard_graph",
32
- "generate_deployment_doc",
33
- "pre_evaluate_check",
34
- "verify_deployment",
35
- "clone_project_to_network",
36
- "migrate_network",
37
- "migrate_to_mainnet",
38
- "plan_object_edit",
39
- "apply_object_edit",
40
- "patch_machine_nodes",
41
- "patch_guard_tree",
42
- "recommend_industry",
43
- "list_modes",
44
- "derive_user_mode",
45
- "evolve_user_mode",
46
- "register_user_mode",
47
- "unregister_user_mode",
48
- "register_custom_metric",
49
- "register_custom_constraint",
50
- "list_metrics_constraints",
51
- "analyze_intent",
52
- "aggregate_risks",
53
- "trace_substeps",
54
- "merchant_guide",
55
- "participation_radar"
56
- ],
57
- "description": "Action to perform. Two categories:\n1. Project Entity + Evaluation (15, GLM6): list_projects, create_project, create_project_from_onchain, update_project, get_project_detail, add_object, remove_object, create_version, build_graph, get_graph, evaluate_project, save_evaluation, compare_projects, refresh_objects, get_object_diff. Projects are first-class entities with SQLite persistence, rigid project-object relationships, three-pathway graph construction, and a dual rule-based + LLM-assisted evaluation engine.\n2. Context Assembly (1): assemble_context (query on-chain object states + extract embedded history + optional events, and assemble a structured semantic context for LLM consumption). Required input: context_objects (array of object IDs/names). Optional: include_events (query recent state-transition events).\n2b. Reverse Mapping (1): reverse_map (deterministic L4→L1 business report — queries the on-chain objects, classifies them into business semantics, and emits a fixed-rule BusinessReport with merchant profile, user risk assessment, and game-theory analysis. Same objects ALWAYS yield the same report — no LLM involved). Required input: context_objects (include the Service; add Machine/Allocation for refund-path detection). Optional: context_network, order_amount.\n3. Cross-Network Migration (FIX-012): clone_project_to_network (or its alias migrate_network) copies a source project's object metadata to a new project bound to target_network. The 5-step migration workflow: 1) call clone_project_to_network (or migrate_network) with target_network to copy metadata, 2) re-run onchain_operations with env.network=target_network to deploy objects on-chain, 3) re-register LocalMark names with the SAME names on the target network (FIX-011 cross-network consistency), 4) update_project to set service_address on the new project, 5) build_graph to construct the new project's relationship graph."
58
- },
59
- "project": {
60
- "description": "Project prefix (human-readable unique identifier). For create_project: OPTIONAL — if omitted, auto-derived from project_name (e.g. 'Twitch Service' → 'twitch_service'). For other actions (build_graph, evaluate_project, etc.): used to identify the project. Takes precedence resolution: project_id > project (prefix).",
61
- "type": "string"
62
- },
63
- "version": {
64
- "description": "Project version (e.g. 'v1'). Used by create_version.",
65
- "type": "string",
66
- "pattern": "^v\\d+$"
67
- },
68
- "context_objects": {
69
- "description": "Object IDs (0x...) or LocalMark names to assemble context for. Required when action='assemble_context'. The current on-chain state of each object will be queried and enriched with semantic annotations.",
70
- "type": "array",
71
- "items": {
72
- "type": "string"
73
- }
74
- },
75
- "include_events": {
76
- "description": "When true, assemble_context also queries recent state-transition events (NewOrderEvent, ProgressEvent, ArbEvent, etc.). Events are the real-time transition log — convergent and bounded. Defaults to false. Note: object-embedded history (ProgressSession.forwards, Order.disputes) is ALWAYS extracted automatically — no flag needed.",
77
- "type": "boolean"
78
- },
79
- "context_network": {
80
- "description": "Network for assemble_context / reverse_map queries. Defaults to 'testnet' if omitted.",
81
- "type": "string",
82
- "enum": [
83
- "testnet",
84
- "mainnet"
85
- ]
86
- },
87
- "reverse_order_amount": {
88
- "description": "Escrowed order amount (smallest-unit string) for reverse_map — included in the report summary as the concrete escrow mention.",
89
- "type": "string"
90
- },
91
- "context_depth": {
92
- "description": "BFS recursion depth for dependency expansion in assemble_context (default 0 = no expansion). When >0, the assembly recursively queries objects referenced by the center objects (permission, guard, machine, service, repositories, etc.) up to the given depth, using the same address-field extraction rules as build_graph (Pathway 1). Each level issues one batched query_objects call (≤50 IDs per batch). Cycles are detected and skipped via a visited set. Discovered dependencies are returned in `dependencies` (edge metadata) and `dependency_objects` (full object states). Recommended: 1–2 for most use cases; 3+ may pull large subgraphs (use context_include to constrain).",
93
- "type": "integer",
94
- "minimum": 0,
95
- "maximum": 5
96
- },
97
- "context_include": {
98
- "description": "Optional filter for dependency expansion edge types. When omitted, ALL outbound references are followed. When provided, only edges whose `field` matches one of the listed names are followed. Recognized field names (from extractAddressFields): 'permission', 'machine', 'service', 'progress', 'buy_guard', 'um', 'repositories', 'arbitrations', 'rewards', 'consensus_repositories', 'context_repositories', 'dispute', 'allocation', 'external_deposit_guard', 'external_withdraw_guard', 'allocator_guard', 'for_object', 'for_guard', 'payment', 'voting_guard', 'usage_guard', 'guard', 'write_guard', 'quote_guard', 'recipient_entity', 'order_allocators'. Example: ['permission','guard'] expands only permission/guard dependencies.",
99
- "type": "array",
100
- "items": {
101
- "type": "string"
102
- }
103
- },
104
- "filter_status": {
105
- "description": "Filter list_projects by project status.",
106
- "type": "string",
107
- "enum": [
108
- "draft",
109
- "active",
110
- "inactive",
111
- "archived"
112
- ]
113
- },
114
- "filter_perspective": {
115
- "description": "Filter list_projects by project perspective.",
116
- "type": "string",
117
- "enum": [
118
- "producer",
119
- "consumer",
120
- "both"
121
- ]
122
- },
123
- "filter_network": {
124
- "description": "Filter list_projects by network.",
125
- "type": "string",
126
- "enum": [
127
- "testnet",
128
- "mainnet"
129
- ]
130
- },
131
- "project_name": {
132
- "description": "Display name for create_project / create_project_from_onchain / update_project. Required when action='create_project'.",
133
- "type": "string",
134
- "minLength": 1,
135
- "maxLength": 200
136
- },
137
- "project_description": {
138
- "description": "Project description for create_project / update_project.",
139
- "type": "string",
140
- "maxLength": 2000
141
- },
142
- "project_industry": {
143
- "description": "Industry tag for create_project. Drives template defaults — when set (and not 'general'), the system auto-applies an industry blueprint with ~10 draft objects (Permission, Service, Machine, Guard, Treasury, Allocation, etc.) + graph edges, ready for deployment. Supported industries: 'general' (no template), 'retail', 'retail_d2c' (Direct-to-Consumer, e.g., Shopify — Allocation escrow + 2 Guards), 'service', 'rental', 'freelance', 'education', 'travel', 'subscription', 'custom'. Each industry preset embeds risk constraints (e.g., 'freelance' does NOT require compensation_fund, while 'rental'/'travel' do). Example: project_industry='freelance' creates a freelance-style blueprint with setting_locked_time ≥ 7d. Set skip_templates=true to bypass template application.",
144
- "type": "string",
145
- "enum": [
146
- "general",
147
- "retail",
148
- "retail_d2c",
149
- "service",
150
- "rental",
151
- "freelance",
152
- "education",
153
- "travel",
154
- "subscription",
155
- "custom"
156
- ]
157
- },
158
- "project_perspective": {
159
- "description": "Project perspective for create_project. 'producer' = build/operate services, 'consumer' = evaluate/buy services, 'both' = dual role. Defaults to 'producer'.",
160
- "type": "string",
161
- "enum": [
162
- "producer",
163
- "consumer",
164
- "both"
165
- ]
166
- },
167
- "project_labels": {
168
- "description": "Free-form labels for create_project / update_project (e.g. ['travel','london','priority']).",
169
- "type": "array",
170
- "items": {
171
- "type": "string"
172
- }
173
- },
174
- "service_address": {
175
- "description": "On-chain Service object address. Required for create_project_from_onchain. Optional for create_project (links the project to its core Service).",
176
- "type": "string"
177
- },
178
- "project_network": {
179
- "description": "Network the project is bound to. A Service deployed to different networks are different projects. Defaults to 'testnet'.",
180
- "type": "string",
181
- "enum": [
182
- "testnet",
183
- "mainnet"
184
- ]
185
- },
186
- "skip_templates": {
187
- "description": "When true, create_project skips applying the industry template (no draft:* blueprint objects). Use this when you want a clean project with no pre-filled blueprint objects — useful for custom architectures that do not match any industry mode, or to avoid draft objects appearing in build_graph / evaluate_project before deployment. Defaults to false (templates applied).",
188
- "type": "boolean"
189
- },
190
- "project_id": {
191
- "description": "Project UUID for update_project / get_project_detail / add_object / remove_object / create_version / build_graph / evaluate_project / refresh_objects. Takes precedence over 'project' (prefix) when both are given.",
192
- "type": "string"
193
- },
194
- "project_status": {
195
- "description": "New status for update_project. 'active' projects are live, 'archived' are read-only.",
196
- "type": "string",
197
- "enum": [
198
- "draft",
199
- "active",
200
- "inactive",
201
- "archived"
202
- ]
203
- },
204
- "target_network": {
205
- "description": "Target network for clone_project_to_network (or its alias migrate_network). The source project's objects are copied to a new project bound to this network. The new project's prefix is '<source_prefix>_<target_network>' to avoid collision. See the action description for the full 5-step migration workflow (FIX-012).",
206
- "type": "string",
207
- "enum": [
208
- "testnet",
209
- "mainnet"
210
- ]
211
- },
212
- "object_address": {
213
- "description": "On-chain object address (0x followed by 32-64 hex chars) for add_object / remove_object. Also accepts the internal 'draft:<name>' sentinel used by create_project for blueprint objects not yet on-chain. For add_object, alternatively use object_name_add to resolve via LocalMark. H-06 fix: invalid formats are rejected at the handler level with a descriptive error.",
214
- "type": "string"
215
- },
216
- "object_name_add": {
217
- "description": "LocalMark name for add_object (alternative to object_address).",
218
- "type": "string"
219
- },
220
- "object_type_add": {
221
- "description": "Object type for add_object.",
222
- "type": "string",
223
- "enum": [
224
- "Service",
225
- "Machine",
226
- "Guard",
227
- "Permission",
228
- "Reward",
229
- "Arbitration",
230
- "Progress",
231
- "Treasury",
232
- "Demand",
233
- "Repository",
234
- "Contact",
235
- "Order",
236
- "Allocation",
237
- "Personal",
238
- "Payment",
239
- "Proof"
240
- ]
241
- },
242
- "object_role": {
243
- "description": "Object role in project for add_object. 'core' = the Service (only one per project), 'dependency' = required binding, 'reference' = optional/auxiliary. Defaults to 'reference'.",
244
- "type": "string",
245
- "enum": [
246
- "core",
247
- "dependency",
248
- "reference"
249
- ]
250
- },
251
- "object_tags_add": {
252
- "description": "Tags for add_object.",
253
- "type": "array",
254
- "items": {
255
- "type": "string"
256
- }
257
- },
258
- "object_id_remove": {
259
- "description": "ProjectObject UUID for remove_object (the project_objects.id, NOT the on-chain address).",
260
- "type": "string"
261
- },
262
- "object_id_update": {
263
- "description": "ProjectObject UUID for update_object (the project_objects.id).",
264
- "type": "string"
265
- },
266
- "object_name_update": {
267
- "description": "New name for update_object.",
268
- "type": "string"
269
- },
270
- "object_type_update": {
271
- "description": "New type for update_object.",
272
- "type": "string"
273
- },
274
- "object_role_update": {
275
- "description": "New role for update_object.",
276
- "type": "string",
277
- "enum": [
278
- "core",
279
- "dependency",
280
- "reference"
281
- ]
282
- },
283
- "object_tags_update": {
284
- "description": "New tags for update_object.",
285
- "type": "array",
286
- "items": {
287
- "type": "string"
288
- }
289
- },
290
- "version_description": {
291
- "description": "Description for create_version.",
292
- "type": "string",
293
- "maxLength": 500
294
- },
295
- "fork_from_version": {
296
- "description": "Source version for create_version (fork objects + graph from this version).",
297
- "type": "string"
298
- },
299
- "max_depth": {
300
- "description": "Max recursion depth for Pathway 1 (internal reference derivation) in build_graph. Default 3.",
301
- "type": "integer",
302
- "minimum": 1,
303
- "maximum": 5
304
- },
305
- "depth": {
306
- "description": "Alias for max_depth (build_graph). When both are set, max_depth takes precedence. Default 3.",
307
- "type": "integer",
308
- "minimum": 1,
309
- "maximum": 5
310
- },
311
- "enable_registrar": {
312
- "description": "Enable Pathway 2 (Registrar inbound query) in build_graph. Default true.",
313
- "type": "boolean"
314
- },
315
- "enable_potential": {
316
- "description": "Enable Pathway 3 (potential relationship detection) in build_graph. Default false.",
317
- "type": "boolean"
318
- },
319
- "async_mode": {
320
- "description": "When true, build_graph / evaluate_project runs in the background and returns { task_id } immediately. Poll query_task_status(task_id) to check progress and retrieve the result. Default false (synchronous). Use async_mode=true for large projects with enable_potential=true where build may take >10s.",
321
- "type": "boolean"
322
- },
323
- "evaluation_type": {
324
- "description": "Evaluation type for evaluate_project. risk/trust/completeness are rule-based (computed locally). worth_buying/value require LLM assistance (returns a prompt for the caller to process).",
325
- "type": "string",
326
- "enum": [
327
- "risk",
328
- "trust",
329
- "completeness",
330
- "value",
331
- "worth_buying"
332
- ]
333
- },
334
- "refresh_before_eval": {
335
- "description": "When true (DEFAULT), evaluate_project refreshes object cache from chain before evaluating. Set to false ONLY for read-only checks where staleness is acceptable (e.g., quick comparisons). BUG-P0-2 fix: previously defaulted to false, causing stale Machine node_count and other dynamic-field-derived fields to produce false findings (e.g., 'Machine has no nodes'). Now defaults to true — set refresh_before_eval=false explicitly to skip refresh.",
336
- "type": "boolean"
337
- },
338
- "eval_score": {
339
- "description": "Overall evaluation score (0-100) for save_evaluation.",
340
- "type": "number",
341
- "minimum": 0,
342
- "maximum": 100
343
- },
344
- "eval_summary": {
345
- "description": "Evaluation summary for save_evaluation.",
346
- "type": "string",
347
- "maxLength": 1000
348
- },
349
- "eval_details": {
350
- "description": "Structured evaluation details for save_evaluation (criterion_scores, findings, etc.).",
351
- "type": "object",
352
- "propertyNames": {
353
- "type": "string"
354
- },
355
- "additionalProperties": {}
356
- },
357
- "compare_project_ids": {
358
- "description": "Array of project IDs to compare (for compare_projects). Minimum 2.",
359
- "minItems": 2,
360
- "type": "array",
361
- "items": {
362
- "type": "string"
363
- }
364
- },
365
- "diff_address": {
366
- "description": "Object address for get_object_diff.",
367
- "type": "string"
368
- },
369
- "diff_from_time": {
370
- "description": "Start timestamp (ms) for get_object_diff.",
371
- "type": "integer",
372
- "minimum": -9007199254740991,
373
- "maximum": 9007199254740991
374
- },
375
- "diff_to_time": {
376
- "description": "End timestamp (ms) for get_object_diff.",
377
- "type": "integer",
378
- "minimum": -9007199254740991,
379
- "maximum": 9007199254740991
380
- },
381
- "network": {
382
- "description": "Target network for generate_deployment_doc. Required when action='generate_deployment_doc'.",
383
- "type": "string",
384
- "enum": [
385
- "testnet",
386
- "mainnet"
387
- ]
388
- },
389
- "save": {
390
- "description": "When true (default), persist the generated MD to SQLite project_documents table for generate_deployment_doc.",
391
- "type": "boolean"
392
- },
393
- "detail_level": {
394
- "description": "P2-03: Deployment document detail level (only for generate_deployment_doc). 'summary' (default): object name + type + key bindings (machine, permission, buy_guard, order_allocators). 'detailed': adds sale list, arbitration list, reward list. 'full': complete fields including stock, price, wip_hash, all config. Use 'summary' for quick review; request 'detailed' or 'full' only when deeper inspection is needed.",
395
- "type": "string",
396
- "enum": [
397
- "summary",
398
- "detailed",
399
- "full"
400
- ]
401
- },
402
- "object_kind": {
403
- "description": "Object kind for plan_object_edit. 'machine' = Machine workflow directed graph (cycles allowed), 'guard' = Guard computation tree. Required when action='plan_object_edit'. Inferred from action for patch_machine_nodes (always 'machine') and patch_guard_tree (always 'guard').",
404
- "type": "string",
405
- "enum": [
406
- "machine",
407
- "guard"
408
- ]
409
- },
410
- "edit_format": {
411
- "description": "Format of the edited content for plan_object_edit. 'tree_outline' (default): the indented Markdown outline produced by get_machine_graph / get_guard_graph (human-editable). 'json': raw JSON (machine-readable, for programmatic edits). Both formats are bidirectional with the parse functions in knowledge/machine-render.ts / guard-render.ts.",
412
- "type": "string",
413
- "enum": [
414
- "tree_outline",
415
- "json"
416
- ]
417
- },
418
- "edited_content": {
419
- "description": "Edited content for plan_object_edit. Must be in the format specified by edit_format. For 'tree_outline': the full tree_outline string from get_machine_graph/get_guard_graph with user edits. For 'json': a JSON string matching the Machine/Guard schema. The content is parsed + validated + diffed against the current on-chain state.",
420
- "type": "string"
421
- },
422
- "plan_id": {
423
- "description": "Plan ID returned by plan_object_edit. Required for apply_object_edit. The plan is short-lived (10-minute TTL) and stored in-memory.",
424
- "type": "string"
425
- },
426
- "expected_hash": {
427
- "description": "Expected hash returned by plan_object_edit. Required for apply_object_edit. Used for optimistic concurrency control: if the on-chain state changed between plan and apply, the hash will mismatch and apply will refuse to proceed (stale edit protection).",
428
- "type": "string"
429
- },
430
- "patch_operations": {
431
- "description": "Patch operations for patch_machine_nodes / patch_guard_tree. Each string is a single patch operation.\nMachine operations (13 total):\n 'add node <name>' | 'remove node <name>' | 'set description <node_name> <text...>'\n 'add edge <from> <to>' | 'remove edge <from> <to>' | 'set threshold <edge_from> <edge_to> <value>'\n 'add forward <edge_from> <edge_to> <forward_name>' | 'remove forward <edge_from> <edge_to> <forward_name>'\n 'set guard <edge_from> <edge_to> <forward_name> <guard_addr_or_name|none>'\n 'set permission <edge_from> <edge_to> <forward_name> <perm_index>'\n 'set operator <edge_from> <edge_to> <forward_name> <named_operator|none>'\n 'set weight <edge_from> <edge_to> <forward_name> <weight>'\n 'set retained_submission <edge_from> <edge_to> <forward_name> <comma_separated_indices|none>'\nGuard operations (8 total — see patch_guard_tree):\n 'add table <identifier> <name|none> <value_type> <b_submission> [json_value]'\n 'remove table <identifier>' | 'set table_value <identifier> [json_value|none]'\n 'set table_name <identifier> <name|none>' | 'set table_submission <identifier> <true|false>'\n 'set root <json_node>' | 'set rely <comma_separated_guard_addresses|none>'\nOperations are applied in order. Both patches are validated (validateMachine/validateGuard) before execution.",
432
- "type": "array",
433
- "items": {
434
- "type": "string"
435
- }
436
- },
437
- "intent": {
438
- "description": "Business intent text for recommend_industry (e.g. 'I rent cameras to photographers with deposit and damage inspection'). Falls back to project_description / project_name when omitted.",
439
- "type": "string",
440
- "maxLength": 2000
441
- },
442
- "mode_source": {
443
- "description": "Source builtin mode name for derive_user_mode (e.g. 'freelance'). Call list_modes to see available modes.",
444
- "type": "string"
445
- },
446
- "mode_name": {
447
- "description": "Mode name for derive_user_mode (new mode name), evolve_user_mode / unregister_user_mode (existing custom mode), register_user_mode (new mode name). Must NOT conflict with builtin mode names.",
448
- "type": "string",
449
- "maxLength": 100
450
- },
451
- "mode_display_name": {
452
- "description": "Display name for derive_user_mode / register_user_mode. Defaults to mode_name.",
453
- "type": "string",
454
- "maxLength": 200
455
- },
456
- "mode_changes": {
457
- "description": "Mode field overrides for derive_user_mode / evolve_user_mode / register_user_mode. For register_user_mode, REQUIRED fields: machine_shape (non-empty array of {name, role}) and key_risk (string). Common overrides: machine_shape (array of {name:string, role:string}), config_overrides (per-object config), allocator, guards, build_notes, risk_appetite. R-M1-11 ENFORCED: machine_shape node names must NOT contain dispute/refund/arb terms — disputes flow through Service.arbitrations independently of the Machine.",
458
- "type": "object",
459
- "propertyNames": {
460
- "type": "string"
461
- },
462
- "additionalProperties": {}
463
- },
464
- "mode_change_description": {
465
- "description": "Change description for evolve_user_mode (recorded in evolution history).",
466
- "type": "string",
467
- "maxLength": 500
468
- },
469
- "mode_bump_version": {
470
- "description": "Whether evolve_user_mode bumps the patch version (default true: v1.0 → v1.1).",
471
- "type": "boolean"
472
- },
473
- "metric_id": {
474
- "description": "Unique metric ID for register_custom_metric (e.g. 'seasonality_risk').",
475
- "type": "string",
476
- "maxLength": 100
477
- },
478
- "metric_display_name": {
479
- "description": "Display name for register_custom_metric.",
480
- "type": "string",
481
- "maxLength": 200
482
- },
483
- "metric_description": {
484
- "description": "Description for register_custom_metric.",
485
- "type": "string",
486
- "maxLength": 1000
487
- },
488
- "metric_type": {
489
- "description": "Metric type for register_custom_metric: 'risk' (negative) or 'benefit' (positive).",
490
- "type": "string",
491
- "enum": [
492
- "risk",
493
- "benefit"
494
- ]
495
- },
496
- "metric_scale": {
497
- "description": "Metric scale for register_custom_metric: 'level' (high/medium/low), 'numeric', or 'percentage'.",
498
- "type": "string",
499
- "enum": [
500
- "level",
501
- "numeric",
502
- "percentage"
503
- ]
504
- },
505
- "metric_weight": {
506
- "description": "Metric weight for register_custom_metric (default 1.0).",
507
- "type": "number",
508
- "minimum": 0,
509
- "maximum": 10
510
- },
511
- "constraint_id": {
512
- "description": "Unique constraint ID for register_custom_constraint.",
513
- "type": "string",
514
- "maxLength": 100
515
- },
516
- "constraint_display_name": {
517
- "description": "Display name for register_custom_constraint.",
518
- "type": "string",
519
- "maxLength": 200
520
- },
521
- "constraint_description": {
522
- "description": "Description for register_custom_constraint.",
523
- "type": "string",
524
- "maxLength": 1000
525
- },
526
- "constraint_rule": {
527
- "description": "Constraint rule for register_custom_constraint. 4 types: capability_required/capability_forbidden (capability_id), numeric_limit (field + max/min), condition_required (natural-language condition, AI-evaluated).",
528
- "oneOf": [
529
- {
530
- "type": "object",
531
- "properties": {
532
- "type": {
533
- "type": "string",
534
- "const": "capability_required"
535
- },
536
- "capability_id": {
537
- "type": "string"
538
- }
539
- },
540
- "required": [
541
- "type",
542
- "capability_id"
543
- ],
544
- "additionalProperties": false
545
- },
546
- {
547
- "type": "object",
548
- "properties": {
549
- "type": {
550
- "type": "string",
551
- "const": "capability_forbidden"
552
- },
553
- "capability_id": {
554
- "type": "string"
555
- }
556
- },
557
- "required": [
558
- "type",
559
- "capability_id"
560
- ],
561
- "additionalProperties": false
562
- },
563
- {
564
- "type": "object",
565
- "properties": {
566
- "type": {
567
- "type": "string",
568
- "const": "numeric_limit"
569
- },
570
- "field": {
571
- "type": "string"
572
- },
573
- "max": {
574
- "type": "number"
575
- },
576
- "min": {
577
- "type": "number"
578
- }
579
- },
580
- "required": [
581
- "type",
582
- "field"
583
- ],
584
- "additionalProperties": false
585
- },
586
- {
587
- "type": "object",
588
- "properties": {
589
- "type": {
590
- "type": "string",
591
- "const": "condition_required"
592
- },
593
- "condition": {
594
- "type": "string"
595
- },
596
- "ai_evaluated": {
597
- "type": "boolean",
598
- "const": true
599
- }
600
- },
601
- "required": [
602
- "type",
603
- "condition",
604
- "ai_evaluated"
605
- ],
606
- "additionalProperties": false
607
- }
608
- ]
609
- },
610
- "constraint_severity": {
611
- "description": "Constraint severity for register_custom_constraint: 'hard' blocks applyTemplate on violation; 'soft' only warns (default 'soft').",
612
- "type": "string",
613
- "enum": [
614
- "hard",
615
- "soft"
616
- ]
617
- },
618
- "constraint_on_violation": {
619
- "description": "Violation action for register_custom_constraint (default 'warn').",
620
- "type": "string",
621
- "enum": [
622
- "block",
623
- "warn",
624
- "log"
625
- ]
626
- },
627
- "metric_type_filter": {
628
- "description": "Filter list_metrics_constraints by metric type.",
629
- "type": "string",
630
- "enum": [
631
- "risk",
632
- "benefit"
633
- ]
634
- },
635
- "scope_filter": {
636
- "description": "Filter list_metrics_constraints by scope (builtin or custom).",
637
- "type": "string",
638
- "enum": [
639
- "builtin",
640
- "custom"
641
- ]
642
- },
643
- "target_objects": {
644
- "description": "Optional explicit target objects for analyze_intent (entry_ids or object_type names). When provided, puzzle snapshots are restricted to these objects.",
645
- "type": "array",
646
- "items": {
647
- "type": "string"
648
- }
649
- },
650
- "puzzles": {
651
- "description": "Per-object puzzle snapshots for aggregate_risks, keyed by object_type. Pass the 'puzzles' field from a prior analyze_intent result UNCHANGED. When omitted but 'intent' is present, the handler runs analyze_intent first (C1→C2 in one call).",
652
- "type": "object",
653
- "propertyNames": {
654
- "type": "string"
655
- },
656
- "additionalProperties": {
657
- "type": "object",
658
- "properties": {
659
- "puzzle": {
660
- "description": "Puzzle snapshot (opaque — pass through from analyze_intent output unchanged)."
661
- },
662
- "completeness": {
663
- "description": "Completeness snapshot (opaque — pass through unchanged)."
664
- },
665
- "missing_dimensions": {
666
- "type": "array",
667
- "items": {
668
- "type": "string"
669
- },
670
- "description": "Dimensions still missing for this object."
671
- }
672
- },
673
- "required": [
674
- "puzzle",
675
- "completeness",
676
- "missing_dimensions"
677
- ],
678
- "additionalProperties": false
679
- }
680
- },
681
- "severity_threshold": {
682
- "description": "Severity threshold for aggregate_risks (default 'HIGH'). Risks at or above this level block deployment (status RISK_BLOCKED).",
683
- "type": "string",
684
- "enum": [
685
- "CRITICAL",
686
- "HIGH",
687
- "MEDIUM",
688
- "LOW",
689
- "INFO"
690
- ]
691
- },
692
- "user_confirmed_high_risks": {
693
- "description": "IDs of HIGH risks the user has already confirmed in a prior round (aggregate_risks). Confirmed HIGH risks no longer trigger RISK_PENDING_CONFIRM.",
694
- "type": "array",
695
- "items": {
696
- "type": "string"
697
- }
698
- },
699
- "planned_objects": {
700
- "description": "Planned objects for aggregate_risks OBJECT_REUSE check (safety-rules). Flags NEW objects whose type carries an always/strongly-recommended reuse rule.",
701
- "type": "array",
702
- "items": {
703
- "type": "object",
704
- "properties": {
705
- "object_type": {
706
- "type": "string",
707
- "description": "Wowok object type (e.g. 'service', 'guard', 'machine')."
708
- },
709
- "is_new": {
710
- "type": "boolean",
711
- "description": "true when creating a NEW object; false when reusing an existing one."
712
- },
713
- "name": {
714
- "description": "Planned object name (for readable messages).",
715
- "type": "string"
716
- }
717
- },
718
- "required": [
719
- "object_type",
720
- "is_new"
721
- ],
722
- "additionalProperties": false
723
- }
724
- },
725
- "planned_operations": {
726
- "description": "Planned create/publish operations for aggregate_risks IMMUTABILITY check (safety-rules). Warns which fields become permanently locked after each operation.",
727
- "type": "array",
728
- "items": {
729
- "type": "object",
730
- "properties": {
731
- "object_type": {
732
- "type": "string",
733
- "description": "Wowok object type (e.g. 'service', 'arbitration')."
734
- },
735
- "trigger": {
736
- "type": "string",
737
- "enum": [
738
- "create",
739
- "publish"
740
- ],
741
- "description": "Lifecycle trigger that locks fields."
742
- },
743
- "name": {
744
- "description": "Object name (for readable messages).",
745
- "type": "string"
746
- }
747
- },
748
- "required": [
749
- "object_type",
750
- "trigger"
751
- ],
752
- "additionalProperties": false
753
- }
754
- },
755
- "substeps": {
756
- "description": "Substep execution records for trace_substeps (63-spec §2.1). Required when action='trace_substeps'. Construct from your deployment execution trace.",
757
- "type": "array",
758
- "items": {
759
- "type": "object",
760
- "properties": {
761
- "step_id": {
762
- "type": "string",
763
- "description": "Substep id, format 'T<step>.<substep>' e.g. 'T1.1'."
764
- },
765
- "parent_step": {
766
- "type": "string",
767
- "description": "Parent step id, format 'T<step>' e.g. 'T1'."
768
- },
769
- "object_type": {
770
- "type": "string",
771
- "enum": [
772
- "service",
773
- "machine",
774
- "guard",
775
- "permission",
776
- "reward",
777
- "arb",
778
- "progress",
779
- "treasury",
780
- "demand",
781
- "repository",
782
- "contact",
783
- "order",
784
- "allocation",
785
- "personal",
786
- "payment",
787
- "proof"
788
- ],
789
- "description": "Wowok object type this substep operates on."
790
- },
791
- "entry_id": {
792
- "type": "string",
793
- "description": "Puzzle entry_id this substep corresponds to."
794
- },
795
- "operation_type": {
796
- "type": "string",
797
- "description": "operation_type for onchain_operations."
798
- },
799
- "network": {
800
- "type": "string",
801
- "enum": [
802
- "testnet",
803
- "mainnet"
804
- ],
805
- "description": "Target network."
806
- },
807
- "input": {
808
- "type": "object",
809
- "properties": {
810
- "data": {
811
- "type": "object",
812
- "propertyNames": {
813
- "type": "string"
814
- },
815
- "additionalProperties": {},
816
- "description": "Input data payload."
817
- },
818
- "input_refs": {
819
- "type": "array",
820
- "items": {
821
- "type": "string"
822
- },
823
- "description": "Upstream substep_ids this substep consumes."
824
- }
825
- },
826
- "required": [
827
- "data",
828
- "input_refs"
829
- ],
830
- "additionalProperties": false
831
- },
832
- "output": {
833
- "description": "Output data (filled after execution).",
834
- "type": "object",
835
- "properties": {
836
- "object_id": {
837
- "type": "string"
838
- },
839
- "tx_digest": {
840
- "type": "string"
841
- }
842
- },
843
- "additionalProperties": {}
844
- },
845
- "timestamp": {
846
- "type": "number",
847
- "description": "Execution timestamp (ms)."
848
- },
849
- "status": {
850
- "type": "string",
851
- "enum": [
852
- "PENDING",
853
- "SUCCESS",
854
- "FAILED",
855
- "SKIPPED"
856
- ],
857
- "description": "Execution status."
858
- },
859
- "failure_reason": {
860
- "description": "Failure reason (when status='FAILED').",
861
- "type": "string"
862
- },
863
- "dependencies": {
864
- "type": "object",
865
- "properties": {
866
- "input_refs": {
867
- "type": "array",
868
- "items": {
869
- "type": "string"
870
- }
871
- },
872
- "output_refs": {
873
- "type": "array",
874
- "items": {
875
- "type": "object",
876
- "properties": {
877
- "substep_id": {
878
- "type": "string",
879
- "description": "Downstream substep that consumes this output."
880
- },
881
- "field_path": {
882
- "type": "string",
883
- "description": "Field path produced by this substep (e.g. 'permission_address')."
884
- }
885
- },
886
- "required": [
887
- "substep_id",
888
- "field_path"
889
- ],
890
- "additionalProperties": false
891
- }
892
- }
893
- },
894
- "required": [
895
- "input_refs",
896
- "output_refs"
897
- ],
898
- "additionalProperties": false,
899
- "description": "Dependencies (input_refs + output_refs)."
900
- },
901
- "retry_info": {
902
- "description": "Retry info (when this substep is a retry of an earlier one).",
903
- "type": "object",
904
- "properties": {
905
- "original_step_id": {
906
- "type": "string"
907
- },
908
- "retry_count": {
909
- "type": "number"
910
- },
911
- "retry_reason": {
912
- "type": "string"
913
- }
914
- },
915
- "required": [
916
- "original_step_id",
917
- "retry_count",
918
- "retry_reason"
919
- ],
920
- "additionalProperties": false
921
- }
922
- },
923
- "required": [
924
- "step_id",
925
- "parent_step",
926
- "object_type",
927
- "entry_id",
928
- "operation_type",
929
- "network",
930
- "input",
931
- "timestamp",
932
- "status",
933
- "dependencies"
934
- ],
935
- "additionalProperties": false
936
- }
937
- },
938
- "substep_edges": {
939
- "description": "Explicit DAG edges for trace_substeps. When omitted, edges are derived from each substep's input_refs.",
940
- "type": "array",
941
- "items": {
942
- "type": "object",
943
- "properties": {
944
- "source": {
945
- "type": "string",
946
- "description": "Source substep id."
947
- },
948
- "target": {
949
- "type": "string",
950
- "description": "Target substep id (depends on source)."
951
- },
952
- "field_path": {
953
- "type": "string",
954
- "description": "Field path flowing along this edge."
955
- }
956
- },
957
- "required": [
958
- "source",
959
- "target",
960
- "field_path"
961
- ],
962
- "additionalProperties": false
963
- }
964
- },
965
- "guide_state": {
966
- "description": "Wizard state from a prior merchant_guide result. Pass back UNCHANGED on every subsequent call (same pattern as C1→C2 puzzles). The handler re-runs the pipeline deterministically and advances to the furthest reachable step.",
967
- "type": "object",
968
- "properties": {
969
- "intent_text": {
970
- "type": "string",
971
- "description": "Step 1: raw merchant business description."
972
- },
973
- "confirmed_industry": {
974
- "description": "Step 2: merchant-confirmed industry id.",
975
- "type": "string"
976
- },
977
- "currency": {
978
- "description": "Step 5: payment currency (default WOW).",
979
- "type": "string"
980
- },
981
- "deliverables": {
982
- "description": "Step 4: merchant-defined deliverables (opaque passthrough).",
983
- "type": "array",
984
- "items": {}
985
- },
986
- "payment_override": {
987
- "description": "Step 5: payment structure overrides (opaque passthrough).",
988
- "type": "object",
989
- "propertyNames": {
990
- "type": "string"
991
- },
992
- "additionalProperties": {}
993
- },
994
- "trust_override": {
995
- "description": "Step 6: trust mechanism overrides (opaque passthrough).",
996
- "type": "object",
997
- "propertyNames": {
998
- "type": "string"
999
- },
1000
- "additionalProperties": {}
1001
- },
1002
- "adopted_module_ids": {
1003
- "description": "Step 6: merchant-confirmed business module ids.",
1004
- "type": "array",
1005
- "items": {
1006
- "type": "string"
1007
- }
1008
- }
1009
- },
1010
- "required": [
1011
- "intent_text"
1012
- ],
1013
- "additionalProperties": false
1014
- },
1015
- "guide_confirm": {
1016
- "description": "Merchant decisions for the current wizard step. Merged over guide_state. Typical flow: call 1 with intent only → receive step-2 industry options → call 2 with guide_state + guide_confirm={industry} → receive full blueprint plan (steps 7-10).",
1017
- "type": "object",
1018
- "properties": {
1019
- "industry": {
1020
- "description": "Step 2 confirmation: industry id (e.g. 'freelance').",
1021
- "type": "string"
1022
- },
1023
- "currency": {
1024
- "description": "Step 5 confirmation: payment currency.",
1025
- "type": "string"
1026
- },
1027
- "deliverables": {
1028
- "description": "Step 4 confirmation: deliverable definitions.",
1029
- "type": "array",
1030
- "items": {}
1031
- },
1032
- "payment": {
1033
- "description": "Step 5 confirmation: { model, triggers, allocation } overrides.",
1034
- "type": "object",
1035
- "propertyNames": {
1036
- "type": "string"
1037
- },
1038
- "additionalProperties": {}
1039
- },
1040
- "trust": {
1041
- "description": "Step 6 confirmation: { refundPolicy, arbitration, escrow } overrides.",
1042
- "type": "object",
1043
- "propertyNames": {
1044
- "type": "string"
1045
- },
1046
- "additionalProperties": {}
1047
- },
1048
- "adopted_module_ids": {
1049
- "description": "Step 6 confirmation: business module ids to adopt (overrides recommendation).",
1050
- "type": "array",
1051
- "items": {
1052
- "type": "string"
1053
- }
1054
- }
1055
- },
1056
- "additionalProperties": false
1057
- },
1058
- "radar_account": {
1059
- "description": "Account to analyze — address (0x...) or LocalMark name (resolved to an address). Required when action='participation_radar'. The perspective (customer/operator/observer) is DERIVED from on-chain data (Order.builder + PermissionPerm grants) — never asserted by this field.",
1060
- "type": "string"
1061
- },
1062
- "radar_targets": {
1063
- "description": "In-flight orders to analyze (1-20). Required when action='participation_radar'. Each target is analyzed independently; results are aggregated into one account dashboard.",
1064
- "minItems": 1,
1065
- "maxItems": 20,
1066
- "type": "array",
1067
- "items": {
1068
- "type": "object",
1069
- "properties": {
1070
- "progress": {
1071
- "type": "string",
1072
- "description": "Progress object address (0x...) or LocalMark name. The Progress carries the current node + bound Machine."
1073
- },
1074
- "order": {
1075
- "description": "Order object address or LocalMark name (optional but recommended — enables order-holder detection, service-level compensation/reward claims, and dispute context).",
1076
- "type": "string"
1077
- }
1078
- },
1079
- "required": [
1080
- "progress"
1081
- ],
1082
- "additionalProperties": false
1083
- }
1084
- },
1085
- "radar_include_alerts": {
1086
- "description": "Attach order-monitor alerts (progress stall / compensation fund / review & arbitration windows) to each per-order result. Default true.",
1087
- "type": "boolean"
1088
- },
1089
- "radar_monitor_thresholds": {
1090
- "description": "Optional per-call overrides for order-monitor alert thresholds (only used when radar_include_alerts is on). All fields optional; omitted fields keep defaults. Units: hours/days as marked per field.",
1091
- "type": "object",
1092
- "properties": {
1093
- "progress_stall_hours": {
1094
- "description": "Progress stall alert threshold in HOURS. Default 0 = auto (expected_node_duration × 2).",
1095
- "type": "number",
1096
- "exclusiveMinimum": 0
1097
- },
1098
- "compensation_drop_ratio": {
1099
- "description": "Compensation fund drop alert ratio (0-1). Default 0.3 = alert on ≥30% drop.",
1100
- "type": "number",
1101
- "minimum": 0,
1102
- "maximum": 1
1103
- },
1104
- "compensation_coverage_min": {
1105
- "description": "Minimum compensation coverage ratio vs order amount (0-1). Default 1.0 = must fully cover.",
1106
- "type": "number",
1107
- "minimum": 0,
1108
- "maximum": 1
1109
- },
1110
- "messenger_timeout_hours": {
1111
- "description": "Messenger no-reply timeout in HOURS. Default 24.",
1112
- "type": "number",
1113
- "exclusiveMinimum": 0
1114
- },
1115
- "review_window_closing_days": {
1116
- "description": "Review window near-closing alert threshold in DAYS. Default 3.",
1117
- "type": "number",
1118
- "exclusiveMinimum": 0
1119
- },
1120
- "arb_window_closing_days": {
1121
- "description": "Arbitration window near-closing alert threshold in DAYS. Default 3.",
1122
- "type": "number",
1123
- "exclusiveMinimum": 0
1124
- }
1125
- },
1126
- "additionalProperties": false
1127
- }
1128
- },
1129
- "required": [
1130
- "action"
1131
- ],
1132
- "additionalProperties": false
1133
- }