@wowok/agent-mcp 2.5.3 → 2.5.5

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 (69) hide show
  1. package/README.md +33 -26
  2. package/dist/customer/index.d.ts +2 -2
  3. package/dist/customer/index.js +1 -1
  4. package/dist/customer/info-puzzle.d.ts +39 -2
  5. package/dist/customer/info-puzzle.js +370 -29
  6. package/dist/customer/risk-assessment.js +51 -14
  7. package/dist/customer/types.d.ts +85 -0
  8. package/dist/knowledge/machine-ledger.js +32 -29
  9. package/dist/knowledge/machine-risk.js +23 -0
  10. package/dist/knowledge/machine-templates.js +118 -86
  11. package/dist/knowledge/reward-confirm.d.ts +3 -0
  12. package/dist/knowledge/reward-confirm.js +30 -0
  13. package/dist/knowledge/reward-puzzle.d.ts +1 -0
  14. package/dist/knowledge/reward-puzzle.js +12 -0
  15. package/dist/knowledge/reward-risk.d.ts +4 -1
  16. package/dist/knowledge/reward-risk.js +85 -3
  17. package/dist/knowledge/reward-templates.d.ts +1 -1
  18. package/dist/knowledge/reward-templates.js +77 -5
  19. package/dist/knowledge/tools-reference.js +5 -4
  20. package/dist/knowledge/trust-metrics.d.ts +4 -0
  21. package/dist/knowledge/trust-metrics.js +67 -7
  22. package/dist/project/evaluation.d.ts +53 -0
  23. package/dist/project/evaluation.js +853 -0
  24. package/dist/project/graph-builder.d.ts +43 -0
  25. package/dist/project/graph-builder.js +572 -0
  26. package/dist/project/handlers.d.ts +152 -0
  27. package/dist/project/handlers.js +458 -0
  28. package/dist/project/index.d.ts +1 -0
  29. package/dist/project/index.js +24 -1
  30. package/dist/project/query.d.ts +1 -0
  31. package/dist/project/query.js +2 -0
  32. package/dist/project/semantic-assembler.d.ts +93 -0
  33. package/dist/project/semantic-assembler.js +345 -0
  34. package/dist/schema/call/arbitration.d.ts +54 -54
  35. package/dist/schema/call/base.js +1 -1
  36. package/dist/schema/call/demand.d.ts +48 -48
  37. package/dist/schema/operations.d.ts +76 -76
  38. package/dist/schema/project/index.d.ts +1558 -3885
  39. package/dist/schema/project/index.js +357 -961
  40. package/dist/schema/trust/index.d.ts +24 -24
  41. package/dist/schemas/bridge_operation.schema.json +1 -1
  42. package/dist/schemas/guard2file.schema.json +1 -1
  43. package/dist/schemas/index.json +2 -2
  44. package/dist/schemas/machineNode2file.schema.json +1 -1
  45. package/dist/schemas/onchain_operations.schema.json +5 -5
  46. package/dist/schemas/onchain_operations_allocation.schema.json +1 -1
  47. package/dist/schemas/onchain_operations_arbitration.schema.json +1 -1
  48. package/dist/schemas/onchain_operations_contact.schema.json +1 -1
  49. package/dist/schemas/onchain_operations_demand.schema.json +1 -1
  50. package/dist/schemas/onchain_operations_gen_passport.schema.json +2 -2
  51. package/dist/schemas/onchain_operations_gen_proof.schema.json +2 -2
  52. package/dist/schemas/onchain_operations_guard.schema.json +1 -1
  53. package/dist/schemas/onchain_operations_machine.schema.json +1 -1
  54. package/dist/schemas/onchain_operations_order.schema.json +1 -1
  55. package/dist/schemas/onchain_operations_payment.schema.json +1 -1
  56. package/dist/schemas/onchain_operations_permission.schema.json +1 -1
  57. package/dist/schemas/onchain_operations_personal.schema.json +1 -1
  58. package/dist/schemas/onchain_operations_progress.schema.json +1 -1
  59. package/dist/schemas/onchain_operations_proof.schema.json +1 -1
  60. package/dist/schemas/onchain_operations_repository.schema.json +1 -1
  61. package/dist/schemas/onchain_operations_reward.schema.json +1 -1
  62. package/dist/schemas/onchain_operations_service.schema.json +1 -1
  63. package/dist/schemas/onchain_operations_treasury.schema.json +1 -1
  64. package/dist/schemas/project_operation.output.json +975 -2471
  65. package/dist/schemas/project_operation.schema.json +207 -534
  66. package/dist/tools/handlers/onchain.js +97 -19
  67. package/dist/tools/handlers/project.js +34 -1046
  68. package/dist/tools/index.js +84 -55
  69. package/package.json +2 -2
@@ -1,8 +1,8 @@
1
1
  {
2
2
  "$schema": "http://json-schema.org/draft-07/schema#",
3
3
  "$id": "https://wowok.net/schemas/project_operation.json",
4
- "title": "Project - Namespace & Object Graph",
5
- "description": "Manage and query the local object dependency graph (DAG) built on top of local_mark tags. Actions: list_projects, list_objects, shareable, dependencies, referenced_by, pre_publish_check, cross_project_refs, graph_stats, save_graph, load_graph.",
4
+ "title": "Project - Entity Management & Evaluation",
5
+ "description": "Project management service — manage projects as first-class entities with SQLite persistence, rigid project-object relationships, three-pathway graph construction, and a dual rule-based + LLM-assisted evaluation engine. Actions: list_projects, create_project, create_project_from_onchain, update_project, get_project_detail, add_object, remove_object, create_version, build_graph, get_graph, evaluate_project, save_evaluation, compare_projects, refresh_objects, get_object_diff, assemble_context.",
6
6
  "$ref": "#/definitions/project_operation",
7
7
  "definitions": {
8
8
  "project_operation": {
@@ -12,68 +12,93 @@
12
12
  "type": "string",
13
13
  "enum": [
14
14
  "list_projects",
15
- "list_objects",
16
- "shareable",
17
- "dependencies",
18
- "referenced_by",
19
- "pre_publish_check",
20
- "cross_project_refs",
21
- "graph_stats",
22
- "save_graph",
23
- "load_graph",
24
- "analyze_intent",
25
- "aggregate_risks",
26
- "generate_deployment_doc",
27
- "trace_substeps",
28
- "get_project_status",
29
- "load_project",
30
- "fork_project",
31
- "export_project",
32
- "get_project_files",
33
- "validate_stage_unit",
34
- "get_stage_assessment",
35
- "get_stage_risk_policy",
36
- "get_doc_relations",
37
- "update_deployment_doc",
38
- "validate_validation_chain",
39
- "apply_improvement",
40
- "get_improvement_queue",
41
- "get_flywheel_config",
42
- "rollback_stage",
43
- "get_reversibility",
15
+ "create_project",
16
+ "create_project_from_onchain",
17
+ "update_project",
18
+ "get_project_detail",
19
+ "add_object",
20
+ "remove_object",
21
+ "update_object",
22
+ "create_version",
23
+ "build_graph",
24
+ "get_graph",
25
+ "evaluate_project",
26
+ "save_evaluation",
27
+ "compare_projects",
28
+ "refresh_objects",
29
+ "get_object_diff",
30
+ "delete_project",
44
31
  "assemble_context"
45
32
  ],
46
- "description": "Action to perform. Six categories:\n1. Graph Query (10): list_projects, list_objects, shareable, dependencies, referenced_by, pre_publish_check, cross_project_refs, graph_stats, save_graph, load_graph.\n2. Project-Based Deployment 5-Stage (4): Call IN ORDER — analyze_intent (Stage 2) → aggregate_risks (Stage 3) → generate_deployment_doc (Stage 4) → trace_substeps (Stage 5). Each action's output includes `next_action` telling you which action to call next. Stage 1 (Project Naming) uses the `project` + `version` params.\n3. Project Memory Layer (5): load_project, fork_project, export_project, get_project_files, get_project_status.\n4. Nested-Autonomy Stage Unit (6): validate_stage_unit, get_stage_assessment, get_stage_risk_policy, get_doc_relations, update_deployment_doc, validate_validation_chain.\n5. Distillation Reflow (3): apply_improvement (review + apply a proposal — config_override writes overrides/, source_patch writes patches/), get_improvement_queue (list pending/approved proposals), get_flywheel_config (query reflow loop status).\n6. Rollback & Reversibility (2): rollback_stage (evaluate + execute stage rollback with file cleanup — blocked if has_published_object), get_reversibility (query object lifecycle reversibility matrix for risk reminders).\n7. Context Assembly (1): assemble_context (query on-chain object states + extract embedded history + optional events, and assemble a structured semantic context for LLM consumption — bridges raw facts to business-understandable context). Required input: context_objects (array of object IDs/names). Optional: include_events (query recent state-transition events)."
33
+ "description": "Action to perform. Two categories:\n1. Project Entity + Evaluation (15, GLM6): list_projects, create_project, create_project_from_onchain, update_project, get_project_detail, add_object, remove_object, create_version, build_graph, get_graph, evaluate_project, save_evaluation, compare_projects, refresh_objects, get_object_diff. Projects are first-class entities with SQLite persistence, rigid project-object relationships, three-pathway graph construction, and a dual rule-based + LLM-assisted evaluation engine.\n2. Context Assembly (1): assemble_context (query on-chain object states + extract embedded history + optional events, and assemble a structured semantic context for LLM consumption). Required input: context_objects (array of object IDs/names). Optional: include_events (query recent state-transition events)."
47
34
  },
48
35
  "project": {
49
36
  "type": "string",
50
- "description": "Project prefix (for list_objects and C1-C4 actions)"
37
+ "description": "Project prefix (human-readable unique identifier). Used by create_version, build_graph, evaluate_project, etc. Takes precedence resolution: project_id > project (prefix)."
51
38
  },
52
39
  "version": {
53
40
  "type": "string",
54
41
  "pattern": "^v\\d+$",
55
- "description": "Project version (e.g. 'v1'). Required for C1-C4 actions."
42
+ "description": "Project version (e.g. 'v1'). Used by create_version."
56
43
  },
57
- "object": {
44
+ "context_objects": {
45
+ "type": "array",
46
+ "items": {
47
+ "type": "string"
48
+ },
49
+ "description": "Object IDs (0x...) or LocalMark names to assemble context for. Required when action='assemble_context'. The current on-chain state of each object will be queried and enriched with semantic annotations."
50
+ },
51
+ "include_events": {
52
+ "type": "boolean",
53
+ "description": "When true, assemble_context also queries recent state-transition events (NewOrderEvent, ProgressEvent, ArbEvent, etc.). Events are the real-time transition log — convergent and bounded. Defaults to false. Note: object-embedded history (ProgressSession.forwards, Order.disputes) is ALWAYS extracted automatically — no flag needed."
54
+ },
55
+ "context_network": {
56
+ "type": "string",
57
+ "enum": [
58
+ "testnet",
59
+ "mainnet"
60
+ ],
61
+ "description": "Network for assemble_context queries. Defaults to 'testnet' if omitted."
62
+ },
63
+ "filter_status": {
58
64
  "type": "string",
59
- "description": "Object name or address (for dependencies / referenced_by / pre_publish_check)"
65
+ "enum": [
66
+ "draft",
67
+ "active",
68
+ "inactive",
69
+ "archived"
70
+ ],
71
+ "description": "Filter list_projects by project status."
60
72
  },
61
- "fork_to_version": {
73
+ "filter_perspective": {
62
74
  "type": "string",
63
- "pattern": "^v\\d+$",
64
- "description": "Target version for fork_project (e.g. 'v2'). Must differ from source 'version'."
75
+ "enum": [
76
+ "producer",
77
+ "consumer",
78
+ "both"
79
+ ],
80
+ "description": "Filter list_projects by project perspective."
65
81
  },
66
- "fork_to_prefix": {
82
+ "filter_network": {
67
83
  "type": "string",
68
- "description": "Target prefix for fork_project. Defaults to source 'project' prefix when omitted."
84
+ "enum": [
85
+ "testnet",
86
+ "mainnet"
87
+ ],
88
+ "description": "Filter list_projects by network."
69
89
  },
70
- "user_intent": {
90
+ "project_name": {
71
91
  "type": "string",
72
92
  "minLength": 1,
93
+ "maxLength": 200,
94
+ "description": "Display name for create_project / create_project_from_onchain / update_project. Required when action='create_project'."
95
+ },
96
+ "project_description": {
97
+ "type": "string",
73
98
  "maxLength": 2000,
74
- "description": "Natural-language business intent for analyze_intent (stage 2). Required when action='analyze_intent'."
99
+ "description": "Project description for create_project / update_project."
75
100
  },
76
- "industry": {
101
+ "project_industry": {
77
102
  "type": "string",
78
103
  "enum": [
79
104
  "general",
@@ -86,553 +111,201 @@
86
111
  "subscription",
87
112
  "custom"
88
113
  ],
89
- "description": "Industry hint — drives template defaults. Used by analyze_intent and aggregate_risks."
114
+ "description": "Industry tag for create_project. Drives template defaults."
90
115
  },
91
- "target_objects": {
92
- "type": "array",
93
- "items": {
94
- "type": "string"
95
- },
96
- "description": "Optional explicit target objects (entry_ids or object_type names) for analyze_intent."
97
- },
98
- "puzzles": {
99
- "type": "object",
100
- "additionalProperties": {
101
- "type": "object",
102
- "properties": {
103
- "puzzle": {
104
- "type": "object",
105
- "additionalProperties": {},
106
- "description": "Per-object puzzle snapshot. Shape varies per object_type — see knowledge/<obj>-puzzle.ts."
107
- },
108
- "completeness": {
109
- "type": "object",
110
- "additionalProperties": {},
111
- "description": "Completeness assessment from checkPuzzleCompleteness(). Shape varies per object."
112
- },
113
- "missing_dimensions": {
114
- "type": "array",
115
- "items": {
116
- "type": "string"
117
- },
118
- "description": "Dimensions still missing for this object (e.g. ['A','B'])."
119
- }
120
- },
121
- "required": [
122
- "puzzle",
123
- "completeness",
124
- "missing_dimensions"
125
- ],
126
- "additionalProperties": false
127
- },
128
- "description": "Per-object puzzle snapshots keyed by object_type. Required for aggregate_risks and generate_deployment_doc."
129
- },
130
- "severity_threshold": {
116
+ "project_perspective": {
131
117
  "type": "string",
132
118
  "enum": [
133
- "CRITICAL",
134
- "HIGH",
135
- "MEDIUM",
136
- "LOW",
137
- "INFO"
119
+ "producer",
120
+ "consumer",
121
+ "both"
138
122
  ],
139
- "description": "Severity threshold for aggregate_risks. Risks at or above this level are flagged."
123
+ "description": "Project perspective for create_project. 'producer' = build/operate services, 'consumer' = evaluate/buy services, 'both' = dual role. Defaults to 'producer'."
140
124
  },
141
- "user_confirmed_high_risks": {
125
+ "project_labels": {
142
126
  "type": "array",
143
127
  "items": {
144
128
  "type": "string"
145
129
  },
146
- "description": "IDs of HIGH risks the user has already confirmed (suppressed in subsequent aggregate_risks)."
130
+ "description": "Free-form labels for create_project / update_project (e.g. ['travel','london','priority'])."
147
131
  },
148
- "business_intent": {
132
+ "service_address": {
149
133
  "type": "string",
150
- "minLength": 1,
151
- "maxLength": 500,
152
- "description": "One-line business intent description for the deployment doc. Required when action='generate_deployment_doc'."
134
+ "description": "On-chain Service object address. Required for create_project_from_onchain. Optional for create_project (links the project to its core Service)."
153
135
  },
154
- "author": {
136
+ "project_network": {
155
137
  "type": "string",
156
- "description": "Optional author name for the deployment doc meta section."
157
- },
158
- "objects": {
159
- "type": "array",
160
- "items": {
161
- "type": "object",
162
- "properties": {
163
- "entry_id": {
164
- "type": "string",
165
- "description": "Stable id '<object_type>:<name>'"
166
- },
167
- "object_type": {
168
- "type": "string",
169
- "enum": [
170
- "service",
171
- "machine",
172
- "guard",
173
- "permission",
174
- "reward",
175
- "arb",
176
- "progress",
177
- "treasury",
178
- "demand",
179
- "repository",
180
- "contact",
181
- "order",
182
- "allocation",
183
- "personal",
184
- "payment",
185
- "proof"
186
- ]
187
- },
188
- "name": {
189
- "type": "string"
190
- },
191
- "reused_from": {
192
- "type": "string",
193
- "description": "Existing on-chain address or local name if reused"
194
- },
195
- "publish_required": {
196
- "type": "boolean",
197
- "description": "Whether publish is required (only Service/Machine)"
198
- },
199
- "description": {
200
- "type": "string"
201
- }
202
- },
203
- "required": [
204
- "entry_id",
205
- "object_type",
206
- "name",
207
- "publish_required"
208
- ],
209
- "additionalProperties": false
210
- },
211
- "description": "Deployment objects for generate_deployment_doc."
212
- },
213
- "edges": {
214
- "type": "array",
215
- "items": {
216
- "type": "object",
217
- "properties": {
218
- "from": {
219
- "type": "string"
220
- },
221
- "to": {
222
- "type": "string"
223
- },
224
- "edge_kind": {
225
- "type": "string",
226
- "enum": [
227
- "machine",
228
- "order_allocators",
229
- "arbitrations",
230
- "compensation_fund",
231
- "rewards",
232
- "buy_guard",
233
- "permission",
234
- "guard",
235
- "prev",
236
- "next",
237
- "forward",
238
- "parent",
239
- "service",
240
- "progress",
241
- "arbitration",
242
- "sub_order",
243
- "references"
244
- ]
245
- },
246
- "field_path": {
247
- "type": "string"
248
- },
249
- "required_at_publish": {
250
- "type": "boolean"
251
- }
252
- },
253
- "required": [
254
- "from",
255
- "to",
256
- "edge_kind",
257
- "field_path",
258
- "required_at_publish"
259
- ],
260
- "additionalProperties": false
261
- },
262
- "description": "Dependency graph edges for generate_deployment_doc."
263
- },
264
- "steps": {
265
- "type": "array",
266
- "items": {
267
- "type": "object",
268
- "properties": {
269
- "step": {
270
- "type": "integer",
271
- "exclusiveMinimum": 0
272
- },
273
- "object_type": {
274
- "$ref": "#/definitions/project_operation/properties/objects/items/properties/object_type"
275
- },
276
- "operation": {
277
- "type": "string"
278
- },
279
- "substep_count": {
280
- "type": "integer",
281
- "minimum": 0
282
- },
283
- "depends_on": {
284
- "type": "array",
285
- "items": {
286
- "type": "integer"
287
- }
288
- },
289
- "entry_id": {
290
- "type": "string"
291
- },
292
- "network_phase": {
293
- "type": "string",
294
- "enum": [
295
- "testnet",
296
- "mainnet",
297
- "both"
298
- ]
299
- }
300
- },
301
- "required": [
302
- "step",
303
- "object_type",
304
- "operation",
305
- "substep_count",
306
- "depends_on",
307
- "entry_id",
308
- "network_phase"
309
- ],
310
- "additionalProperties": false
311
- },
312
- "description": "Topological execution plan for generate_deployment_doc."
138
+ "enum": [
139
+ "testnet",
140
+ "mainnet"
141
+ ],
142
+ "description": "Network the project is bound to. A Service deployed to different networks are different projects. Defaults to 'testnet'."
313
143
  },
314
- "scenarios": {
315
- "type": "array",
316
- "items": {
317
- "type": "object",
318
- "properties": {
319
- "scenario_id": {
320
- "type": "string"
321
- },
322
- "description": {
323
- "type": "string"
324
- },
325
- "primary_object": {
326
- "type": "string"
327
- },
328
- "supporting_objects": {
329
- "type": "array",
330
- "items": {
331
- "type": "string"
332
- }
333
- },
334
- "test_step_refs": {
335
- "type": "array",
336
- "items": {
337
- "type": "string"
338
- }
339
- }
340
- },
341
- "required": [
342
- "scenario_id",
343
- "description",
344
- "primary_object",
345
- "supporting_objects"
346
- ],
347
- "additionalProperties": false
348
- },
349
- "description": "Business scenarios for generate_deployment_doc §7."
144
+ "project_id": {
145
+ "type": "string",
146
+ "description": "Project UUID for update_project / get_project_detail / add_object / remove_object / create_version / build_graph / evaluate_project / refresh_objects. Takes precedence over 'project' (prefix) when both are given."
350
147
  },
351
- "risk_status": {
148
+ "project_status": {
352
149
  "type": "string",
353
150
  "enum": [
354
- "RISK_PASSED",
355
- "RISK_BLOCKED",
356
- "RISK_PENDING_CONFIRM",
357
- "RISK_CANCELLED"
151
+ "draft",
152
+ "active",
153
+ "inactive",
154
+ "archived"
358
155
  ],
359
- "description": "Risk status from aggregate_risks (for D-16 check)."
156
+ "description": "New status for update_project. 'active' projects are live, 'archived' are read-only."
360
157
  },
361
- "risk_critical_count": {
362
- "type": "integer",
363
- "minimum": 0,
364
- "description": "CRITICAL risk count from aggregate_risks."
365
- },
366
- "risk_high_count": {
367
- "type": "integer",
368
- "minimum": 0,
369
- "description": "HIGH risk count from aggregate_risks."
158
+ "object_address": {
159
+ "type": "string",
160
+ "description": "On-chain object address (0x...) for add_object / remove_object. For add_object, alternatively use object_name to resolve via LocalMark."
370
161
  },
371
- "run_scanner": {
372
- "type": "boolean",
373
- "description": "Whether to run deployment-scanner validation after generating the doc. Defaults to true."
162
+ "object_name_add": {
163
+ "type": "string",
164
+ "description": "LocalMark name for add_object (alternative to object_address)."
374
165
  },
375
- "gas_budget": {
376
- "type": "object",
377
- "properties": {
378
- "network": {
379
- "type": "string",
380
- "enum": [
381
- "testnet",
382
- "mainnet"
383
- ]
384
- },
385
- "already_spent_gas": {
386
- "type": "integer",
387
- "minimum": 0,
388
- "description": "Gas already spent on-chain in MIST (from telemetry). Defaults to 0."
389
- },
390
- "estimated_rerun_gas": {
391
- "type": "integer",
392
- "minimum": 0,
393
- "description": "Estimated gas to re-run remaining ops in MIST. Auto-computed from estimateDeploymentGas when omitted."
394
- },
395
- "warning": {
396
- "type": "string",
397
- "description": "Custom warning text. Defaults to a computed cost summary."
398
- }
399
- },
400
- "required": [
401
- "network"
166
+ "object_type_add": {
167
+ "type": "string",
168
+ "enum": [
169
+ "Service",
170
+ "Machine",
171
+ "Guard",
172
+ "Permission",
173
+ "Reward",
174
+ "Arbitration",
175
+ "Progress",
176
+ "Treasury",
177
+ "Demand",
178
+ "Repository",
179
+ "Contact",
180
+ "Order",
181
+ "Allocation",
182
+ "Personal",
183
+ "Payment",
184
+ "Proof"
402
185
  ],
403
- "additionalProperties": false,
404
- "description": "Gas budget input for stage 4/5 gate (§3.5). Non-blocking; only surfaces a WARN on mainnet."
186
+ "description": "Object type for add_object."
405
187
  },
406
- "network": {
188
+ "object_role": {
407
189
  "type": "string",
408
190
  "enum": [
409
- "testnet",
410
- "mainnet"
191
+ "core",
192
+ "dependency",
193
+ "reference"
411
194
  ],
412
- "description": "Target network for trace_substeps."
195
+ "description": "Object role in project for add_object. 'core' = the Service (only one per project), 'dependency' = required binding, 'reference' = optional/auxiliary. Defaults to 'reference'."
413
196
  },
414
- "substeps": {
197
+ "object_tags_add": {
415
198
  "type": "array",
416
199
  "items": {
417
- "type": "object",
418
- "properties": {
419
- "step_id": {
420
- "type": "string",
421
- "pattern": "^T\\d+\\.\\d+$"
422
- },
423
- "parent_step": {
424
- "type": "string",
425
- "pattern": "^T\\d+$"
426
- },
427
- "object_type": {
428
- "$ref": "#/definitions/project_operation/properties/objects/items/properties/object_type"
429
- },
430
- "entry_id": {
431
- "type": "string"
432
- },
433
- "operation_type": {
434
- "type": "string"
435
- },
436
- "network": {
437
- "type": "string",
438
- "enum": [
439
- "testnet",
440
- "mainnet"
441
- ]
442
- },
443
- "input": {
444
- "type": "object",
445
- "properties": {
446
- "data": {
447
- "type": "object",
448
- "additionalProperties": {}
449
- },
450
- "input_refs": {
451
- "type": "array",
452
- "items": {
453
- "type": "string"
454
- }
455
- }
456
- },
457
- "required": [
458
- "data",
459
- "input_refs"
460
- ],
461
- "additionalProperties": false
462
- },
463
- "output": {
464
- "type": "object",
465
- "properties": {
466
- "object_id": {
467
- "type": "string"
468
- },
469
- "tx_digest": {
470
- "type": "string"
471
- }
472
- },
473
- "additionalProperties": false
474
- },
475
- "timestamp": {
476
- "type": "integer"
477
- },
478
- "status": {
479
- "type": "string",
480
- "enum": [
481
- "PENDING",
482
- "SUCCESS",
483
- "FAILED",
484
- "SKIPPED"
485
- ]
486
- },
487
- "failure_reason": {
488
- "type": "string"
489
- },
490
- "dependencies": {
491
- "type": "object",
492
- "properties": {
493
- "input_refs": {
494
- "type": "array",
495
- "items": {
496
- "type": "string"
497
- }
498
- },
499
- "output_refs": {
500
- "type": "array",
501
- "items": {
502
- "type": "object",
503
- "properties": {
504
- "substep_id": {
505
- "type": "string"
506
- },
507
- "field_path": {
508
- "type": "string"
509
- }
510
- },
511
- "required": [
512
- "substep_id",
513
- "field_path"
514
- ],
515
- "additionalProperties": false
516
- }
517
- }
518
- },
519
- "required": [
520
- "input_refs",
521
- "output_refs"
522
- ],
523
- "additionalProperties": false
524
- },
525
- "retry_info": {
526
- "type": "object",
527
- "properties": {
528
- "original_step_id": {
529
- "type": "string"
530
- },
531
- "retry_count": {
532
- "type": "integer",
533
- "minimum": 0
534
- },
535
- "retry_reason": {
536
- "type": "string"
537
- }
538
- },
539
- "required": [
540
- "original_step_id",
541
- "retry_count",
542
- "retry_reason"
543
- ],
544
- "additionalProperties": false
545
- }
546
- },
547
- "required": [
548
- "step_id",
549
- "parent_step",
550
- "object_type",
551
- "entry_id",
552
- "operation_type",
553
- "network",
554
- "input",
555
- "timestamp",
556
- "status",
557
- "dependencies"
558
- ],
559
- "additionalProperties": false
200
+ "type": "string"
560
201
  },
561
- "description": "Substep records for trace_substeps."
202
+ "description": "Tags for add_object."
562
203
  },
563
- "target_stage": {
564
- "type": "integer",
565
- "minimum": 1,
566
- "maximum": 5,
567
- "description": "Stage number (1-5) for validate_stage_unit, get_stage_assessment, get_stage_risk_policy, and rollback_stage (the stage to rollback to). Required by these 4 actions."
204
+ "object_id_remove": {
205
+ "type": "string",
206
+ "description": "ProjectObject UUID for remove_object (the project_objects.id, NOT the on-chain address)."
568
207
  },
569
- "proposal_id": {
208
+ "object_id_update": {
570
209
  "type": "string",
571
- "description": "Improvement proposal ID (for apply_improvement). Required by apply_improvement."
210
+ "description": "ProjectObject UUID for update_object (the project_objects.id)."
572
211
  },
573
- "review_status": {
212
+ "object_name_update": {
574
213
  "type": "string",
575
- "enum": [
576
- "approved",
577
- "rejected",
578
- "applied"
579
- ],
580
- "description": "New review status to set (for apply_improvement). 'approved' triggers application (config_override or source_patch); 'rejected' marks as rejected; 'applied' marks as already applied."
214
+ "description": "New name for update_object."
215
+ },
216
+ "object_type_update": {
217
+ "type": "string",
218
+ "description": "New type for update_object."
581
219
  },
582
- "queue_filter_status": {
220
+ "object_role_update": {
583
221
  "type": "string",
584
222
  "enum": [
585
- "pending",
586
- "approved",
587
- "rejected",
588
- "applied"
223
+ "core",
224
+ "dependency",
225
+ "reference"
589
226
  ],
590
- "description": "Filter the improvement queue by review_status (for get_improvement_queue)."
227
+ "description": "New role for update_object."
591
228
  },
592
- "queue_filter_type": {
229
+ "object_tags_update": {
230
+ "type": "array",
231
+ "items": {
232
+ "type": "string"
233
+ },
234
+ "description": "New tags for update_object."
235
+ },
236
+ "version_description": {
593
237
  "type": "string",
594
- "description": "Filter the improvement queue by proposal type (for get_improvement_queue)."
238
+ "maxLength": 500,
239
+ "description": "Description for create_version."
595
240
  },
596
- "queue_filter_priority": {
241
+ "fork_from_version": {
597
242
  "type": "string",
598
- "description": "Filter the improvement queue by priority P0/P1/P2/P3 (for get_improvement_queue)."
243
+ "description": "Source version for create_version (fork objects + graph from this version)."
599
244
  },
600
- "dry_run": {
245
+ "max_depth": {
246
+ "type": "integer",
247
+ "minimum": 1,
248
+ "maximum": 5,
249
+ "description": "Max recursion depth for Pathway 1 (internal reference derivation) in build_graph. Default 3."
250
+ },
251
+ "enable_registrar": {
601
252
  "type": "boolean",
602
- "description": "When true, rollback_stage only evaluates the policy and returns the cleanup plan WITHOUT executing the rollback. Defaults to false (execute)."
253
+ "description": "Enable Pathway 2 (Registrar inbound query) in build_graph. Default true."
603
254
  },
604
- "query_object_type": {
605
- "type": "string",
606
- "description": "Object type for get_reversibility query (e.g. 'service', 'machine', 'guard'). When omitted, returns the full matrix."
255
+ "enable_potential": {
256
+ "type": "boolean",
257
+ "description": "Enable Pathway 3 (potential relationship detection) in build_graph. Default false."
607
258
  },
608
- "query_lifecycle_state": {
259
+ "evaluation_type": {
609
260
  "type": "string",
610
261
  "enum": [
611
- "created",
612
- "referenced",
613
- "published",
614
- "bound"
262
+ "risk",
263
+ "trust",
264
+ "completeness",
265
+ "value",
266
+ "worth_buying"
615
267
  ],
616
- "description": "Object lifecycle state for get_reversibility query. When omitted, returns all lifecycle states for the given object_type."
268
+ "description": "Evaluation type for evaluate_project. risk/trust/completeness are rule-based (computed locally). worth_buying/value require LLM assistance (returns a prompt for the caller to process)."
617
269
  },
618
- "context_objects": {
270
+ "refresh_before_eval": {
271
+ "type": "boolean",
272
+ "description": "When true, evaluate_project refreshes object cache from chain before evaluating. Default false."
273
+ },
274
+ "eval_score": {
275
+ "type": "number",
276
+ "minimum": 0,
277
+ "maximum": 100,
278
+ "description": "Overall evaluation score (0-100) for save_evaluation."
279
+ },
280
+ "eval_summary": {
281
+ "type": "string",
282
+ "maxLength": 1000,
283
+ "description": "Evaluation summary for save_evaluation."
284
+ },
285
+ "eval_details": {
286
+ "type": "object",
287
+ "additionalProperties": {},
288
+ "description": "Structured evaluation details for save_evaluation (criterion_scores, findings, etc.)."
289
+ },
290
+ "compare_project_ids": {
619
291
  "type": "array",
620
292
  "items": {
621
293
  "type": "string"
622
294
  },
623
- "description": "Object IDs (0x...) or LocalMark names to assemble context for. Required when action='assemble_context'. The current on-chain state of each object will be queried and enriched with semantic annotations."
295
+ "minItems": 2,
296
+ "description": "Array of project IDs to compare (for compare_projects). Minimum 2."
624
297
  },
625
- "include_events": {
626
- "type": "boolean",
627
- "description": "When true, assemble_context also queries recent state-transition events (NewOrderEvent, ProgressEvent, ArbEvent, etc.). Events are the real-time transition log — convergent and bounded. Defaults to false. Note: object-embedded history (ProgressSession.forwards, Order.disputes) is ALWAYS extracted automatically — no flag needed."
628
- },
629
- "context_network": {
298
+ "diff_address": {
630
299
  "type": "string",
631
- "enum": [
632
- "testnet",
633
- "mainnet"
634
- ],
635
- "description": "Network for assemble_context queries. Defaults to 'testnet' if omitted."
300
+ "description": "Object address for get_object_diff."
301
+ },
302
+ "diff_from_time": {
303
+ "type": "integer",
304
+ "description": "Start timestamp (ms) for get_object_diff."
305
+ },
306
+ "diff_to_time": {
307
+ "type": "integer",
308
+ "description": "End timestamp (ms) for get_object_diff."
636
309
  }
637
310
  },
638
311
  "required": [