@unified-product-graph/mcp-server 0.7.4 → 0.7.6
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.
- package/CHANGELOG.md +12 -0
- package/TOOLS.md +93 -73
- package/dist/index.js +453 -135
- package/dist/index.js.map +1 -1
- package/dist/tools-manifest.json +352 -101
- package/package.json +1 -1
package/dist/tools-manifest.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"schema_version": "2",
|
|
3
3
|
"package": "@unified-product-graph/mcp-server",
|
|
4
|
-
"package_version": "0.7.
|
|
5
|
-
"tool_count":
|
|
4
|
+
"package_version": "0.7.6",
|
|
5
|
+
"tool_count": 94,
|
|
6
6
|
"domains": [
|
|
7
7
|
"context",
|
|
8
8
|
"nodes",
|
|
@@ -12,9 +12,7 @@
|
|
|
12
12
|
"schema",
|
|
13
13
|
"spec",
|
|
14
14
|
"sync",
|
|
15
|
-
"validation"
|
|
16
|
-
"migrations",
|
|
17
|
-
"skills"
|
|
15
|
+
"validation"
|
|
18
16
|
],
|
|
19
17
|
"tools": [
|
|
20
18
|
{
|
|
@@ -42,9 +40,13 @@
|
|
|
42
40
|
"see": [
|
|
43
41
|
"get_product_context"
|
|
44
42
|
],
|
|
45
|
-
"source": "src/tools/context.ts:
|
|
43
|
+
"source": "src/tools/context.ts:241",
|
|
46
44
|
"symbol": "getGraphDigest",
|
|
47
45
|
"returns": "JSON object: `{ counts, health, chains, coverage, lifecycle,\nlens, lens_digest, _hash }`. ~500 tokens vs ~5-8K for equivalent manual\nfetches.",
|
|
46
|
+
"return_shape": "{ counts, health, chains, coverage, lifecycle, lens, lens_digest, _hash }",
|
|
47
|
+
"return_notes": [
|
|
48
|
+
"~500 tokens vs ~5-8K for equivalent manual fetches."
|
|
49
|
+
],
|
|
48
50
|
"atomicity": "atomic (read-only)"
|
|
49
51
|
},
|
|
50
52
|
{
|
|
@@ -77,9 +79,12 @@
|
|
|
77
79
|
"get_graph_digest",
|
|
78
80
|
"get_entity_schema"
|
|
79
81
|
],
|
|
80
|
-
"source": "src/tools/context.ts:
|
|
82
|
+
"source": "src/tools/context.ts:56",
|
|
81
83
|
"symbol": "getProductContext",
|
|
82
84
|
"returns": "Markdown string with product header, lens preamble, entity counts,\nactive-domain creation sequences, and `_hash` footer for `if_changed_since`\ndiffing.",
|
|
85
|
+
"return_notes": [
|
|
86
|
+
"Markdown string with product header, lens preamble, entity counts, active-domain creation sequences, and `_hash` footer for `if_changed_since` diffing."
|
|
87
|
+
],
|
|
83
88
|
"atomicity": "atomic (read-only)"
|
|
84
89
|
},
|
|
85
90
|
{
|
|
@@ -102,9 +107,41 @@
|
|
|
102
107
|
"see": [
|
|
103
108
|
"update_session_context"
|
|
104
109
|
],
|
|
105
|
-
"source": "src/tools/context.ts:
|
|
110
|
+
"source": "src/tools/context.ts:417",
|
|
106
111
|
"symbol": "getSessionContext",
|
|
107
112
|
"returns": "JSON: `{ lens, skills_invoked, recommendations_given,\nrecommendations_to_avoid, focus_area, custom, skills_count, last_skill,\nlast_recommendation }`. `recommendations_to_avoid` is the deduped list of\nevery recommendation given this session; runners should filter their\nnext recommendation against this array rather than re-deriving the\ndedup rule from prose.",
|
|
113
|
+
"return_shape": "{ lens, skills_invoked, recommendations_given, recommendations_to_avoid, focus_area, custom, skills_count, last_skill, last_recommendation }",
|
|
114
|
+
"return_notes": [
|
|
115
|
+
"`recommendations_to_avoid` is the deduped list of every recommendation given this session; runners should filter their next recommendation against this array rather than re-deriving the dedup rule from prose."
|
|
116
|
+
],
|
|
117
|
+
"atomicity": "atomic (read-only)"
|
|
118
|
+
},
|
|
119
|
+
{
|
|
120
|
+
"name": "start",
|
|
121
|
+
"description": "Zero-state on-ramp: \"there is nothing here yet, where do I begin?\". Reads the live graph and, for an empty or barely-started graph, recommends the first canonical playbook (from UPG_PLAYBOOKS) plus the exact create_node call for its anchor entity. Established graphs are routed to plan / inspect / get_graph_digest instead. Takes no arguments.",
|
|
122
|
+
"domain": "context",
|
|
123
|
+
"inputSchema": {
|
|
124
|
+
"type": "object",
|
|
125
|
+
"properties": {}
|
|
126
|
+
},
|
|
127
|
+
"throws": [],
|
|
128
|
+
"examples": [
|
|
129
|
+
"// Input (empty graph):\n{}\n// Output (truncated):\n{\n \"graph_state\": \"empty\",\n \"node_count\": 0,\n \"recommended_playbook\": { \"id\": \"playbook:users-needs\", \"name\": \"Users & Needs\", \"target_anchor_entity\": \"persona\" },\n \"first_action\": { \"tool\": \"create_node\", \"args\": { \"type\": \"persona\", \"title\": \"<your first persona>\" } },\n \"recommendation\": \"Your graph is empty. Begin with the \\\"Users & Needs\\\" playbook: create your first persona.\"\n}"
|
|
130
|
+
],
|
|
131
|
+
"warnings": [],
|
|
132
|
+
"see": [
|
|
133
|
+
"plan",
|
|
134
|
+
"get_playbook",
|
|
135
|
+
"list_playbooks",
|
|
136
|
+
"get_graph_digest"
|
|
137
|
+
],
|
|
138
|
+
"source": "src/tools/context.ts:326",
|
|
139
|
+
"symbol": "start",
|
|
140
|
+
"returns": "JSON: `{ graph_state: \"empty\" | \"young\" | \"established\", product,\nnode_count, recommended_playbook?, first_action?, recommendation,\nnext_tools }`. `recommended_playbook` and `first_action` are present only\nfor empty/young graphs.",
|
|
141
|
+
"return_shape": "{ graph_state: \"empty\" | \"young\" | \"established\", product, node_count, recommended_playbook?, first_action?, recommendation, next_tools }",
|
|
142
|
+
"return_notes": [
|
|
143
|
+
"`recommended_playbook` and `first_action` are present only for empty/young graphs."
|
|
144
|
+
],
|
|
108
145
|
"atomicity": "atomic (read-only)"
|
|
109
146
|
},
|
|
110
147
|
{
|
|
@@ -158,9 +195,13 @@
|
|
|
158
195
|
"see": [
|
|
159
196
|
"get_session_context"
|
|
160
197
|
],
|
|
161
|
-
"source": "src/tools/context.ts:
|
|
198
|
+
"source": "src/tools/context.ts:458",
|
|
162
199
|
"symbol": "updateSessionContext",
|
|
163
200
|
"returns": "JSON: `{ updated: true, session: SessionContext }` reflecting the\nnew state.",
|
|
201
|
+
"return_shape": "{ updated: true, session: SessionContext }",
|
|
202
|
+
"return_notes": [
|
|
203
|
+
"reflecting the new state."
|
|
204
|
+
],
|
|
164
205
|
"atomicity": "non-atomic. Session mutates in-memory immediately; lens\npersistence flushes the .upg file as a separate side-effect that may\nsucceed or fail independently of the session update."
|
|
165
206
|
},
|
|
166
207
|
{
|
|
@@ -263,9 +304,10 @@
|
|
|
263
304
|
"create_node",
|
|
264
305
|
"batch_create_edges"
|
|
265
306
|
],
|
|
266
|
-
"source": "src/tools/nodes.ts:
|
|
307
|
+
"source": "src/tools/nodes.ts:991",
|
|
267
308
|
"symbol": "batchCreateNodes",
|
|
268
309
|
"returns": "JSON: `{ created, edges_created, count, edges_count, warnings? }`.",
|
|
310
|
+
"return_shape": "{ created, edges_created, count, edges_count, warnings? }",
|
|
269
311
|
"atomicity": "atomic-with-rollback. Full validation pass first, then commit."
|
|
270
312
|
},
|
|
271
313
|
{
|
|
@@ -301,9 +343,10 @@
|
|
|
301
343
|
"see": [
|
|
302
344
|
"delete_node"
|
|
303
345
|
],
|
|
304
|
-
"source": "src/tools/nodes.ts:
|
|
346
|
+
"source": "src/tools/nodes.ts:1095",
|
|
305
347
|
"symbol": "batchDeleteNodes",
|
|
306
348
|
"returns": "JSON: `{ deleted, edges_removed, count }`.",
|
|
349
|
+
"return_shape": "{ deleted, edges_removed, count }",
|
|
307
350
|
"atomicity": "atomic. Validation pass rejects the entire batch before any\nmutation lands."
|
|
308
351
|
},
|
|
309
352
|
{
|
|
@@ -361,9 +404,13 @@
|
|
|
361
404
|
"see": [
|
|
362
405
|
"update_node"
|
|
363
406
|
],
|
|
364
|
-
"source": "src/tools/nodes.ts:
|
|
407
|
+
"source": "src/tools/nodes.ts:1019",
|
|
365
408
|
"symbol": "batchUpdateNodes",
|
|
366
409
|
"returns": "JSON: `{ updated, count, warnings? }`. `warnings` carries\nlifecycle-phase hints aggregated across the batch.",
|
|
410
|
+
"return_shape": "{ updated, count, warnings? }",
|
|
411
|
+
"return_notes": [
|
|
412
|
+
"`warnings` carries lifecycle-phase hints aggregated across the batch."
|
|
413
|
+
],
|
|
367
414
|
"atomicity": "atomic. Validation pass rejects the entire batch before any\nmutation lands."
|
|
368
415
|
},
|
|
369
416
|
{
|
|
@@ -429,9 +476,16 @@
|
|
|
429
476
|
"batch_create_nodes",
|
|
430
477
|
"update_node"
|
|
431
478
|
],
|
|
432
|
-
"source": "src/tools/nodes.ts:
|
|
479
|
+
"source": "src/tools/nodes.ts:727",
|
|
433
480
|
"symbol": "createNode",
|
|
434
|
-
"returns": "JSON: `{ node, edge?, unknown_properties?, warning? }`. The `edge`\nfield is present only when `parent_id` was supplied and a canonical\nhierarchy edge could be inferred. `unknown_properties` and `warning` are\npresent when the caller passed properties not in the entity's schema
|
|
481
|
+
"returns": "JSON: `{ node, edge?, unknown_properties?, warning? }`. The `edge`\nfield is present only when `parent_id` was supplied and a canonical\nhierarchy edge could be inferred. `unknown_properties` and `warning` are\npresent when the caller passed properties not in the entity's schema.\nPass `strict: true` to reject unknown properties instead of\nwarning. For portfolio-scoped types the response shape is\n`{ node, portfolio_file, written_to, warning? }` where `node` is the\npersisted typed record.",
|
|
482
|
+
"return_shape": "{ node, edge?, unknown_properties?, warning? }",
|
|
483
|
+
"return_notes": [
|
|
484
|
+
"The `edge` field is present only when `parent_id` was supplied and a canonical hierarchy edge could be inferred.",
|
|
485
|
+
"`unknown_properties` and `warning` are present when the caller passed properties not in the entity's schema.",
|
|
486
|
+
"Pass `strict: true` to reject unknown properties instead of warning.",
|
|
487
|
+
"For portfolio-scoped types the response shape is `{ node, portfolio_file, written_to, warning? }` where `node` is the persisted typed record."
|
|
488
|
+
],
|
|
435
489
|
"atomicity": "atomic-with-rollback. Schema validation runs before mutation."
|
|
436
490
|
},
|
|
437
491
|
{
|
|
@@ -474,9 +528,13 @@
|
|
|
474
528
|
"batch_delete_nodes",
|
|
475
529
|
"validate_graph"
|
|
476
530
|
],
|
|
477
|
-
"source": "src/tools/nodes.ts:
|
|
531
|
+
"source": "src/tools/nodes.ts:1340",
|
|
478
532
|
"symbol": "deduplicateNodes",
|
|
479
533
|
"returns": "JSON: with `dry_run: true`, `{ duplicates, total_groups,\ntotal_duplicate_nodes, dry_run, message }`. With `dry_run: false`,\n`{ merged: true, groups_merged, nodes_removed, edges_redirected,\nstrategy }`.",
|
|
534
|
+
"return_notes": [
|
|
535
|
+
"JSON: with `dry_run: true`, `{ duplicates, total_groups, total_duplicate_nodes, dry_run, message }`.",
|
|
536
|
+
"With `dry_run: false`, `{ merged: true, groups_merged, nodes_removed, edges_redirected, strategy }`."
|
|
537
|
+
],
|
|
480
538
|
"atomicity": "non-atomic. Merges are applied group-by-group; a mid-flight\nerror leaves earlier groups merged."
|
|
481
539
|
},
|
|
482
540
|
{
|
|
@@ -509,9 +567,10 @@
|
|
|
509
567
|
"see": [
|
|
510
568
|
"batch_delete_nodes"
|
|
511
569
|
],
|
|
512
|
-
"source": "src/tools/nodes.ts:
|
|
570
|
+
"source": "src/tools/nodes.ts:965",
|
|
513
571
|
"symbol": "deleteNode",
|
|
514
572
|
"returns": "JSON: `{ node, removed_edge_ids }`.",
|
|
573
|
+
"return_shape": "{ node, removed_edge_ids }",
|
|
515
574
|
"atomicity": "atomic. Node + cascading edges removed in one mutation."
|
|
516
575
|
},
|
|
517
576
|
{
|
|
@@ -548,9 +607,13 @@
|
|
|
548
607
|
"see": [
|
|
549
608
|
"get_nodes"
|
|
550
609
|
],
|
|
551
|
-
"source": "src/tools/nodes.ts:
|
|
610
|
+
"source": "src/tools/nodes.ts:207",
|
|
552
611
|
"symbol": "getNode",
|
|
553
612
|
"returns": "JSON: the node object plus an `edges` array. `compact_edges: true`\nomits `source_title` and `target_title` (saves ~30% on edge-heavy nodes).",
|
|
613
|
+
"return_notes": [
|
|
614
|
+
"JSON: the node object plus an `edges` array.",
|
|
615
|
+
"`compact_edges: true` omits `source_title` and `target_title` (saves ~30% on edge-heavy nodes)."
|
|
616
|
+
],
|
|
554
617
|
"atomicity": "atomic (read-only)"
|
|
555
618
|
},
|
|
556
619
|
{
|
|
@@ -593,9 +656,14 @@
|
|
|
593
656
|
"see": [
|
|
594
657
|
"get_node"
|
|
595
658
|
],
|
|
596
|
-
"source": "src/tools/nodes.ts:
|
|
659
|
+
"source": "src/tools/nodes.ts:251",
|
|
597
660
|
"symbol": "getNodes",
|
|
598
661
|
"returns": "JSON array of node objects with edges. Missing IDs are silently\nskipped. May include a `degraded` block when the response was\nauto-trimmed to fit.",
|
|
662
|
+
"return_notes": [
|
|
663
|
+
"JSON array of node objects with edges.",
|
|
664
|
+
"Missing IDs are silently skipped.",
|
|
665
|
+
"May include a `degraded` block when the response was auto-trimmed to fit."
|
|
666
|
+
],
|
|
599
667
|
"atomicity": "atomic (read-only)"
|
|
600
668
|
},
|
|
601
669
|
{
|
|
@@ -662,9 +730,14 @@
|
|
|
662
730
|
"search_nodes",
|
|
663
731
|
"query"
|
|
664
732
|
],
|
|
665
|
-
"source": "src/tools/nodes.ts:
|
|
733
|
+
"source": "src/tools/nodes.ts:107",
|
|
666
734
|
"symbol": "listNodes",
|
|
667
735
|
"returns": "JSON: `{ nodes, total, offset, limit, _hash }`. With\n`count_only: true`, returns `{ total, _hash }` only. May include a\n`degraded` block when the response was auto-trimmed to fit.",
|
|
736
|
+
"return_shape": "{ nodes, total, offset, limit, _hash }",
|
|
737
|
+
"return_notes": [
|
|
738
|
+
"With `count_only: true`, returns `{ total, _hash }` only.",
|
|
739
|
+
"May include a `degraded` block when the response was auto-trimmed to fit."
|
|
740
|
+
],
|
|
668
741
|
"atomicity": "atomic (read-only)"
|
|
669
742
|
},
|
|
670
743
|
{
|
|
@@ -696,11 +769,64 @@
|
|
|
696
769
|
"validate_graph",
|
|
697
770
|
"list_type_migrations"
|
|
698
771
|
],
|
|
699
|
-
"source": "src/tools/nodes.ts:
|
|
772
|
+
"source": "src/tools/nodes.ts:1286",
|
|
700
773
|
"symbol": "migrateProperties",
|
|
701
774
|
"returns": "JSON: `{ top_level_renames, lifted_properties, dropped_props,\ndropped_self_referential, dry_run }`.",
|
|
775
|
+
"return_shape": "{ top_level_renames, lifted_properties, dropped_props, dropped_self_referential, dry_run }",
|
|
702
776
|
"atomicity": "non-atomic. Mutations are applied node-by-node; a mid-flight\nerror may leave the graph partially migrated."
|
|
703
777
|
},
|
|
778
|
+
{
|
|
779
|
+
"name": "migrate_status",
|
|
780
|
+
"description": "Apply `UPG_STATUS_MIGRATIONS` graph-wide: rewrite legacy lifecycle status values to canonical phase ids. Auto-mode (no filters) selects nodes whose current status is invalid against the entity type's lifecycle and has a registered replacement (the same invariant that drives `validate_graph` lifecycle_drift). Surgical mode (`from_status` + `to_status`) overrides the registry and rewrites every (entity_type?, from_status) match. Nodes with invalid statuses but no registered replacement surface under `skipped_no_migration`. Default `dry_run=true`; pass `dry_run=false` to commit.",
|
|
781
|
+
"domain": "nodes",
|
|
782
|
+
"inputSchema": {
|
|
783
|
+
"type": "object",
|
|
784
|
+
"properties": {
|
|
785
|
+
"entity_type": {
|
|
786
|
+
"type": "string",
|
|
787
|
+
"description": "Optional. Restrict the rewrite to nodes of this canonical entity type (e.g. \"service\", \"feature\")."
|
|
788
|
+
},
|
|
789
|
+
"from_status": {
|
|
790
|
+
"type": "string",
|
|
791
|
+
"description": "Optional. Restrict the rewrite to nodes whose current status equals this exact value. When provided, `to_status` is required and the registry is bypassed."
|
|
792
|
+
},
|
|
793
|
+
"to_status": {
|
|
794
|
+
"type": "string",
|
|
795
|
+
"description": "Required when `from_status` is provided. The canonical phase id to write."
|
|
796
|
+
},
|
|
797
|
+
"dry_run": {
|
|
798
|
+
"type": "boolean",
|
|
799
|
+
"description": "Preview changes without applying (default true). Pass false to commit."
|
|
800
|
+
}
|
|
801
|
+
}
|
|
802
|
+
},
|
|
803
|
+
"throws": [
|
|
804
|
+
"Returns a textError when `from_status` is provided without\n`to_status`, or when `entity_type` is provided but isn't a string."
|
|
805
|
+
],
|
|
806
|
+
"examples": [
|
|
807
|
+
{
|
|
808
|
+
"description": "Live call against the Notion example graph.",
|
|
809
|
+
"input": "{}",
|
|
810
|
+
"output": "{\n \"migrated_nodes\": 0,\n \"skipped_no_migration\": 0,\n \"changes\": [],\n \"dry_run\": true\n}"
|
|
811
|
+
}
|
|
812
|
+
],
|
|
813
|
+
"warnings": [
|
|
814
|
+
"Default is `dry_run: true`. Pass `dry_run: false` to commit.\nIdempotent on retry; re-running after a successful commit reports\nzero changes (canonical statuses pass the validity check)."
|
|
815
|
+
],
|
|
816
|
+
"see": [
|
|
817
|
+
"migrate_type",
|
|
818
|
+
"migrate_properties",
|
|
819
|
+
"validate_graph",
|
|
820
|
+
"list_lifecycles"
|
|
821
|
+
],
|
|
822
|
+
"source": "src/tools/migrations.ts:64",
|
|
823
|
+
"symbol": "migrateStatus",
|
|
824
|
+
"returns": "JSON: `MigrateStatusResult`.",
|
|
825
|
+
"return_notes": [
|
|
826
|
+
"JSON: `MigrateStatusResult`."
|
|
827
|
+
],
|
|
828
|
+
"atomicity": "per-node. Status writes go through `store.updateNode`\none at a time. Dry-run is read-only."
|
|
829
|
+
},
|
|
704
830
|
{
|
|
705
831
|
"name": "migrate_type",
|
|
706
832
|
"description": "Migrate every entity of one type to another, applying defaults from `UPG_MIGRATIONS`. Three passes commit as one write: (1) node rename, (2) edges through `UPG_EDGE_MIGRATIONS` (catalog-aware renames, direction flips, drops; endpoint guards check post-migration types; uncatalogued edges surface as `unmapped_legacy_edges`), (3) every node through `UPG_PROPERTY_MIGRATIONS` (top-level renames, lifts, drops, self-referential cleanup). Type-specific property rules see the post-rename type.",
|
|
@@ -742,9 +868,14 @@
|
|
|
742
868
|
"export_edges",
|
|
743
869
|
"update_node"
|
|
744
870
|
],
|
|
745
|
-
"source": "src/tools/nodes.ts:
|
|
871
|
+
"source": "src/tools/nodes.ts:1149",
|
|
746
872
|
"symbol": "migrateType",
|
|
747
873
|
"returns": "JSON: `{ migrated_nodes, migrated_edges, edge_renames,\ndropped_edges, unmapped_legacy_edges, defaults_applied, dry_run }`.\n`edge_renames` is `[{ id, from, to, flipped }]`; `dropped_edges` is\n`[{ id, from }]`; `unmapped_legacy_edges` is `[{ type, count }]`.\n`migrated_edges` is the total mutated count (renames + drops).",
|
|
874
|
+
"return_shape": "{ migrated_nodes, migrated_edges, edge_renames, dropped_edges, unmapped_legacy_edges, defaults_applied, dry_run }",
|
|
875
|
+
"return_notes": [
|
|
876
|
+
"`edge_renames` is `[{ id, from, to, flipped }]`; `dropped_edges` is `[{ id, from }]`; `unmapped_legacy_edges` is `[{ type, count }]`.",
|
|
877
|
+
"`migrated_edges` is the total mutated count (renames + drops)."
|
|
878
|
+
],
|
|
748
879
|
"atomicity": "atomic. Single store-level migration call commits or fails as\none mutation. Note: full graph canonicalisation runs as a side-effect of\nany node-type migration, so unrelated legacy edges may also be retargeted."
|
|
749
880
|
},
|
|
750
881
|
{
|
|
@@ -821,9 +952,13 @@
|
|
|
821
952
|
"list_nodes",
|
|
822
953
|
"get_area_graph"
|
|
823
954
|
],
|
|
824
|
-
"source": "src/tools/nodes.ts:
|
|
955
|
+
"source": "src/tools/nodes.ts:406",
|
|
825
956
|
"symbol": "query",
|
|
826
957
|
"returns": "JSON: `{ nodes, edges, total_nodes, total_edges, _result_id,\ntruncated?, truncated_at_depth?, diff? }`. The `_result_id` is a cache\nhandle for `diff_from`; cache holds the last 20 results.",
|
|
958
|
+
"return_shape": "{ nodes, edges, total_nodes, total_edges, _result_id, truncated?, truncated_at_depth?, diff? }",
|
|
959
|
+
"return_notes": [
|
|
960
|
+
"The `_result_id` is a cache handle for `diff_from`; cache holds the last 20 results."
|
|
961
|
+
],
|
|
827
962
|
"atomicity": "atomic (read-only)"
|
|
828
963
|
},
|
|
829
964
|
{
|
|
@@ -872,9 +1007,10 @@
|
|
|
872
1007
|
"list_nodes",
|
|
873
1008
|
"query"
|
|
874
1009
|
],
|
|
875
|
-
"source": "src/tools/nodes.ts:
|
|
1010
|
+
"source": "src/tools/nodes.ts:355",
|
|
876
1011
|
"symbol": "searchNodes",
|
|
877
1012
|
"returns": "JSON: `{ results: Array<{ id, type, title, status, tags,\nmatch_field, score }>, total, searched_fields }`.",
|
|
1013
|
+
"return_shape": "{ results: Array<{ id, type, title, status, tags, match_field, score }>, total, searched_fields }",
|
|
878
1014
|
"atomicity": "atomic (read-only)"
|
|
879
1015
|
},
|
|
880
1016
|
{
|
|
@@ -931,9 +1067,15 @@
|
|
|
931
1067
|
"migrate_type",
|
|
932
1068
|
"batch_update_nodes"
|
|
933
1069
|
],
|
|
934
|
-
"source": "src/tools/nodes.ts:
|
|
1070
|
+
"source": "src/tools/nodes.ts:874",
|
|
935
1071
|
"symbol": "updateNode",
|
|
936
1072
|
"returns": "JSON: `{ node, warning?, unknown_properties? }`. `warning`\naggregates lifecycle-status hints, migration warnings, and any\nunknown-property notice. `unknown_properties` lists property\nkeys not in the entity's schema. Pass `strict: true` to reject unknown\nproperties instead of warning.",
|
|
1073
|
+
"return_shape": "{ node, warning?, unknown_properties? }",
|
|
1074
|
+
"return_notes": [
|
|
1075
|
+
"`warning` aggregates lifecycle-status hints, migration warnings, and any unknown-property notice.",
|
|
1076
|
+
"`unknown_properties` lists property keys not in the entity's schema.",
|
|
1077
|
+
"Pass `strict: true` to reject unknown properties instead of warning."
|
|
1078
|
+
],
|
|
937
1079
|
"atomicity": "atomic-with-rollback (when `type` is changed); atomic for\nshallow-merge patches."
|
|
938
1080
|
},
|
|
939
1081
|
{
|
|
@@ -984,6 +1126,7 @@
|
|
|
984
1126
|
"source": "src/tools/edges.ts:209",
|
|
985
1127
|
"symbol": "batchCreateEdges",
|
|
986
1128
|
"returns": "JSON: `{ created, count }`.",
|
|
1129
|
+
"return_shape": "{ created, count }",
|
|
987
1130
|
"atomicity": "atomic. Full validation pass before any mutation lands."
|
|
988
1131
|
},
|
|
989
1132
|
{
|
|
@@ -1022,6 +1165,7 @@
|
|
|
1022
1165
|
"source": "src/tools/edges.ts:293",
|
|
1023
1166
|
"symbol": "batchDeleteEdges",
|
|
1024
1167
|
"returns": "JSON: `{ deleted, count }`.",
|
|
1168
|
+
"return_shape": "{ deleted, count }",
|
|
1025
1169
|
"atomicity": "atomic. Validation pass rejects the batch before any mutation\nlands."
|
|
1026
1170
|
},
|
|
1027
1171
|
{
|
|
@@ -1072,6 +1216,10 @@
|
|
|
1072
1216
|
"source": "src/tools/edges.ts:177",
|
|
1073
1217
|
"symbol": "batchMoveNodes",
|
|
1074
1218
|
"returns": "JSON: `{ moves, warnings? }` mirroring the per-move result of\n`move_node`.",
|
|
1219
|
+
"return_shape": "{ moves, warnings? }",
|
|
1220
|
+
"return_notes": [
|
|
1221
|
+
"mirroring the per-move result of `move_node`."
|
|
1222
|
+
],
|
|
1075
1223
|
"atomicity": "atomic-with-rollback."
|
|
1076
1224
|
},
|
|
1077
1225
|
{
|
|
@@ -1122,6 +1270,9 @@
|
|
|
1122
1270
|
"source": "src/tools/edges.ts:85",
|
|
1123
1271
|
"symbol": "createEdge",
|
|
1124
1272
|
"returns": "JSON: the created edge object plus optional resolution metadata.",
|
|
1273
|
+
"return_notes": [
|
|
1274
|
+
"JSON: the created edge object plus optional resolution metadata."
|
|
1275
|
+
],
|
|
1125
1276
|
"atomicity": "atomic. Single store mutation."
|
|
1126
1277
|
},
|
|
1127
1278
|
{
|
|
@@ -1153,6 +1304,9 @@
|
|
|
1153
1304
|
"source": "src/tools/edges.ts:122",
|
|
1154
1305
|
"symbol": "deleteEdge",
|
|
1155
1306
|
"returns": "JSON: the removed edge object.",
|
|
1307
|
+
"return_notes": [
|
|
1308
|
+
"JSON: the removed edge object."
|
|
1309
|
+
],
|
|
1156
1310
|
"atomicity": "atomic."
|
|
1157
1311
|
},
|
|
1158
1312
|
{
|
|
@@ -1201,6 +1355,10 @@
|
|
|
1201
1355
|
"source": "src/tools/edges.ts:403",
|
|
1202
1356
|
"symbol": "exportEdges",
|
|
1203
1357
|
"returns": "JSON: `{ edges, total, offset, limit, types?, _hash }`. Each edge\ncarries `{ id, source, target, type, mapping_confidence? }`.",
|
|
1358
|
+
"return_shape": "{ edges, total, offset, limit, types?, _hash }",
|
|
1359
|
+
"return_notes": [
|
|
1360
|
+
"Each edge carries `{ id, source, target, type, mapping_confidence? }`."
|
|
1361
|
+
],
|
|
1204
1362
|
"atomicity": "atomic (read-only)"
|
|
1205
1363
|
},
|
|
1206
1364
|
{
|
|
@@ -1243,6 +1401,10 @@
|
|
|
1243
1401
|
"source": "src/tools/edges.ts:149",
|
|
1244
1402
|
"symbol": "moveNode",
|
|
1245
1403
|
"returns": "JSON: `{ moved: true, node_id, new_parent_id, new_edge,\nold_edge_id?, warning? }`. The internal `removed_edge` field is stripped\nfrom the wire payload.",
|
|
1404
|
+
"return_shape": "{ moved: true, node_id, new_parent_id, new_edge, old_edge_id?, warning? }",
|
|
1405
|
+
"return_notes": [
|
|
1406
|
+
"The internal `removed_edge` field is stripped from the wire payload."
|
|
1407
|
+
],
|
|
1246
1408
|
"atomicity": "atomic-with-rollback. Pre-validates the new edge before\ntouching the old one."
|
|
1247
1409
|
},
|
|
1248
1410
|
{
|
|
@@ -1286,6 +1448,10 @@
|
|
|
1286
1448
|
"source": "src/tools/edges.ts:490",
|
|
1287
1449
|
"symbol": "renameEdgeType",
|
|
1288
1450
|
"returns": "JSON: with `dry_run: true`, `{ dry_run, from, to, flip, would_rename, sample }`.\nWith `dry_run: false`, `{ dry_run, from, to, flip, renamed, ids }`.",
|
|
1451
|
+
"return_notes": [
|
|
1452
|
+
"JSON: with `dry_run: true`, `{ dry_run, from, to, flip, would_rename, sample }`.",
|
|
1453
|
+
"With `dry_run: false`, `{ dry_run, from, to, flip, renamed, ids }`."
|
|
1454
|
+
],
|
|
1289
1455
|
"atomicity": "atomic. Single-pass mutation; an empty match-set is a clean\nno-op rather than an error."
|
|
1290
1456
|
},
|
|
1291
1457
|
{
|
|
@@ -1330,6 +1496,11 @@
|
|
|
1330
1496
|
"source": "src/tools/edges.ts:337",
|
|
1331
1497
|
"symbol": "repairDanglingEdges",
|
|
1332
1498
|
"returns": "JSON: `{ dry_run, report, dropped?, remaining? }`. `report` is\nthe pre-action classification. With `dry_run: false`, `dropped` is the\ncount of edges removed and `remaining` is the post-action report.",
|
|
1499
|
+
"return_shape": "{ dry_run, report, dropped?, remaining? }",
|
|
1500
|
+
"return_notes": [
|
|
1501
|
+
"`report` is the pre-action classification.",
|
|
1502
|
+
"With `dry_run: false`, `dropped` is the count of edges removed and `remaining` is the post-action report."
|
|
1503
|
+
],
|
|
1333
1504
|
"atomicity": "atomic-with-rollback. Classification runs against the live\ndocument before any mutation; with `dry_run: false`, the drop set is\ncomputed up-front and applied in a single index rebuild."
|
|
1334
1505
|
},
|
|
1335
1506
|
{
|
|
@@ -1387,6 +1558,10 @@
|
|
|
1387
1558
|
"source": "src/tools/areas.ts:261",
|
|
1388
1559
|
"symbol": "createArea",
|
|
1389
1560
|
"returns": "JSON: `{ node, portfolio_file, written_to }`. `node` is the typed\n`UPGProductArea` record persisted to `portfolio_areas[]`.",
|
|
1561
|
+
"return_shape": "{ node, portfolio_file, written_to }",
|
|
1562
|
+
"return_notes": [
|
|
1563
|
+
"`node` is the typed `UPGProductArea` record persisted to `portfolio_areas[]`."
|
|
1564
|
+
],
|
|
1390
1565
|
"atomicity": "atomic per write; the portfolio file is read, mutated, and\nflushed in one pass."
|
|
1391
1566
|
},
|
|
1392
1567
|
{
|
|
@@ -1410,6 +1585,10 @@
|
|
|
1410
1585
|
"source": "src/tools/areas.ts:211",
|
|
1411
1586
|
"symbol": "getAreaContext",
|
|
1412
1587
|
"returns": "JSON: `{ has_area_context: false }` or\n`{ has_area_context: true, area_id, area_name, found_at }`.",
|
|
1588
|
+
"return_shape": "{ has_area_context: false }",
|
|
1589
|
+
"return_notes": [
|
|
1590
|
+
"or `{ has_area_context: true, area_id, area_name, found_at }`."
|
|
1591
|
+
],
|
|
1413
1592
|
"atomicity": "atomic (read-only)"
|
|
1414
1593
|
},
|
|
1415
1594
|
{
|
|
@@ -1446,6 +1625,10 @@
|
|
|
1446
1625
|
"source": "src/tools/areas.ts:69",
|
|
1447
1626
|
"symbol": "getAreaGraph",
|
|
1448
1627
|
"returns": "JSON: `{ area, nodes, edges, node_count, edge_count }`. May\ninclude a `degraded` block when the response was auto-trimmed.",
|
|
1628
|
+
"return_shape": "{ area, nodes, edges, node_count, edge_count }",
|
|
1629
|
+
"return_notes": [
|
|
1630
|
+
"May include a `degraded` block when the response was auto-trimmed."
|
|
1631
|
+
],
|
|
1449
1632
|
"atomicity": "atomic (read-only)"
|
|
1450
1633
|
},
|
|
1451
1634
|
{
|
|
@@ -1474,6 +1657,10 @@
|
|
|
1474
1657
|
"source": "src/tools/areas.ts:300",
|
|
1475
1658
|
"symbol": "getChanges",
|
|
1476
1659
|
"returns": "JSON: `{ changes, summary: { create, update, delete }, total }`.\n`since` filters to ISO 8601 timestamps after the cutoff.",
|
|
1660
|
+
"return_shape": "{ changes, summary: { create, update, delete }, total }",
|
|
1661
|
+
"return_notes": [
|
|
1662
|
+
"`since` filters to ISO 8601 timestamps after the cutoff."
|
|
1663
|
+
],
|
|
1477
1664
|
"atomicity": "atomic (read-only)"
|
|
1478
1665
|
},
|
|
1479
1666
|
{
|
|
@@ -1500,6 +1687,7 @@
|
|
|
1500
1687
|
"source": "src/tools/areas.ts:33",
|
|
1501
1688
|
"symbol": "listProductAreas",
|
|
1502
1689
|
"returns": "JSON: `{ areas: Array<{ id, title, strategic_priority?,\nparent_area_id?, products? }>, total }`.",
|
|
1690
|
+
"return_shape": "{ areas: Array<{ id, title, strategic_priority?, parent_area_id?, products? }>, total }",
|
|
1503
1691
|
"atomicity": "atomic (read-only)"
|
|
1504
1692
|
},
|
|
1505
1693
|
{
|
|
@@ -1557,6 +1745,7 @@
|
|
|
1557
1745
|
"source": "src/tools/workspace.ts:395",
|
|
1558
1746
|
"symbol": "createCrossProductEdge",
|
|
1559
1747
|
"returns": "JSON: `{ edge, portfolio_file }`.",
|
|
1748
|
+
"return_shape": "{ edge, portfolio_file }",
|
|
1560
1749
|
"atomicity": "non-atomic. Portfolio file create (if new) + edge append are\nseparate filesystem operations."
|
|
1561
1750
|
},
|
|
1562
1751
|
{
|
|
@@ -1608,6 +1797,10 @@
|
|
|
1608
1797
|
"source": "src/tools/workspace.ts:275",
|
|
1609
1798
|
"symbol": "createProductTool",
|
|
1610
1799
|
"returns": "JSON: `{ message, ...result }`. `result` carries `id`, `title`,\n`slug`, `file_path`, and the optional portfolio edge.",
|
|
1800
|
+
"return_shape": "{ message,...result }",
|
|
1801
|
+
"return_notes": [
|
|
1802
|
+
"`result` carries `id`, `title`, `slug`, `file_path`, and the optional portfolio edge."
|
|
1803
|
+
],
|
|
1611
1804
|
"atomicity": "non-atomic. File write + workspace.json patch + optional\nportfolio edge are separate mutations."
|
|
1612
1805
|
},
|
|
1613
1806
|
{
|
|
@@ -1633,6 +1826,10 @@
|
|
|
1633
1826
|
"source": "src/tools/workspace.ts:344",
|
|
1634
1827
|
"symbol": "getOrganization",
|
|
1635
1828
|
"returns": "JSON: `{ organization: UPGOrganization | null, portfolio_file? }`.\nReturns `{ organization: null }` when no portfolio document exists yet.",
|
|
1829
|
+
"return_shape": "{ organization: UPGOrganization | null, portfolio_file? }",
|
|
1830
|
+
"return_notes": [
|
|
1831
|
+
"Returns `{ organization: null }` when no portfolio document exists yet."
|
|
1832
|
+
],
|
|
1636
1833
|
"atomicity": "atomic (read-only)"
|
|
1637
1834
|
},
|
|
1638
1835
|
{
|
|
@@ -1658,6 +1855,10 @@
|
|
|
1658
1855
|
"source": "src/tools/workspace.ts:163",
|
|
1659
1856
|
"symbol": "getWorkspaceInfo",
|
|
1660
1857
|
"returns": "JSON: `{ mode, workspace_path?, current_product?, current_file?,\nproducts }`. The shape depends on whether `.upg/workspace.json` exists.",
|
|
1858
|
+
"return_shape": "{ mode, workspace_path?, current_product?, current_file?, products }",
|
|
1859
|
+
"return_notes": [
|
|
1860
|
+
"The shape depends on whether `.upg/workspace.json` exists."
|
|
1861
|
+
],
|
|
1661
1862
|
"atomicity": "atomic (read-only)"
|
|
1662
1863
|
},
|
|
1663
1864
|
{
|
|
@@ -1694,6 +1895,10 @@
|
|
|
1694
1895
|
"source": "src/tools/workspace.ts:239",
|
|
1695
1896
|
"symbol": "initWorkspaceTool",
|
|
1696
1897
|
"returns": "JSON: `{ message, ...result }`. `result` carries the workspace\npath and the moved file's new location.",
|
|
1898
|
+
"return_shape": "{ message,...result }",
|
|
1899
|
+
"return_notes": [
|
|
1900
|
+
"`result` carries the workspace path and the moved file's new location."
|
|
1901
|
+
],
|
|
1697
1902
|
"atomicity": "non-atomic. The operation creates a directory and (optionally)\nmoves a file as separate filesystem mutations."
|
|
1698
1903
|
},
|
|
1699
1904
|
{
|
|
@@ -1720,6 +1925,7 @@
|
|
|
1720
1925
|
"source": "src/tools/workspace.ts:40",
|
|
1721
1926
|
"symbol": "listLocalProducts",
|
|
1722
1927
|
"returns": "JSON: `{ products: Array<{ file, title, stage, nodes, edges }> }`.",
|
|
1928
|
+
"return_shape": "{ products: Array<{ file, title, stage, nodes, edges }> }",
|
|
1723
1929
|
"atomicity": "atomic (read-only)"
|
|
1724
1930
|
},
|
|
1725
1931
|
{
|
|
@@ -1739,6 +1945,7 @@
|
|
|
1739
1945
|
"source": "src/tools/workspace.ts:534",
|
|
1740
1946
|
"symbol": "listPortfolioCrossEdges",
|
|
1741
1947
|
"returns": "JSON: `{ cross_edges: UPGCrossEdge[], total, portfolio_file? }`.",
|
|
1948
|
+
"return_shape": "{ cross_edges: UPGCrossEdge[], total, portfolio_file? }",
|
|
1742
1949
|
"atomicity": "atomic (read-only)"
|
|
1743
1950
|
},
|
|
1744
1951
|
{
|
|
@@ -1765,6 +1972,7 @@
|
|
|
1765
1972
|
"source": "src/tools/workspace.ts:317",
|
|
1766
1973
|
"symbol": "listPortfolios",
|
|
1767
1974
|
"returns": "JSON: `{ portfolios: Array<{ id, title, description?,\nparent_portfolio_id?, hierarchy_model?, products? }>, total }`.",
|
|
1975
|
+
"return_shape": "{ portfolios: Array<{ id, title, description?, parent_portfolio_id?, hierarchy_model?, products? }>, total }",
|
|
1768
1976
|
"atomicity": "atomic (read-only)"
|
|
1769
1977
|
},
|
|
1770
1978
|
{
|
|
@@ -1807,6 +2015,7 @@
|
|
|
1807
2015
|
"source": "src/tools/workspace.ts:603",
|
|
1808
2016
|
"symbol": "migrateCrossEdges",
|
|
1809
2017
|
"returns": "JSON: `{ migrated, skipped, dry_run, portfolio_file? }`.",
|
|
2018
|
+
"return_shape": "{ migrated, skipped, dry_run, portfolio_file? }",
|
|
1810
2019
|
"atomicity": "non-atomic. Portfolio write + product file save are separate."
|
|
1811
2020
|
},
|
|
1812
2021
|
{
|
|
@@ -1840,6 +2049,7 @@
|
|
|
1840
2049
|
"source": "src/tools/workspace.ts:108",
|
|
1841
2050
|
"symbol": "switchProduct",
|
|
1842
2051
|
"returns": "JSON: `{ message, file, product: { title, stage }, entities }`.",
|
|
2052
|
+
"return_shape": "{ message, file, product: { title, stage }, entities }",
|
|
1843
2053
|
"atomicity": "non-atomic. Flushes the current store, stops watching, and\nloads the new file as separate filesystem operations."
|
|
1844
2054
|
},
|
|
1845
2055
|
{
|
|
@@ -1881,6 +2091,7 @@
|
|
|
1881
2091
|
"source": "src/tools/schema.ts:32",
|
|
1882
2092
|
"symbol": "getEntitySchema",
|
|
1883
2093
|
"returns": "JSON: `{ type, alias_of?, domain, expected_properties, edges_out,\nedges_in, phases?, initial_phase?, terminal_phases?, domain_guide? }`.",
|
|
2094
|
+
"return_shape": "{ type, alias_of?, domain, expected_properties, edges_out, edges_in, phases?, initial_phase?, terminal_phases?, domain_guide? }",
|
|
1884
2095
|
"atomicity": "atomic (read-only)"
|
|
1885
2096
|
},
|
|
1886
2097
|
{
|
|
@@ -1919,6 +2130,9 @@
|
|
|
1919
2130
|
"source": "src/tools/spec.ts:1425",
|
|
1920
2131
|
"symbol": "getAntiPattern",
|
|
1921
2132
|
"returns": "JSON: `UPGCuratedAntiPattern`",
|
|
2133
|
+
"return_notes": [
|
|
2134
|
+
"JSON: `UPGCuratedAntiPattern`"
|
|
2135
|
+
],
|
|
1922
2136
|
"atomicity": "atomic (read-only)"
|
|
1923
2137
|
},
|
|
1924
2138
|
{
|
|
@@ -1966,6 +2180,9 @@
|
|
|
1966
2180
|
"source": "src/tools/spec.ts:321",
|
|
1967
2181
|
"symbol": "getApproach",
|
|
1968
2182
|
"returns": "JSON: the full `UPGApproach` record.",
|
|
2183
|
+
"return_notes": [
|
|
2184
|
+
"JSON: the full `UPGApproach` record."
|
|
2185
|
+
],
|
|
1969
2186
|
"atomicity": "atomic (read-only)"
|
|
1970
2187
|
},
|
|
1971
2188
|
{
|
|
@@ -2004,6 +2221,9 @@
|
|
|
2004
2221
|
"source": "src/tools/spec.ts:746",
|
|
2005
2222
|
"symbol": "getDomainGuide",
|
|
2006
2223
|
"returns": "JSON: the full `UPGDomainUsageGuide` record.",
|
|
2224
|
+
"return_notes": [
|
|
2225
|
+
"JSON: the full `UPGDomainUsageGuide` record."
|
|
2226
|
+
],
|
|
2007
2227
|
"atomicity": "atomic (read-only)"
|
|
2008
2228
|
},
|
|
2009
2229
|
{
|
|
@@ -2039,6 +2259,9 @@
|
|
|
2039
2259
|
"source": "src/tools/spec.ts:1881",
|
|
2040
2260
|
"symbol": "getDomainRing",
|
|
2041
2261
|
"returns": "JSON: the full `UPGDomainRing` record.",
|
|
2262
|
+
"return_notes": [
|
|
2263
|
+
"JSON: the full `UPGDomainRing` record."
|
|
2264
|
+
],
|
|
2042
2265
|
"atomicity": "atomic (read-only)"
|
|
2043
2266
|
},
|
|
2044
2267
|
{
|
|
@@ -2077,6 +2300,7 @@
|
|
|
2077
2300
|
"source": "src/tools/spec.ts:877",
|
|
2078
2301
|
"symbol": "getEdgeType",
|
|
2079
2302
|
"returns": "JSON: `{ type, forward_verb, reverse_verb, classification, source_type, target_type }`",
|
|
2303
|
+
"return_shape": "{ type, forward_verb, reverse_verb, classification, source_type, target_type }",
|
|
2080
2304
|
"atomicity": "atomic (read-only)"
|
|
2081
2305
|
},
|
|
2082
2306
|
{
|
|
@@ -2115,6 +2339,9 @@
|
|
|
2115
2339
|
"source": "src/tools/spec.ts:1340",
|
|
2116
2340
|
"symbol": "getEntityMeta",
|
|
2117
2341
|
"returns": "JSON: `EntityTypeMeta & { domain_id: string | null }`",
|
|
2342
|
+
"return_notes": [
|
|
2343
|
+
"JSON: `EntityTypeMeta & { domain_id: string | null }`"
|
|
2344
|
+
],
|
|
2118
2345
|
"atomicity": "atomic (read-only)"
|
|
2119
2346
|
},
|
|
2120
2347
|
{
|
|
@@ -2153,6 +2380,9 @@
|
|
|
2153
2380
|
"source": "src/tools/spec.ts:814",
|
|
2154
2381
|
"symbol": "getFramework",
|
|
2155
2382
|
"returns": "JSON: the full `UPGFramework` record.",
|
|
2383
|
+
"return_notes": [
|
|
2384
|
+
"JSON: the full `UPGFramework` record."
|
|
2385
|
+
],
|
|
2156
2386
|
"atomicity": "atomic (read-only)"
|
|
2157
2387
|
},
|
|
2158
2388
|
{
|
|
@@ -2191,6 +2421,7 @@
|
|
|
2191
2421
|
"source": "src/tools/spec.ts:1134",
|
|
2192
2422
|
"symbol": "getLensTool",
|
|
2193
2423
|
"returns": "JSON: `{ ...UPGLens, visible_types: string[] }`",
|
|
2424
|
+
"return_shape": "{...UPGLens, visible_types: string[] }",
|
|
2194
2425
|
"atomicity": "atomic (read-only)"
|
|
2195
2426
|
},
|
|
2196
2427
|
{
|
|
@@ -2226,6 +2457,9 @@
|
|
|
2226
2457
|
"source": "src/tools/spec.ts:1751",
|
|
2227
2458
|
"symbol": "getLifecycle",
|
|
2228
2459
|
"returns": "JSON: the full `UPGLifecycle` record, or a descriptive message.",
|
|
2460
|
+
"return_notes": [
|
|
2461
|
+
"JSON: the full `UPGLifecycle` record, or a descriptive message."
|
|
2462
|
+
],
|
|
2229
2463
|
"atomicity": "atomic (read-only)"
|
|
2230
2464
|
},
|
|
2231
2465
|
{
|
|
@@ -2264,6 +2498,9 @@
|
|
|
2264
2498
|
"source": "src/tools/spec.ts:253",
|
|
2265
2499
|
"symbol": "getPlaybook",
|
|
2266
2500
|
"returns": "JSON: the full `UPGPlaybook` record.",
|
|
2501
|
+
"return_notes": [
|
|
2502
|
+
"JSON: the full `UPGPlaybook` record."
|
|
2503
|
+
],
|
|
2267
2504
|
"atomicity": "atomic (read-only)"
|
|
2268
2505
|
},
|
|
2269
2506
|
{
|
|
@@ -2302,6 +2539,9 @@
|
|
|
2302
2539
|
"source": "src/tools/spec.ts:936",
|
|
2303
2540
|
"symbol": "getRegion",
|
|
2304
2541
|
"returns": "JSON: the full `UPGRegion` record.",
|
|
2542
|
+
"return_notes": [
|
|
2543
|
+
"JSON: the full `UPGRegion` record."
|
|
2544
|
+
],
|
|
2305
2545
|
"atomicity": "atomic (read-only)"
|
|
2306
2546
|
},
|
|
2307
2547
|
{
|
|
@@ -2340,6 +2580,9 @@
|
|
|
2340
2580
|
"source": "src/tools/spec.ts:958",
|
|
2341
2581
|
"symbol": "getRegionForEntity",
|
|
2342
2582
|
"returns": "JSON: the full `UPGRegion` record.",
|
|
2583
|
+
"return_notes": [
|
|
2584
|
+
"JSON: the full `UPGRegion` record."
|
|
2585
|
+
],
|
|
2343
2586
|
"atomicity": "atomic (read-only)"
|
|
2344
2587
|
},
|
|
2345
2588
|
{
|
|
@@ -2368,6 +2611,9 @@
|
|
|
2368
2611
|
"source": "src/tools/spec.ts:1797",
|
|
2369
2612
|
"symbol": "getScale",
|
|
2370
2613
|
"returns": "JSON: the full `UPGScaleDefinition` record including all points.",
|
|
2614
|
+
"return_notes": [
|
|
2615
|
+
"JSON: the full `UPGScaleDefinition` record including all points."
|
|
2616
|
+
],
|
|
2371
2617
|
"atomicity": "atomic (read-only)"
|
|
2372
2618
|
},
|
|
2373
2619
|
{
|
|
@@ -2396,6 +2642,7 @@
|
|
|
2396
2642
|
"source": "src/tools/spec.ts:986",
|
|
2397
2643
|
"symbol": "getSpecVersion",
|
|
2398
2644
|
"returns": "JSON: `{ upg_version, markdown_format_version, entity_count, edge_count, domain_count, region_count }`",
|
|
2645
|
+
"return_shape": "{ upg_version, markdown_format_version, entity_count, edge_count, domain_count, region_count }",
|
|
2399
2646
|
"atomicity": "atomic (read-only)"
|
|
2400
2647
|
},
|
|
2401
2648
|
{
|
|
@@ -2441,6 +2688,7 @@
|
|
|
2441
2688
|
"source": "src/tools/spec.ts:1202",
|
|
2442
2689
|
"symbol": "getTypeLabel",
|
|
2443
2690
|
"returns": "JSON: `{ ...UPGTypeLabel, resolved_label: string }`",
|
|
2691
|
+
"return_shape": "{...UPGTypeLabel, resolved_label: string }",
|
|
2444
2692
|
"atomicity": "atomic (read-only)"
|
|
2445
2693
|
},
|
|
2446
2694
|
{
|
|
@@ -2479,6 +2727,7 @@
|
|
|
2479
2727
|
"source": "src/tools/spec.ts:1232",
|
|
2480
2728
|
"symbol": "getValidChildrenTool",
|
|
2481
2729
|
"returns": "JSON: `{ parent_type, valid_children: string[] }`",
|
|
2730
|
+
"return_shape": "{ parent_type, valid_children: string[] }",
|
|
2482
2731
|
"atomicity": "atomic (read-only)"
|
|
2483
2732
|
},
|
|
2484
2733
|
{
|
|
@@ -2516,6 +2765,9 @@
|
|
|
2516
2765
|
"source": "src/tools/spec.ts:459",
|
|
2517
2766
|
"symbol": "inspect",
|
|
2518
2767
|
"returns": "JSON envelope: `{ approach_id, scope, generated_at, approach,\nparams, violations, summary, execution_mode: \"execution_v0_4_0\" }`",
|
|
2768
|
+
"return_notes": [
|
|
2769
|
+
"JSON envelope: `{ approach_id, scope, generated_at, approach, params, violations, summary, execution_mode: \"execution_v0_4_0\" }`"
|
|
2770
|
+
],
|
|
2519
2771
|
"atomicity": "atomic (read-only)"
|
|
2520
2772
|
},
|
|
2521
2773
|
{
|
|
@@ -2578,6 +2830,7 @@
|
|
|
2578
2830
|
"source": "src/tools/spec.ts:1383",
|
|
2579
2831
|
"symbol": "listAntiPatterns",
|
|
2580
2832
|
"returns": "JSON: `{ total, count, next_cursor?, anti_patterns: UPGCuratedAntiPattern[] }`",
|
|
2833
|
+
"return_shape": "{ total, count, next_cursor?, anti_patterns: UPGCuratedAntiPattern[] }",
|
|
2581
2834
|
"atomicity": "atomic (read-only)"
|
|
2582
2835
|
},
|
|
2583
2836
|
{
|
|
@@ -2614,6 +2867,7 @@
|
|
|
2614
2867
|
"source": "src/tools/spec.ts:293",
|
|
2615
2868
|
"symbol": "listApproaches",
|
|
2616
2869
|
"returns": "JSON: `{ count, approaches: UPGApproach[] }`",
|
|
2870
|
+
"return_shape": "{ count, approaches: UPGApproach[] }",
|
|
2617
2871
|
"atomicity": "atomic (read-only)"
|
|
2618
2872
|
},
|
|
2619
2873
|
{
|
|
@@ -2677,6 +2931,7 @@
|
|
|
2677
2931
|
"source": "src/tools/spec.ts:1472",
|
|
2678
2932
|
"symbol": "listBenchmarks",
|
|
2679
2933
|
"returns": "JSON: `{ kind, total, count, benchmarks: ... }`",
|
|
2934
|
+
"return_shape": "{ kind, total, count, benchmarks:... }",
|
|
2680
2935
|
"atomicity": "atomic (read-only)"
|
|
2681
2936
|
},
|
|
2682
2937
|
{
|
|
@@ -2704,6 +2959,7 @@
|
|
|
2704
2959
|
"source": "src/tools/spec.ts:1072",
|
|
2705
2960
|
"symbol": "listCrossEdgeTypes",
|
|
2706
2961
|
"returns": "JSON: `{ count, types: readonly UPGCrossEdgeType[] }`",
|
|
2962
|
+
"return_shape": "{ count, types: readonly UPGCrossEdgeType[] }",
|
|
2707
2963
|
"atomicity": "atomic (read-only)"
|
|
2708
2964
|
},
|
|
2709
2965
|
{
|
|
@@ -2731,6 +2987,7 @@
|
|
|
2731
2987
|
"source": "src/tools/spec.ts:1860",
|
|
2732
2988
|
"symbol": "listDomainRings",
|
|
2733
2989
|
"returns": "JSON: `{ rings: UPGDomainRing[], total: number }`",
|
|
2990
|
+
"return_shape": "{ rings: UPGDomainRing[], total: number }",
|
|
2734
2991
|
"atomicity": "atomic (read-only)"
|
|
2735
2992
|
},
|
|
2736
2993
|
{
|
|
@@ -2765,6 +3022,7 @@
|
|
|
2765
3022
|
"source": "src/tools/spec.ts:711",
|
|
2766
3023
|
"symbol": "listDomains",
|
|
2767
3024
|
"returns": "JSON: `{ count, domains: Array<{ domain_id, anchor_entity, creation_sequence } | { domain_id, label, description, types, has_guide }> }`",
|
|
3025
|
+
"return_shape": "{ count, domains: Array<{ domain_id, anchor_entity, creation_sequence } | { domain_id, label, description, types, has_guide }> }",
|
|
2768
3026
|
"atomicity": "atomic (read-only)"
|
|
2769
3027
|
},
|
|
2770
3028
|
{
|
|
@@ -2799,6 +3057,7 @@
|
|
|
2799
3057
|
"source": "src/tools/spec.ts:1644",
|
|
2800
3058
|
"symbol": "listEdgeMigrations",
|
|
2801
3059
|
"returns": "JSON: `{ migrations: [{ kind, from, to?, since }], total: number }`",
|
|
3060
|
+
"return_shape": "{ migrations: [{ kind, from, to?, since }], total: number }",
|
|
2802
3061
|
"atomicity": "atomic (read-only)"
|
|
2803
3062
|
},
|
|
2804
3063
|
{
|
|
@@ -2837,6 +3096,7 @@
|
|
|
2837
3096
|
"source": "src/tools/spec.ts:858",
|
|
2838
3097
|
"symbol": "listEdgeTypes",
|
|
2839
3098
|
"returns": "JSON: `{ count, edges: Array<{ type, forward_verb, reverse_verb, classification, source_type, target_type }> }`",
|
|
3099
|
+
"return_shape": "{ count, edges: Array<{ type, forward_verb, reverse_verb, classification, source_type, target_type }> }",
|
|
2840
3100
|
"atomicity": "atomic (read-only)"
|
|
2841
3101
|
},
|
|
2842
3102
|
{
|
|
@@ -2894,6 +3154,7 @@
|
|
|
2894
3154
|
"source": "src/tools/spec.ts:1284",
|
|
2895
3155
|
"symbol": "listEntityTypes",
|
|
2896
3156
|
"returns": "JSON: `{ total, count, next_cursor?, types: Array<EntityTypeMeta & { domain_id: string | null }> }`",
|
|
3157
|
+
"return_shape": "{ total, count, next_cursor?, types: Array<EntityTypeMeta & { domain_id: string | null }> }",
|
|
2897
3158
|
"atomicity": "atomic (read-only)"
|
|
2898
3159
|
},
|
|
2899
3160
|
{
|
|
@@ -2920,6 +3181,7 @@
|
|
|
2920
3181
|
"source": "src/tools/spec.ts:1816",
|
|
2921
3182
|
"symbol": "listFrameworkCategories",
|
|
2922
3183
|
"returns": "JSON: `{ categories: string[], total: number }`",
|
|
3184
|
+
"return_shape": "{ categories: string[], total: number }",
|
|
2923
3185
|
"atomicity": "atomic (read-only)"
|
|
2924
3186
|
},
|
|
2925
3187
|
{
|
|
@@ -2947,6 +3209,7 @@
|
|
|
2947
3209
|
"source": "src/tools/spec.ts:1837",
|
|
2948
3210
|
"symbol": "listFrameworkStructurePatterns",
|
|
2949
3211
|
"returns": "JSON: `{ patterns: string[], total: number }`",
|
|
3212
|
+
"return_shape": "{ patterns: string[], total: number }",
|
|
2950
3213
|
"atomicity": "atomic (read-only)"
|
|
2951
3214
|
},
|
|
2952
3215
|
{
|
|
@@ -2989,6 +3252,7 @@
|
|
|
2989
3252
|
"source": "src/tools/spec.ts:778",
|
|
2990
3253
|
"symbol": "listFrameworks",
|
|
2991
3254
|
"returns": "JSON: `{ total, count, next_cursor?, frameworks: UPGFramework[] }`",
|
|
3255
|
+
"return_shape": "{ total, count, next_cursor?, frameworks: UPGFramework[] }",
|
|
2992
3256
|
"atomicity": "atomic (read-only)"
|
|
2993
3257
|
},
|
|
2994
3258
|
{
|
|
@@ -3017,6 +3281,7 @@
|
|
|
3017
3281
|
"source": "src/tools/spec.ts:1101",
|
|
3018
3282
|
"symbol": "listLenses",
|
|
3019
3283
|
"returns": "JSON: `{ count, lenses: Array<{ id, name, description, icon, audience, perspective, framework_id?, playbook_id?, visible_domain_count, intelligence_prompt_count }> }`",
|
|
3284
|
+
"return_shape": "{ count, lenses: Array<{ id, name, description, icon, audience, perspective, framework_id?, playbook_id?, visible_domain_count, intelligence_prompt_count }> }",
|
|
3020
3285
|
"atomicity": "atomic (read-only)"
|
|
3021
3286
|
},
|
|
3022
3287
|
{
|
|
@@ -3053,6 +3318,7 @@
|
|
|
3053
3318
|
"source": "src/tools/spec.ts:1709",
|
|
3054
3319
|
"symbol": "listLifecycles",
|
|
3055
3320
|
"returns": "JSON: `{ lifecycles, total, free_types: string[], planned_types: string[] }`",
|
|
3321
|
+
"return_shape": "{ lifecycles, total, free_types: string[], planned_types: string[] }",
|
|
3056
3322
|
"atomicity": "atomic (read-only)"
|
|
3057
3323
|
},
|
|
3058
3324
|
{
|
|
@@ -3094,6 +3360,7 @@
|
|
|
3094
3360
|
"source": "src/tools/spec.ts:205",
|
|
3095
3361
|
"symbol": "listPlaybooks",
|
|
3096
3362
|
"returns": "JSON: `{ count, playbooks: UPGPlaybook[] }`",
|
|
3363
|
+
"return_shape": "{ count, playbooks: UPGPlaybook[] }",
|
|
3097
3364
|
"atomicity": "atomic (read-only)"
|
|
3098
3365
|
},
|
|
3099
3366
|
{
|
|
@@ -3122,6 +3389,7 @@
|
|
|
3122
3389
|
"source": "src/tools/spec.ts:1580",
|
|
3123
3390
|
"symbol": "listProductStages",
|
|
3124
3391
|
"returns": "JSON: `{ count, stages: readonly UPGProductStage[] }`",
|
|
3392
|
+
"return_shape": "{ count, stages: readonly UPGProductStage[] }",
|
|
3125
3393
|
"atomicity": "atomic (read-only)"
|
|
3126
3394
|
},
|
|
3127
3395
|
{
|
|
@@ -3150,6 +3418,7 @@
|
|
|
3150
3418
|
"source": "src/tools/spec.ts:904",
|
|
3151
3419
|
"symbol": "listRegions",
|
|
3152
3420
|
"returns": "JSON: `{ count, regions: Array<{ id, label, order, shape, mental_model, anchor_type, composes_atomic_domains, entity_count, intra_edge_count, boundary_edge_count }> }`",
|
|
3421
|
+
"return_shape": "{ count, regions: Array<{ id, label, order, shape, mental_model, anchor_type, composes_atomic_domains, entity_count, intra_edge_count, boundary_edge_count }> }",
|
|
3153
3422
|
"atomicity": "atomic (read-only)"
|
|
3154
3423
|
},
|
|
3155
3424
|
{
|
|
@@ -3176,6 +3445,7 @@
|
|
|
3176
3445
|
"source": "src/tools/spec.ts:1782",
|
|
3177
3446
|
"symbol": "listScales",
|
|
3178
3447
|
"returns": "JSON: `{ scales: UPGScaleDefinition[], total: number }`",
|
|
3448
|
+
"return_shape": "{ scales: UPGScaleDefinition[], total: number }",
|
|
3179
3449
|
"atomicity": "atomic (read-only)"
|
|
3180
3450
|
},
|
|
3181
3451
|
{
|
|
@@ -3204,6 +3474,7 @@
|
|
|
3204
3474
|
"source": "src/tools/spec.ts:1681",
|
|
3205
3475
|
"symbol": "listSplitMigrations",
|
|
3206
3476
|
"returns": "JSON: `{ splits: [...], total: number }`",
|
|
3477
|
+
"return_shape": "{ splits: [...], total: number }",
|
|
3207
3478
|
"atomicity": "atomic (read-only)"
|
|
3208
3479
|
},
|
|
3209
3480
|
{
|
|
@@ -3240,6 +3511,7 @@
|
|
|
3240
3511
|
"source": "src/tools/spec.ts:1167",
|
|
3241
3512
|
"symbol": "listTypeLabels",
|
|
3242
3513
|
"returns": "JSON: `{ total, count, next_cursor?, labels: UPGTypeLabel[] }`",
|
|
3514
|
+
"return_shape": "{ total, count, next_cursor?, labels: UPGTypeLabel[] }",
|
|
3243
3515
|
"atomicity": "atomic (read-only)"
|
|
3244
3516
|
},
|
|
3245
3517
|
{
|
|
@@ -3275,6 +3547,7 @@
|
|
|
3275
3547
|
"source": "src/tools/spec.ts:1613",
|
|
3276
3548
|
"symbol": "listTypeMigrations",
|
|
3277
3549
|
"returns": "JSON: `{ migrations: [{ from, to, since }], total: number }`",
|
|
3550
|
+
"return_shape": "{ migrations: [{ from, to, since }], total: number }",
|
|
3278
3551
|
"atomicity": "atomic (read-only)"
|
|
3279
3552
|
},
|
|
3280
3553
|
{
|
|
@@ -3309,6 +3582,9 @@
|
|
|
3309
3582
|
"source": "src/tools/spec.ts:419",
|
|
3310
3583
|
"symbol": "plan",
|
|
3311
3584
|
"returns": "JSON envelope: `{ approach_id, scope, generated_at, approach,\nparams, missing_entities, coverage_score, expected_count, covered_count,\nexecution_mode: \"execution_v0_4_0\" }`.",
|
|
3585
|
+
"return_notes": [
|
|
3586
|
+
"JSON envelope: `{ approach_id, scope, generated_at, approach, params, missing_entities, coverage_score, expected_count, covered_count, execution_mode: \"execution_v0_4_0\" }`."
|
|
3587
|
+
],
|
|
3312
3588
|
"atomicity": "atomic (read-only)"
|
|
3313
3589
|
},
|
|
3314
3590
|
{
|
|
@@ -3350,6 +3626,10 @@
|
|
|
3350
3626
|
"source": "src/tools/spec.ts:518",
|
|
3351
3627
|
"symbol": "prioritise",
|
|
3352
3628
|
"returns": "JSON envelope: `{ approach_id, scope, generated_at, approach,\nparams, framework_resolved, ranked?, required_properties?,\nhint?, execution_mode }`. Execution mode is `\"execution_v0_4_0\"` when\nthe framework has an expression, `\"definition_lookup_v0_4_0\"` otherwise.",
|
|
3629
|
+
"return_notes": [
|
|
3630
|
+
"JSON envelope: `{ approach_id, scope, generated_at, approach, params, framework_resolved, ranked?, required_properties?, hint?, execution_mode }`.",
|
|
3631
|
+
"Execution mode is `\"execution_v0_4_0\"` when the framework has an expression, `\"definition_lookup_v0_4_0\"` otherwise."
|
|
3632
|
+
],
|
|
3353
3633
|
"atomicity": "atomic (read-only)"
|
|
3354
3634
|
},
|
|
3355
3635
|
{
|
|
@@ -3398,6 +3678,9 @@
|
|
|
3398
3678
|
"source": "src/tools/spec.ts:661",
|
|
3399
3679
|
"symbol": "reflect",
|
|
3400
3680
|
"returns": "JSON envelope: `{ approach_id, scope, generated_at, approach,\nparams, prompts, execution_mode: \"execution_v0_4_0\" }`",
|
|
3681
|
+
"return_notes": [
|
|
3682
|
+
"JSON envelope: `{ approach_id, scope, generated_at, approach, params, prompts, execution_mode: \"execution_v0_4_0\" }`"
|
|
3683
|
+
],
|
|
3401
3684
|
"atomicity": "atomic (read-only)"
|
|
3402
3685
|
},
|
|
3403
3686
|
{
|
|
@@ -3443,6 +3726,7 @@
|
|
|
3443
3726
|
"source": "src/tools/spec.ts:1040",
|
|
3444
3727
|
"symbol": "resolveEdgeForPair",
|
|
3445
3728
|
"returns": "JSON: `{ source_type, target_type, edge_type: string | null,\nanchor_hint?, alternate_anchors?, adjacent_edges? }`",
|
|
3729
|
+
"return_shape": "{ source_type, target_type, edge_type: string | null, anchor_hint?, alternate_anchors?, adjacent_edges? }",
|
|
3446
3730
|
"atomicity": "atomic (read-only)"
|
|
3447
3731
|
},
|
|
3448
3732
|
{
|
|
@@ -3501,6 +3785,9 @@
|
|
|
3501
3785
|
"source": "src/tools/spec.ts:598",
|
|
3502
3786
|
"symbol": "trace",
|
|
3503
3787
|
"returns": "JSON envelope: `{ approach_id, scope, generated_at, approach,\nparams, trail, reached, error?, halted_at_depth?,\nexecution_mode: \"execution_v0_4_0\" }`",
|
|
3788
|
+
"return_notes": [
|
|
3789
|
+
"JSON envelope: `{ approach_id, scope, generated_at, approach, params, trail, reached, error?, halted_at_depth?, execution_mode: \"execution_v0_4_0\" }`"
|
|
3790
|
+
],
|
|
3504
3791
|
"atomicity": "atomic (read-only)"
|
|
3505
3792
|
},
|
|
3506
3793
|
{
|
|
@@ -3564,6 +3851,7 @@
|
|
|
3564
3851
|
"source": "src/tools/sync.ts:80",
|
|
3565
3852
|
"symbol": "applyPullChangeset",
|
|
3566
3853
|
"returns": "JSON: `{ nodes_created, nodes_updated, nodes_deleted,\nedges_created, edges_deleted, strategy, conflicts?, message? }`.",
|
|
3854
|
+
"return_shape": "{ nodes_created, nodes_updated, nodes_deleted, edges_created, edges_deleted, strategy, conflicts?, message? }",
|
|
3567
3855
|
"atomicity": "non-atomic. Node/edge mutations apply incrementally; a partial\nfailure mid-application leaves the graph in a half-merged state. The\n`.upg-sync` file is updated after the merge sweep so its hashes reflect\nwhatever landed."
|
|
3568
3856
|
},
|
|
3569
3857
|
{
|
|
@@ -3592,6 +3880,10 @@
|
|
|
3592
3880
|
"source": "src/tools/sync.ts:31",
|
|
3593
3881
|
"symbol": "getSyncState",
|
|
3594
3882
|
"returns": "JSON: `{ synced: false, message }` or\n`{ synced: true, cloud_endpoint, product_id, last_synced_at,\nmapped_nodes, mapped_edges, last_snapshot_hash }`.",
|
|
3883
|
+
"return_shape": "{ synced: false, message }",
|
|
3884
|
+
"return_notes": [
|
|
3885
|
+
"or `{ synced: true, cloud_endpoint, product_id, last_synced_at, mapped_nodes, mapped_edges, last_snapshot_hash }`."
|
|
3886
|
+
],
|
|
3595
3887
|
"atomicity": "atomic (read-only)"
|
|
3596
3888
|
},
|
|
3597
3889
|
{
|
|
@@ -3640,6 +3932,7 @@
|
|
|
3640
3932
|
"source": "src/tools/sync.ts:264",
|
|
3641
3933
|
"symbol": "pushToCloud",
|
|
3642
3934
|
"returns": "JSON: `{ success, product_id, nodes_created, edges_created,\nerrors, sync_file_updated }`.",
|
|
3935
|
+
"return_shape": "{ success, product_id, nodes_created, edges_created, errors, sync_file_updated }",
|
|
3643
3936
|
"atomicity": "non-atomic. Performs an HTTP round-trip and then writes the\nsync file as a separate filesystem mutation. A partial failure (e.g.\ncloud accepted some entities, then network broke) is reflected in the\n`errors` array; the sync file is only updated when the import call\nsucceeds."
|
|
3644
3937
|
},
|
|
3645
3938
|
{
|
|
@@ -3680,8 +3973,38 @@
|
|
|
3680
3973
|
"source": "src/tools/validation.ts:906",
|
|
3681
3974
|
"symbol": "getAntiPatternViolationsFor",
|
|
3682
3975
|
"returns": "JSON: `{ entity_id, type, violations: [...] }`.",
|
|
3976
|
+
"return_shape": "{ entity_id, type, violations: [...] }",
|
|
3683
3977
|
"atomicity": "atomic (read-only)"
|
|
3684
3978
|
},
|
|
3979
|
+
{
|
|
3980
|
+
"name": "skill_audit",
|
|
3981
|
+
"description": "Audit one or every UPG skill for source-vs-deployed integrity. Use before recommending a skill to confirm `.claude/skills/<name>/SKILL.md` is a symlink to canonical source and the bodies match. When `in_sync: false`, what you read from `packages/upg-mcp-server/skills/` is NOT what the user will experience.",
|
|
3982
|
+
"domain": "validation",
|
|
3983
|
+
"inputSchema": {
|
|
3984
|
+
"type": "object",
|
|
3985
|
+
"properties": {
|
|
3986
|
+
"name": {
|
|
3987
|
+
"type": "string",
|
|
3988
|
+
"description": "Optional skill name (e.g. \"upg-trace\"). If omitted, audits every canonical skill."
|
|
3989
|
+
}
|
|
3990
|
+
}
|
|
3991
|
+
},
|
|
3992
|
+
"throws": [],
|
|
3993
|
+
"examples": [
|
|
3994
|
+
{
|
|
3995
|
+
"description": "Live call against the Notion example graph.",
|
|
3996
|
+
"input": "{}",
|
|
3997
|
+
"output": "{\n \"skills\": []\n}"
|
|
3998
|
+
}
|
|
3999
|
+
],
|
|
4000
|
+
"warnings": [],
|
|
4001
|
+
"see": [],
|
|
4002
|
+
"source": "src/tools/skills.ts:191",
|
|
4003
|
+
"symbol": "skillAudit",
|
|
4004
|
+
"returns": "`{ skills: SkillAuditRecord[] }`",
|
|
4005
|
+
"return_shape": "{ skills: SkillAuditRecord[] }",
|
|
4006
|
+
"atomicity": "atomic (read-only filesystem stat + read)"
|
|
4007
|
+
},
|
|
3685
4008
|
{
|
|
3686
4009
|
"name": "validate_graph",
|
|
3687
4010
|
"description": "Walk the loaded graph and return a per-class, per-node report of schema drift plus anti-pattern violations from `UPG_ANTI_PATTERNS`. Schema-drift classes: non-canonical entity types, non-canonical edge types, top-level fields outside `UPGBaseNode`, invalid status values, self-referential `source_id`/`source_type`, properties matching `UPG_PROPERTY_MIGRATIONS` rules. Anti-patterns: catalog entries that fired against the live graph, sorted high → medium → low. Each entry carries `suggested_migration` (drift) or `remediation` (anti-pattern). Top-level `valid` is true iff drift is empty AND no violations fired. Read-only; pairs with `migrate_type`, `rename_edge_type`, `get_anti_pattern_violations_for`.",
|
|
@@ -3766,84 +4089,12 @@
|
|
|
3766
4089
|
"source": "src/tools/validation.ts:257",
|
|
3767
4090
|
"symbol": "validateGraph",
|
|
3768
4091
|
"returns": "JSON: `{ valid, summary, entity_drift?, edge_drift?,\nproperty_drift?, top_level_drift?, lifecycle_drift?, self_referential?,\nanti_pattern_violations?, notes?, _hash }`. Per-class drift arrays appear\nonly when the requested `scope` includes that class. Each array is capped\nat `limit` (default 100).",
|
|
3769
|
-
"
|
|
3770
|
-
|
|
3771
|
-
|
|
3772
|
-
|
|
3773
|
-
"description": "Apply `UPG_STATUS_MIGRATIONS` graph-wide: rewrite legacy lifecycle status values to canonical phase ids. Auto-mode (no filters) selects nodes whose current status is invalid against the entity type's lifecycle and has a registered replacement (the same invariant that drives `validate_graph` lifecycle_drift). Surgical mode (`from_status` + `to_status`) overrides the registry and rewrites every (entity_type?, from_status) match. Nodes with invalid statuses but no registered replacement surface under `skipped_no_migration`. Default `dry_run=true`; pass `dry_run=false` to commit.",
|
|
3774
|
-
"domain": "migrations",
|
|
3775
|
-
"inputSchema": {
|
|
3776
|
-
"type": "object",
|
|
3777
|
-
"properties": {
|
|
3778
|
-
"entity_type": {
|
|
3779
|
-
"type": "string",
|
|
3780
|
-
"description": "Optional. Restrict the rewrite to nodes of this canonical entity type (e.g. \"service\", \"feature\")."
|
|
3781
|
-
},
|
|
3782
|
-
"from_status": {
|
|
3783
|
-
"type": "string",
|
|
3784
|
-
"description": "Optional. Restrict the rewrite to nodes whose current status equals this exact value. When provided, `to_status` is required and the registry is bypassed."
|
|
3785
|
-
},
|
|
3786
|
-
"to_status": {
|
|
3787
|
-
"type": "string",
|
|
3788
|
-
"description": "Required when `from_status` is provided. The canonical phase id to write."
|
|
3789
|
-
},
|
|
3790
|
-
"dry_run": {
|
|
3791
|
-
"type": "boolean",
|
|
3792
|
-
"description": "Preview changes without applying (default true). Pass false to commit."
|
|
3793
|
-
}
|
|
3794
|
-
}
|
|
3795
|
-
},
|
|
3796
|
-
"throws": [
|
|
3797
|
-
"Returns a textError when `from_status` is provided without\n`to_status`, or when `entity_type` is provided but isn't a string."
|
|
3798
|
-
],
|
|
3799
|
-
"examples": [
|
|
3800
|
-
{
|
|
3801
|
-
"description": "Live call against the Notion example graph.",
|
|
3802
|
-
"input": "{}",
|
|
3803
|
-
"output": "{\n \"migrated_nodes\": 0,\n \"skipped_no_migration\": 0,\n \"changes\": [],\n \"dry_run\": true\n}"
|
|
3804
|
-
}
|
|
3805
|
-
],
|
|
3806
|
-
"warnings": [
|
|
3807
|
-
"Default is `dry_run: true`. Pass `dry_run: false` to commit.\nIdempotent on retry; re-running after a successful commit reports\nzero changes (canonical statuses pass the validity check)."
|
|
3808
|
-
],
|
|
3809
|
-
"see": [
|
|
3810
|
-
"migrate_type",
|
|
3811
|
-
"migrate_properties",
|
|
3812
|
-
"validate_graph",
|
|
3813
|
-
"list_lifecycles"
|
|
3814
|
-
],
|
|
3815
|
-
"source": "src/tools/migrations.ts:64",
|
|
3816
|
-
"symbol": "migrateStatus",
|
|
3817
|
-
"returns": "JSON: `MigrateStatusResult`.",
|
|
3818
|
-
"atomicity": "per-node. Status writes go through `store.updateNode`\none at a time. Dry-run is read-only."
|
|
3819
|
-
},
|
|
3820
|
-
{
|
|
3821
|
-
"name": "skill_audit",
|
|
3822
|
-
"description": "Audit one or every UPG skill for source-vs-deployed integrity. Use before recommending a skill to confirm `.claude/skills/<name>/SKILL.md` is a symlink to canonical source and the bodies match. When `in_sync: false`, what you read from `packages/upg-mcp-server/skills/` is NOT what the user will experience.",
|
|
3823
|
-
"domain": "skills",
|
|
3824
|
-
"inputSchema": {
|
|
3825
|
-
"type": "object",
|
|
3826
|
-
"properties": {
|
|
3827
|
-
"name": {
|
|
3828
|
-
"type": "string",
|
|
3829
|
-
"description": "Optional skill name (e.g. \"upg-trace\"). If omitted, audits every canonical skill."
|
|
3830
|
-
}
|
|
3831
|
-
}
|
|
3832
|
-
},
|
|
3833
|
-
"throws": [],
|
|
3834
|
-
"examples": [
|
|
3835
|
-
{
|
|
3836
|
-
"description": "Live call against the Notion example graph.",
|
|
3837
|
-
"input": "{}",
|
|
3838
|
-
"output": "{\n \"skills\": []\n}"
|
|
3839
|
-
}
|
|
4092
|
+
"return_shape": "{ valid, summary, entity_drift?, edge_drift?, property_drift?, top_level_drift?, lifecycle_drift?, self_referential?, anti_pattern_violations?, notes?, _hash }",
|
|
4093
|
+
"return_notes": [
|
|
4094
|
+
"Per-class drift arrays appear only when the requested `scope` includes that class.",
|
|
4095
|
+
"Each array is capped at `limit` (default 100)."
|
|
3840
4096
|
],
|
|
3841
|
-
"
|
|
3842
|
-
"see": [],
|
|
3843
|
-
"source": "src/tools/skills.ts:191",
|
|
3844
|
-
"symbol": "skillAudit",
|
|
3845
|
-
"returns": "`{ skills: SkillAuditRecord[] }`",
|
|
3846
|
-
"atomicity": "atomic (read-only filesystem stat + read)"
|
|
4097
|
+
"atomicity": "atomic (read-only)"
|
|
3847
4098
|
}
|
|
3848
4099
|
]
|
|
3849
4100
|
}
|