@wowok/agent-mcp 3.4.3 → 3.4.4

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 (853) hide show
  1. package/dist/.build-stamp.json +3 -3
  2. package/dist/build-stamp.js +1 -0
  3. package/dist/chain-semantics/composition-truth.js +1 -1
  4. package/dist/chain-semantics/eval-order.js +1 -1
  5. package/dist/chain-semantics/freeze-map.js +1 -1
  6. package/dist/chain-semantics/fund-flow.js +1 -1
  7. package/dist/chain-semantics/object-graph.js +1 -1
  8. package/dist/composition/audit.js +1 -1
  9. package/dist/composition/compile.js +1 -1
  10. package/dist/composition/emit-phases.js +1 -1
  11. package/dist/composition/generate.js +1 -1
  12. package/dist/composition/guard-fill.js +1 -1
  13. package/dist/composition/input-normalize.js +1 -1
  14. package/dist/composition/materialize.js +1 -1
  15. package/dist/composition/mode-gates.js +1 -1
  16. package/dist/composition/plan.js +1 -1
  17. package/dist/composition/product-card.js +1 -1
  18. package/dist/composition/shape-expand.js +1 -0
  19. package/dist/config/judgment.js +1 -1
  20. package/dist/config/template-params.js +1 -1
  21. package/dist/data/sync/cdc.js +1 -1
  22. package/dist/data/sync/graphql-source.js +1 -1
  23. package/dist/evaluation/engine.js +1 -1
  24. package/dist/experience/realtime-feedback.js +1 -1
  25. package/dist/graph/onchain/expand.js +1 -1
  26. package/dist/graph/onchain/exposure.js +1 -1
  27. package/dist/graph/onchain/sdk-batch.js +1 -1
  28. package/dist/harness/entry-ignite-selfheal.js +1 -0
  29. package/dist/harness/forward-leg-preflight.js +1 -0
  30. package/dist/harness/recover.js +1 -1
  31. package/dist/keeper/detectors.js +1 -1
  32. package/dist/knowledge/allocator-rail-verifier.js +1 -1
  33. package/dist/knowledge/arb-operation-face.js +1 -0
  34. package/dist/knowledge/arbitration-rail-verifier.js +1 -1
  35. package/dist/knowledge/arbitration-templates.js +1 -1
  36. package/dist/knowledge/audit-rules.d.ts +15 -0
  37. package/dist/knowledge/audit-rules.js +1 -1
  38. package/dist/knowledge/baselines/rules/alloc_audit.json.good +310 -0
  39. package/dist/knowledge/baselines/rules/allocation.json.good +568 -0
  40. package/dist/knowledge/baselines/rules/arb.json.good +174 -0
  41. package/dist/knowledge/baselines/rules/arbitration.json.good +393 -0
  42. package/dist/knowledge/baselines/rules/bridge.json.good +197 -0
  43. package/dist/knowledge/baselines/rules/contact.json.good +152 -0
  44. package/dist/knowledge/baselines/rules/demand.json.good +158 -0
  45. package/dist/knowledge/baselines/rules/graph.json.good +534 -0
  46. package/dist/knowledge/baselines/rules/guard.json +18 -5
  47. package/dist/knowledge/baselines/rules/guard.json.good +1192 -0
  48. package/dist/knowledge/baselines/rules/machine.json.good +734 -0
  49. package/dist/knowledge/baselines/rules/oracle.json +1 -1
  50. package/dist/knowledge/baselines/rules/oracle.json.good +120 -0
  51. package/dist/knowledge/baselines/rules/order.json.good +549 -0
  52. package/dist/knowledge/baselines/rules/payment.json.good +205 -0
  53. package/dist/knowledge/baselines/rules/permission.json.good +330 -0
  54. package/dist/knowledge/baselines/rules/personal.json.good +139 -0
  55. package/dist/knowledge/baselines/rules/plan.json +343 -1
  56. package/dist/knowledge/baselines/rules/plan.json.good +1187 -0
  57. package/dist/knowledge/baselines/rules/progress.json.good +364 -0
  58. package/dist/knowledge/baselines/rules/proof.json.good +158 -0
  59. package/dist/knowledge/baselines/rules/registrar.json.good +159 -0
  60. package/dist/knowledge/baselines/rules/repository.json.good +244 -0
  61. package/dist/knowledge/baselines/rules/resource.json.good +117 -0
  62. package/dist/knowledge/baselines/rules/reward.json +10 -10
  63. package/dist/knowledge/baselines/rules/reward.json.good +586 -0
  64. package/dist/knowledge/baselines/rules/service.json.good +595 -0
  65. package/dist/knowledge/baselines/rules/treasury.json.good +440 -0
  66. package/dist/knowledge/baselines/rules/util.json.good +101 -0
  67. package/dist/knowledge/builtin-templates.d.ts +13 -1
  68. package/dist/knowledge/builtin-templates.js +1 -1
  69. package/dist/knowledge/chain-query-registry.js +1 -1
  70. package/dist/knowledge/discount-threshold.js +1 -1
  71. package/dist/knowledge/fee-param-bindings.js +1 -1
  72. package/dist/knowledge/fund-layer.d.ts +2 -0
  73. package/dist/knowledge/fund-layer.js +1 -1
  74. package/dist/knowledge/getting-started.js +1 -1
  75. package/dist/knowledge/guard-binding-table.js +1 -1
  76. package/dist/knowledge/guard-binding-verifier.js +1 -1
  77. package/dist/knowledge/guard-create-preflight.js +1 -0
  78. package/dist/knowledge/guard-field-cognition.js +1 -1
  79. package/dist/knowledge/guard-host-context.js +1 -1
  80. package/dist/knowledge/guard-leg-eval.js +1 -0
  81. package/dist/knowledge/guard-node-gates.js +1 -1
  82. package/dist/knowledge/guard-puzzle.js +1 -1
  83. package/dist/knowledge/guard-quality.js +1 -0
  84. package/dist/knowledge/guard-render.js +1 -1
  85. package/dist/knowledge/guard-risk.js +1 -1
  86. package/dist/knowledge/guard-semantic-walk.js +1 -0
  87. package/dist/knowledge/guard-templates.d.ts +1 -0
  88. package/dist/knowledge/guard-templates.js +1 -1
  89. package/dist/knowledge/guard-translation.js +1 -1
  90. package/dist/knowledge/index.js +1 -1
  91. package/dist/knowledge/industry-registry.js +1 -1
  92. package/dist/knowledge/jsonrpc-enum.js +1 -1
  93. package/dist/knowledge/param-schema.js +1 -1
  94. package/dist/knowledge/param-tiers.js +1 -1
  95. package/dist/knowledge/path-oracle/coverage.js +1 -1
  96. package/dist/knowledge/path-oracle/index.js +1 -1
  97. package/dist/knowledge/path-oracle/products/airbnb.js +1 -0
  98. package/dist/knowledge/path-oracle/products/algora.js +1 -0
  99. package/dist/knowledge/path-oracle/products/alibaba-1688.js +1 -0
  100. package/dist/knowledge/path-oracle/products/amazon.js +1 -0
  101. package/dist/knowledge/path-oracle/products/beatstars.js +1 -0
  102. package/dist/knowledge/path-oracle/products/booking-com.js +1 -0
  103. package/dist/knowledge/path-oracle/products/contra.js +1 -0
  104. package/dist/knowledge/path-oracle/products/costco.js +1 -0
  105. package/dist/knowledge/path-oracle/products/coursera.js +1 -0
  106. package/dist/knowledge/path-oracle/products/duoduo-maicai.js +1 -0
  107. package/dist/knowledge/path-oracle/products/etsy.js +1 -0
  108. package/dist/knowledge/path-oracle/products/food-delivery.js +1 -1
  109. package/dist/knowledge/path-oracle/products/gamefound.js +1 -0
  110. package/dist/knowledge/path-oracle/products/gofundme.js +1 -0
  111. package/dist/knowledge/path-oracle/products/hackerone.js +1 -0
  112. package/dist/knowledge/path-oracle/products/kickstarter.js +1 -0
  113. package/dist/knowledge/path-oracle/products/klook.js +1 -0
  114. package/dist/knowledge/path-oracle/products/ninety-nine-designs.js +1 -0
  115. package/dist/knowledge/path-oracle/products/onlyfans.js +1 -0
  116. package/dist/knowledge/path-oracle/products/patreon.js +1 -0
  117. package/dist/knowledge/path-oracle/products/pinduoduo-kuaituantuan.js +1 -0
  118. package/dist/knowledge/path-oracle/products/royalty-exchange.js +1 -0
  119. package/dist/knowledge/path-oracle/products/shansong.js +1 -0
  120. package/dist/knowledge/path-oracle/products/taobao-presale.js +1 -0
  121. package/dist/knowledge/path-oracle/products/upwork-catalog.js +1 -0
  122. package/dist/knowledge/path-oracle/products/upwork.js +1 -0
  123. package/dist/knowledge/path-oracle/products/yuanfudao.js +1 -0
  124. package/dist/knowledge/path-oracle/products/ziroom.js +1 -0
  125. package/dist/knowledge/pattern-resolutions.js +1 -1
  126. package/dist/knowledge/product-detail-source.js +1 -1
  127. package/dist/knowledge/product-doc-b5.js +1 -1
  128. package/dist/knowledge/product-doc-facets.js +1 -0
  129. package/dist/knowledge/projection.js +1 -1
  130. package/dist/knowledge/publish-gate.js +1 -1
  131. package/dist/knowledge/publish-surface-contract.js +1 -1
  132. package/dist/knowledge/recipient-constraint.d.ts +20 -0
  133. package/dist/knowledge/recipient-constraint.js +1 -1
  134. package/dist/knowledge/rule-declaration-types.d.ts +13 -0
  135. package/dist/knowledge/rule-declaration-types.js +1 -0
  136. package/dist/knowledge/rule-declarations.js +1 -0
  137. package/dist/knowledge/scenario-modes.d.ts +6 -0
  138. package/dist/knowledge/scenario-topology.js +1 -1
  139. package/dist/knowledge/template-loader.js +1 -1
  140. package/dist/knowledge/template-prose.js +1 -1
  141. package/dist/knowledge/template-registry.js +1 -1
  142. package/dist/knowledge/template-scanner.js +1 -1
  143. package/dist/knowledge/tools-reference.js +1 -1
  144. package/dist/monitor/MonitorLoop.js +1 -1
  145. package/dist/playbooks/service-build/business-puzzle.js +1 -1
  146. package/dist/playbooks/service-build/machine-panorama.js +1 -1
  147. package/dist/playbooks/service-build/merchant-guide.js +1 -1
  148. package/dist/playbooks/service-build/object-panorama.js +1 -1
  149. package/dist/playbooks/service-build/participation-radar.js +1 -1
  150. package/dist/playbooks/service-build/relationship-profile.js +1 -1
  151. package/dist/playbooks/service-build/service-panorama.js +1 -1
  152. package/dist/playbooks/service-build/service-quote.js +1 -1
  153. package/dist/review/index.js +1 -1
  154. package/dist/review/service.js +1 -1
  155. package/dist/safety/confirm-gate.js +1 -1
  156. package/dist/schema/benchmark-migration/index.d.ts +9 -0
  157. package/dist/schema/benchmark-migration/index.js +1 -1
  158. package/dist/schema/call/arbitration.d.ts +8 -0
  159. package/dist/schema/call/arbitration.js +1 -1
  160. package/dist/schema/call/base.d.ts +8 -0
  161. package/dist/schema/call/base.js +1 -1
  162. package/dist/schema/call/bridge.d.ts +2 -0
  163. package/dist/schema/call/error-codes.d.ts +1 -1
  164. package/dist/schema/call/error-codes.js +1 -1
  165. package/dist/schema/call/handler.d.ts +2 -1
  166. package/dist/schema/call/handler.js +1 -1
  167. package/dist/schema/call/order.d.ts +10 -0
  168. package/dist/schema/call/permission-handler.js +1 -1
  169. package/dist/schema/call/permission.js +1 -1
  170. package/dist/schema/call/progress.d.ts +15 -0
  171. package/dist/schema/call/progress.js +1 -1
  172. package/dist/schema/call/receipt.d.ts +1 -0
  173. package/dist/schema/call/receipt.js +1 -1
  174. package/dist/schema/call/repository.d.ts +12 -0
  175. package/dist/schema/call/repository.js +1 -1
  176. package/dist/schema/call/reward.js +1 -1
  177. package/dist/schema/call/semantic.d.ts +1 -0
  178. package/dist/schema/call/semantic.js +1 -1
  179. package/dist/schema/call/service.d.ts +5 -3
  180. package/dist/schema/call/service.js +1 -1
  181. package/dist/schema/common/index.js +1 -1
  182. package/dist/schema/envelope-unify.js +1 -1
  183. package/dist/schema/goal/index.d.ts +23 -0
  184. package/dist/schema/goal/planning.js +1 -1
  185. package/dist/schema/industry-pack/index.d.ts +2 -2
  186. package/dist/schema/local/index.d.ts +20 -0
  187. package/dist/schema/local/index.js +1 -1
  188. package/dist/schema/local/wip.d.ts +4 -0
  189. package/dist/schema/local/wip.js +1 -1
  190. package/dist/schema/messenger/index.d.ts +5 -0
  191. package/dist/schema/messenger/index.js +1 -1
  192. package/dist/schema/operations.d.ts +944 -1
  193. package/dist/schema/operations.js +1 -1
  194. package/dist/schema/query/bi.js +1 -1
  195. package/dist/schema/query/index.d.ts +5 -5
  196. package/dist/schema/query/index.js +1 -1
  197. package/dist/schema/schema-version.js +1 -1
  198. package/dist/schema/workspace/index.d.ts +2 -2
  199. package/dist/schema-query-impl/index.js +1 -1
  200. package/dist/schemas/account_operation.schema.json +1 -257
  201. package/dist/schemas/ask_user.schema.json +1 -78
  202. package/dist/schemas/benchmark_migration_operation.schema.json +1 -626
  203. package/dist/schemas/bridge_operation.schema.json +1 -1069
  204. package/dist/schemas/config_operation.schema.json +1 -82
  205. package/dist/schemas/employee_operation.schema.json +1 -319
  206. package/dist/schemas/evaluation_operation.schema.json +1 -3932
  207. package/dist/schemas/goal_operation.schema.json +1 -1650
  208. package/dist/schemas/guard2file.schema.json +1 -137
  209. package/dist/schemas/index.json +1 -285
  210. package/dist/schemas/industry_pack_operation.schema.json +1 -582
  211. package/dist/schemas/intent_radar.schema.json +1 -155
  212. package/dist/schemas/keeper_operation.schema.json +1 -364
  213. package/dist/schemas/local_cache_operation.schema.json +1 -116
  214. package/dist/schemas/local_history_operation.schema.json +1 -105
  215. package/dist/schemas/local_info_operation.schema.json +1 -140
  216. package/dist/schemas/local_mark_operation.schema.json +1 -124
  217. package/dist/schemas/machineNode2file.schema.json +1 -137
  218. package/dist/schemas/messenger_operation.schema.json +1 -2068
  219. package/dist/schemas/monitor_events.schema.json +1 -87
  220. package/dist/schemas/monitor_subscription.schema.json +1 -327
  221. package/dist/schemas/onchain_events.schema.json +1 -207
  222. package/dist/schemas/onchain_operations.schema.json +1 -28699
  223. package/dist/schemas/onchain_operations_allocation.schema.json +1 -1376
  224. package/dist/schemas/onchain_operations_arbitration.schema.json +1 -1355
  225. package/dist/schemas/onchain_operations_contact.schema.json +1 -988
  226. package/dist/schemas/onchain_operations_demand.schema.json +1 -1146
  227. package/dist/schemas/onchain_operations_gen_passport.schema.json +1 -663
  228. package/dist/schemas/onchain_operations_gen_proof.schema.json +1 -180
  229. package/dist/schemas/onchain_operations_guard.schema.json +1 -8518
  230. package/dist/schemas/onchain_operations_machine.schema.json +1 -1879
  231. package/dist/schemas/onchain_operations_order.schema.json +1 -1121
  232. package/dist/schemas/onchain_operations_payment.schema.json +1 -316
  233. package/dist/schemas/onchain_operations_permission.schema.json +1 -1036
  234. package/dist/schemas/onchain_operations_personal.schema.json +1 -1463
  235. package/dist/schemas/onchain_operations_progress.schema.json +1 -1041
  236. package/dist/schemas/onchain_operations_proof.schema.json +1 -750
  237. package/dist/schemas/onchain_operations_repository.schema.json +1 -2046
  238. package/dist/schemas/onchain_operations_reward.schema.json +1 -1286
  239. package/dist/schemas/onchain_operations_service.schema.json +1 -2602
  240. package/dist/schemas/onchain_operations_treasury.schema.json +1 -1527
  241. package/dist/schemas/onchain_table_data.schema.json +1 -1146
  242. package/dist/schemas/permission_operation.schema.json +1 -43
  243. package/dist/schemas/persona_operation.schema.json +1 -10424
  244. package/dist/schemas/query_toolkit.schema.json +1 -1867
  245. package/dist/schemas/schema_query.schema.json +1 -116
  246. package/dist/schemas/service_clone_operation.schema.json +1 -49
  247. package/dist/schemas/settle_sweep.schema.json +1 -0
  248. package/dist/schemas/strategy_review_operation.schema.json +1 -66
  249. package/dist/schemas/verify_guard_dry_run.schema.json +1 -0
  250. package/dist/schemas/watch_operation.schema.json +1 -145
  251. package/dist/schemas/wip_file.schema.json +1 -299
  252. package/dist/schemas/workflow_operation.schema.json +1 -722
  253. package/dist/schemas/workspace_operation.schema.json +1 -104
  254. package/dist/schemas/wowok_buildin_info.schema.json +1 -758
  255. package/dist/tools/handlers/benchmark-migration.js +1 -1
  256. package/dist/tools/handlers/config.js +1 -1
  257. package/dist/tools/handlers/entry-edge-recipe.js +1 -1
  258. package/dist/tools/handlers/file-export.js +1 -1
  259. package/dist/tools/handlers/local.js +1 -1
  260. package/dist/tools/handlers/messenger.js +1 -1
  261. package/dist/tools/handlers/onchain.js +1 -1
  262. package/dist/tools/handlers/pending-settlement-recipe.js +1 -0
  263. package/dist/tools/handlers/plan-recovery.js +1 -0
  264. package/dist/tools/handlers/query.js +1 -1
  265. package/dist/tools/handlers/repository-row-id.js +1 -0
  266. package/dist/tools/handlers/review-chain.js +1 -1
  267. package/dist/tools/handlers/settle-sweep.js +1 -0
  268. package/dist/tools/handlers/stale-build-check.js +1 -1
  269. package/dist/tools/handlers/submission-assembly.js +1 -1
  270. package/dist/tools/handlers/verify-guard-dry-run.js +1 -0
  271. package/dist/tools/handlers/wip-upload.js +1 -1
  272. package/dist/tools/index.d.ts +3 -1
  273. package/dist/tools/index.js +1 -1
  274. package/dist/tools/move-fn-index.gen.js +1 -1
  275. package/dist/tools/publish-gate-state.js +1 -1
  276. package/dist/tools/registry/business.js +1 -1
  277. package/dist/tools/registry/onchain.js +1 -1
  278. package/dist/tools/shared.js +1 -1
  279. package/dist/tools/types.d.ts +1 -1
  280. package/dist/tools/wrap.js +1 -1
  281. package/package.json +11 -4
  282. package/dist/chain-semantics/composition-truth.d.ts +0 -102
  283. package/dist/chain-semantics/eval-order.d.ts +0 -17
  284. package/dist/chain-semantics/field-capability.d.ts +0 -11
  285. package/dist/chain-semantics/freeze-map.d.ts +0 -11
  286. package/dist/chain-semantics/fund-flow.d.ts +0 -10
  287. package/dist/chain-semantics/guard-verbs.d.ts +0 -22
  288. package/dist/chain-semantics/index.d.ts +0 -12
  289. package/dist/chain-semantics/object-graph.d.ts +0 -18
  290. package/dist/communication/evidence.d.ts +0 -6
  291. package/dist/communication/message-cursors.d.ts +0 -35
  292. package/dist/communication/proof-reuse.d.ts +0 -9
  293. package/dist/communication/wts-attestation.d.ts +0 -39
  294. package/dist/composition/audit.d.ts +0 -15
  295. package/dist/composition/blueprint-view.d.ts +0 -63
  296. package/dist/composition/compile.d.ts +0 -83
  297. package/dist/composition/emit-phases.d.ts +0 -234
  298. package/dist/composition/generate.d.ts +0 -40
  299. package/dist/composition/guard-fill.d.ts +0 -52
  300. package/dist/composition/inflight.d.ts +0 -86
  301. package/dist/composition/input-normalize.d.ts +0 -15
  302. package/dist/composition/materialize.d.ts +0 -78
  303. package/dist/composition/mode-gates.d.ts +0 -35
  304. package/dist/composition/param-disclosure.d.ts +0 -61
  305. package/dist/composition/plan-retry-ledger.d.ts +0 -37
  306. package/dist/composition/plan.d.ts +0 -121
  307. package/dist/composition/product-card.d.ts +0 -94
  308. package/dist/composition/reflux.d.ts +0 -28
  309. package/dist/composition/supply-chain-emit.d.ts +0 -46
  310. package/dist/config/config-audit.spec.d.ts +0 -1
  311. package/dist/config/config-audit.spec.js +0 -1
  312. package/dist/config/config-warnings.d.ts +0 -2
  313. package/dist/config/index.d.ts +0 -4
  314. package/dist/config/judgment.spec.d.ts +0 -1
  315. package/dist/config/judgment.spec.js +0 -1
  316. package/dist/config/match-policy-file.d.ts +0 -34
  317. package/dist/config/match-policy-file.spec.d.ts +0 -1
  318. package/dist/config/match-policy-file.spec.js +0 -1
  319. package/dist/config/rule-engine.spec.d.ts +0 -1
  320. package/dist/config/rule-engine.spec.js +0 -1
  321. package/dist/config/runtime.d.ts +0 -29
  322. package/dist/config/store-policy.d.ts +0 -14
  323. package/dist/config/store-policy.spec.d.ts +0 -1
  324. package/dist/config/store-policy.spec.js +0 -1
  325. package/dist/config/template-params.d.ts +0 -42
  326. package/dist/config/template-params.spec.d.ts +0 -1
  327. package/dist/config/template-params.spec.js +0 -1
  328. package/dist/customer/account-events.d.ts +0 -32
  329. package/dist/data/api/api.spec.d.ts +0 -1
  330. package/dist/data/api/api.spec.js +0 -1
  331. package/dist/data/api/cli.d.ts +0 -1
  332. package/dist/data/api/head.d.ts +0 -16
  333. package/dist/data/api/head.spec.d.ts +0 -1
  334. package/dist/data/api/head.spec.js +0 -1
  335. package/dist/data/api/index.d.ts +0 -2
  336. package/dist/data/api/match.d.ts +0 -69
  337. package/dist/data/api/match.spec.d.ts +0 -1
  338. package/dist/data/api/match.spec.js +0 -1
  339. package/dist/data/api/server.d.ts +0 -13
  340. package/dist/data/projection/cli.d.ts +0 -1
  341. package/dist/data/projection/edges.d.ts +0 -8
  342. package/dist/data/projection/edges.spec.d.ts +0 -1
  343. package/dist/data/projection/edges.spec.js +0 -1
  344. package/dist/data/projection/facets.d.ts +0 -18
  345. package/dist/data/projection/facets.spec.d.ts +0 -1
  346. package/dist/data/projection/facets.spec.js +0 -1
  347. package/dist/data/projection/facts.d.ts +0 -40
  348. package/dist/data/projection/index.d.ts +0 -6
  349. package/dist/data/projection/project.d.ts +0 -10
  350. package/dist/data/projection/projection.spec.d.ts +0 -1
  351. package/dist/data/projection/projection.spec.js +0 -1
  352. package/dist/data/projection/schema.d.ts +0 -1
  353. package/dist/data/projection/store.d.ts +0 -51
  354. package/dist/data/projection/types.d.ts +0 -169
  355. package/dist/data/sync/cdc.d.ts +0 -33
  356. package/dist/data/sync/cdc.spec.d.ts +0 -1
  357. package/dist/data/sync/cdc.spec.js +0 -1
  358. package/dist/data/sync/graphql-source.d.ts +0 -16
  359. package/dist/data/sync/index.d.ts +0 -5
  360. package/dist/data/sync/reconciler.d.ts +0 -14
  361. package/dist/data/sync/reconciler.spec.d.ts +0 -1
  362. package/dist/data/sync/reconciler.spec.js +0 -1
  363. package/dist/data/sync/schema.d.ts +0 -1
  364. package/dist/data/sync/store.d.ts +0 -24
  365. package/dist/data/sync/sync.spec.d.ts +0 -1
  366. package/dist/data/sync/sync.spec.js +0 -1
  367. package/dist/data/sync/synchronizer.d.ts +0 -10
  368. package/dist/data/sync/types.d.ts +0 -164
  369. package/dist/evaluation/acceptance.d.ts +0 -33
  370. package/dist/evaluation/architecture.spec.d.ts +0 -1
  371. package/dist/evaluation/architecture.spec.js +0 -1
  372. package/dist/evaluation/builtins/arbitration-score.d.ts +0 -42
  373. package/dist/evaluation/builtins/demand-match.d.ts +0 -16
  374. package/dist/evaluation/builtins/graph-service.spec.d.ts +0 -1
  375. package/dist/evaluation/builtins/graph-service.spec.js +0 -1
  376. package/dist/evaluation/builtins/index.d.ts +0 -4
  377. package/dist/evaluation/builtins/purity.spec.d.ts +0 -1
  378. package/dist/evaluation/builtins/purity.spec.js +0 -1
  379. package/dist/evaluation/composer.d.ts +0 -38
  380. package/dist/evaluation/facets/catalog.d.ts +0 -19
  381. package/dist/evaluation/gap.d.ts +0 -2
  382. package/dist/evaluation/guard-scan.d.ts +0 -10
  383. package/dist/evaluation/index.d.ts +0 -14
  384. package/dist/evaluation/injection.d.ts +0 -6
  385. package/dist/evaluation/location-match.d.ts +0 -42
  386. package/dist/evaluation/match-operation.d.ts +0 -23
  387. package/dist/evaluation/match-policy-resolver.d.ts +0 -9
  388. package/dist/evaluation/match-policy.spec.d.ts +0 -1
  389. package/dist/evaluation/match-policy.spec.js +0 -1
  390. package/dist/evaluation/path-reasoning.d.ts +0 -37
  391. package/dist/evaluation/standards.d.ts +0 -11
  392. package/dist/evaluation/standards.spec.d.ts +0 -1
  393. package/dist/evaluation/standards.spec.js +0 -1
  394. package/dist/evaluation/structured-lines.d.ts +0 -8
  395. package/dist/evaluation/user-injection.d.ts +0 -6
  396. package/dist/experience/experience-reuse.d.ts +0 -10
  397. package/dist/experience/index.d.ts +0 -7
  398. package/dist/experience/persistence-config.d.ts +0 -6
  399. package/dist/experience/persistence.d.ts +0 -21
  400. package/dist/experience/realtime-feedback.d.ts +0 -5
  401. package/dist/experience/user-profile.d.ts +0 -25
  402. package/dist/extensions/capability.d.ts +0 -91
  403. package/dist/extensions/industry-audit.spec.d.ts +0 -1
  404. package/dist/extensions/industry-audit.spec.js +0 -1
  405. package/dist/goal/GoalClassifier.d.ts +0 -17
  406. package/dist/goal/GoalEngine.d.ts +0 -175
  407. package/dist/goal/GoalStore.d.ts +0 -27
  408. package/dist/goal/next-steps.d.ts +0 -12
  409. package/dist/goal/plan-approval.d.ts +0 -5
  410. package/dist/goal/pursue.d.ts +0 -18
  411. package/dist/graph/base.d.ts +0 -8
  412. package/dist/graph/onchain/analyze.d.ts +0 -59
  413. package/dist/graph/onchain/analyze.spec.d.ts +0 -1
  414. package/dist/graph/onchain/analyze.spec.js +0 -1
  415. package/dist/graph/onchain/anti-cheat.d.ts +0 -69
  416. package/dist/graph/onchain/anti-cheat.spec.d.ts +0 -1
  417. package/dist/graph/onchain/anti-cheat.spec.js +0 -1
  418. package/dist/graph/onchain/dataplane.d.ts +0 -44
  419. package/dist/graph/onchain/edge-batch.spec.d.ts +0 -1
  420. package/dist/graph/onchain/edge-batch.spec.js +0 -1
  421. package/dist/graph/onchain/edge-schema.d.ts +0 -69
  422. package/dist/graph/onchain/entity-profile.spec.d.ts +0 -1
  423. package/dist/graph/onchain/entity-profile.spec.js +0 -1
  424. package/dist/graph/onchain/event-history.spec.d.ts +0 -1
  425. package/dist/graph/onchain/event-history.spec.js +0 -1
  426. package/dist/graph/onchain/expand.d.ts +0 -4
  427. package/dist/graph/onchain/exploration.d.ts +0 -28
  428. package/dist/graph/onchain/exploration.spec.d.ts +0 -1
  429. package/dist/graph/onchain/exploration.spec.js +0 -1
  430. package/dist/graph/onchain/exposure.d.ts +0 -18
  431. package/dist/graph/onchain/exposure.spec.d.ts +0 -1
  432. package/dist/graph/onchain/exposure.spec.js +0 -1
  433. package/dist/graph/onchain/extract-deep.spec.d.ts +0 -1
  434. package/dist/graph/onchain/extract-deep.spec.js +0 -1
  435. package/dist/graph/onchain/extract.d.ts +0 -29
  436. package/dist/graph/onchain/facet-projection.d.ts +0 -99
  437. package/dist/graph/onchain/facet-projection.spec.d.ts +0 -1
  438. package/dist/graph/onchain/facet-projection.spec.js +0 -1
  439. package/dist/graph/onchain/facts.spec.d.ts +0 -1
  440. package/dist/graph/onchain/facts.spec.js +0 -1
  441. package/dist/graph/onchain/field-manifest.d.ts +0 -29
  442. package/dist/graph/onchain/field-manifest.spec.d.ts +0 -1
  443. package/dist/graph/onchain/field-manifest.spec.js +0 -1
  444. package/dist/graph/onchain/fixtures.d.ts +0 -80
  445. package/dist/graph/onchain/fixtures.spec.d.ts +0 -1
  446. package/dist/graph/onchain/fixtures.spec.js +0 -1
  447. package/dist/graph/onchain/graph-policy.spec.d.ts +0 -1
  448. package/dist/graph/onchain/graph-policy.spec.js +0 -1
  449. package/dist/graph/onchain/index.d.ts +0 -29
  450. package/dist/graph/onchain/interest.d.ts +0 -10
  451. package/dist/graph/onchain/interest.spec.d.ts +0 -1
  452. package/dist/graph/onchain/interest.spec.js +0 -1
  453. package/dist/graph/onchain/label-lint.spec.d.ts +0 -1
  454. package/dist/graph/onchain/label-lint.spec.js +0 -1
  455. package/dist/graph/onchain/names.d.ts +0 -23
  456. package/dist/graph/onchain/names.spec.d.ts +0 -1
  457. package/dist/graph/onchain/names.spec.js +0 -1
  458. package/dist/graph/onchain/object-held-receipts.d.ts +0 -20
  459. package/dist/graph/onchain/object-held-receipts.spec.d.ts +0 -1
  460. package/dist/graph/onchain/object-held-receipts.spec.js +0 -1
  461. package/dist/graph/onchain/onchain.spec.d.ts +0 -1
  462. package/dist/graph/onchain/onchain.spec.js +0 -1
  463. package/dist/graph/onchain/policy.d.ts +0 -8
  464. package/dist/graph/onchain/project-relationship.d.ts +0 -3
  465. package/dist/graph/onchain/proposal-graph.d.ts +0 -11
  466. package/dist/graph/onchain/proposal-graph.spec.d.ts +0 -1
  467. package/dist/graph/onchain/proposal-graph.spec.js +0 -1
  468. package/dist/graph/onchain/sdk-batch.d.ts +0 -129
  469. package/dist/graph/onchain/sdk-dataplane.d.ts +0 -44
  470. package/dist/graph/onchain/strategy.spec.d.ts +0 -1
  471. package/dist/graph/onchain/strategy.spec.js +0 -1
  472. package/dist/graph/onchain/synthesis.d.ts +0 -20
  473. package/dist/graph/onchain/synthesis.spec.d.ts +0 -1
  474. package/dist/graph/onchain/synthesis.spec.js +0 -1
  475. package/dist/graph/onchain/table-ledger.spec.d.ts +0 -1
  476. package/dist/graph/onchain/table-ledger.spec.js +0 -1
  477. package/dist/graph/onchain/viewport.d.ts +0 -6
  478. package/dist/harness/auto-escalation.d.ts +0 -15
  479. package/dist/intent/enrich.d.ts +0 -1
  480. package/dist/intent/index.d.ts +0 -23
  481. package/dist/intent/matcher.d.ts +0 -2
  482. package/dist/intent/store.d.ts +0 -19
  483. package/dist/intent/types.d.ts +0 -32
  484. package/dist/keeper/KeeperScan.d.ts +0 -41
  485. package/dist/keeper/KeeperStore.d.ts +0 -43
  486. package/dist/keeper/detectors.d.ts +0 -42
  487. package/dist/keeper/keeper.spec.d.ts +0 -1
  488. package/dist/keeper/keeper.spec.js +0 -1
  489. package/dist/keeper/types.d.ts +0 -67
  490. package/dist/knowledge/account-marks.d.ts +0 -36
  491. package/dist/knowledge/allocation-ledger.d.ts +0 -75
  492. package/dist/knowledge/allocation-puzzle.d.ts +0 -138
  493. package/dist/knowledge/allocation-risk.d.ts +0 -82
  494. package/dist/knowledge/allocation-templates.d.ts +0 -38
  495. package/dist/knowledge/allocator-rail-verifier.d.ts +0 -59
  496. package/dist/knowledge/anti-cheat.d.ts +0 -2
  497. package/dist/knowledge/arb-fund-facts.d.ts +0 -51
  498. package/dist/knowledge/arb-risk.d.ts +0 -39
  499. package/dist/knowledge/arbitration-puzzle.d.ts +0 -84
  500. package/dist/knowledge/arbitration-rail-verifier.d.ts +0 -35
  501. package/dist/knowledge/arbitration-risk.d.ts +0 -114
  502. package/dist/knowledge/arbitration-templates.d.ts +0 -39
  503. package/dist/knowledge/arbitration-venue-order.d.ts +0 -25
  504. package/dist/knowledge/baselines/guard-lint-baseline.spec.d.ts +0 -1
  505. package/dist/knowledge/baselines/guard-lint-baseline.spec.js +0 -1
  506. package/dist/knowledge/baselines/risk-baselines.spec.d.ts +0 -1
  507. package/dist/knowledge/baselines/risk-baselines.spec.js +0 -1
  508. package/dist/knowledge/baselines/risk-cases.d.ts +0 -8
  509. package/dist/knowledge/baselines/semantic-facts.d.ts +0 -12
  510. package/dist/knowledge/bridge-risk.d.ts +0 -36
  511. package/dist/knowledge/catalog-facts.d.ts +0 -4
  512. package/dist/knowledge/chain-query-registry.d.ts +0 -14
  513. package/dist/knowledge/commission-landing.d.ts +0 -26
  514. package/dist/knowledge/component-schema.d.ts +0 -64
  515. package/dist/knowledge/contact-risk.d.ts +0 -32
  516. package/dist/knowledge/contact-templates.d.ts +0 -26
  517. package/dist/knowledge/contract-invariants.d.ts +0 -54
  518. package/dist/knowledge/demand-risk.d.ts +0 -30
  519. package/dist/knowledge/discount-threshold.d.ts +0 -26
  520. package/dist/knowledge/dynamic-pricing.d.ts +0 -29
  521. package/dist/knowledge/entity-recipient-guard.d.ts +0 -21
  522. package/dist/knowledge/event-semantics.d.ts +0 -23
  523. package/dist/knowledge/evidence-review.d.ts +0 -35
  524. package/dist/knowledge/fee-param-bindings.d.ts +0 -28
  525. package/dist/knowledge/flywheel-loop.d.ts +0 -41
  526. package/dist/knowledge/game-scenarios.d.ts +0 -21
  527. package/dist/knowledge/getting-started.d.ts +0 -37
  528. package/dist/knowledge/goal-completion.d.ts +0 -31
  529. package/dist/knowledge/guard-anchor-reach.d.ts +0 -19
  530. package/dist/knowledge/guard-binding-table.d.ts +0 -52
  531. package/dist/knowledge/guard-binding-verifier.d.ts +0 -37
  532. package/dist/knowledge/guard-bindings.d.ts +0 -21
  533. package/dist/knowledge/guard-blueprint.d.ts +0 -68
  534. package/dist/knowledge/guard-design-patterns.d.ts +0 -38
  535. package/dist/knowledge/guard-eval.d.ts +0 -15
  536. package/dist/knowledge/guard-field-cognition.d.ts +0 -48
  537. package/dist/knowledge/guard-host-context.d.ts +0 -24
  538. package/dist/knowledge/guard-ledger.d.ts +0 -19
  539. package/dist/knowledge/guard-leg-map.d.ts +0 -5
  540. package/dist/knowledge/guard-lint.d.ts +0 -79
  541. package/dist/knowledge/guard-node-gates.d.ts +0 -9
  542. package/dist/knowledge/guard-puzzle.d.ts +0 -188
  543. package/dist/knowledge/guard-render.d.ts +0 -71
  544. package/dist/knowledge/guard-risk.d.ts +0 -71
  545. package/dist/knowledge/guard-submission-brief.d.ts +0 -94
  546. package/dist/knowledge/guard-submission-prompt.d.ts +0 -63
  547. package/dist/knowledge/guard-translation.d.ts +0 -58
  548. package/dist/knowledge/index.d.ts +0 -299
  549. package/dist/knowledge/industry-evolution.d.ts +0 -82
  550. package/dist/knowledge/industry-generalizer.d.ts +0 -63
  551. package/dist/knowledge/industry-rule-node.d.ts +0 -7
  552. package/dist/knowledge/industry-strategy.d.ts +0 -91
  553. package/dist/knowledge/intent-metrics.d.ts +0 -43
  554. package/dist/knowledge/jsonrpc-enum.d.ts +0 -102
  555. package/dist/knowledge/knob-docs.d.ts +0 -5
  556. package/dist/knowledge/machine-fork-watch.d.ts +0 -9
  557. package/dist/knowledge/machine-ledger.d.ts +0 -42
  558. package/dist/knowledge/machine-puzzle.d.ts +0 -206
  559. package/dist/knowledge/machine-risk.d.ts +0 -72
  560. package/dist/knowledge/machine-templates.d.ts +0 -92
  561. package/dist/knowledge/machine-topology.d.ts +0 -116
  562. package/dist/knowledge/machine-translation.d.ts +0 -96
  563. package/dist/knowledge/market-metrics.d.ts +0 -34
  564. package/dist/knowledge/market-operations.d.ts +0 -46
  565. package/dist/knowledge/migration-preflight.d.ts +0 -27
  566. package/dist/knowledge/object-dependency.d.ts +0 -31
  567. package/dist/knowledge/operation-dictionary.d.ts +0 -18
  568. package/dist/knowledge/order-ledger.d.ts +0 -69
  569. package/dist/knowledge/order-puzzle.d.ts +0 -162
  570. package/dist/knowledge/order-risk.d.ts +0 -62
  571. package/dist/knowledge/order-templates.d.ts +0 -50
  572. package/dist/knowledge/param-schema.d.ts +0 -93
  573. package/dist/knowledge/param-tiers.d.ts +0 -27
  574. package/dist/knowledge/passport-ledger.d.ts +0 -60
  575. package/dist/knowledge/passport-templates.d.ts +0 -40
  576. package/dist/knowledge/path-oracle/coverage.d.ts +0 -16
  577. package/dist/knowledge/path-oracle/index.d.ts +0 -5
  578. package/dist/knowledge/path-oracle/products/food-delivery.d.ts +0 -2
  579. package/dist/knowledge/path-oracle/schema.d.ts +0 -188
  580. package/dist/knowledge/pattern-resolutions.d.ts +0 -110
  581. package/dist/knowledge/payment-risk.d.ts +0 -38
  582. package/dist/knowledge/payment-tracker.d.ts +0 -63
  583. package/dist/knowledge/permission-ledger.d.ts +0 -49
  584. package/dist/knowledge/permission-puzzle.d.ts +0 -122
  585. package/dist/knowledge/permission-risk.d.ts +0 -70
  586. package/dist/knowledge/permission-templates.d.ts +0 -38
  587. package/dist/knowledge/personal-risk.d.ts +0 -36
  588. package/dist/knowledge/product-detail-source.d.ts +0 -37
  589. package/dist/knowledge/product-doc-b5.d.ts +0 -16
  590. package/dist/knowledge/progress-ledger.d.ts +0 -63
  591. package/dist/knowledge/progress-puzzle.d.ts +0 -82
  592. package/dist/knowledge/progress-risk.d.ts +0 -75
  593. package/dist/knowledge/progress-templates.d.ts +0 -38
  594. package/dist/knowledge/projection.d.ts +0 -54
  595. package/dist/knowledge/projection.spec.d.ts +0 -1
  596. package/dist/knowledge/projection.spec.js +0 -1
  597. package/dist/knowledge/proof-risk.d.ts +0 -33
  598. package/dist/knowledge/protocol-facts.d.ts +0 -17
  599. package/dist/knowledge/publish-gate.d.ts +0 -20
  600. package/dist/knowledge/publish-readiness.d.ts +0 -25
  601. package/dist/knowledge/publish-surface-contract.d.ts +0 -16
  602. package/dist/knowledge/puzzle-projections.d.ts +0 -11
  603. package/dist/knowledge/rail-exit-satisfiability.d.ts +0 -25
  604. package/dist/knowledge/registrar-risk.d.ts +0 -34
  605. package/dist/knowledge/release-sentinel.d.ts +0 -12
  606. package/dist/knowledge/repository-risk.d.ts +0 -46
  607. package/dist/knowledge/repository-write-semantics.d.ts +0 -27
  608. package/dist/knowledge/reputation-rules.d.ts +0 -36
  609. package/dist/knowledge/requirement-families.d.ts +0 -13
  610. package/dist/knowledge/resource-risk.d.ts +0 -32
  611. package/dist/knowledge/reward-ledger.d.ts +0 -97
  612. package/dist/knowledge/reward-puzzle.d.ts +0 -98
  613. package/dist/knowledge/reward-risk.d.ts +0 -86
  614. package/dist/knowledge/reward-templates.d.ts +0 -25
  615. package/dist/knowledge/rule-node-analyzers.d.ts +0 -49
  616. package/dist/knowledge/rule-outcome.d.ts +0 -5
  617. package/dist/knowledge/scenario-topology.d.ts +0 -48
  618. package/dist/knowledge/semantic-ir.d.ts +0 -136
  619. package/dist/knowledge/service-allocation-semantics.d.ts +0 -36
  620. package/dist/knowledge/service-allocator-audit-node.d.ts +0 -3
  621. package/dist/knowledge/service-ledger.d.ts +0 -87
  622. package/dist/knowledge/service-puzzle.d.ts +0 -158
  623. package/dist/knowledge/service-risk-node.d.ts +0 -3
  624. package/dist/knowledge/service-risk.d.ts +0 -110
  625. package/dist/knowledge/service-templates.d.ts +0 -41
  626. package/dist/knowledge/settlement-semantics.d.ts +0 -1
  627. package/dist/knowledge/strategy-manuals.d.ts +0 -15
  628. package/dist/knowledge/supply-chain.d.ts +0 -35
  629. package/dist/knowledge/template-index.d.ts +0 -19
  630. package/dist/knowledge/template-loader.d.ts +0 -425
  631. package/dist/knowledge/template-nav.d.ts +0 -9
  632. package/dist/knowledge/template-prose.d.ts +0 -50
  633. package/dist/knowledge/template-registry.d.ts +0 -48
  634. package/dist/knowledge/template-scanner.d.ts +0 -158
  635. package/dist/knowledge/template-test-profiles.d.ts +0 -17
  636. package/dist/knowledge/template-validation.d.ts +0 -3
  637. package/dist/knowledge/tools-reference.d.ts +0 -17
  638. package/dist/knowledge/treasury-ledger.d.ts +0 -42
  639. package/dist/knowledge/treasury-puzzle.d.ts +0 -163
  640. package/dist/knowledge/treasury-risk.d.ts +0 -88
  641. package/dist/knowledge/treasury-templates.d.ts +0 -38
  642. package/dist/knowledge/universal-template.d.ts +0 -22
  643. package/dist/knowledge/util-risk.d.ts +0 -30
  644. package/dist/knowledge/workflow-guidance.d.ts +0 -194
  645. package/dist/knowledge/workspace-lists.d.ts +0 -61
  646. package/dist/monitor/SuggestionBridge.spec.d.ts +0 -1
  647. package/dist/monitor/SuggestionBridge.spec.js +0 -1
  648. package/dist/participation/arbitrator-interest.d.ts +0 -22
  649. package/dist/participation/demander-interest.d.ts +0 -23
  650. package/dist/participation/employee-kpi.d.ts +0 -37
  651. package/dist/participation/employee-kpi.spec.d.ts +0 -1
  652. package/dist/participation/employee-kpi.spec.js +0 -1
  653. package/dist/participation/employee-store.d.ts +0 -16
  654. package/dist/participation/game-context.d.ts +0 -25
  655. package/dist/participation/index.d.ts +0 -2
  656. package/dist/participation/node-action-advisor.d.ts +0 -68
  657. package/dist/participation/time-window.d.ts +0 -48
  658. package/dist/persona/facet-profile.d.ts +0 -33
  659. package/dist/persona/persona-audit.spec.d.ts +0 -1
  660. package/dist/persona/persona-audit.spec.js +0 -1
  661. package/dist/playbooks/service-build/business-puzzle.d.ts +0 -48
  662. package/dist/playbooks/service-build/context-assembly.d.ts +0 -32
  663. package/dist/playbooks/service-build/facet-money.d.ts +0 -33
  664. package/dist/playbooks/service-build/facet-money.spec.d.ts +0 -1
  665. package/dist/playbooks/service-build/facet-money.spec.js +0 -1
  666. package/dist/playbooks/service-build/game-theory.d.ts +0 -47
  667. package/dist/playbooks/service-build/index.d.ts +0 -15
  668. package/dist/playbooks/service-build/intent-analyzer.d.ts +0 -72
  669. package/dist/playbooks/service-build/machine-nodes.d.ts +0 -27
  670. package/dist/playbooks/service-build/machine-panorama.d.ts +0 -71
  671. package/dist/playbooks/service-build/merchant-guide.d.ts +0 -382
  672. package/dist/playbooks/service-build/migration-planner.d.ts +0 -61
  673. package/dist/playbooks/service-build/mode-actions.d.ts +0 -260
  674. package/dist/playbooks/service-build/object-panorama.d.ts +0 -317
  675. package/dist/playbooks/service-build/object-type.d.ts +0 -1
  676. package/dist/playbooks/service-build/participation-radar.d.ts +0 -20
  677. package/dist/playbooks/service-build/pipeline-actions.d.ts +0 -108
  678. package/dist/playbooks/service-build/process.d.ts +0 -6
  679. package/dist/playbooks/service-build/relationship-profile.d.ts +0 -3
  680. package/dist/playbooks/service-build/reverse-mapping-nk4.spec.d.ts +0 -1
  681. package/dist/playbooks/service-build/reverse-mapping-nk4.spec.js +0 -1
  682. package/dist/playbooks/service-build/reverse-mapping-refund-p0-5.spec.d.ts +0 -1
  683. package/dist/playbooks/service-build/reverse-mapping-refund-p0-5.spec.js +0 -1
  684. package/dist/playbooks/service-build/reverse-mapping.d.ts +0 -66
  685. package/dist/playbooks/service-build/risk-aggregator.d.ts +0 -59
  686. package/dist/playbooks/service-build/service-panorama.d.ts +0 -229
  687. package/dist/playbooks/service-build/service-quote.d.ts +0 -2
  688. package/dist/playbooks/service-build/service-quote.spec.d.ts +0 -1
  689. package/dist/playbooks/service-build/service-quote.spec.js +0 -1
  690. package/dist/playbooks/service-build/topology-evaluation.spec.d.ts +0 -1
  691. package/dist/playbooks/service-build/topology-evaluation.spec.js +0 -1
  692. package/dist/playbooks/service-build/topology-query.d.ts +0 -25
  693. package/dist/playbooks/service-build/workflow-design-assessment.d.ts +0 -33
  694. package/dist/relationship/derivation.d.ts +0 -95
  695. package/dist/relationship/derivation.spec.d.ts +0 -1
  696. package/dist/relationship/derivation.spec.js +0 -1
  697. package/dist/relationship/incentive.d.ts +0 -38
  698. package/dist/relationship/index.d.ts +0 -4
  699. package/dist/relationship/registry.d.ts +0 -13
  700. package/dist/relationship/types.d.ts +0 -45
  701. package/dist/review/arb.d.ts +0 -4
  702. package/dist/review/demand.d.ts +0 -3
  703. package/dist/review/index.d.ts +0 -3
  704. package/dist/review/machine.d.ts +0 -3
  705. package/dist/review/order.d.ts +0 -8
  706. package/dist/review/progress.d.ts +0 -3
  707. package/dist/review/repository.d.ts +0 -3
  708. package/dist/review/service.d.ts +0 -5
  709. package/dist/review/types.d.ts +0 -163
  710. package/dist/role/derivation.d.ts +0 -35
  711. package/dist/role/index.d.ts +0 -6
  712. package/dist/role/intent.d.ts +0 -23
  713. package/dist/role/model.d.ts +0 -9
  714. package/dist/role/profiles.d.ts +0 -26
  715. package/dist/role/resolution.d.ts +0 -27
  716. package/dist/runtime/instance-registry.d.ts +0 -14
  717. package/dist/safety/index.d.ts +0 -3
  718. package/dist/schema/call/permission-handler.d.ts +0 -5
  719. package/dist/schema/call/semantic-customer-advice.spec.d.ts +0 -1
  720. package/dist/schema/call/semantic-customer-advice.spec.js +0 -1
  721. package/dist/schema/common/tokentype-short-probe.spec.d.ts +0 -1
  722. package/dist/schema/common/tokentype-short-probe.spec.js +0 -1
  723. package/dist/schema/envelope-unify.d.ts +0 -5
  724. package/dist/schema/goal/planning.d.ts +0 -742
  725. package/dist/schema/industry-pack/modes.d.ts +0 -447
  726. package/dist/schema/query/bi.d.ts +0 -3369
  727. package/dist/schema/utils/guard-query-utils.d.ts +0 -18
  728. package/dist/schema/utils/permission-index-utils.d.ts +0 -2
  729. package/dist/schema/utils/skills-recommendation.d.ts +0 -2
  730. package/dist/schema-query-impl/index.d.ts +0 -83
  731. package/dist/schemas/account_operation.output.json +0 -3869
  732. package/dist/schemas/ask_user.output.json +0 -54
  733. package/dist/schemas/benchmark_migration_operation.output.json +0 -1669
  734. package/dist/schemas/bridge_operation.output.json +0 -1548
  735. package/dist/schemas/config_operation.output.json +0 -896
  736. package/dist/schemas/employee_operation.output.json +0 -307
  737. package/dist/schemas/evaluation_operation.output.json +0 -4716
  738. package/dist/schemas/guard2file.output.json +0 -83
  739. package/dist/schemas/industry_pack_operation.output.json +0 -2985
  740. package/dist/schemas/intent_radar.output.json +0 -326
  741. package/dist/schemas/keeper_operation.output.json +0 -1441
  742. package/dist/schemas/local_cache_operation.output.json +0 -1718
  743. package/dist/schemas/local_history_operation.output.json +0 -1644
  744. package/dist/schemas/local_info_operation.output.json +0 -1530
  745. package/dist/schemas/local_mark_operation.output.json +0 -1622
  746. package/dist/schemas/machineNode2file.output.json +0 -88
  747. package/dist/schemas/messenger_operation.output.json +0 -4692
  748. package/dist/schemas/monitor_events.output.json +0 -1602
  749. package/dist/schemas/monitor_subscription.output.json +0 -1629
  750. package/dist/schemas/onchain_events.output.json +0 -4053
  751. package/dist/schemas/onchain_operations.output.json +0 -7788
  752. package/dist/schemas/onchain_table_data.output.json +0 -11868
  753. package/dist/schemas/permission_operation.output.json +0 -205
  754. package/dist/schemas/persona_operation.output.json +0 -64612
  755. package/dist/schemas/query_toolkit.output.json +0 -28302
  756. package/dist/schemas/schema_query.output.json +0 -81
  757. package/dist/schemas/service_clone_operation.output.json +0 -247
  758. package/dist/schemas/strategy_review_operation.output.json +0 -532
  759. package/dist/schemas/watch_operation.output.json +0 -930
  760. package/dist/schemas/wip_file.output.json +0 -360
  761. package/dist/schemas/workflow_operation.output.json +0 -422
  762. package/dist/schemas/workspace_operation.output.json +0 -477
  763. package/dist/schemas/wowok_buildin_info.output.json +0 -2477
  764. package/dist/strategy/collectors.d.ts +0 -66
  765. package/dist/strategy/collectors.spec.d.ts +0 -1
  766. package/dist/strategy/collectors.spec.js +0 -1
  767. package/dist/strategy/index.d.ts +0 -5
  768. package/dist/strategy/metrics.d.ts +0 -20
  769. package/dist/strategy/review.d.ts +0 -48
  770. package/dist/strategy/scorecard.d.ts +0 -32
  771. package/dist/strategy/store.d.ts +0 -26
  772. package/dist/task/ProcessStore.d.ts +0 -98
  773. package/dist/task/playbook.d.ts +0 -11
  774. package/dist/task/substep-trace.d.ts +0 -91
  775. package/dist/tools/build-fingerprint.d.ts +0 -28
  776. package/dist/tools/error-catalog.d.ts +0 -17
  777. package/dist/tools/handlers/ask-user.d.ts +0 -3
  778. package/dist/tools/handlers/benchmark-migration.d.ts +0 -121
  779. package/dist/tools/handlers/bridge.d.ts +0 -8
  780. package/dist/tools/handlers/config.d.ts +0 -2
  781. package/dist/tools/handlers/dispatch-expectations.d.ts +0 -2
  782. package/dist/tools/handlers/dispatch-expectations.spec.d.ts +0 -1
  783. package/dist/tools/handlers/dispatch-expectations.spec.js +0 -1
  784. package/dist/tools/handlers/employee.d.ts +0 -8
  785. package/dist/tools/handlers/employee.spec.d.ts +0 -1
  786. package/dist/tools/handlers/employee.spec.js +0 -1
  787. package/dist/tools/handlers/entry-edge-recipe.d.ts +0 -101
  788. package/dist/tools/handlers/escrow-deficit.d.ts +0 -10
  789. package/dist/tools/handlers/evaluation.d.ts +0 -2
  790. package/dist/tools/handlers/evaluation.spec.d.ts +0 -1
  791. package/dist/tools/handlers/evaluation.spec.js +0 -1
  792. package/dist/tools/handlers/file-export.d.ts +0 -3
  793. package/dist/tools/handlers/fund-rail-recipe.d.ts +0 -10
  794. package/dist/tools/handlers/goal.d.ts +0 -4
  795. package/dist/tools/handlers/industry-pack.d.ts +0 -3
  796. package/dist/tools/handlers/intent-radar.d.ts +0 -2
  797. package/dist/tools/handlers/keeper.d.ts +0 -12
  798. package/dist/tools/handlers/local.d.ts +0 -6
  799. package/dist/tools/handlers/mark-namespace.d.ts +0 -30
  800. package/dist/tools/handlers/messenger.d.ts +0 -24
  801. package/dist/tools/handlers/monitor.d.ts +0 -26
  802. package/dist/tools/handlers/name-resolution.d.ts +0 -4
  803. package/dist/tools/handlers/name-resolution.spec.d.ts +0 -1
  804. package/dist/tools/handlers/name-resolution.spec.js +0 -1
  805. package/dist/tools/handlers/network.d.ts +0 -1
  806. package/dist/tools/handlers/onchain-name-registration.d.ts +0 -49
  807. package/dist/tools/handlers/onchain-name-registration.spec.d.ts +0 -1
  808. package/dist/tools/handlers/onchain-name-registration.spec.js +0 -1
  809. package/dist/tools/handlers/onchain.d.ts +0 -132
  810. package/dist/tools/handlers/permission.d.ts +0 -2
  811. package/dist/tools/handlers/persona.d.ts +0 -4
  812. package/dist/tools/handlers/publish-binding-echo.d.ts +0 -22
  813. package/dist/tools/handlers/review-chain.d.ts +0 -19
  814. package/dist/tools/handlers/schema-query.d.ts +0 -2
  815. package/dist/tools/handlers/service-clone.d.ts +0 -20
  816. package/dist/tools/handlers/stale-build-check.d.ts +0 -9
  817. package/dist/tools/handlers/strategy-review.d.ts +0 -2
  818. package/dist/tools/handlers/submission-assembly.d.ts +0 -55
  819. package/dist/tools/handlers/watch.d.ts +0 -2
  820. package/dist/tools/handlers/winner-derivation.d.ts +0 -20
  821. package/dist/tools/handlers/wip-upload.d.ts +0 -22
  822. package/dist/tools/handlers/wip.d.ts +0 -2
  823. package/dist/tools/handlers/workflow.d.ts +0 -2
  824. package/dist/tools/handlers/workspace.d.ts +0 -4
  825. package/dist/tools/move-fn-index.gen.d.ts +0 -3
  826. package/dist/tools/publish-gate-state.d.ts +0 -5
  827. package/dist/tools/registry/agent.d.ts +0 -2
  828. package/dist/tools/registry/bridge.d.ts +0 -2
  829. package/dist/tools/registry/business.d.ts +0 -2
  830. package/dist/tools/registry/config.d.ts +0 -2
  831. package/dist/tools/registry/evaluation.d.ts +0 -2
  832. package/dist/tools/registry/files.d.ts +0 -2
  833. package/dist/tools/registry/identity.d.ts +0 -2
  834. package/dist/tools/registry/interaction.d.ts +0 -2
  835. package/dist/tools/registry/local.d.ts +0 -2
  836. package/dist/tools/registry/messenger.d.ts +0 -2
  837. package/dist/tools/registry/monitor.d.ts +0 -2
  838. package/dist/tools/registry/onchain.d.ts +0 -2
  839. package/dist/tools/registry/query.d.ts +0 -2
  840. package/dist/tools/retry.d.ts +0 -8
  841. package/dist/tools/rules-hook.d.ts +0 -5
  842. package/dist/tools/runtime-health.d.ts +0 -10
  843. package/dist/tools/sanitize-description-roundtrip.spec.d.ts +0 -1
  844. package/dist/tools/sanitize-description-roundtrip.spec.js +0 -1
  845. package/dist/tools/sanitize-output.d.ts +0 -4
  846. package/dist/tools/sanitize-output.spec.d.ts +0 -1
  847. package/dist/tools/sanitize-output.spec.js +0 -1
  848. package/dist/tools/shared.d.ts +0 -20
  849. package/dist/tools/transport-integrity.d.ts +0 -7
  850. package/dist/tools/upgrade-check.d.ts +0 -75
  851. package/dist/tools/wip-deploy-assist.d.ts +0 -34
  852. package/dist/tools/wip-verify-ledger.d.ts +0 -16
  853. package/dist/tools/wrap.d.ts +0 -45
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- import{describe,expect,it}from'vitest';import{EntityAddress,ENTRYPOINT}from'@wowok/wowok';import{FakeDataPlane}from'./dataplane.js';import{expandTopology}from'./expand.js';import{extractReverseRefs}from'./extract.js';import{FULL,fullServiceState}from'./fixtures.js';import{buildViewport,edgesOut,profileOf}from'./viewport.js';const ENTITY_SCHEMAS=['entity.profile','entity.referrer','entity.resource'];function byId(a){return new Map(a['map'](b=>[b['schemaId'],b['refs']]));}async function graphFrom(a){const b=new FakeDataPlane(fullServiceState()),c=await expandTopology(b,{'network':ENTRYPOINT['Mainnet'],'seed':a,'edges':{'schemas':ENTITY_SCHEMAS}});return{'plane':b,'graph':c};}describe('Task\x209\x20entity\x20registrar\x20—\x20pure\x20extraction\x20(TR-9.1)',()=>{it('complete\x20SDK-shaped\x20AddressInfo\x20row\x20yields\x20profile\x20+\x20referrer\x20+\x20resource',()=>{const a=extractReverseRefs(EntityAddress,{'description':'Acme\x20logistics\x20co.','time':0x18bcfe57b88,'referrer':FULL['merchant'],'mark_object':FULL['resource'],'records':[{'name':'region','value_type':0x1,'value':'cn-east'}]}),b=byId(a);expect([...b['keys']()]['sort']())['toEqual'](['entity.profile','entity.referrer','entity.resource']['sort']());const c=b['get']('entity.profile')[0x0];expect(c['to'])['toBe'](''),expect(c['payload'])['toMatchObject']({'description':'Acme\x20logistics\x20co.','registeredAt':0x18bcfe57b88,'profileRecords':[{'name':'region','valueType':0x1,'value':'cn-east'}]}),expect(b['get']('entity.referrer')['map'](d=>d['to']))['toEqual']([FULL['merchant']]),expect(b['get']('entity.resource')['map'](d=>d['to']))['toEqual']([FULL['resource']]);}),it('raw\x20Move\x20shape\x20(resource\x20/\x20typed_value)\x20parses\x20identically',()=>{const a=byId(extractReverseRefs(EntityAddress,{'description':'on-chain\x20native','time':0x1,'referrer':null,'resource':FULL['resource'],'records':[{'name':'tag','typed_value':[0x1,0x2,0x3]}]}));expect(a['get']('entity.resource')[0x0]['to'])['toBe'](FULL['resource']),expect(a['has']('entity.referrer'))['toBe'](![]),expect(a['get']('entity.profile')[0x0]['payload']?.['profileRecords'])['toEqual']([{'name':'tag','value':[0x1,0x2,0x3]}]);}),it('null\x20Options\x20and\x20no\x20records\x20yield\x20only\x20the\x20profile\x20edge',()=>{const a=byId(extractReverseRefs(EntityAddress,{'description':'warehouse\x20member','time':0x18bcfe57f70,'referrer':null,'resource':null,'records':[]}));expect([...a['keys']()])['toEqual'](['entity.profile']),expect(a['get']('entity.profile')[0x0]['payload'])['toEqual']({'description':'warehouse\x20member','registeredAt':0x18bcfe57f70});}),it('empty/garbage\x20row\x20still\x20yields\x20one\x20profile\x20edge,\x20never\x20throws',()=>{const a=byId(extractReverseRefs(EntityAddress,{}));expect([...a['keys']()])['toEqual'](['entity.profile']),expect(a['get']('entity.profile')[0x0]['payload'])['toEqual']({});const b=byId(extractReverseRefs(EntityAddress,{'description':0x2a,'time':'not-a-time','referrer':'0xdead','mark_object':0x3039,'records':[{'value_type':0x1},'junk',{'name':'ok','value_type':0x0,'value':!![]}]}));expect(b['has']('entity.referrer'))['toBe'](![]),expect(b['has']('entity.resource'))['toBe'](![]),expect(b['get']('entity.profile')[0x0]['payload']?.['profileRecords'])['toEqual']([{'name':'ok','valueType':0x0,'value':!![]}]);});}),describe('Task\x209\x20entity\x20registrar\x20—\x20end-to-end\x20expansion\x20(TR-9.1)',()=>{it('all\x20three\x20co-edges\x20materialize\x20from\x20one\x20keyed\x20channel\x20read;\x20Resource\x20node\x20is\x20typed\x20and\x20fetched',async()=>{const {plane:a,graph:b}=await graphFrom(FULL['supplier']),c=f=>b['edges']['filter'](g=>g['schema']===f),d=c('entity.profile');expect(d)['toHaveLength'](0x1),expect(d[0x0]['from'])['toBe'](FULL['supplier']),expect(d[0x0]['to'])['toBe'](FULL['supplier']),expect(d[0x0]['payload'])['toMatchObject']({'description':'Acme\x20logistics\x20co.','registeredAt':0x18bcfe57b88}),expect(d[0x0]['payload']?.['profileRecords'])['toHaveLength'](0x1),expect(c('entity.referrer')['map'](f=>f['to']))['toEqual']([FULL['merchant']]),expect(c('entity.resource')['map'](f=>f['to']))['toEqual']([FULL['resource']]);const e=b['nodes']['get'](FULL['resource']['toLowerCase']());expect(e['kind'])['toBe']('object'),expect(e['objectType'])['toBe']('Resource'),expect(e['state'])['toBe']('fetched'),expect(a['batches']['keyedFields'])['toBe'](0x2),expect(b['gaps'])['toEqual']([]);}),it('row\x20with\x20null\x20Options\x20produces\x20the\x20profile\x20self-edge\x20only',async()=>{const {graph:a}=await graphFrom(FULL['member']),b=new Set(a['edges']['map'](d=>d['schema']));expect(b['has']('entity.profile'))['toBe'](!![]),expect(b['has']('entity.referrer'))['toBe'](![]),expect(b['has']('entity.resource'))['toBe'](![]);const c=a['edges']['find'](d=>d['schema']==='entity.profile');expect(c['from'])['toBe'](FULL['member']),expect(c['to'])['toBe'](FULL['member']),expect(c['payload']?.['description'])['toBe']('warehouse\x20member');}),it('absent\x20profile\x20row\x20produces\x20no\x20entity\x20edges\x20and\x20no\x20error',async()=>{const {plane:a,graph:b}=await graphFrom(FULL['buyer']);expect(b['edges']['filter'](c=>ENTITY_SCHEMAS['includes'](c['schema'])))['toEqual']([]),expect(b['gaps'])['toEqual']([]),expect(a['batches']['keyedFields'])['toBe'](0x1);});}),describe('Task\x209\x20viewport\x20—\x20personal-data\x20minimization\x20(TR-9.2)',()=>{it('neutral\x20tooling\x20sees\x20the\x20full\x20profile\x20payload',async()=>{const {graph:a}=await graphFrom(FULL['supplier']),b=buildViewport(a,FULL['supplier'],'neutral'),c=profileOf(b,FULL['supplier']);expect(c['description'])['toBe']('Acme\x20logistics\x20co.'),expect(c['profileRecords'])['toHaveLength'](0x1),expect(c['hasDescription'])['toBeUndefined']();}),it('subject\x20sees\x20its\x20own\x20full\x20profile\x20under\x20a\x20retail\x20role;\x20referrer/resource\x20stay\x20denied',async()=>{const {graph:a}=await graphFrom(FULL['supplier']),b=buildViewport(a,FULL['supplier'],'buyer');expect(profileOf(b,FULL['supplier'])?.['description'])['toBe']('Acme\x20logistics\x20co.'),expect(edgesOut(b,FULL['supplier'],'entity.referrer'))['toEqual']([]),expect(edgesOut(b,FULL['supplier'],'entity.resource'))['toEqual']([]),expect(b['visibleNodes']['has'](FULL['resource']['toLowerCase']()))['toBe'](![]);}),it('commercial\x20roles\x20see\x20third\x20parties\x20through\x20the\x20minimized\x20projection\x20only',async()=>{const {graph:a}=await graphFrom(FULL['supplier']),b=buildViewport(a,FULL['merchant'],'merchant');expect(b['visibleNodes']['has'](FULL['supplier']['toLowerCase']()))['toBe'](!![]);const c=profileOf(b,FULL['supplier']);expect(c['hasDescription'])['toBe'](!![]),expect(c['recordCount'])['toBe'](0x1),expect(c['registeredAt'])['toBe'](0x18bcfe57b88),expect(c['description'])['toBeUndefined'](),expect(c['profileRecords'])['toBeUndefined']();const d=a['edges']['find'](f=>f['schema']==='entity.profile');expect(d['payload']?.['description'])['toBe']('Acme\x20logistics\x20co.'),expect(edgesOut(b,FULL['supplier'],'entity.referrer'))['toHaveLength'](0x1),expect(edgesOut(b,FULL['supplier'],'entity.resource'))['toHaveLength'](0x1);}),it('roles\x20without\x20a\x20social\x20surface\x20see\x20no\x20entity\x20edges\x20at\x20all',async()=>{const {graph:a}=await graphFrom(FULL['supplier']),b=buildViewport(a,FULL['supplier'],'supplier');expect(profileOf(b,FULL['supplier']))['toBeUndefined'](),expect(edgesOut(b,FULL['supplier'],'entity.profile'))['toEqual']([]),expect(edgesOut(b,FULL['supplier'],'entity.referrer'))['toEqual']([]),expect(edgesOut(b,FULL['supplier'],'entity.resource'))['toEqual']([]);});});
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- import{describe,expect,it}from'vitest';import{PackageAddress,ENTRYPOINT}from'@wowok/wowok';import{FakeDataPlane}from'./dataplane.js';import{expandTopology}from'./expand.js';import{FULL,fullServiceState,rowObject}from'./fixtures.js';import{pathConfidence}from'./analyze.js';const ORDER_EVENT=PackageAddress+'::order::NewOrderEvent',ARB_EVENT=PackageAddress+'::arb::ArbEvent',ORDER_OLD_A='0x6600000000000000000000000000000000000000000000000000000000000a01',ORDER_OLD_B='0x6600000000000000000000000000000000000000000000000000000000000a02',CASE_OLD='0x6700000000000000000000000000000000000000000000000000000000000b01';function envelope(a,b,c,d){return{'id':{'txDigest':'tx'+c,'eventSeq':String(c)},'type':a,'sender':b,'timestampMs':String(c),'parsedJson':d};}function orderCreated(a,b,c,d=FULL['svc']){return envelope(ORDER_EVENT,b,c,{'object':a,'service':d,'amount':'500000'});}function withEvents(a){const b=fullServiceState();return b['events']=new Map([[ORDER_EVENT,a]]),b['objects']['set'](ORDER_OLD_A['toLowerCase'](),rowObject('Order',{'service':FULL['svc'],'amount':'1'})['object']),b['objects']['set'](ORDER_OLD_B['toLowerCase'](),rowObject('Order',{'service':FULL['svc'],'amount':'2'})['object']),b;}describe('Task\x2010\x20E\x20family\x20—\x20order\x20history\x20streams\x20(TR-10.1)',()=>{it('service.order_history\x20pulls\x20orders\x20beyond\x20the\x20FIFO\x20window;\x20retention\x20event_full,\x20exact\x20confidence',async()=>{const a=new FakeDataPlane(withEvents([{'events':[orderCreated(ORDER_OLD_A,FULL['buyer'],0x3e8),orderCreated(ORDER_OLD_B,FULL['agent'],0x44c)]},{'events':[orderCreated(FULL['o1'],FULL['buyer'],0x7d0)]}])),b=await expandTopology(a,{'network':ENTRYPOINT['Mainnet'],'seed':FULL['svc'],'edges':{'eventEdges':['service.order_history']}}),c=b['edges']['filter'](f=>f['schema']==='service.order_history');expect(c['map'](f=>f['to'])['sort']())['toEqual']([FULL['o1'],ORDER_OLD_A,ORDER_OLD_B]['sort']()),expect(c['every'](f=>f['from']===FULL['svc']['toLowerCase']()))['toBe'](!![]),expect(c['every'](f=>f['retention']==='event_full'&&!f['truncated']))['toBe'](!![]);const d=c['find'](f=>f['to']===ORDER_OLD_A);expect(d['payload'])['toMatchObject']({'amount':'500000','service':FULL['svc']['toLowerCase'](),'time':0x3e8}),expect(b['nodes']['get'](ORDER_OLD_A['toLowerCase']())?.['state'])['toBe']('fetched'),expect(a['batches']['events'])['toBe'](0x2),expect(pathConfidence({'graph':b,'observer':FULL['svc'],'role':'neutral','visibleNodes':new Set(),'visibleEdges':[],'edgeById':new Map(),'maskedNodes':new Set()},[{'schema':'service.order_history','from':FULL['svc'],'retention':'event_full'}])['confidence'])['toBe']('exact'),expect(b['gaps'])['toEqual']([]);}),it('eoa.order_history\x20matches\x20the\x20tx\x20sender\x20(transacting\x20buyer),\x20not\x20a\x20parsed\x20field',async()=>{const a=new FakeDataPlane(withEvents([{'events':[orderCreated(ORDER_OLD_A,FULL['buyer'],0x3e8),orderCreated(ORDER_OLD_B,FULL['merchant'],0x44c)]}])),b=await expandTopology(a,{'network':ENTRYPOINT['Mainnet'],'seed':FULL['buyer'],'edges':{'eventEdges':['eoa.order_history']}}),c=b['edges']['filter'](d=>d['schema']==='eoa.order_history');expect(c['map'](d=>d['to']))['toEqual']([ORDER_OLD_A]),expect(c[0x0]['from'])['toBe'](FULL['buyer']);}),it('arb.history:\x20repeat\x20status\x20transitions\x20collapse\x20to\x20one\x20edge\x20per\x20case,\x20latest\x20wins',async()=>{const a=fullServiceState();a['events']=new Map([[ARB_EVENT,[{'events':[envelope(ARB_EVENT,FULL['merchant'],0x3e8,{'object':CASE_OLD,'arbitration':FULL['arbsvc'],'order':FULL['o2'],'status':0x1})]},{'events':[envelope(ARB_EVENT,FULL['merchant'],0x2328,{'object':CASE_OLD,'arbitration':FULL['arbsvc'],'order':FULL['o2'],'status':0x3,'indemnity_amount':'700'})]}]]]);const b=new FakeDataPlane(a),c=await expandTopology(b,{'network':ENTRYPOINT['Mainnet'],'seed':FULL['arbsvc'],'edges':{'eventEdges':['arb.history']}}),d=c['edges']['filter'](f=>f['schema']==='arb.history');expect(d)['toHaveLength'](0x1),expect(d[0x0]['to'])['toBe'](CASE_OLD),expect(d[0x0]['payload'])['toMatchObject']({'status':0x3,'indemnity_amount':'700'});});}),describe('Task\x2010\x20E\x20family\x20—\x20degradation\x20semantics\x20(TR-10.2)',()=>{it('failed\x20event\x20channel:\x20graph\x20builds,\x20gap\x20records\x20the\x20stream,\x20no\x20edges,\x20no\x20throw',async()=>{const a=fullServiceState();a['events']=new Map([[ORDER_EVENT,[{'events':[],'fail':!![]}]]]);const b=new FakeDataPlane(a),c=await expandTopology(b,{'network':ENTRYPOINT['Mainnet'],'seed':FULL['svc'],'edges':{'eventEdges':['service.order_history']}});expect(c['edges']['filter'](d=>d['schema']==='service.order_history'))['toEqual']([]),expect(c['gaps'])['toContain']('events:'+ORDER_EVENT),expect(c['edges']['some'](d=>d['schema']==='service.order'))['toBe'](!![]),expect(b['batches']['events'])['toBe'](0x1);}),it('page-budget\x20truncation:\x20edges\x20stained\x20truncated\x20+\x20event_pages\x20record\x20+\x20windowed\x20confidence',async()=>{const a=new FakeDataPlane(withEvents([{'events':[orderCreated(ORDER_OLD_A,FULL['buyer'],0x3e8)]},{'events':[orderCreated(FULL['o1'],FULL['buyer'],0x7d0)]}])),b=await expandTopology(a,{'network':ENTRYPOINT['Mainnet'],'seed':FULL['svc'],'budget':{'maxEventPages':0x1},'edges':{'eventEdges':['service.order_history']}}),c=b['edges']['filter'](f=>f['schema']==='service.order_history');expect(c['map'](f=>f['to']))['toEqual']([FULL['o1']]),expect(c['every'](f=>f['truncated']===!![]))['toBe'](!![]);const d=b['truncations']['find'](e=>e['schema']==='service.order_history');expect(d)['toMatchObject']({'nodeId':FULL['svc']['toLowerCase'](),'reason':'event_pages','limit':0x1}),expect(b['budgetExhausted']['eventPages'])['toBe'](!![]),expect(pathConfidence({'graph':b,'observer':FULL['svc'],'role':'neutral','visibleNodes':new Set(),'visibleEdges':[],'edgeById':new Map(),'maskedNodes':new Set()},[{'schema':'service.order_history','from':FULL['svc'],'retention':'event_full','truncated':!![]}])['confidence'])['toBe']('windowed');});}),describe('Task\x2010\x20E\x20family\x20—\x20opt-in\x20discipline',()=>{it('events\x20stay\x20OFF\x20by\x20default\x20even\x20when\x20stream\x20data\x20exists',async()=>{const a=new FakeDataPlane(withEvents([{'events':[orderCreated(ORDER_OLD_A,FULL['buyer'],0x3e8)]}])),b=await expandTopology(a,{'network':ENTRYPOINT['Mainnet'],'seed':FULL['svc'],'edges':{}});expect(a['batches']['events'])['toBe'](0x0),expect(b['edges']['filter'](c=>c['family']==='E'))['toEqual']([]);}),it('eventEdges\x20are\x20independent\x20of\x20the\x20schemas\x20whitelist\x20(channel\x20D,\x20like\x20channel\x20B)',async()=>{const a=new FakeDataPlane(withEvents([{'events':[orderCreated(ORDER_OLD_A,FULL['buyer'],0x3e8)]}])),b=await expandTopology(a,{'network':ENTRYPOINT['Mainnet'],'seed':FULL['svc'],'edges':{'schemas':['service.order'],'eventEdges':['service.order_history']}});expect(a['batches']['events'])['toBe'](0x1),expect(b['edges']['some'](c=>c['schema']==='service.order_history'))['toBe'](!![]);});});
@@ -1,4 +0,0 @@
1
- import type { DataPlane, ExpandOptions, TopologyGraph } from "./types.js";
2
- import { type CompletionResult } from "./order-status.js";
3
- export declare function expandTopology(plane: DataPlane, opts: ExpandOptions): Promise<TopologyGraph>;
4
- export declare function orderCompletionInGraph(graph: TopologyGraph, orderId: string): CompletionResult;
@@ -1,28 +0,0 @@
1
- import type { Finding } from "./types.js";
2
- export type OpenQuestionKind = "verification" | "data_gap" | "coverage";
3
- export interface OpenQuestion {
4
- id: string;
5
- kind: OpenQuestionKind;
6
- question: string;
7
- resolves_with: string[];
8
- source: string;
9
- }
10
- export interface ExplorationBlock {
11
- open_questions: OpenQuestion[];
12
- }
13
- export interface ExplorationContext {
14
- truncations: ReadonlyArray<{
15
- nodeId: string;
16
- schema: string;
17
- observed: number;
18
- limit: number;
19
- }>;
20
- budgetExhausted: {
21
- nodes?: boolean;
22
- depth?: boolean;
23
- rpcs?: boolean;
24
- eventPages?: boolean;
25
- };
26
- dataGaps: ReadonlyArray<string>;
27
- }
28
- export declare function projectExploration(findings: ReadonlyArray<Finding>, ctx: ExplorationContext): ExplorationBlock;
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- import{describe,expect,it}from'vitest';import{projectExploration}from'./exploration.js';function finding(a){return{'id':'T1:0xa#0','kind':'risk','severity':'high','title':'Guard\x20relies\x20on\x20sub-guards','path':['0xguard'],'confidence':'exact','roles':['buyer'],'detail':'d','suggestion':'s',...a};}const EMPTY_CTX={'truncations':[],'budgetExhausted':{},'dataGaps':[]};describe('projectExploration\x20—\x20verification\x20leads',()=>{it('groups\x20undecided\x20gain\x20paths\x20per\x20finding\x20with\x20the\x20disclosure\x20duty\x20as\x20the\x20question',()=>{const a=finding({'id':'ALC1:0xsvc#0','title':'Guard\x20relies\x20on\x20sub-guards\x20—\x20their\x20constraints\x20are\x20NOT\x20credited','path':['0xsvc','0xguard'],'objects':['0xsub1'],'exposure':{'lossParties':[{'role':'buyer','basis':'b'}],'gainPaths':[{'role':'neutral','path':'p1','viability':'viable','gate':'decided'},{'role':'neutral','path':'p2','viability':'unverifiable','gate':'Duty\x20one.'},{'role':'neutral','path':'p3','viability':'unverifiable','gate':'Duty\x20two.'}],'verdict':'pending-disclosure'}}),{open_questions:b}=projectExploration([a],EMPTY_CTX);expect(b)['toHaveLength'](0x1),expect(b[0x0])['toMatchObject']({'id':'X1','kind':'verification','source':'ALC1:0xsvc#0'}),expect(b[0x0]['question'])['toContain']('Settle\x20the\x20undecided\x20exposure\x20of\x20\x22Guard\x20relies\x20on\x20sub-guards'),expect(b[0x0]['question'])['toContain']('Duty\x20one.'),expect(b[0x0]['question'])['toContain']('Duty\x20two.'),expect(b[0x0]['resolves_with'])['toEqual'](['0xsvc','0xguard','0xsub1']);}),it('emits\x20nothing\x20for\x20findings\x20without\x20exposure\x20or\x20without\x20undecided\x20paths',()=>{const a=finding({}),b=finding({'exposure':{'lossParties':[{'role':'buyer','basis':'b'}],'gainPaths':[{'role':'neutral','path':'p','viability':'blocked','gate':'g'}],'verdict':'downgraded','baseSeverity':'high'}});expect(projectExploration([a,b],EMPTY_CTX)['open_questions'])['toHaveLength'](0x0);});}),describe('projectExploration\x20—\x20coverage\x20leads',()=>{it('turns\x20window\x20truncations\x20into\x20lower-bound\x20questions\x20with\x20the\x20node\x20as\x20the\x20handle',()=>{const {open_questions:a}=projectExploration([],{...EMPTY_CTX,'truncations':[{'nodeId':'0xn1','schema':'treasury.record','observed':0x1450,'limit':0x1450}]});expect(a)['toHaveLength'](0x1),expect(a[0x0]['kind'])['toBe']('coverage'),expect(a[0x0]['source'])['toBe']('truncation'),expect(a[0x0]['question'])['toContain']('treasury.record\x20at\x200xn1'),expect(a[0x0]['question'])['toContain']('lower\x20bounds'),expect(a[0x0]['resolves_with'])['toEqual'](['0xn1']);}),it('combines\x20exhausted\x20budgets\x20into\x20ONE\x20posture\x20question',()=>{const {open_questions:a}=projectExploration([],{...EMPTY_CTX,'budgetExhausted':{'nodes':!![],'depth':!![]}});expect(a)['toHaveLength'](0x1),expect(a[0x0]['kind'])['toBe']('coverage'),expect(a[0x0]['source'])['toBe']('budget'),expect(a[0x0]['question'])['toContain']('node/depth\x20budget'),expect(a[0x0]['resolves_with'])['toEqual']([]);});}),describe('projectExploration\x20—\x20data-gap\x20leads\x20and\x20ordering',()=>{it('carries\x20fetch\x20gaps\x20verbatim\x20and\x20extracts\x20embedded\x20addresses\x20as\x20handles',()=>{const {open_questions:a}=projectExploration([],{...EMPTY_CTX,'dataGaps':['Evaluation\x20projection\x20failed\x20for\x200xAbC0000000000000000000000000000000000001\x20(non-blocking)']});expect(a)['toHaveLength'](0x1),expect(a[0x0]['kind'])['toBe']('data_gap'),expect(a[0x0]['source'])['toBe']('data_gap'),expect(a[0x0]['question'])['toContain']('Evaluation\x20projection\x20failed'),expect(a[0x0]['resolves_with'])['toEqual'](['0xabc0000000000000000000000000000000000001']);}),it('orders\x20verification\x20before\x20coverage\x20before\x20data\x20gaps\x20with\x20stable\x20ids',()=>{const a=finding({'exposure':{'lossParties':[],'gainPaths':[{'role':'neutral','path':'p','viability':'unverifiable','gate':'Duty.'}],'verdict':'pending-disclosure'}}),{open_questions:b}=projectExploration([a],{'truncations':[{'nodeId':'0xn','schema':'s','observed':0x1,'limit':0x2}],'budgetExhausted':{'rpcs':!![]},'dataGaps':['graph:\x20node\x20fetch\x20failed']});expect(b['map'](c=>c['kind']))['toEqual'](['verification','coverage','coverage','data_gap']),expect(b['map'](c=>c['id']))['toEqual'](['X1','X2','X3','X4']);}),it('returns\x20an\x20empty\x20block\x20for\x20a\x20fully\x20settled\x20payload',()=>{expect(projectExploration([],EMPTY_CTX)['open_questions'])['toEqual']([]);});});
@@ -1,18 +0,0 @@
1
- import type { ExposureParty, FindingExposure, GainPath, GainPathViability, FindingSeverity, ViewerRole } from "./types.js";
2
- export { resolveViability, factRef, parseFactRef } from "../../config/exposure.js";
3
- export type { ExposureFragment, ExposureParty, ExposureVerdict, FindingExposure, GainPath, GainPathViability, } from "../../config/exposure.js";
4
- export declare const EXPOSURE_ROLES: {
5
- buyer: ViewerRole;
6
- merchant: ViewerRole;
7
- supplier: ViewerRole;
8
- collaborator: ViewerRole;
9
- arbitrator: ViewerRole;
10
- system: ViewerRole;
11
- neutral: ViewerRole;
12
- };
13
- export declare function applyExposureGate(severity: FindingSeverity, exposure: Omit<FindingExposure, "verdict" | "baseSeverity">): {
14
- severity: FindingSeverity;
15
- exposure: FindingExposure;
16
- };
17
- export declare function lossParty(role: ViewerRole, basis: string): ExposureParty;
18
- export declare function gainPath(role: ViewerRole, path: string, viability: GainPathViability, gate: string): GainPath;
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- import{describe,expect,it}from'vitest';import{applyExposureGate,gainPath,lossParty}from'./exposure.js';import{analyzeRewardClaimGuard}from'../../knowledge/recipient-constraint.js';describe('applyExposureGate',()=>{it('downgrades\x20to\x20info\x20when\x20every\x20gain\x20path\x20is\x20blocked',()=>{const {severity:a,exposure:b}=applyExposureGate('critical',{'lossParties':[lossParty('merchant','pool\x20funder')],'gainPaths':[gainPath('neutral','redirect','blocked','entity-pinned'),gainPath('neutral','re-entry','blocked','one-shot\x20drain')]});expect(a)['toBe']('info'),expect(b['verdict'])['toBe']('downgraded'),expect(b['baseSeverity'])['toBe']('critical');}),it('keeps\x20severity\x20when\x20any\x20path\x20is\x20viable\x20or\x20conditional',()=>{const a=applyExposureGate('high',{'lossParties':[lossParty('buyer','escrow')],'gainPaths':[gainPath('neutral','steal','blocked','bound'),gainPath('merchant','defund','viable','own\x20permission')]});expect(a['severity'])['toBe']('high'),expect(a['exposure']['verdict'])['toBe']('confirmed');const b=applyExposureGate('medium',{'lossParties':[lossParty('buyer','escrow')],'gainPaths':[gainPath('supplier','cross-settle','conditional','needs\x20own\x20order')]});expect(b['severity'])['toBe']('medium'),expect(b['exposure']['verdict'])['toBe']('confirmed');}),it('stamps\x20pending-disclosure\x20when\x20undecided\x20paths\x20exist\x20and\x20none\x20are\x20executable',()=>{const {severity:a,exposure:b}=applyExposureGate('critical',{'lossParties':[lossParty('merchant','treasury')],'gainPaths':[gainPath('neutral','release','unverifiable','guard\x20predicate\x20outside\x20evidence')]});expect(a)['toBe']('critical'),expect(b['verdict'])['toBe']('pending-disclosure');}),it('never\x20downgrades\x20shortfall\x20findings\x20with\x20no\x20gain\x20path',()=>{const {severity:a,exposure:b}=applyExposureGate('high',{'lossParties':[lossParty('supplier','payout\x20stranded')],'gainPaths':[]});expect(a)['toBe']('high'),expect(b['verdict'])['toBe']('confirmed');});});const GUARD_ADDR='0x::guard',NODE={'type':'logic_and','nodes':[]};function tableEntry(a,b,c,d){return{'identifier':a,'value_type':b,...c!==undefined?{'value':c}:{},...d!==undefined?{'b_submission':d}:{}};}describe('analyzeRewardClaimGuard',()=>{it('returns\x20unverifiable\x20when\x20the\x20guard\x20def\x20is\x20not\x20fetched',()=>{const b=analyzeRewardClaimGuard({'entry_index':0x0,'guard':GUARD_ADDR,'recipient':{'GuardIdentifier':0x0}});expect(b['viability'])['toBe']('unverifiable'),expect(b['guard_resolved'])['toBe'](![]);}),it('entity\x20recipient\x20is\x20blocked\x20even\x20with\x20an\x20empty\x20guard',()=>{const b=analyzeRewardClaimGuard({'entry_index':0x0,'guard':GUARD_ADDR,'recipient':{'Entity':'0xabc'},'guard_def':{'table':[],'root':NODE}});expect(b['viability'])['toBe']('blocked'),expect(b['recipient_kind'])['toBe']('entity');}),it('signer\x20recipient\x20is\x20viable\x20without\x20a\x20caller\x20constraint',()=>{const b=analyzeRewardClaimGuard({'entry_index':0x0,'guard':GUARD_ADDR,'recipient':{'Signer':!![]},'guard_def':{'table':[],'root':NODE}});expect(b['viability'])['toBe']('viable');}),it('submission\x20slot\x20never\x20consumed\x20by\x20the\x20guard\x20is\x20viable',()=>{const b=analyzeRewardClaimGuard({'entry_index':0x0,'guard':GUARD_ADDR,'recipient':{'GuardIdentifier':0x3},'guard_def':{'table':[tableEntry(0x3,0x0,undefined,!![])],'root':{'type':'logic_equal','nodeLeft':{'type':'context','context':'Clock'},'nodeRight':{'type':'context','context':'Clock'}}}});expect(b['viability'])['toBe']('viable'),expect(b['recipient_slot_usages'])['toBe'](0x0);}),it('submission\x20slot\x20consumed\x20without\x20a\x20recognized\x20constraint\x20is\x20conditional',()=>{const b=analyzeRewardClaimGuard({'entry_index':0x0,'guard':GUARD_ADDR,'recipient':{'guard_identifier':0x3},'guard_def':{'table':[tableEntry(0x3,0x0,undefined,!![])],'root':{'type':'query','query':0x61b,'object':{'identifier':0x3}}}});expect(b['viability'])['toBe']('conditional'),expect(b['recipient_slot_usages'])['toBe'](0x1);});});
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- import{describe,expect,it}from'vitest';import{extractObjectEdges,walkDeepAddrs}from'./extract.js';function addr(a){return'0x'+a['padEnd'](0x40,'0');}const G1=addr('a1'),G2=addr('a2'),G3=addr('a3'),G4=addr('a4'),G5=addr('a5');describe('walkDeepAddrs\x20—\x20form\x201:\x20vector<struct>\x20→\x20scalar\x20address',()=>{it('reads\x20every\x20struct\x20row\x20and\x20exposes\x20the\x20row\x20as\x20payload\x20context',()=>{const a={'guards':[{'guard':G1,'mode':0x1},{'guard':G2,'mode':0x2}]},b=walkDeepAddrs(a,['guards'],'guard');expect(b['map'](c=>c['addr']))['toEqual']([G1,G2]),expect(b[0x0]['leaf']['mode'])['toBe'](0x1),expect(b[0x0]['rows'])['toHaveLength'](0x1),expect(b[0x0]['rows'][0x0])['toBe'](a['guards'][0x0]);});}),describe('walkDeepAddrs\x20—\x20form\x202:\x20vector<struct>\x20→\x20vector<struct>\x20→\x20address,\x20multi-schema\x20fanout',()=>{const a={'policies':[{'name':'default','write_guard':[{'guard':G1}],'quote_guard':G2},{'name':'strict','write_guard':[{'guard':G3},{'guard':G4}],'quote_guard':G5}]};it('walks\x20two\x20nested\x20vector\x20levels\x20(policies[].write_guard[].guard)',()=>{const b=walkDeepAddrs(a,['policies','write_guard'],'guard');expect(b['map'](c=>c['addr']))['toEqual']([G1,G3,G4]),expect(b[0x0]['rows'])['toHaveLength'](0x2),expect(b[0x0]['rows'][0x0]['name'])['toBe']('default'),expect(b[0x1]['rows'][0x0]['name'])['toBe']('strict');}),it('lets\x20the\x20same\x20row\x20fan\x20out\x20to\x20a\x20sibling\x20field\x20(policies[].quote_guard)',()=>{const b=walkDeepAddrs(a,['policies'],'quote_guard');expect(b['map'](c=>c['addr']))['toEqual']([G2,G5]),expect(b[0x1]['rows'][0x0]['name'])['toBe']('strict');});}),describe('walkDeepAddrs\x20—\x20form\x203:\x20vector<struct>\x20→\x20vector<address|struct>',()=>{it('accepts\x20bare\x20addresses\x20and\x20address-carrying\x20structs\x20in\x20one\x20leaf\x20vector',()=>{const a={'guard':[{'guard':addr('b0'),'relies':[G1,G2]},{'guard':addr('b1'),'relies':[{'guard':G3},{'address':G4}]}]},b=walkDeepAddrs(a,['guard','relies'],'guard');expect(b['map'](c=>c['addr']))['toEqual']([G1,G2,G3,G4]),expect(b[0x0]['leaf'])['toEqual']({}),expect(b[0x0]['rows'][0x0]['guard'])['toBe'](addr('b0')),expect(b[0x2]['leaf'])['toEqual']({'guard':G3});});}),describe('walkDeepAddrs\x20—\x20form\x204:\x20historical\x20layout\x20compatibility',()=>{it('accepts\x20a\x20bare\x20struct\x20where\x20a\x20vector<struct>\x20is\x20current',()=>{const a={'policies':{'name':'solo','write_guard':[{'guard':G1}]}},b=walkDeepAddrs(a,['policies','write_guard'],'guard');expect(b['map'](c=>c['addr']))['toEqual']([G1]),expect(b[0x0]['rows']['map'](c=>c['name']))['toEqual'](['solo',undefined]);}),it('accepts\x20a\x20scalar\x20struct\x20at\x20the\x20leaf\x20container\x20slot',()=>{const a={'policies':[{'name':'only','write_guard':{'guard':G2}}]},b=walkDeepAddrs(a,['policies','write_guard'],'guard');expect(b['map'](c=>c['addr']))['toEqual']([G2]);}),it('recognizes\x20the\x20historical\x20address/address-who\x20member\x20aliases',()=>{const a={'refs':[{'address':G3},{'who':G4},{'guard':G5}]},b=walkDeepAddrs(a,['refs'],'guard');expect(b['map'](c=>c['addr']))['toEqual']([G3,G4,G5]);});}),describe('walkDeepAddrs\x20—\x20form\x205:\x20empty\x20values\x20and\x20malformed\x20entries',()=>{it('returns\x20nothing\x20for\x20missing\x20paths,\x20null\x20roots\x20or\x20empty\x20vectors',()=>{expect(walkDeepAddrs({},['policies','write_guard'],'guard'))['toEqual']([]),expect(walkDeepAddrs({'policies':null},['policies'],'guard'))['toEqual']([]),expect(walkDeepAddrs({'policies':[]},['policies'],'guard'))['toEqual']([]),expect(walkDeepAddrs({'policies':[{'write_guard':[]}]},['policies','write_guard'],'guard'))['toEqual']([]);}),it('skips\x20garbage\x20without\x20throwing\x20and\x20keeps\x20the\x20valid\x20leaves',()=>{const a={'policies':[null,'garbage',0x2a,{'write_guard':[null,{'guard':'0xnotanaddress'},{'guard':G1}]},{'write_guard':['0x123',G2,{'guard':G3,'extra':!![]}]},{'write_guard':[{'guard':undefined}]}]};let b;expect(()=>{b=walkDeepAddrs(a,['policies','write_guard'],'guard');})['not']['toThrow'](),expect(b['map'](c=>c['addr']))['toEqual']([G1,G2,G3]),expect(b[0x2]['leaf']['extra'])['toBe'](!![]);}),it('preserves\x20multiplicity\x20when\x20the\x20same\x20address\x20appears\x20under\x20different\x20rows',()=>{const a={'policies':[{'name':'default','write_guard':[{'guard':G1}]},{'name':'strict','write_guard':[{'guard':G1}]}]},b=walkDeepAddrs(a,['policies','write_guard'],'guard');expect(b)['toHaveLength'](0x2),expect(b[0x0]['rows'][0x0]['name'])['toBe']('default'),expect(b[0x1]['rows'][0x0]['name'])['toBe']('strict');});}),describe('extractObjectEdges\x20—\x20registry\x20integration\x20of\x20the\x20unified\x20walk',()=>{it('still\x20extracts\x20structFields\x20demand.guard\x20from\x20struct\x20and\x20bare-address\x20rows',()=>{const a={'type_raw':'0x2::demand::Demand','data':{'guards':[{'guard':G1,'service_identifier':0x9},G2]}},b=extractObjectEdges('Demand',a),c=b['find'](d=>d['schemaId']==='demand.guard');expect(c?.['refs']['map'](d=>d['to']))['toEqual']([G1,G2]);});});
@@ -1,29 +0,0 @@
1
- import { type EdgeSchema, type EventRead } from "./edge-schema.js";
2
- import type { RawObject, TableItem, TopoEdgePayload } from "./types.js";
3
- export declare function normAddr(v: unknown): string | undefined;
4
- export declare function rootOf(raw: RawObject | undefined): Record<string, unknown>;
5
- export interface DeepLeaf {
6
- addr: string;
7
- leaf: Record<string, unknown>;
8
- rows: Record<string, unknown>[];
9
- }
10
- export declare function walkDeepAddrs(root: Record<string, unknown>, segments: string[], field: string): DeepLeaf[];
11
- export interface RawRef {
12
- to: string;
13
- from?: string;
14
- payload?: TopoEdgePayload;
15
- key?: string;
16
- }
17
- export interface ExtractedEdges {
18
- schemaId: string;
19
- refs: RawRef[];
20
- }
21
- export declare function wfNodeId(machine: string, name: string): string;
22
- export declare const REVERSE_GROUP_WILDCARD = "*";
23
- export declare function extractReverseRefs(parent: string, field: unknown): ExtractedEdges[];
24
- export declare function extractTableRefs(rowType: string, sourceId: string, items: TableItem[]): ExtractedEdges[];
25
- export declare function extractEventRefs(read: EventRead, sourceId: string, events: unknown[]): RawRef[];
26
- export declare function inferObjectType(addr: string): string | undefined;
27
- export declare function extractCoinType(typeRaw: unknown): string | undefined;
28
- export declare function extractObjectEdges(objectType: string, raw: RawObject): ExtractedEdges[];
29
- export declare function schemaById(id: string): EdgeSchema | undefined;
@@ -1,99 +0,0 @@
1
- import type { GraphServiceEvaluation } from "../../evaluation/builtins/graph-service.js";
2
- import { type FacetId } from "../../evaluation/facets/catalog.js";
3
- import type { GraphEvaluationFacts } from "./facts.js";
4
- import type { Finding, InterestPayload, TopologyGraph, Viewport } from "./types.js";
5
- export type FacetState = "present" | "empty" | "gap";
6
- export interface FacetMoney {
7
- raw: string;
8
- coin_type?: string;
9
- display?: string;
10
- symbol?: string;
11
- decimals?: number;
12
- precision_known: boolean;
13
- tip?: string;
14
- }
15
- export interface FacetAmount {
16
- key: string;
17
- label: string;
18
- money: FacetMoney;
19
- }
20
- export interface FacetSignal {
21
- key: string;
22
- label: string;
23
- state: "configured" | "missing" | "unknown";
24
- detail?: string;
25
- gloss?: string;
26
- }
27
- export interface FacetScoreRef {
28
- evaluation: "trust" | "risk";
29
- rule_id: string;
30
- }
31
- export interface FacetGraphRef {
32
- id: string;
33
- label: string;
34
- full?: string;
35
- role?: string;
36
- }
37
- export interface FacetGraph {
38
- kind: "workflow" | "fund_flow" | "supply_chain";
39
- summary: string;
40
- refs: FacetGraphRef[];
41
- }
42
- export interface FacetResult {
43
- id: FacetId;
44
- label: string;
45
- question: string;
46
- state: FacetState;
47
- scores?: FacetScoreRef[];
48
- signals?: FacetSignal[];
49
- amounts?: FacetAmount[];
50
- graph?: FacetGraph;
51
- evidence: string[];
52
- gap_reason?: string;
53
- threshold?: number;
54
- }
55
- export interface FacetsBlock {
56
- profile: {
57
- role?: string;
58
- industry?: string;
59
- persona_applied: boolean;
60
- sources: string[];
61
- };
62
- items: FacetResult[];
63
- }
64
- export interface FacetProjectionProfile {
65
- role?: string;
66
- industry?: string;
67
- persona_applied: boolean;
68
- sources: string[];
69
- facets: Record<string, {
70
- visible: boolean;
71
- order: number;
72
- weight?: number;
73
- threshold?: number;
74
- }>;
75
- }
76
- export interface FacetWorkflowShape {
77
- machine: string;
78
- transitions: Array<{
79
- node: string;
80
- prev_node: string;
81
- forward?: string;
82
- guard: string | null;
83
- named_operator: string | null;
84
- permission_index: unknown;
85
- }>;
86
- terminal_names: string[];
87
- }
88
- export interface ProjectFacetsInput {
89
- graph: TopologyGraph;
90
- viewport: Viewport;
91
- target: string;
92
- facts: GraphEvaluationFacts;
93
- evaluation: GraphServiceEvaluation;
94
- workflows: FacetWorkflowShape[];
95
- profile: FacetProjectionProfile;
96
- roleInterest?: InterestPayload;
97
- findings?: Finding[];
98
- }
99
- export declare function projectFacets(input: ProjectFacetsInput): FacetsBlock;
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- import{describe,expect,it}from'vitest';import{ENTRYPOINT}from'@wowok/wowok';import{FakeDataPlane}from'./dataplane.js';import{expandTopology}from'./expand.js';import{FULL,GAP,T_USDT,fullServiceState,gapServiceState,truncatedServiceState}from'./fixtures.js';import{buildViewport}from'./viewport.js';import{runAnalyzers}from'./analyze.js';import{workflowSubgraphFromEdges}from'./order-status.js';import{EVALUATION_SERVICE_INTENTS,resolveExpansionStrategy,withEvaluationBundle}from'./strategy.js';import{projectEvaluationFacts}from'./facts.js';import{projectFacets}from'./facet-projection.js';import{FACET_IDS}from'../../evaluation/facets/catalog.js';import{evaluateGraphServiceFacts,registerGraphServiceEvaluations}from'../../evaluation/builtins/graph-service.js';import{resolveFacetProfile}from'../../persona/facet-profile.js';const TYPE_TAG_NODE='0x2::machine::Node<0x2::wow::WOW>';async function assemble(a,b){registerGraphServiceEvaluations();const c=withEvaluationBundle(resolveExpansionStrategy({'intents':[...EVALUATION_SERVICE_INTENTS]})),d=await expandTopology(new FakeDataPlane(a),{'network':ENTRYPOINT['Mainnet'],'seed':b,'edges':c['edges'],'budget':c['budget']}),e=buildViewport(d,b,'neutral'),f=projectEvaluationFacts(e,b,runAnalyzers(e)),g=await evaluateGraphServiceFacts(f),h=[...new Set(d['edges']['filter'](j=>j['schema']==='wf.transition')['flatMap'](j=>[j['from'],j['to']])['map'](j=>{const k=j['indexOf']('::node::');return k>0x0?j['slice'](0x0,k):'';})['filter'](Boolean))]['sort'](),i=h['map'](j=>{const k=workflowSubgraphFromEdges(d['edges'],j);return{'machine':j,'transitions':k['transitions']['map'](l=>({'node':l['node'],'prev_node':l['prevNode'],...l['forward']!==undefined?{'forward':l['forward']}:{},'guard':l['guard']??null,'named_operator':l['namedOperator']??null,'permission_index':l['permissionIndex']??null})),'terminal_names':[...k['terminalNames']]['sort']()};});return{'graph':d,'viewport':e,'facts':f,'evaluation':g,'workflows':i};}function project(b,c,d=resolveFacetProfile(),e,f){return projectFacets({'graph':b['graph'],'viewport':b['viewport'],'target':c,'facts':b['facts'],'evaluation':b['evaluation'],'workflows':f??b['workflows'],'profile':{'role':d['role'],'industry':d['industry'],'persona_applied':d['personaApplied'],'sources':d['sources'],'facets':d['facets']},...e?{'roleInterest':e}:{}});}const itemOf=(a,b)=>a['items']['find'](c=>c['id']===b);describe('facet\x20projection\x20—\x20fully\x20hooked\x20shop',()=>{it('emits\x20nine\x20catalog\x20facets\x20in\x20order,\x20my_stakes\x20gated\x20out\x20without\x20an\x20observer',async()=>{const b=await assemble(fullServiceState(),FULL['svc']),c=project(b,FULL['svc']);expect(c['items']['map'](d=>d['id']))['toEqual'](FACET_IDS['filter'](d=>d!=='my_stakes')),expect(c['profile']['sources'])['toContain']('catalog\x20defaults'),expect(c['profile']['persona_applied'])['toBe'](![]);}),it('business\x20facets\x20carry\x20no\x20score\x20refs\x20at\x20all',async()=>{const b=await assemble(fullServiceState(),FULL['svc']),c=project(b,FULL['svc']);for(const d of['offering_price','fund_flow','supply_chain']){expect(itemOf(c,d)?.['scores'])['toBeUndefined']();}expect(itemOf(c,'fund_safety')?.['scores']?.['map'](e=>e['rule_id'])['sort']())['toEqual'](['risk_fund','trust_fund_safety']['sort']()),expect(itemOf(c,'workflow')?.['scores'])['toEqual']([{'evaluation':'risk','rule_id':'risk_workflow'}]),expect(itemOf(c,'permission')?.['scores'])['toEqual']([{'evaluation':'risk','rule_id':'risk_behavior'}]);for(const e of itemOf(c,'fund_safety')['scores']){const f=e['evaluation']==='trust'?b['evaluation']['trust']:b['evaluation']['risk'];expect(f['breakdown']['some'](g=>g['rule_id']===e['rule_id']))['toBe'](!![]);}}),it('projects\x20fund_safety\x20raw\x20amounts\x20with\x20coin\x20types\x20and\x20placeholder\x20evidence',async()=>{const b=await assemble(fullServiceState(),FULL['svc']),c=itemOf(project(b,FULL['svc']),'fund_safety');expect(c['state'])['toBe']('present');const d=Object['fromEntries']((c['amounts']??[])['map'](e=>[e['key'],e]));expect(d['fund']?.['money']['raw'])['toBe']('0'),expect(d['largest']?.['money']['raw'])['toBe']('1000000'),expect(d['ceiling']?.['money']['raw'])['toBe']('3000000');for(const e of Object['values'](d))expect(e['money']['coin_type'])['toBe'](T_USDT);expect(d['fund']?.['money']['precision_known'])['toBe'](![]),expect(d['fund']?.['money']['display'])['toBeUndefined'](),expect(c['evidence']['some'](f=>f['includes']('{largest}')&&f['includes']('{ceiling}')))['toBe'](!![]);}),it('surfaces\x20the\x20live\x20buy\x20ceiling\x20+\x20blocked\x20listings\x20only\x20when\x20the\x20wall\x20is\x20live',async()=>{const b=fullServiceState(),c=b['objects']['get'](FULL['svc']['toLowerCase']());c['data']['compensation_fund']='1000000',c['data']['sales']=[{'name':'top','price':'900000','suspension':![]},{'name':'low','price':'100000','suspension':![]}];const d=await assemble(b,FULL['svc']),e=itemOf(project(d,FULL['svc']),'fund_safety'),f=Object['fromEntries']((e['amounts']??[])['map'](j=>[j['key'],j]));expect(f['cap']?.['money']['raw'])['toBe']('333333');const g=e['evidence']['find'](j=>j['includes']('Live\x20buy\x20ceiling'));expect(g)['toContain']('{cap}'),expect(g)['toContain']('top');const h=await assemble(fullServiceState(),FULL['svc']),i=itemOf(project(h,FULL['svc']),'fund_safety');expect(Object['fromEntries']((i['amounts']??[])['map'](j=>[j['key'],j]))['cap'])['toBeUndefined'](),expect(i['evidence']['some'](j=>j['includes']('Live\x20buy\x20ceiling')))['toBe'](![]);}),it('projects\x20offering_price\x20from\x20the\x20seed\x20raw\x20with\x20published/active\x20signals',async()=>{const b=await assemble(fullServiceState(),FULL['svc']),c=itemOf(project(b,FULL['svc']),'offering_price');expect(c['state'])['toBe']('present'),expect(c['amounts'])['toHaveLength'](0x1),expect(c['amounts'][0x0]['money']['raw'])['toBe']('1000000'),expect(c['amounts'][0x0]['money']['coin_type'])['toBe'](T_USDT);const d=Object['fromEntries']((c['signals']??[])['map'](e=>[e['key'],e]));expect(d['published']['state'])['toBe']('configured'),expect(d['active']['state'])['toBe']('configured');}),it('projects\x20arbitration\x20binding/roster/fee/active\x20signals',async()=>{const b=await assemble(fullServiceState(),FULL['svc']),c=itemOf(project(b,FULL['svc']),'arbitration'),d=Object['fromEntries']((c['signals']??[])['map'](e=>[e['key'],e['state']]));expect(d)['toMatchObject']({'arbitration_binding':'configured','voting_roster':'configured','arbitration_fee':'configured','arbitration_active':'configured'});for(const e of c['signals']??[]){expect(e['gloss']?.['length'])['toBeGreaterThan'](0x14);}}),it('emits\x20coverage\x20slot\x20glosses\x20+\x20the\x20coverage\x20vocabulary',async()=>{const b=await assemble(fullServiceState(),FULL['svc']),{evaluation:c}=b;for(const e of c['coverage']){expect(e['label']['length'])['toBeGreaterThan'](0x2),expect(e['gloss']['length'])['toBeGreaterThan'](0x14);}const d=c['vocabulary'];expect(d['present'])['toMatch'](/present/i),expect(d['empty'])['toMatch'](/verified/i),expect(d['gap'])['toMatch'](/unverifiable|not retrieved|truncated/i),expect(d['unverified']['length'])['toBeGreaterThan'](0x14),expect(d['completeness']['length'])['toBeGreaterThan'](0x14);}),it('projects\x20the\x20workflow\x20graph\x20with\x20resolved\x20machine/node\x20names\x20and\x20no\x20synthetic\x20ids',async()=>{const b=await assemble(fullServiceState(),FULL['svc']),c=itemOf(project(b,FULL['svc']),'workflow');expect(c['state'])['toBe']('present'),expect(c['graph']?.['kind'])['toBe']('workflow');const d=c['graph']['refs']['filter'](f=>f['role']==='workflow\x20node')['map'](f=>f['label']);expect(d)['toEqual'](expect['arrayContaining'](['start','shipping','done'])),expect(c['graph']['refs']['some'](f=>f['role']==='machine'))['toBe'](!![]);const e=[...c['graph']['refs']['map'](f=>f['label']+'\x20'+(f['full']??'')),c['graph']['summary'],...c['evidence']]['join']('\x20');expect(e)['not']['toContain']('::node::'),expect(c['graph']['refs']['filter'](f=>f['role']==='workflow\x20node')['some'](f=>f['label']['startsWith']('0x')))['toBe'](![]);}),it('humanizes\x20Move\x20type-tag\x20node\x20names\x20into\x20Node<WOW>\x20with\x20full\x20kept',async()=>{const b=await assemble(fullServiceState(),FULL['svc']),c=[{'machine':FULL['mac']['toLowerCase'](),'transitions':[{'node':TYPE_TAG_NODE,'prev_node':'start','guard':null,'named_operator':null,'permission_index':null}],'terminal_names':[TYPE_TAG_NODE]}],d=itemOf(project(b,FULL['svc'],undefined,undefined,c),'workflow'),e=d['graph']['refs']['find'](f=>f['label']==='Node<WOW>');expect(e)['toBeDefined'](),expect(e['full'])['toBe'](TYPE_TAG_NODE);}),it('projects\x20fund_flow\x20pools,\x20payment\x20legs,\x20recipients,\x20guards\x20and\x20leg\x20amounts',async()=>{const b=await assemble(fullServiceState(),FULL['svc']),c=itemOf(project(b,FULL['svc']),'fund_flow');expect(c['state'])['toBe']('present');const d=(c['graph']['refs']??[])['reduce']((f,g)=>{return f[g['role']??'']=(f[g['role']??'']??0x0)+0x1,f;},{});expect(d['allocation\x20pool'])['toBe'](0x1),expect(d['payment\x20leg'])['toBe'](0x2),expect(d['recipient'])['toBe'](0x2),expect(d['split\x20guard'])['toBe'](0x1);const e=(c['amounts']??[])['map'](f=>f['money']['raw'])['sort']();expect(e)['toEqual'](['10000','50000','990000']),expect(c['evidence']['some'](f=>f['includes']('{pay_0}')||f['includes']('{pay_')))['toBe'](!![]);}),it('keeps\x20supply_chain\x20empty\x20for\x20the\x20single-shop\x20fixture\x20(own\x20orders\x20excluded)',async()=>{const b=await assemble(fullServiceState(),FULL['svc']),c=itemOf(project(b,FULL['svc']),'supply_chain');expect(c['state'])['toBe']('empty'),expect(c['graph']?.['refs'])['toEqual']([]);}),it('projects\x20permission\x20signals\x20incl.\x20bound\x20group,\x20buy\x20guard\x20and\x20admins',async()=>{const b=await assemble(fullServiceState(),FULL['svc']),c=itemOf(project(b,FULL['svc']),'permission'),d=Object['fromEntries']((c['signals']??[])['map'](e=>[e['key'],e['state']]));expect(d['service_permission'])['toBe']('configured'),expect(d['buy_guard'])['toBe']('configured'),expect(d['admins'])['toBe']('configured');}),it('carries\x20risk\x20finding\x20titles\x20+\x20graph-aware\x20where\x20lines\x20as\x20evidence,\x20never\x20raw\x20ids',async()=>{const b=await assemble(fullServiceState(),FULL['svc']),c=project(b,FULL['svc']),d=c['items']['flatMap'](f=>f['evidence']),e=itemOf(c,'fund_safety')['evidence']['join']('\x20');expect(e)['toContain']('Payout\x20exposure'),expect(e)['not']['toContain']('::node::'),expect(d['some'](f=>/0x[0-9a-f]{40,}/['test'](f)))['toBe'](![]);}),it('projects\x20my_stakes\x20only\x20when\x20role\x20interest\x20is\x20supplied',async()=>{const b=await assemble(fullServiceState(),FULL['svc']);expect(itemOf(project(b,FULL['svc']),'my_stakes'))['toBeUndefined']();const c={'role':'customer','observer':FULL['buyer'],'stakes':[{'object':FULL['svc'],'object_type':'Service','positions':['buyer'],'state':'in_flight','evidence':[]}],'actions':[],'arb_actions':[],'counterparties':[],'risk_finding_ids':[],'summary':'Buyer\x20has\x20one\x20in-flight\x20order\x20at\x20stake.'},d=itemOf(project(b,FULL['svc'],resolveFacetProfile(),c),'my_stakes');expect(d['state'])['toBe']('present'),expect(d['signals'])['toHaveLength'](0x1),expect(d['signals'][0x0]['label'])['toContain']('buyer'),expect(d['evidence']['join']('\x20'))['toContain']('one\x20in-flight\x20order');});}),describe('facet\x20projection\x20—\x20configured-empty\x20shell',()=>{it('marks\x20verified\x20absences\x20empty/missing\x20and\x20the\x20dangling\x20machine\x20a\x20gap',async()=>{const b=await assemble(gapServiceState(),GAP['svc']),c=project(b,GAP['svc']);expect(itemOf(c,'workflow')?.['state'])['toBe']('gap'),expect(itemOf(c,'workflow')?.['gap_reason'])['toBeTruthy'](),expect(itemOf(c,'workflow')?.['graph'])['toBeUndefined'](),expect(itemOf(c,'offering_price')?.['state'])['toBe']('empty'),expect(itemOf(c,'fund_flow')?.['state'])['toBe']('empty'),expect(itemOf(c,'supply_chain')?.['state'])['toBe']('empty');const d=itemOf(c,'arbitration');expect(d['state'])['toBe']('present'),expect(d['signals']['find'](f=>f['key']==='arbitration_binding')?.['state'])['toBe']('missing');const e=itemOf(c,'permission');expect(e['state'])['toBe']('present'),expect(e['signals']['find'](f=>f['key']==='buy_guard')?.['state'])['toBe']('missing'),expect(e['signals']['find'](f=>f['key']==='service_permission')?.['state'])['toBe']('configured');});}),describe('facet\x20projection\x20—\x20truncated\x20order\x20window',()=>{it('exposes\x20fund_safety/fulfillment\x20as\x20gaps\x20with\x20no\x20score\x20refs\x20and\x20a\x20reason',async()=>{const b=await assemble(truncatedServiceState(),FULL['svc']),c=project(b,FULL['svc']);for(const d of['fund_safety','fulfillment']){const e=itemOf(c,d);expect(e['state'])['toBe']('gap'),expect(e['scores']??[])['toEqual']([]),expect(e['gap_reason'])['toBeTruthy']();}expect(itemOf(c,'reputation')?.['state'])['toBe']('present');});}),describe('facet\x20projection\x20—\x20profile\x20lens',()=>{it('orders\x20facets\x20by\x20role\x20emphasis\x20and\x20hides\x20profile-hidden\x20facets',async()=>{const b=await assemble(fullServiceState(),FULL['svc']),c=resolveFacetProfile({'role':'merchant'}),d=project(b,FULL['svc'],c);expect(d['items'][0x0]['id'])['toBe']('fund_flow'),expect(d['profile']['role'])['toBe']('merchant'),expect(d['profile']['sources']['some'](g=>g['startsWith']('role\x20default:merchant')))['toBe'](!![]);const e=resolveFacetProfile({'request':{'fund_safety':{'visible':![]},'reputation':{'order':0x1}}}),f=project(b,FULL['svc'],e);expect(f['items']['some'](g=>g['id']==='fund_safety'))['toBe'](![]),expect(f['items'][0x0]['id'])['toBe']('reputation');});});
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- import{describe,expect,it}from'vitest';import{ENTRYPOINT}from'@wowok/wowok';import{FakeDataPlane}from'./dataplane.js';import{expandTopology}from'./expand.js';import{FULL,GAP,fullServiceState,gapServiceState,truncatedServiceState}from'./fixtures.js';import{buildViewport}from'./viewport.js';import{runAnalyzers}from'./analyze.js';import{EVALUATION_SERVICE_INTENTS,resolveExpansionStrategy,withEvaluationBundle}from'./strategy.js';import{projectEvaluationFacts}from'./facts.js';async function evalFacts(a,b){const c=withEvaluationBundle(resolveExpansionStrategy({'intents':[...EVALUATION_SERVICE_INTENTS]})),d=await expandTopology(new FakeDataPlane(a),{'network':ENTRYPOINT['Mainnet'],'seed':b,'edges':c['edges'],'budget':c['budget']}),e=buildViewport(d,b,'neutral'),f=runAnalyzers(e);return projectEvaluationFacts(e,b,f);}async function evalFactsWithFindings(a,b,c){const d=withEvaluationBundle(resolveExpansionStrategy({'intents':[...EVALUATION_SERVICE_INTENTS]})),e=await expandTopology(new FakeDataPlane(a),{'network':ENTRYPOINT['Mainnet'],'seed':b,'edges':d['edges'],'budget':d['budget']}),f=buildViewport(e,b,'neutral');return projectEvaluationFacts(f,b,c);}const slotOf=(a,b)=>a['slots']['find'](c=>c['slot']===b),factOf=(a,b)=>{const c=a['facts']['find'](d=>d['key']===b);return expect(c,'fact\x20'+b+'\x20must\x20exist')['toBeDefined'](),c;},EMPTY_STATE={'objects':new Map(),'keyedFields':new Map(),'tables':new Map(),'events':new Map()};describe('facts\x20—\x20fully\x20hooked\x20service\x20(TR-13.1)',()=>{it('classifies\x20every\x20required\x20slot\x20present\x20with\x20material\x20facts',async()=>{const a=await evalFacts(fullServiceState(),FULL['svc']);expect(slotOf(a,'service_snapshot')['state'])['toBe']('present'),expect(slotOf(a,'arbitration')['state'])['toBe']('present'),expect(slotOf(a,'reviews')['state'])['toBe']('present'),expect(slotOf(a,'fulfillment_orders')['state'])['toBe']('present'),expect(slotOf(a,'fulfillment_workflow')['state'])['toBe']('present'),expect(slotOf(a,'fund_safety')['state'])['toBe']('present'),expect(slotOf(a,'transparency')['state'])['toBe']('present'),expect(a['completeness'])['toBe'](0x64);const b=factOf(a,'arbitration.binding');expect(b['state'])['toBe']('present'),expect(b['value'])['toMatchObject']([{'id':FULL['arbsvc']['toLowerCase'](),'paused':![],'votingGuards':0x1,'usageGuard':!![]}]),expect(b['provenance']['path'])['toContain']('service.arbitration'),expect(factOf(a,'reviews.votes')['value'])['toMatchObject']({'total':0x2,'like':0x1,'dislike':0x1,'favor':0x1}),expect(factOf(a,'fulfillment.orders')['value'])['toMatchObject']({'observed':0x2,'completed':0x1,'inProgress':0x1,'unknown':0x0,'windowedAmount':'1000000'});const c=factOf(a,'fulfillment.workflow');expect(c['state'])['toBe']('present'),expect(c['value'])['toMatchObject']({'machine':FULL['mac']['toLowerCase'](),'nodes':0x3}),expect(factOf(a,'fund.compensation')['value'])['toMatchObject']({'fund':'0'});const d=factOf(a,'fund.exposure');expect(d['value'])['toMatchObject']({'windowedCount':0x2,'windowedAmount':'1000000','largestAmount':'1000000','neededCeiling':'3000000','coverageMet':![]}),expect(d['findingIds'])['toEqual'](['R2:'+FULL['svc']['toLowerCase']()]),expect(factOf(a,'transparency.profile')['findingIds'])['toEqual'](['R6:'+FULL['svc']['toLowerCase']()]);}),it('reuses\x20analyzer\x20findings\x20by\x20reference\x20in\x20the\x20risk\x20dimensions',async()=>{const a=await evalFacts(fullServiceState(),FULL['svc']),b=factOf(a,'risk_trust.findings');expect(b['state'])['toBe']('present'),expect(b['findingIds']['some'](g=>g['startsWith']('R1:')))['toBe'](!![]);const c=factOf(a,'risk_fund.findings');expect(c['state'])['toBe']('present'),expect(c['findingIds'])['toContain']('R2:'+FULL['svc']['toLowerCase']());const d=factOf(a,'risk_behavior.findings');expect(d['state'])['toBe']('present'),expect(d['findingIds'])['toEqual']([]);const e=factOf(a,'risk_workflow.findings');expect(e['state'])['toBe']('present'),expect(e['evidence'])['toContain']('fully\x20materialized');});}),describe('facts\x20—\x20configured-empty\x20shell\x20merchant\x20(TR-13.1)',()=>{it('scores\x20configured\x20absence\x20as\x20empty\x20and\x20the\x20dangling\x20machine\x20as\x20gap',async()=>{const a=await evalFacts(gapServiceState(),GAP['svc']);expect(slotOf(a,'service_snapshot')['state'])['toBe']('present'),expect(slotOf(a,'arbitration')['state'])['toBe']('empty'),expect(factOf(a,'arbitration.binding')['state'])['toBe']('empty'),expect(slotOf(a,'reviews')['state'])['toBe']('empty'),expect(slotOf(a,'fulfillment_orders')['state'])['toBe']('present'),expect(slotOf(a,'fulfillment_workflow')['state'])['toBe']('gap'),expect(factOf(a,'fulfillment.workflow')['evidence'])['toContain']('fetch\x20gap'),expect(slotOf(a,'fund_safety')['state'])['toBe']('present'),expect(slotOf(a,'transparency')['state'])['toBe']('present'),expect(a['completeness'])['toBe'](0x39),expect(factOf(a,'risk_workflow.findings')['state'])['toBe']('gap'),expect(factOf(a,'risk_workflow.findings')['provenance']['confidence'])['toBe']('windowed'),expect(factOf(a,'risk_trust.findings')['state'])['toBe']('empty');});}),describe('facts\x20—\x20truncated\x20order\x20window\x20(TR-13.1)',()=>{it('marks\x20the\x20truncated\x20window\x20slot\x20gap\x20and\x20cascades\x20into\x20risk_fund',async()=>{const a=await evalFacts(truncatedServiceState(),FULL['svc']);expect(slotOf(a,'fulfillment_orders')['state'])['toBe']('gap');const b=factOf(a,'fulfillment.orders');expect(b['state'])['toBe']('gap'),expect(b['provenance']['window'])['toBeDefined'](),expect(b['value']['observed'])['toBeGreaterThan'](0x0);const c=factOf(a,'risk_fund.findings');expect(c['state'])['toBe']('gap'),expect(c['evidence'])['toContain']('unverifiable'),expect(slotOf(a,'arbitration')['state'])['toBe']('present'),expect(slotOf(a,'fulfillment_workflow')['state'])['toBe']('present'),expect(a['completeness'])['toBe'](0x56);});}),describe('facts\x20—\x20fund\x20listing\x20wall\x20(F-BS-59)',()=>{it('zero\x20fund\x20never\x20walls:\x20the\x20priced\x20listing\x20reads\x20present\x20with\x20walled=false',async()=>{const a=await evalFacts(fullServiceState(),FULL['svc']),b=factOf(a,'fund.listing_wall');expect(b['state'])['toBe']('present'),expect(b['value'])['toMatchObject']({'fund':'0','coverCap':'0','largestListing':'1000000','blockedCount':0x0,'blockedNames':[],'walled':![]}),expect(b['evidence'])['toContain']('No\x20compensation\x20fund');}),it('under-covers\x20the\x20listings\x20priced\x20above\x20fund/3,\x20largest\x20first,\x20ignoring\x20suspended\x20rows',async()=>{const a=fullServiceState(),b=a['objects']['get'](FULL['svc']['toLowerCase']());b['data']['compensation_fund']='1000000',b['data']['sales']=[{'name':'top','price':'900000','suspension':![]},{'name':'low','price':'100000','suspension':![]},{'name':'off','price':'9000000','suspension':!![]}];const c=await evalFacts(a,FULL['svc']),d=factOf(c,'fund.listing_wall');expect(d['state'])['toBe']('present'),expect(d['value'])['toMatchObject']({'fund':'1000000','coverCap':'333333','largestListing':'900000','blockedCount':0x1,'blockedNames':['top'],'walled':!![]}),expect(d['evidence'])['toContain']('top'),expect(d['evidence'])['toContain']('UNDER-COVERED');}),it('an\x20empty\x20catalog\x20reads\x20verified-absent\x20(no\x20listing\x20can\x20be\x20walled)',async()=>{const a=await evalFacts(gapServiceState(),GAP['svc']),b=factOf(a,'fund.listing_wall');expect(b['state'])['toBe']('empty'),expect(b['evidence'])['toContain']('No\x20sellable\x20priced\x20listing');});}),describe('facts\x20—\x20completeness\x20(TR-13.2)',()=>{it('is\x20an\x20integer\x200..100\x20consistent\x20with\x20present/required\x20on\x20every\x20fixture',async()=>{const a=await Promise['all']([evalFacts(fullServiceState(),FULL['svc']),evalFacts(gapServiceState(),GAP['svc']),evalFacts(truncatedServiceState(),FULL['svc'])]);for(const b of a){expect(Number['isInteger'](b['completeness']))['toBe'](!![]),expect(b['completeness'])['toBeGreaterThanOrEqual'](0x0),expect(b['completeness'])['toBeLessThanOrEqual'](0x64);const c=b['slots']['filter'](e=>e['required']&&e['state']==='present')['length'],d=b['slots']['filter'](e=>e['required'])['length'];expect(b['completeness'])['toBe'](Math['round'](c/d*0x64));for(const e of b['facts']){expect(e['provenance']['path']['length'])['toBeGreaterThan'](0x0),expect(e['provenance']['retention'])['toBeDefined'](),expect(e['evidence']['length'])['toBeGreaterThan'](0x0);if(e['dimension']['startsWith']('risk_'))continue;const g=e['dimension']==='fulfillment'?e['key']['includes']('workflow')?'fulfillment_workflow':'fulfillment_orders':e['dimension'];expect(slotOf(b,g)['facts'])['toContain'](e['key']);}}}),it('collapses\x20to\x200\x20with\x20all\x20slots\x20gap\x20when\x20the\x20target\x20is\x20missing',async()=>{const a=await evalFacts(EMPTY_STATE,FULL['svc']);expect(a['slots']['every'](b=>b['state']==='gap'))['toBe'](!![]),expect(a['completeness'])['toBe'](0x0),expect(factOf(a,'risk_behavior.findings')['state'])['toBe']('gap');});}),describe('facts\x20—\x20entity\x20profile\x20attributes',()=>{it('projects\x20viewport-cropped\x20payloads;\x20absence\x20yields\x20no\x20entry',async()=>{const a=await evalFacts(fullServiceState(),FULL['svc']),b=a['profiles']['map'](e=>e['nodeId']);expect(b)['toContain'](FULL['supplier']['toLowerCase']());const c=a['profiles']['find'](e=>e['nodeId']===FULL['supplier']['toLowerCase']());expect(c['description'])['toBe']('Acme\x20logistics\x20co.'),expect(c['registeredAt'])['toBe'](0x18bcfe57b88),expect(c['recordCount'])['toBe'](0x1),expect(c['profileRecords'])['toEqual']([{'name':'region','valueType':0x1,'value':'cn-east'}]);const d=a['profiles']['find'](e=>e['nodeId']===FULL['member']['toLowerCase']());expect(d['hasDescription'])['toBe'](!![]),expect(d['recordCount'])['toBe'](0x0),expect(b)['not']['toContain'](FULL['buyer']['toLowerCase']());});}),describe('facts\x20—\x20N-K5\x20own-scope\x20partition\x20folds\x20neighbor\x20findings',()=>{const a='0x1549f8aa00000000000000000000000000000000000000000000000000000000',b=c=>({'id':'R4:'+c+':accepted→completed','kind':'risk','severity':'medium','title':'Workflow\x20single\x20point:\x20the\x20only\x20Forward\x20before\x20a\x20terminal\x20state\x20has\x20a\x20single\x20operator\x20and\x20no\x20fallback\x20Guard','path':[c,'machine.node','wf.transition','accepted→completed'],'confidence':'exact','roles':['neutral'],'detail':'synthetic\x20single-point\x20finding\x20for\x20the\x20scope\x20test','suggestion':'add\x20a\x20fallback\x20operator'});it('scores\x20only\x20own-machine\x20R4\x20findings;\x20the\x20foreign\x20machine\x27s\x20identical\x20finding\x20is\x20folded\x20as\x20neighbor\x20count',async()=>{const c=await evalFactsWithFindings(fullServiceState(),FULL['svc'],[b(FULL['mac']['toLowerCase']()),b(a)]),d=factOf(c,'risk_workflow.findings');expect(d['state'])['toBe']('present'),expect(d['findingIds'])['toEqual'](['R4:'+FULL['mac']['toLowerCase']()+':accepted→completed']);const e=d['value'];expect(e['findings'])['toHaveLength'](0x1),expect(e['findings'][0x0]['id'])['toBe']('R4:'+FULL['mac']['toLowerCase']()+':accepted→completed'),expect(d['evidence'])['toContain']('1\x20further\x20finding(s)\x20on\x20NEIGHBOR\x20objects'),expect(d['evidence'])['toContain']('do\x20not\x20belong\x20to\x20this\x20object\x27s\x20score');}),it('an\x20all-neighbor\x20finding\x20set\x20matches\x20nothing\x20and\x20reports\x20the\x20folded\x20count\x20on\x20a\x20clean\x20own\x20structure',async()=>{const c=await evalFactsWithFindings(fullServiceState(),FULL['svc'],[b(a)]),d=factOf(c,'risk_workflow.findings');expect(d['state'])['toBe']('present'),expect(d['findingIds'])['toEqual']([]),expect(d['evidence'])['toContain']('No\x20risk\x20fired\x20on\x20this\x20object'),expect(d['evidence'])['toContain']('1\x20finding(s)\x20on\x20neighbor\x20objects');});});
@@ -1,29 +0,0 @@
1
- export type FieldDisposition = {
2
- readonly kind: "edge";
3
- readonly schema: string;
4
- readonly coSchemas?: readonly string[];
5
- readonly note?: string;
6
- } | {
7
- readonly kind: "attribute";
8
- readonly note: string;
9
- } | {
10
- readonly kind: "transient";
11
- readonly note: string;
12
- } | {
13
- readonly kind: "nonAddress";
14
- readonly note: string;
15
- };
16
- export interface FieldEntry {
17
- readonly field: string;
18
- readonly disposition: FieldDisposition;
19
- readonly evidence: string;
20
- readonly oq?: string;
21
- }
22
- export interface ObjectManifest {
23
- readonly object: string;
24
- readonly moveStruct: string;
25
- readonly fields: readonly FieldEntry[];
26
- }
27
- export declare const FIELD_MANIFEST: readonly ObjectManifest[];
28
- export declare const MANIFEST_BY_OBJECT: ReadonlyMap<string, ObjectManifest>;
29
- export declare const BUSINESS_OBJECTS: readonly string[];
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- import{describe,expect,it}from'vitest';import{EDGE_SCHEMAS,EDGE_SCHEMA_BY_ID}from'./edge-schema.js';import{BUSINESS_OBJECTS,FIELD_MANIFEST,MANIFEST_BY_OBJECT}from'./field-manifest.js';import{fullServiceObjects}from'./fixtures.js';const HAS_KEY_STRUCTS={'Service':['id','description','location','sales','repositories','buy_guard','machine','bPublished','bPaused','customer_required','arbitrations','compensation_fund','paused_time','setting_lock_duration','order_allocators','rewards','um','permission'],'Order':['id','items','discount','progress','machine','amount','owner','service','dispute','agent','allocation','claimed_by','required_info','time'],'Discount':['id','name','discount_type','benchmark','off','time_start','time_end','service','transferable'],'Progress':['id','machine','context_repositories','current','task','namedOperator','session','history','current_time'],'Machine':['id','description','nodes','consensus_repositories','bPaused','bPublished','um','permission'],'Allocation':['id','balance','allocators','payment_info','payment'],'Arbitration':['id','description','location','voting_guard','usage_guard','fee','balance','bPaused','um','permission'],'Arb':['id','description','order','arbitration','voted','proposition','fee','feedback','indemnity','voting_deadline','objection','status','compensation_time','time'],'Demand':['id','description','location','rewards','guards','presenters','um','permission'],'Reward':['id','description','guards','balance','guard_not_added_expiration_time','record','um','permission'],'Repository':['id','description','policies','data','rewards','um','permission'],'Contact':['id','description','location','ims','permission'],'Permission':['id','owner','admin','description','remark','table','um'],'Guard':['id','description','table','validated','input','relies','relies_logic_and','immutable','rep'],'Passport':['id','guard','result','tx_hash','impack','time','signer','has_verified'],'Proof':['id','description','proof','item_count','server_pubkey','server_signature','about','signer','proof_type','time'],'Treasury':['id','description','balance','history','external_deposit_guard','external_withdraw_guard','inflow','outflow','um','permission'],'Payment':['id','amount','time','info','from_object','signer','record'],'CoinWrapper':['id','balance','payment'],'Resource':['id','table'],'EntityOrders':['id','table'],'EntityPermission':['id','table'],'EntityContact':['id','table'],'Entity':['id','table'],'Registrar':['id','table'],'ObjectLinkerCore':['id','table'],'ObjectLinkerTx':['id','table']},NON_STRUCT_KEYS=new Set(['EventStreams']);function walk(a,b){if(b['length']===0x0)return a!==undefined;if(a===null||a===undefined)return![];if(Array['isArray'](a))return a['some'](c=>walk(c,b));if(typeof a==='object'){const c=a[b[0x0]];if(c===undefined)return![];return walk(c,b['slice'](0x1));}return![];}function readResolves(a,b){switch(a['kind']){case'field':case'fields':case'structFields':return walk(b,a['path']['split']('.'));case'deep':{if(!walk(b,a['segments']))return![];return a['field']===''||walk(b,[...a['segments'],a['field']]);}default:return!![];}}describe('field\x20manifest\x20—\x20coverage\x20(TR-12.1)',()=>{it('manifest\x20keys\x20equal\x20the\x20audited\x20has-key\x20struct\x20registry\x20plus\x20EventStreams',()=>{const a=FIELD_MANIFEST['map'](c=>c['object'])['sort'](),b=[...Object['keys'](HAS_KEY_STRUCTS),...NON_STRUCT_KEYS]['sort']();expect(a)['toEqual'](b);}),it('every\x20manifest\x20object\x27s\x20field\x20set\x20matches\x20its\x20audited\x20Move\x20struct\x20(both\x20directions)',()=>{for(const [a,b]of Object['entries'](HAS_KEY_STRUCTS)){const c=MANIFEST_BY_OBJECT['get'](a);expect(c,'missing\x20manifest\x20for\x20'+a)['toBeDefined']();const d=c['fields']['map'](e=>e['field'])['sort']();expect(d,a+'\x20field\x20mismatch')['toEqual']([...b]['sort']());}}),it('no\x20field\x20row\x20is\x20left\x20unclassified\x20(TR-12.2)',()=>{for(const a of FIELD_MANIFEST){for(const b of a['fields']){expect(['edge','attribute','transient','nonAddress'],a['object']+'.'+b['field']+'\x20kind')['toContain'](b['disposition']['kind']),b['disposition']['kind']!=='edge'&&expect(b['disposition']['note']['trim']()['length'],a['object']+'.'+b['field']+'\x20note\x20empty')['toBeGreaterThan'](0x0);}}});}),describe('field\x20manifest\x20—\x20schema\x20cross-reference',()=>{it('every\x20referenced\x20schema\x20id\x20is\x20registered\x20(primary\x20and\x20co-edges)',()=>{for(const a of FIELD_MANIFEST){for(const b of a['fields']){if(b['disposition']['kind']!=='edge')continue;expect(EDGE_SCHEMA_BY_ID['has'](b['disposition']['schema']),a['object']+'.'+b['field']+':\x20unknown\x20schema\x20'+b['disposition']['schema'])['toBe'](!![]);for(const c of b['disposition']['coSchemas']??[]){expect(EDGE_SCHEMA_BY_ID['has'](c),a['object']+'.'+b['field']+':\x20unknown\x20co-schema\x20'+c)['toBe'](!![]);}}}}),it('every\x20non-E\x20schema\x20is\x20referenced\x20by\x20the\x20manifest\x20(registry\x20completeness)',()=>{const a=new Set();for(const c of FIELD_MANIFEST){for(const d of c['fields']){if(d['disposition']['kind']!=='edge')continue;a['add'](d['disposition']['schema']);for(const e of d['disposition']['coSchemas']??[])a['add'](e);}}const b=EDGE_SCHEMAS['filter'](g=>g['family']!=='E'&&!a['has'](g['id']));expect(b['map'](g=>g['id']),'schemas\x20with\x20no\x20manifest\x20row')['toEqual']([]);}),it('business-object\x20edge\x20rows\x20are\x20sourced\x20from\x20their\x20own\x20object',()=>{for(const a of BUSINESS_OBJECTS){const b=MANIFEST_BY_OBJECT['get'](a);for(const c of b['fields']){if(c['disposition']['kind']!=='edge')continue;const d=EDGE_SCHEMA_BY_ID['get'](c['disposition']['schema']);expect(d['source'],a+'.'+c['field']+'\x20->\x20'+d['id'])['toBe'](a);}}});}),describe('field\x20manifest\x20—\x20fixture\x20resolvability',()=>{const a=fullServiceObjects();function b(c){return a['filter'](d=>d['type']===c||(d['type_raw']??'')['startsWith'](c+'<'));}it('every\x20field-family\x20read\x20path\x20resolves\x20on\x20at\x20least\x20one\x20fixture\x20instance',()=>{let c=0x0;for(const d of BUSINESS_OBJECTS){const e=MANIFEST_BY_OBJECT['get'](d),g=b(d);expect(g['length'],'no\x20fixture\x20instance\x20for\x20'+d)['toBeGreaterThan'](0x0);for(const h of e['fields']){if(h['disposition']['kind']!=='edge')continue;const i=EDGE_SCHEMA_BY_ID['get'](h['disposition']['schema']);if(i['read']['kind']!=='field'&&i['read']['kind']!=='fields'&&i['read']['kind']!=='structFields'&&i['read']['kind']!=='deep')continue;const j=g['some'](k=>readResolves(i['read'],k['data']));expect(j,i['id']+':\x20read\x20path\x20unresolvable\x20on\x20any\x20'+d+'\x20fixture')['toBe'](!![]),c+=0x1;}}expect(c,'sanity:\x20fixture-checked\x20field-family\x20edges')['toBeGreaterThan'](0x32);});});
@@ -1,80 +0,0 @@
1
- import type { RawObject, TableItem } from "./types.js";
2
- import type { FakePlaneState } from "./dataplane.js";
3
- export declare const T_USDT = "0x2::wow::coins::USDT";
4
- export interface FullAddrs {
5
- merchant: string;
6
- buyer: string;
7
- agent: string;
8
- voter1: string;
9
- voter2: string;
10
- member: string;
11
- supplier: string;
12
- claimant: string;
13
- signer: string;
14
- buyer2: string;
15
- svc: string;
16
- mac: string;
17
- perm: string;
18
- permArb: string;
19
- permRew: string;
20
- permRepo: string;
21
- permT: string;
22
- permDem: string;
23
- ctShop: string;
24
- ctMac: string;
25
- ctArb: string;
26
- ctRew: string;
27
- ctRepo: string;
28
- ctT: string;
29
- ctDem: string;
30
- gBuy: string;
31
- gAlloc: string;
32
- gShip: string;
33
- gRel: string;
34
- gDeep: string;
35
- gVote: string;
36
- gUsage: string;
37
- gClaim: string;
38
- gWrite: string;
39
- gQuote: string;
40
- gSub: string;
41
- gDep: string;
42
- gWd: string;
43
- arbsvc: string;
44
- arb1: string;
45
- rew: string;
46
- repo: string;
47
- tres: string;
48
- alloc: string;
49
- disc: string;
50
- o1: string;
51
- o2: string;
52
- pr1: string;
53
- pr2: string;
54
- pay1: string;
55
- pay2: string;
56
- proof1: string;
57
- pp: string;
58
- dem: string;
59
- resource: string;
60
- }
61
- export declare const FULL: FullAddrs;
62
- export declare function rowObject(type: string, data: Record<string, unknown>): {
63
- objectId: string;
64
- object: RawObject;
65
- };
66
- export declare function fullServiceObjects(): RawObject[];
67
- export declare function fullServiceTables(): Map<string, TableItem[]>;
68
- export declare function fullServiceKeyedFields(): Map<string, Map<string, unknown>>;
69
- export declare function fullServiceState(): FakePlaneState;
70
- export interface GapAddrs {
71
- merchant: string;
72
- svc: string;
73
- perm: string;
74
- macMissing: string;
75
- bareOrder: string;
76
- }
77
- export declare const GAP: GapAddrs;
78
- export declare function gapServiceState(): FakePlaneState;
79
- export declare const TRUNC_EXTRA_ORDERS = 250;
80
- export declare function truncatedServiceState(): FakePlaneState;
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- import{describe,expect,it}from'vitest';import{ENTRYPOINT}from'@wowok/wowok';import{FakeDataPlane}from'./dataplane.js';import{expandTopology}from'./expand.js';import{FULL,GAP,TRUNC_EXTRA_ORDERS,fullServiceState,gapServiceState,truncatedServiceState}from'./fixtures.js';const TABLE_EDGES={'tableEdges':['machine.node','permission.entity','demand.presenter']};describe('fixtures\x20—\x20fully\x20hooked\x20shop',()=>{it('expands\x20service→machine→wfnode→guard(relies)\x20and\x20the\x20arbitration/order/payment\x20subtree',async()=>{const a=new FakeDataPlane(fullServiceState()),b=await expandTopology(a,{'network':ENTRYPOINT['Mainnet'],'seed':FULL['svc'],'edges':TABLE_EDGES}),c=new Set(b['edges']['map'](f=>f['schema']));for(const f of['service.machine','service.buy_guard','service.arbitration','service.reward','service.repository','service.um','service.order_allocator_guard','machine.permission','machine.consensus_repository','machine.um','machine.node','wf.transition','wf.forward_guard','guard.relies','arbitration.permission','arbitration.voting_guard','arbitration.usage_guard','arb.order','arb.voter','reward.guard','repository.reward','service.order','order.progress','order.allocation','order.dispute','allocation.guard','permission.admin','permission.entity']){expect(c['has'](f),'missing\x20edge\x20'+f)['toBe'](!![]);}const d=b['edges']['filter'](g=>g['schema']==='guard.relies');expect(d['some'](g=>g['from']===FULL['gShip']&&g['to']===FULL['gRel']))['toBe'](!![]),expect(d['some'](g=>g['from']===FULL['gRel']&&g['to']===FULL['gDeep']))['toBe'](![]),expect(b['nodes']['has'](FULL['gDeep']),'second-hop\x20relied\x20guard\x20must\x20not\x20be\x20fetched')['toBe'](![]);const e=b['truncations']['filter'](g=>g['reason']==='schema_hops');expect(e)['toEqual']([{'nodeId':FULL['gRel'],'schema':'guard.relies','observed':0x1,'limit':0x1,'reason':'schema_hops'}]),expect(b['gaps'])['toEqual']([]);});}),describe('fixtures\x20—\x20shell\x20merchant\x20with\x20gaps',()=>{it('distinguishes\x20configured-empty\x20lists\x20from\x20a\x20dangling\x20machine\x20fetch',async()=>{const a=new FakeDataPlane(gapServiceState()),b=await expandTopology(a,{'network':ENTRYPOINT['Mainnet'],'seed':GAP['svc']});expect(b['nodes']['get'](GAP['macMissing'])?.['state']??'absent')['not']['toBe']('ok'),expect(b['gaps'])['toContain'](GAP['macMissing']),expect(b['edges']['some'](d=>d['schema']==='service.order'&&d['to']===GAP['bareOrder']))['toBe'](!![]);const c=new Set(b['edges']['map'](d=>d['schema']));for(const d of['service.arbitration','service.reward','service.repository']){expect(c['has'](d))['toBe'](![]);}});}),describe('fixtures\x20—\x20window\x20truncation',()=>{it('caps\x20service\x20order\x20fanout\x20under\x20the\x20default\x20budget\x20and\x20records\x20truncation',async()=>{const a=new FakeDataPlane(truncatedServiceState()),b=await expandTopology(a,{'network':ENTRYPOINT['Mainnet'],'seed':FULL['svc']}),c=b['edges']['filter'](d=>d['schema']==='service.order');expect(c['length'])['toBeLessThan'](0x2+TRUNC_EXTRA_ORDERS),expect(b['truncations']['some'](d=>d['schema']==='service.order'))['toBe'](!![]),expect(c['every'](d=>d['truncated']))['toBe'](!![]);}),it('caps\x20buyer\x20order\x20fanout\x20(eoa.order=100)\x20when\x20seeded\x20from\x20the\x20EOA',async()=>{const a=new FakeDataPlane(truncatedServiceState()),b=await expandTopology(a,{'network':ENTRYPOINT['Mainnet'],'seed':FULL['buyer2'],'budget':{'maxFanoutPerNode':0xc8}}),c=b['edges']['filter'](d=>d['schema']==='eoa.order');expect(c['length'])['toBe'](0x64),expect(b['truncations']['some'](d=>d['schema']==='eoa.order'))['toBe'](!![]);});});
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- import{mkdtempSync,writeFileSync}from'node:fs';import{tmpdir}from'node:os';import{join}from'node:path';import{afterAll,beforeAll,describe,expect,it}from'vitest';import{beginPolicyRun,endPolicyRun,factoryRulePack,getJudgmentDoc,judgmentStatus}from'../../config/judgment.js';import{evaluateRuleBook}from'../../config/rule-engine.js';import{graphFindingPolicy}from'./policy.js';const CONFIG_DIR=mkdtempSync(join(tmpdir(),'wowok-graph-policy-'));process['env']['WOWOK_CONFIG_DIR']=CONFIG_DIR;const GRAPH_IDS=['R1','R2','R3','R4','R6','R7-treasury','R7-reward','A1','A2','A3','G2','AC1','AC2','AC3','AC4','AC5','AC6','AC7'];beforeAll(()=>{beginPolicyRun();}),afterAll(()=>{endPolicyRun();}),describe('graph\x20finding\x20policy\x20—\x20factory\x20parity',()=>{it('factory\x20pack\x20carries\x20exactly\x20the\x20kernel\x20emission\x20ids',()=>{const a=factoryRulePack('graph');expect(a)['not']['toBeNull'](),expect(a['rules']['map'](b=>b['rule_id'])['sort']())['toEqual']([...GRAPH_IDS]['sort']());}),it('static\x20literals\x20resolve\x20to\x20the\x20kernel\x20severities',()=>{expect(graphFindingPolicy('R1',{'eoa':'0xa'})['severity'])['toBe']('high'),expect(graphFindingPolicy('R4',{'only':'name:ops'})['severity'])['toBe']('medium'),expect(graphFindingPolicy('R6',{})['severity'])['toBe']('medium'),expect(graphFindingPolicy('R7-treasury',{})['severity'])['toBe']('critical'),expect(graphFindingPolicy('A1',{})['severity'])['toBe']('medium'),expect(graphFindingPolicy('A2',{})['severity'])['toBe']('low'),expect(graphFindingPolicy('A3',{})['severity'])['toBe']('medium'),expect(graphFindingPolicy('G2',{})['severity'])['toBe']('low'),expect(graphFindingPolicy('AC1',{})['severity'])['toBe']('high');}),it('dynamic\x20fact:\x20levels\x20resolve\x20through\x20the\x20extractor\x20facts',()=>{expect(graphFindingPolicy('R2',{'r2_level':'high'})['severity'])['toBe']('high'),expect(graphFindingPolicy('R2',{'r2_level':'medium'})['severity'])['toBe']('medium'),expect(graphFindingPolicy('R3',{'r3_level':'medium'})['severity'])['toBe']('medium'),expect(graphFindingPolicy('R3',{'r3_level':'low'})['severity'])['toBe']('low');for(const a of['high','medium','low']){expect(graphFindingPolicy('AC2',{'ac_signal_level':a})['severity'])['toBe'](a),expect(graphFindingPolicy('AC3',{'ac_signal_level':a})['severity'])['toBe'](a),expect(graphFindingPolicy('AC4',{'ac_shell_code':'shell_no_machine','ac_signal_level':a})['severity'])['toBe'](a),expect(graphFindingPolicy('AC5',{'ac_signal_level':a})['severity'])['toBe'](a),expect(graphFindingPolicy('AC6',{'ac_signal_level':a})['severity'])['toBe'](a),expect(graphFindingPolicy('AC7',{'ac_signal_level':a})['severity'])['toBe'](a);}}),it('R7-reward\x20mirrors\x20the\x20viability\x20gate:\x20viable\x20→\x20critical\x20confirmed',()=>{const a=graphFindingPolicy('R7-reward',{'r7_slot_viability':'viable','r7_slot_audit':'#0\x20viable\x20—\x20no\x20binding'});expect(a['severity'])['toBe']('critical'),expect(a['exposure']?.['verdict'])['toBe']('confirmed'),expect(a['exposure']?.['gainPaths'][0x0]?.['gate'])['toContain']('#0\x20viable\x20—\x20no\x20binding'),expect(a['exposure']?.['gainPaths'][0x0]?.['viability'])['toBe']('viable');}),it('R7-reward\x20all-blocked\x20downgrades\x20to\x20info\x20with\x20baseSeverity\x20kept',()=>{const a=graphFindingPolicy('R7-reward',{'r7_slot_viability':'blocked','r7_slot_audit':'#0\x20blocked\x20—\x20Entity\x20recipient'});expect(a['severity'])['toBe']('info'),expect(a['exposure']?.['verdict'])['toBe']('downgraded'),expect(a['exposure']?.['baseSeverity'])['toBe']('critical');}),it('R7-reward\x20undecided\x20keeps\x20critical\x20as\x20pending-disclosure',()=>{const a=graphFindingPolicy('R7-reward',{'r7_slot_viability':'unverifiable','r7_slot_audit':'#0\x20unverifiable\x20—\x20guard\x20not\x20fetched'});expect(a['severity'])['toBe']('critical'),expect(a['exposure']?.['verdict'])['toBe']('pending-disclosure');}),it('AC4\x20selects\x20the\x20attribution\x20case\x20by\x20shell\x20code',()=>{const a=graphFindingPolicy('AC4',{'ac_shell_code':'shell_no_arbitration','ac_signal_level':'high'});expect(a['exposure']?.['lossParties']['map'](d=>d['role']))['toEqual'](['buyer']),expect(a['exposure']?.['gainPaths'][0x0]?.['role'])['toBe']('merchant');const b=graphFindingPolicy('AC4',{'ac_shell_code':'shell_no_machine','ac_signal_level':'low'});expect(b['exposure']?.['verdict'])['toBe']('confirmed');const c=graphFindingPolicy('AC4',{'ac_shell_code':'other','ac_signal_level':'high'});expect(c['enabled'])['toBe'](!![]),expect(c['severity'])['toBeNull']();}),it('an\x20emission\x20id\x20outside\x20the\x20pack\x20leaves\x20the\x20kernel\x20default\x20intact',()=>{expect(graphFindingPolicy('R5',{}))['toEqual']({'enabled':!![],'severity':null});});}),describe('graph\x20finding\x20policy\x20—\x20pack-driven\x20behavior\x20change',()=>{it('a\x20disabled\x20rule\x20id\x20suppresses\x20the\x20emission\x20with\x20a\x20trace',()=>{const {findings:a,disabled_traces:b}=evaluateRuleBook([{'rule_id':'R6','dimension':'structural','cases':[{'when':{'field':'kernel_fired','op':'truthy'},'level':'medium','title':'t','description':'d'}],'enabled':![]}],{'kernel_fired':!![]});expect(a)['toHaveLength'](0x0),expect(b)['toEqual'](['R6']);}),it('a\x20user\x20fact:\x20reference\x20outside\x20the\x20factory\x20vocabulary\x20is\x20rejected',async()=>{const a={'version':0x1,'rules':{'domains':{'graph':{'rules':[{'rule_id':'R1','cases':[{'when':{'field':'kernel_fired','op':'truthy'},'level':'fact:not_a_kernel_fact','title':'t','description':'d'}]}]}}}};writeFileSync(join(CONFIG_DIR,'judgment.json'),JSON['stringify'](a),'utf-8');const b=getJudgmentDoc();expect(factoryRulePack('graph'))['not']['toBeNull']();const c=judgmentStatus();expect(c['user_doc_loaded'])['toBe'](![]),expect(c['last_reload_error'])['toContain']('fact:not_a_kernel_fact'),expect(c['last_reload_error'])['toContain']('R1'),expect(graphFindingPolicy('R1',{'eoa':'0xa'})['severity'])['toBe']('high'),void b;});});
@@ -1,29 +0,0 @@
1
- export * from "./types.js";
2
- export * from "./edge-schema.js";
3
- export * from "./extract.js";
4
- export * from "./order-status.js";
5
- export { MAX_OBJECTS_PER_QUERY, DEFAULT_BUDGET, mergeBudget, chunk50, mapPool, FakeDataPlane } from "./dataplane.js";
6
- export type { FakePlaneState } from "./dataplane.js";
7
- export { SdkDataPlane } from "./sdk-dataplane.js";
8
- export * from "./sdk-batch.js";
9
- export { expandTopology, orderCompletionInGraph } from "./expand.js";
10
- export { TOPOLOGY_INTENTS, INTENT_PRESETS, EVALUATION_SERVICE_INTENTS, EVALUATION_SERVICE_BUDGET, EVALUATION_SERVICE_EDGES, resolveExpansionStrategy, withEvaluationBundle, isTopologyIntent, normalizeTopologyFocusPref, normalizeSchemaHops, type TopologyIntent, type IntentPreset, type StrategyFragment, type ExpansionStrategy, type StrategyResolutionInput, type ExplicitExpansionParams, type TopologyFocusPref, } from "./strategy.js";
11
- export { detectFakeOrders, detectFakeReviews, detectShellMerchant, reputationTradeNote, assessAntiCheat, detectNewAccountBurst, detectVoteReciprocity, detectTargetFlood, summarizeVoterCredibility, VOTER_NEW_ACCOUNT_DAYS, VOTER_BURST_MIN_VOTES, VOTER_FLOOD_MIN_VOTES, VOTER_FLOOD_LOW_CRED_RATIO, } from "./anti-cheat.js";
12
- export type { AntiCheatSeverity, AntiCheatSignal, OrderEvidence, ReviewEvidence, MerchantEvidence, VoteEdgeEvidence, VoterProfileEvidence, VoterCredibility, } from "./anti-cheat.js";
13
- export { buildViewport, edgesOut, edgesInc, nodeOf } from "./viewport.js";
14
- export { buildRoleInterest, toCommercialRole, viewerRoleOf, type RoleInterestResult, } from "./interest.js";
15
- export { buildControlIndex } from "./analyze.js";
16
- export { projectExploration } from "./exploration.js";
17
- export type { ExplorationBlock, ExplorationContext, OpenQuestion, OpenQuestionKind, } from "./exploration.js";
18
- export { synthesizeVerdicts } from "./synthesis.js";
19
- export type { RoleVerdict, SynthesisBlock, SynthesisInput, SynthesisPosture, } from "./synthesis.js";
20
- export { applyExposureGate, gainPath, lossParty, EXPOSURE_ROLES } from "./exposure.js";
21
- export type { ExposureParty, ExposureVerdict, FindingExposure, GainPath, GainPathViability, } from "./exposure.js";
22
- export { projectEvaluationFacts } from "./facts.js";
23
- export { projectFacets } from "./facet-projection.js";
24
- export type { FacetState, FacetMoney, FacetAmount, FacetSignal, FacetScoreRef, FacetGraphRef, FacetGraph, FacetResult, FacetsBlock, FacetProjectionProfile, FacetWorkflowShape, ProjectFacetsInput, } from "./facet-projection.js";
25
- export type { FactState, EvaluationDimension, FactProvenance, Fact, CoverageSlot, EntityProfileAttributes, GraphEvaluationFacts, ArbitrationBinding, VoteCounts, OrderWindowStats, WorkflowShape, FundPosition, FundExposure, TransparencyProfile, RiskFindingRefs, } from "./facts.js";
26
- export { projectRelationshipFacts } from "./project-relationship.js";
27
- export { DEFAULT_ANALYZERS, registerAnalyzer, getAnalyzer, listAnalyzers, runAnalyzers, adaptNodeAnalyzer, runNodeAnalyzers, pathConfidence, findingWhere, findingWhereResolved, type NodeRuleBinding, type NodeRuleOutcome, } from "./analyze.js";
28
- export { buildNameIndex, createNameResolver, humanizeStoredName, humanizeTypeTag, isWfNodeId, shortAddress, wfMachineOf, wfNodeName, type NameIndex, type NameResolver, type ResolvedName, } from "./names.js";
29
- export { buildProposalGraph, PROPOSAL_GAP_ANALYZER, type ProposalGraphOptions } from "./proposal-graph.js";