@principal-ai/subsystems-react 0.37.12 → 0.39.0
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/dist/graphify/consolidated.d.ts +8 -0
- package/dist/graphify/consolidated.d.ts.map +1 -1
- package/dist/graphify/construct.d.ts +18 -0
- package/dist/graphify/construct.d.ts.map +1 -1
- package/dist/graphify/construct.js +23 -0
- package/dist/graphify/construct.js.map +1 -1
- package/dist/graphify/index.d.ts +2 -2
- package/dist/graphify/index.d.ts.map +1 -1
- package/dist/graphify/index.js +1 -1
- package/dist/graphify/index.js.map +1 -1
- package/dist/index.d.ts +3 -3
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -2
- package/dist/index.js.map +1 -1
- package/dist/stories/Subsystem/ComponentGraph/fixtures.d.ts.map +1 -1
- package/dist/stories/Subsystem/ComponentGraph/fixtures.js +0 -1
- package/dist/stories/Subsystem/ComponentGraph/fixtures.js.map +1 -1
- package/dist/subsystem/IssueList.d.ts +49 -3
- package/dist/subsystem/IssueList.d.ts.map +1 -1
- package/dist/subsystem/IssueList.js +180 -79
- package/dist/subsystem/IssueList.js.map +1 -1
- package/dist/subsystem/SubsystemComponentGraph.d.ts +23 -2
- package/dist/subsystem/SubsystemComponentGraph.d.ts.map +1 -1
- package/dist/subsystem/SubsystemComponentGraph.js +492 -23
- package/dist/subsystem/SubsystemComponentGraph.js.map +1 -1
- package/dist/subsystem/formatDeclaration.js +19 -5
- package/dist/subsystem/formatDeclaration.js.map +1 -1
- package/dist/subsystem/model.d.ts +161 -7
- package/dist/subsystem/model.d.ts.map +1 -1
- package/dist/subsystem/model.js +91 -12
- package/dist/subsystem/model.js.map +1 -1
- package/dist/subsystem/nodes.d.ts.map +1 -1
- package/dist/subsystem/nodes.js +133 -72
- package/dist/subsystem/nodes.js.map +1 -1
- package/dist/subsystem/symbolRefs.d.ts.map +1 -1
- package/dist/subsystem/symbolRefs.js +2 -0
- package/dist/subsystem/symbolRefs.js.map +1 -1
- package/dist/utils/elkLayout.d.ts +9 -0
- package/dist/utils/elkLayout.d.ts.map +1 -1
- package/dist/utils/elkLayout.js +21 -2
- package/dist/utils/elkLayout.js.map +1 -1
- package/package.json +3 -3
- package/src/graphify/__fixtures__/ego-samples.json +545 -0
- package/src/graphify/consolidated.ts +8 -0
- package/src/graphify/construct.test.ts +61 -1
- package/src/graphify/construct.ts +33 -0
- package/src/graphify/index.ts +6 -1
- package/src/index.ts +13 -1
- package/src/stories/Subsystem/ComponentGraph/Basics.stories.tsx +2 -2
- package/src/stories/Subsystem/ComponentGraph/Captures.stories.tsx +9 -9
- package/src/stories/Subsystem/ComponentGraph/EdgeViews.stories.tsx +4 -4
- package/src/stories/Subsystem/ComponentGraph/IssueOverlay.stories.tsx +625 -0
- package/src/stories/Subsystem/ComponentGraph/Issues.stories.tsx +7 -1
- package/src/stories/Subsystem/ComponentGraph/ModuleBadges.stories.tsx +5 -5
- package/src/stories/Subsystem/ComponentGraph/Modules.stories.tsx +5 -5
- package/src/stories/Subsystem/ComponentGraph/NodeAnatomy.stories.tsx +40 -73
- package/src/stories/Subsystem/ComponentGraph/Scenarios.stories.tsx +6 -6
- package/src/stories/Subsystem/ComponentGraph/StoreValueType.stories.tsx +261 -0
- package/src/stories/Subsystem/ComponentGraph/fixtures.ts +0 -1
- package/src/stories/Subsystem/EgoGraph/EgoGraph.stories.tsx +354 -0
- package/src/stories/Subsystem/StoreValueTypeDeclaration.stories.tsx +182 -0
- package/src/subsystem/IssueList.focus.test.tsx +113 -0
- package/src/subsystem/IssueList.icon.test.tsx +95 -0
- package/src/subsystem/IssueList.tsx +267 -111
- package/src/subsystem/SubsystemComponentGraph.tsx +582 -27
- package/src/subsystem/formatDeclaration.test.ts +64 -0
- package/src/subsystem/formatDeclaration.ts +20 -5
- package/src/subsystem/model.test.ts +75 -2
- package/src/subsystem/model.ts +247 -17
- package/src/subsystem/nodes.group.test.tsx +52 -0
- package/src/subsystem/nodes.tsx +112 -8
- package/src/subsystem/symbolRefs.ts +2 -0
- package/src/subsystem/toC4.test.ts +3 -3
- package/src/utils/elkLayout.ts +32 -1
|
@@ -0,0 +1,545 @@
|
|
|
1
|
+
{
|
|
2
|
+
"source": {
|
|
3
|
+
"graph": "/Users/griever/.principal/graphify-graphs/github-principal-ai-subsystem-modeling/56e32c18e1063f68d9ac2fcb9afabd58269270a6+34648fed47c70b3c/graph.json",
|
|
4
|
+
"built_at_commit": "56e32c18e1063f68d9ac2fcb9afabd58269270a6",
|
|
5
|
+
"nodes": 4653,
|
|
6
|
+
"edges": 9717
|
|
7
|
+
},
|
|
8
|
+
"categories": {
|
|
9
|
+
"class": {
|
|
10
|
+
"center": {
|
|
11
|
+
"id": "packages_subsystems_studio_src_mainview_app_errorboundary",
|
|
12
|
+
"label": "ErrorBoundary",
|
|
13
|
+
"file_type": "code",
|
|
14
|
+
"source_file": "packages/subsystems-studio/src/mainview/App.tsx",
|
|
15
|
+
"source_location": "L43"
|
|
16
|
+
},
|
|
17
|
+
"degree": 5,
|
|
18
|
+
"neighborCount": 5,
|
|
19
|
+
"neighborsTruncated": false,
|
|
20
|
+
"neighbors": [
|
|
21
|
+
{
|
|
22
|
+
"id": "packages_subsystems_studio_src_mainview_index",
|
|
23
|
+
"label": "index.tsx",
|
|
24
|
+
"file_type": "code",
|
|
25
|
+
"source_file": "packages/subsystems-studio/src/mainview/index.tsx",
|
|
26
|
+
"source_location": "L1"
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
"id": "packages_subsystems_studio_src_mainview_app",
|
|
30
|
+
"label": "mainview/App.tsx",
|
|
31
|
+
"file_type": "code",
|
|
32
|
+
"source_file": "packages/subsystems-studio/src/mainview/App.tsx",
|
|
33
|
+
"source_location": "L1"
|
|
34
|
+
},
|
|
35
|
+
{
|
|
36
|
+
"id": "packages_subsystems_studio_src_mainview_app_errorboundary_getderivedstatefromerror",
|
|
37
|
+
"label": ".getDerivedStateFromError()",
|
|
38
|
+
"file_type": "code",
|
|
39
|
+
"source_file": "packages/subsystems-studio/src/mainview/App.tsx",
|
|
40
|
+
"source_location": "L48"
|
|
41
|
+
},
|
|
42
|
+
{
|
|
43
|
+
"id": "packages_subsystems_studio_src_mainview_app_errorboundary_componentdidcatch",
|
|
44
|
+
"label": ".componentDidCatch()",
|
|
45
|
+
"file_type": "code",
|
|
46
|
+
"source_file": "packages/subsystems-studio/src/mainview/App.tsx",
|
|
47
|
+
"source_location": "L51"
|
|
48
|
+
},
|
|
49
|
+
{
|
|
50
|
+
"id": "packages_subsystems_studio_src_mainview_app_errorboundary_render",
|
|
51
|
+
"label": ".render()",
|
|
52
|
+
"file_type": "code",
|
|
53
|
+
"source_file": "packages/subsystems-studio/src/mainview/App.tsx",
|
|
54
|
+
"source_location": "L55"
|
|
55
|
+
}
|
|
56
|
+
],
|
|
57
|
+
"edges": [
|
|
58
|
+
{
|
|
59
|
+
"source": "packages_subsystems_studio_src_mainview_index",
|
|
60
|
+
"target": "packages_subsystems_studio_src_mainview_app_errorboundary",
|
|
61
|
+
"relation": "imports",
|
|
62
|
+
"confidence": "EXTRACTED",
|
|
63
|
+
"context": "import",
|
|
64
|
+
"source_file": "packages/subsystems-studio/src/mainview/index.tsx",
|
|
65
|
+
"source_location": "L27"
|
|
66
|
+
},
|
|
67
|
+
{
|
|
68
|
+
"source": "packages_subsystems_studio_src_mainview_app",
|
|
69
|
+
"target": "packages_subsystems_studio_src_mainview_app_errorboundary",
|
|
70
|
+
"relation": "contains",
|
|
71
|
+
"confidence": "EXTRACTED",
|
|
72
|
+
"source_file": "packages/subsystems-studio/src/mainview/App.tsx",
|
|
73
|
+
"source_location": "L43"
|
|
74
|
+
},
|
|
75
|
+
{
|
|
76
|
+
"source": "packages_subsystems_studio_src_mainview_app_errorboundary",
|
|
77
|
+
"target": "packages_subsystems_studio_src_mainview_app_errorboundary_getderivedstatefromerror",
|
|
78
|
+
"relation": "method",
|
|
79
|
+
"confidence": "EXTRACTED",
|
|
80
|
+
"source_file": "packages/subsystems-studio/src/mainview/App.tsx",
|
|
81
|
+
"source_location": "L48"
|
|
82
|
+
},
|
|
83
|
+
{
|
|
84
|
+
"source": "packages_subsystems_studio_src_mainview_app_errorboundary",
|
|
85
|
+
"target": "packages_subsystems_studio_src_mainview_app_errorboundary_componentdidcatch",
|
|
86
|
+
"relation": "method",
|
|
87
|
+
"confidence": "EXTRACTED",
|
|
88
|
+
"source_file": "packages/subsystems-studio/src/mainview/App.tsx",
|
|
89
|
+
"source_location": "L51"
|
|
90
|
+
},
|
|
91
|
+
{
|
|
92
|
+
"source": "packages_subsystems_studio_src_mainview_app_errorboundary",
|
|
93
|
+
"target": "packages_subsystems_studio_src_mainview_app_errorboundary_render",
|
|
94
|
+
"relation": "method",
|
|
95
|
+
"confidence": "EXTRACTED",
|
|
96
|
+
"source_file": "packages/subsystems-studio/src/mainview/App.tsx",
|
|
97
|
+
"source_location": "L55"
|
|
98
|
+
}
|
|
99
|
+
]
|
|
100
|
+
},
|
|
101
|
+
"function": {
|
|
102
|
+
"center": {
|
|
103
|
+
"id": "packages_subsystems_studio_src_bun_maintain_model_readmaintainagentsystemprompt",
|
|
104
|
+
"label": "readMaintainAgentSystemPrompt()",
|
|
105
|
+
"file_type": "code",
|
|
106
|
+
"source_file": "packages/subsystems-studio/src/bun/maintain-model.ts",
|
|
107
|
+
"source_location": "L1398"
|
|
108
|
+
},
|
|
109
|
+
"degree": 4,
|
|
110
|
+
"neighborCount": 4,
|
|
111
|
+
"neighborsTruncated": false,
|
|
112
|
+
"neighbors": [
|
|
113
|
+
{
|
|
114
|
+
"id": "packages_subsystems_studio_src_bun_maintain_model_readclaimadjudicatorsystemprompt",
|
|
115
|
+
"label": "readClaimAdjudicatorSystemPrompt()",
|
|
116
|
+
"file_type": "code",
|
|
117
|
+
"source_file": "packages/subsystems-studio/src/bun/maintain-model.ts",
|
|
118
|
+
"source_location": "L1409"
|
|
119
|
+
},
|
|
120
|
+
{
|
|
121
|
+
"id": "packages_subsystems_studio_src_bun_maintain_model",
|
|
122
|
+
"label": "maintain-model.ts",
|
|
123
|
+
"file_type": "code",
|
|
124
|
+
"source_file": "packages/subsystems-studio/src/bun/maintain-model.ts",
|
|
125
|
+
"source_location": "L1"
|
|
126
|
+
},
|
|
127
|
+
{
|
|
128
|
+
"id": "packages_subsystems_studio_src_bun_maintain_model_ensuremaintainagentsinstalled",
|
|
129
|
+
"label": "ensureMaintainAgentsInstalled()",
|
|
130
|
+
"file_type": "code",
|
|
131
|
+
"source_file": "packages/subsystems-studio/src/bun/maintain-model.ts",
|
|
132
|
+
"source_location": "L399"
|
|
133
|
+
},
|
|
134
|
+
{
|
|
135
|
+
"id": "packages_subsystems_studio_src_bun_maintain_model_agentinstallpath",
|
|
136
|
+
"label": "agentInstallPath()",
|
|
137
|
+
"file_type": "code",
|
|
138
|
+
"source_file": "packages/subsystems-studio/src/bun/maintain-model.ts",
|
|
139
|
+
"source_location": "L95"
|
|
140
|
+
}
|
|
141
|
+
],
|
|
142
|
+
"edges": [
|
|
143
|
+
{
|
|
144
|
+
"source": "packages_subsystems_studio_src_bun_maintain_model_readclaimadjudicatorsystemprompt",
|
|
145
|
+
"target": "packages_subsystems_studio_src_bun_maintain_model_readmaintainagentsystemprompt",
|
|
146
|
+
"relation": "calls",
|
|
147
|
+
"confidence": "EXTRACTED",
|
|
148
|
+
"context": "call",
|
|
149
|
+
"source_file": "packages/subsystems-studio/src/bun/maintain-model.ts",
|
|
150
|
+
"source_location": "L1410"
|
|
151
|
+
},
|
|
152
|
+
{
|
|
153
|
+
"source": "packages_subsystems_studio_src_bun_maintain_model",
|
|
154
|
+
"target": "packages_subsystems_studio_src_bun_maintain_model_readmaintainagentsystemprompt",
|
|
155
|
+
"relation": "contains",
|
|
156
|
+
"confidence": "EXTRACTED",
|
|
157
|
+
"source_file": "packages/subsystems-studio/src/bun/maintain-model.ts",
|
|
158
|
+
"source_location": "L1398"
|
|
159
|
+
},
|
|
160
|
+
{
|
|
161
|
+
"source": "packages_subsystems_studio_src_bun_maintain_model_readmaintainagentsystemprompt",
|
|
162
|
+
"target": "packages_subsystems_studio_src_bun_maintain_model_ensuremaintainagentsinstalled",
|
|
163
|
+
"relation": "calls",
|
|
164
|
+
"confidence": "EXTRACTED",
|
|
165
|
+
"context": "call",
|
|
166
|
+
"source_file": "packages/subsystems-studio/src/bun/maintain-model.ts",
|
|
167
|
+
"source_location": "L1400"
|
|
168
|
+
},
|
|
169
|
+
{
|
|
170
|
+
"source": "packages_subsystems_studio_src_bun_maintain_model_readmaintainagentsystemprompt",
|
|
171
|
+
"target": "packages_subsystems_studio_src_bun_maintain_model_agentinstallpath",
|
|
172
|
+
"relation": "calls",
|
|
173
|
+
"confidence": "EXTRACTED",
|
|
174
|
+
"context": "call",
|
|
175
|
+
"source_file": "packages/subsystems-studio/src/bun/maintain-model.ts",
|
|
176
|
+
"source_location": "L1401"
|
|
177
|
+
}
|
|
178
|
+
]
|
|
179
|
+
},
|
|
180
|
+
"method": {
|
|
181
|
+
"center": {
|
|
182
|
+
"id": "packages_subsystems_core_src_opencode_node_path_adapter_nodepathnormalizationadapter_getrawrepositoryinfo",
|
|
183
|
+
"label": ".getRawRepositoryInfo()",
|
|
184
|
+
"file_type": "code",
|
|
185
|
+
"source_file": "packages/subsystems-core/src/opencode/node-path-adapter.ts",
|
|
186
|
+
"source_location": "L89"
|
|
187
|
+
},
|
|
188
|
+
"degree": 5,
|
|
189
|
+
"neighborCount": 5,
|
|
190
|
+
"neighborsTruncated": false,
|
|
191
|
+
"neighbors": [
|
|
192
|
+
{
|
|
193
|
+
"id": "packages_subsystems_core_src_opencode_node_path_adapter_nodepathnormalizationadapter",
|
|
194
|
+
"label": "NodePathNormalizationAdapter",
|
|
195
|
+
"file_type": "code",
|
|
196
|
+
"source_file": "packages/subsystems-core/src/opencode/node-path-adapter.ts",
|
|
197
|
+
"source_location": "L48"
|
|
198
|
+
},
|
|
199
|
+
{
|
|
200
|
+
"id": "packages_subsystems_core_src_opencode_node_path_adapter_nodepathnormalizationadapter_canonicalizecase",
|
|
201
|
+
"label": ".canonicalizeCase()",
|
|
202
|
+
"file_type": "code",
|
|
203
|
+
"source_file": "packages/subsystems-core/src/opencode/node-path-adapter.ts",
|
|
204
|
+
"source_location": "L67"
|
|
205
|
+
},
|
|
206
|
+
{
|
|
207
|
+
"id": "packages_subsystems_core_src_opencode_node_path_adapter_nodepathnormalizationadapter_findgitroot",
|
|
208
|
+
"label": ".findGitRoot()",
|
|
209
|
+
"file_type": "code",
|
|
210
|
+
"source_file": "packages/subsystems-core/src/opencode/node-path-adapter.ts",
|
|
211
|
+
"source_location": "L159"
|
|
212
|
+
},
|
|
213
|
+
{
|
|
214
|
+
"id": "packages_subsystems_core_src_opencode_node_path_adapter_gitcommand",
|
|
215
|
+
"label": "gitCommand()",
|
|
216
|
+
"file_type": "code",
|
|
217
|
+
"source_file": "packages/subsystems-core/src/opencode/node-path-adapter.ts",
|
|
218
|
+
"source_location": "L22"
|
|
219
|
+
},
|
|
220
|
+
{
|
|
221
|
+
"id": "packages_subsystems_core_src_opencode_node_path_adapter_githubidentityfromremoteurl",
|
|
222
|
+
"label": "githubIdentityFromRemoteUrl()",
|
|
223
|
+
"file_type": "code",
|
|
224
|
+
"source_file": "packages/subsystems-core/src/opencode/node-path-adapter.ts",
|
|
225
|
+
"source_location": "L33"
|
|
226
|
+
}
|
|
227
|
+
],
|
|
228
|
+
"edges": [
|
|
229
|
+
{
|
|
230
|
+
"source": "packages_subsystems_core_src_opencode_node_path_adapter_nodepathnormalizationadapter",
|
|
231
|
+
"target": "packages_subsystems_core_src_opencode_node_path_adapter_nodepathnormalizationadapter_getrawrepositoryinfo",
|
|
232
|
+
"relation": "method",
|
|
233
|
+
"confidence": "EXTRACTED",
|
|
234
|
+
"source_file": "packages/subsystems-core/src/opencode/node-path-adapter.ts",
|
|
235
|
+
"source_location": "L89"
|
|
236
|
+
},
|
|
237
|
+
{
|
|
238
|
+
"source": "packages_subsystems_core_src_opencode_node_path_adapter_nodepathnormalizationadapter_getrawrepositoryinfo",
|
|
239
|
+
"target": "packages_subsystems_core_src_opencode_node_path_adapter_nodepathnormalizationadapter_canonicalizecase",
|
|
240
|
+
"relation": "calls",
|
|
241
|
+
"confidence": "EXTRACTED",
|
|
242
|
+
"context": "call",
|
|
243
|
+
"source_file": "packages/subsystems-core/src/opencode/node-path-adapter.ts",
|
|
244
|
+
"source_location": "L115"
|
|
245
|
+
},
|
|
246
|
+
{
|
|
247
|
+
"source": "packages_subsystems_core_src_opencode_node_path_adapter_nodepathnormalizationadapter_getrawrepositoryinfo",
|
|
248
|
+
"target": "packages_subsystems_core_src_opencode_node_path_adapter_nodepathnormalizationadapter_findgitroot",
|
|
249
|
+
"relation": "calls",
|
|
250
|
+
"confidence": "EXTRACTED",
|
|
251
|
+
"context": "call",
|
|
252
|
+
"source_file": "packages/subsystems-core/src/opencode/node-path-adapter.ts",
|
|
253
|
+
"source_location": "L119"
|
|
254
|
+
},
|
|
255
|
+
{
|
|
256
|
+
"source": "packages_subsystems_core_src_opencode_node_path_adapter_nodepathnormalizationadapter_getrawrepositoryinfo",
|
|
257
|
+
"target": "packages_subsystems_core_src_opencode_node_path_adapter_gitcommand",
|
|
258
|
+
"relation": "calls",
|
|
259
|
+
"confidence": "EXTRACTED",
|
|
260
|
+
"context": "call",
|
|
261
|
+
"source_file": "packages/subsystems-core/src/opencode/node-path-adapter.ts",
|
|
262
|
+
"source_location": "L126"
|
|
263
|
+
},
|
|
264
|
+
{
|
|
265
|
+
"source": "packages_subsystems_core_src_opencode_node_path_adapter_nodepathnormalizationadapter_getrawrepositoryinfo",
|
|
266
|
+
"target": "packages_subsystems_core_src_opencode_node_path_adapter_githubidentityfromremoteurl",
|
|
267
|
+
"relation": "calls",
|
|
268
|
+
"confidence": "EXTRACTED",
|
|
269
|
+
"context": "call",
|
|
270
|
+
"source_file": "packages/subsystems-core/src/opencode/node-path-adapter.ts",
|
|
271
|
+
"source_location": "L133"
|
|
272
|
+
}
|
|
273
|
+
]
|
|
274
|
+
},
|
|
275
|
+
"type": {
|
|
276
|
+
"center": {
|
|
277
|
+
"id": "packages_subsystems_studio_src_shared_contract_subsystemmodelauditfinding",
|
|
278
|
+
"label": "SubsystemModelAuditFinding",
|
|
279
|
+
"file_type": "code",
|
|
280
|
+
"source_file": "packages/subsystems-studio/src/shared/contract.ts",
|
|
281
|
+
"source_location": "L502"
|
|
282
|
+
},
|
|
283
|
+
"degree": 4,
|
|
284
|
+
"neighborCount": 4,
|
|
285
|
+
"neighborsTruncated": false,
|
|
286
|
+
"neighbors": [
|
|
287
|
+
{
|
|
288
|
+
"id": "packages_subsystems_studio_src_mainview_subsystemissues_mappedissues",
|
|
289
|
+
"label": "MappedIssues",
|
|
290
|
+
"file_type": "code",
|
|
291
|
+
"source_file": "packages/subsystems-studio/src/mainview/subsystemIssues.ts",
|
|
292
|
+
"source_location": "L108"
|
|
293
|
+
},
|
|
294
|
+
{
|
|
295
|
+
"id": "packages_subsystems_studio_src_bun_verify_subsystem_component",
|
|
296
|
+
"label": "verify-subsystem-component.ts",
|
|
297
|
+
"file_type": "code",
|
|
298
|
+
"source_file": "packages/subsystems-studio/src/bun/verify-subsystem-component.ts",
|
|
299
|
+
"source_location": "L1"
|
|
300
|
+
},
|
|
301
|
+
{
|
|
302
|
+
"id": "packages_subsystems_studio_src_mainview_subsystemissues",
|
|
303
|
+
"label": "subsystemIssues.ts",
|
|
304
|
+
"file_type": "code",
|
|
305
|
+
"source_file": "packages/subsystems-studio/src/mainview/subsystemIssues.ts",
|
|
306
|
+
"source_location": "L1"
|
|
307
|
+
},
|
|
308
|
+
{
|
|
309
|
+
"id": "packages_subsystems_studio_src_shared_contract",
|
|
310
|
+
"label": "contract.ts",
|
|
311
|
+
"file_type": "code",
|
|
312
|
+
"source_file": "packages/subsystems-studio/src/shared/contract.ts",
|
|
313
|
+
"source_location": "L1"
|
|
314
|
+
}
|
|
315
|
+
],
|
|
316
|
+
"edges": [
|
|
317
|
+
{
|
|
318
|
+
"source": "packages_subsystems_studio_src_mainview_subsystemissues_mappedissues",
|
|
319
|
+
"target": "packages_subsystems_studio_src_shared_contract_subsystemmodelauditfinding",
|
|
320
|
+
"relation": "references",
|
|
321
|
+
"confidence": "EXTRACTED",
|
|
322
|
+
"context": "generic_arg",
|
|
323
|
+
"source_file": "packages/subsystems-studio/src/mainview/subsystemIssues.ts",
|
|
324
|
+
"source_location": "L111"
|
|
325
|
+
},
|
|
326
|
+
{
|
|
327
|
+
"source": "packages_subsystems_studio_src_bun_verify_subsystem_component",
|
|
328
|
+
"target": "packages_subsystems_studio_src_shared_contract_subsystemmodelauditfinding",
|
|
329
|
+
"relation": "imports",
|
|
330
|
+
"confidence": "EXTRACTED",
|
|
331
|
+
"context": "import",
|
|
332
|
+
"source_file": "packages/subsystems-studio/src/bun/verify-subsystem-component.ts",
|
|
333
|
+
"source_location": "L24"
|
|
334
|
+
},
|
|
335
|
+
{
|
|
336
|
+
"source": "packages_subsystems_studio_src_mainview_subsystemissues",
|
|
337
|
+
"target": "packages_subsystems_studio_src_shared_contract_subsystemmodelauditfinding",
|
|
338
|
+
"relation": "imports",
|
|
339
|
+
"confidence": "EXTRACTED",
|
|
340
|
+
"context": "import",
|
|
341
|
+
"source_file": "packages/subsystems-studio/src/mainview/subsystemIssues.ts",
|
|
342
|
+
"source_location": "L12"
|
|
343
|
+
},
|
|
344
|
+
{
|
|
345
|
+
"source": "packages_subsystems_studio_src_shared_contract",
|
|
346
|
+
"target": "packages_subsystems_studio_src_shared_contract_subsystemmodelauditfinding",
|
|
347
|
+
"relation": "contains",
|
|
348
|
+
"confidence": "EXTRACTED",
|
|
349
|
+
"source_file": "packages/subsystems-studio/src/shared/contract.ts",
|
|
350
|
+
"source_location": "L502"
|
|
351
|
+
}
|
|
352
|
+
]
|
|
353
|
+
},
|
|
354
|
+
"module": {
|
|
355
|
+
"center": {
|
|
356
|
+
"id": "packages_subsystems_react_src_components_session_events_index",
|
|
357
|
+
"label": "session-events/index.ts",
|
|
358
|
+
"file_type": "code",
|
|
359
|
+
"source_file": "packages/subsystems-react/src/components/session-events/index.ts",
|
|
360
|
+
"source_location": "L1"
|
|
361
|
+
},
|
|
362
|
+
"degree": 7,
|
|
363
|
+
"neighborCount": 7,
|
|
364
|
+
"neighborsTruncated": false,
|
|
365
|
+
"neighbors": [
|
|
366
|
+
{
|
|
367
|
+
"id": "packages_subsystems_react_src_index",
|
|
368
|
+
"label": "subsystems-react/src/index.ts",
|
|
369
|
+
"file_type": "code",
|
|
370
|
+
"source_file": "packages/subsystems-react/src/index.ts",
|
|
371
|
+
"source_location": "L1"
|
|
372
|
+
},
|
|
373
|
+
{
|
|
374
|
+
"id": "packages_subsystems_react_src_components_session_events_sessioneventfeed",
|
|
375
|
+
"label": "SessionEventFeed.tsx",
|
|
376
|
+
"file_type": "code",
|
|
377
|
+
"source_file": "packages/subsystems-react/src/components/session-events/SessionEventFeed.tsx",
|
|
378
|
+
"source_location": "L1"
|
|
379
|
+
},
|
|
380
|
+
{
|
|
381
|
+
"id": "packages_subsystems_react_src_components_session_events_sessioneventfeed_sessioneventfeed",
|
|
382
|
+
"label": "SessionEventFeed()",
|
|
383
|
+
"file_type": "code",
|
|
384
|
+
"source_file": "packages/subsystems-react/src/components/session-events/SessionEventFeed.tsx",
|
|
385
|
+
"source_location": "L1341"
|
|
386
|
+
},
|
|
387
|
+
{
|
|
388
|
+
"id": "packages_subsystems_react_src_components_session_events_sessioneventfeed_sessioneventfeedgrouped",
|
|
389
|
+
"label": "SessionEventFeedGrouped()",
|
|
390
|
+
"file_type": "code",
|
|
391
|
+
"source_file": "packages/subsystems-react/src/components/session-events/SessionEventFeed.tsx",
|
|
392
|
+
"source_location": "L1448"
|
|
393
|
+
},
|
|
394
|
+
{
|
|
395
|
+
"id": "packages_subsystems_react_src_components_session_events_sessioneventfeed_sessioneventfeedgroupedprops",
|
|
396
|
+
"label": "SessionEventFeedGroupedProps",
|
|
397
|
+
"file_type": "code",
|
|
398
|
+
"source_file": "packages/subsystems-react/src/components/session-events/SessionEventFeed.tsx",
|
|
399
|
+
"source_location": "L40"
|
|
400
|
+
},
|
|
401
|
+
{
|
|
402
|
+
"id": "packages_subsystems_react_src_components_session_events_sessioneventfeed_sessioneventfeedprops",
|
|
403
|
+
"label": "SessionEventFeedProps",
|
|
404
|
+
"file_type": "code",
|
|
405
|
+
"source_file": "packages/subsystems-react/src/components/session-events/SessionEventFeed.tsx",
|
|
406
|
+
"source_location": "L35"
|
|
407
|
+
},
|
|
408
|
+
{
|
|
409
|
+
"id": "packages_subsystems_react_src_components_session_events_sessioneventfeed_sessioneventfeedrow",
|
|
410
|
+
"label": "SessionEventFeedRow",
|
|
411
|
+
"file_type": "code",
|
|
412
|
+
"source_file": "packages/subsystems-react/src/components/session-events/SessionEventFeed.tsx",
|
|
413
|
+
"source_location": "L27"
|
|
414
|
+
}
|
|
415
|
+
],
|
|
416
|
+
"edges": [
|
|
417
|
+
{
|
|
418
|
+
"source": "packages_subsystems_react_src_index",
|
|
419
|
+
"target": "packages_subsystems_react_src_components_session_events_index",
|
|
420
|
+
"relation": "re_exports",
|
|
421
|
+
"confidence": "EXTRACTED",
|
|
422
|
+
"context": "export",
|
|
423
|
+
"source_file": "packages/subsystems-react/src/index.ts",
|
|
424
|
+
"source_location": "L9"
|
|
425
|
+
},
|
|
426
|
+
{
|
|
427
|
+
"source": "packages_subsystems_react_src_components_session_events_index",
|
|
428
|
+
"target": "packages_subsystems_react_src_components_session_events_sessioneventfeed",
|
|
429
|
+
"relation": "re_exports",
|
|
430
|
+
"confidence": "EXTRACTED",
|
|
431
|
+
"context": "export",
|
|
432
|
+
"source_file": "packages/subsystems-react/src/components/session-events/index.ts",
|
|
433
|
+
"source_location": "L5"
|
|
434
|
+
},
|
|
435
|
+
{
|
|
436
|
+
"source": "packages_subsystems_react_src_components_session_events_index",
|
|
437
|
+
"target": "packages_subsystems_react_src_components_session_events_sessioneventfeed_sessioneventfeed",
|
|
438
|
+
"relation": "re_exports",
|
|
439
|
+
"confidence": "EXTRACTED",
|
|
440
|
+
"context": "re-export",
|
|
441
|
+
"source_file": "packages/subsystems-react/src/components/session-events/index.ts",
|
|
442
|
+
"source_location": "L5"
|
|
443
|
+
},
|
|
444
|
+
{
|
|
445
|
+
"source": "packages_subsystems_react_src_components_session_events_index",
|
|
446
|
+
"target": "packages_subsystems_react_src_components_session_events_sessioneventfeed_sessioneventfeedgrouped",
|
|
447
|
+
"relation": "re_exports",
|
|
448
|
+
"confidence": "EXTRACTED",
|
|
449
|
+
"context": "re-export",
|
|
450
|
+
"source_file": "packages/subsystems-react/src/components/session-events/index.ts",
|
|
451
|
+
"source_location": "L5"
|
|
452
|
+
},
|
|
453
|
+
{
|
|
454
|
+
"source": "packages_subsystems_react_src_components_session_events_index",
|
|
455
|
+
"target": "packages_subsystems_react_src_components_session_events_sessioneventfeed_sessioneventfeedgroupedprops",
|
|
456
|
+
"relation": "re_exports",
|
|
457
|
+
"confidence": "EXTRACTED",
|
|
458
|
+
"context": "re-export",
|
|
459
|
+
"source_file": "packages/subsystems-react/src/components/session-events/index.ts",
|
|
460
|
+
"source_location": "L9"
|
|
461
|
+
},
|
|
462
|
+
{
|
|
463
|
+
"source": "packages_subsystems_react_src_components_session_events_index",
|
|
464
|
+
"target": "packages_subsystems_react_src_components_session_events_sessioneventfeed_sessioneventfeedprops",
|
|
465
|
+
"relation": "re_exports",
|
|
466
|
+
"confidence": "EXTRACTED",
|
|
467
|
+
"context": "re-export",
|
|
468
|
+
"source_file": "packages/subsystems-react/src/components/session-events/index.ts",
|
|
469
|
+
"source_location": "L9"
|
|
470
|
+
},
|
|
471
|
+
{
|
|
472
|
+
"source": "packages_subsystems_react_src_components_session_events_index",
|
|
473
|
+
"target": "packages_subsystems_react_src_components_session_events_sessioneventfeed_sessioneventfeedrow",
|
|
474
|
+
"relation": "re_exports",
|
|
475
|
+
"confidence": "EXTRACTED",
|
|
476
|
+
"context": "re-export",
|
|
477
|
+
"source_file": "packages/subsystems-react/src/components/session-events/index.ts",
|
|
478
|
+
"source_location": "L9"
|
|
479
|
+
}
|
|
480
|
+
]
|
|
481
|
+
}
|
|
482
|
+
},
|
|
483
|
+
"authoredCategories": {
|
|
484
|
+
"store": {
|
|
485
|
+
"note": "authored, not graphify-anchored",
|
|
486
|
+
"model": "Open-tab update: stuck cover (fixed)",
|
|
487
|
+
"component": {
|
|
488
|
+
"name": "measuredDimsRef",
|
|
489
|
+
"construct": "store",
|
|
490
|
+
"file": "packages/subsystems-react/src/subsystem/SubsystemComponentGraph.tsx",
|
|
491
|
+
"purl": "pkg:github/principal-ai/subsystem-modeling#packages/subsystems-react/src/subsystem/SubsystemComponentGraph.tsx",
|
|
492
|
+
"symbol": "measuredDimsRef",
|
|
493
|
+
"purpose": "Leaf node width/height bag.\nLanded: prune stale ids on Pass 1; do not wipe the whole Map.",
|
|
494
|
+
"process": "subsystems-react",
|
|
495
|
+
"layer": 7,
|
|
496
|
+
"capture": "analyzed",
|
|
497
|
+
"declaration": {
|
|
498
|
+
"kind": "store",
|
|
499
|
+
"properties": [
|
|
500
|
+
{
|
|
501
|
+
"name": "current",
|
|
502
|
+
"type": "Map<string, { width: number; height: number }>"
|
|
503
|
+
}
|
|
504
|
+
]
|
|
505
|
+
},
|
|
506
|
+
"declarationProvenance": "authored",
|
|
507
|
+
"alias": "measured-dims"
|
|
508
|
+
}
|
|
509
|
+
},
|
|
510
|
+
"external": {
|
|
511
|
+
"note": "authored, not graphify-anchored",
|
|
512
|
+
"model": "Workspace-package boundary framing — wiring plan",
|
|
513
|
+
"component": {
|
|
514
|
+
"alias": "match-path",
|
|
515
|
+
"name": "matchPathToPackage",
|
|
516
|
+
"construct": "external",
|
|
517
|
+
"file": "",
|
|
518
|
+
"purl": "pkg:npm/@principal-ai/codebase-composition",
|
|
519
|
+
"symbol": "matchPathToPackage",
|
|
520
|
+
"purpose": "Maps a file path to its owning workspace package in a monorepo.",
|
|
521
|
+
"declaration": {
|
|
522
|
+
"kind": "external",
|
|
523
|
+
"label": "matchPathToPackage(filePath, workspaceRoot, packages)"
|
|
524
|
+
},
|
|
525
|
+
"declarationProvenance": "authored"
|
|
526
|
+
}
|
|
527
|
+
},
|
|
528
|
+
"custom_entity": {
|
|
529
|
+
"note": "authored, not graphify-anchored",
|
|
530
|
+
"model": "Associating correction proposals with maintenance-session runs",
|
|
531
|
+
"component": {
|
|
532
|
+
"alias": "http-propose",
|
|
533
|
+
"name": "Propose HTTP route",
|
|
534
|
+
"construct": "custom_entity",
|
|
535
|
+
"file": "packages/subsystems-studio/src/bun/http-server.ts",
|
|
536
|
+
"purl": "pkg:github/principal-ai/subsystem-modeling#packages/subsystems-studio/src/bun/http-server.ts",
|
|
537
|
+
"symbol": "POST /api/subsystem-model/:id/proposals",
|
|
538
|
+
"purpose": "HTTP endpoint (line ~399) that parses the propose curl body then calls proposeSubsystemModelCorrection. Seam B entry: parse an optional runId field off the body.",
|
|
539
|
+
"process": "packages/subsystems-studio/run",
|
|
540
|
+
"module": "packages/subsystems-studio/src/bun/http-server.ts",
|
|
541
|
+
"layer": 6
|
|
542
|
+
}
|
|
543
|
+
}
|
|
544
|
+
}
|
|
545
|
+
}
|
|
@@ -240,6 +240,14 @@ export interface GraphifyStoreDetail {
|
|
|
240
240
|
* system (db/service; carries no `process`).
|
|
241
241
|
*/
|
|
242
242
|
storage?: 'memory' | 'disk' | 'external';
|
|
243
|
+
/**
|
|
244
|
+
* The type of the retained state itself — a store declares its type the way
|
|
245
|
+
* every other declaration does (`Map<string, FeedState>`, `Set<Listener>`,
|
|
246
|
+
* a table's row type). Orthogonal to `storage`.
|
|
247
|
+
*/
|
|
248
|
+
valueType?: string;
|
|
249
|
+
/** Backing edge target for `valueType`, when the graph has one. */
|
|
250
|
+
valueTypeRef?: GraphifyReferenceInfo;
|
|
243
251
|
}
|
|
244
252
|
|
|
245
253
|
/** A standalone method selected from its owning class. */
|
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
import { describe, expect, test } from 'bun:test';
|
|
2
2
|
import type { GraphifyEdge, GraphifyNode } from './types';
|
|
3
|
-
import {
|
|
3
|
+
import {
|
|
4
|
+
inferConstructFromGraphify,
|
|
5
|
+
constructsMatch,
|
|
6
|
+
resolveConstructMatch,
|
|
7
|
+
} from './construct';
|
|
4
8
|
|
|
5
9
|
function node(
|
|
6
10
|
id: string,
|
|
@@ -106,3 +110,59 @@ describe('constructsMatch', () => {
|
|
|
106
110
|
expect(constructsMatch('function', 'class')).toBe(false);
|
|
107
111
|
});
|
|
108
112
|
});
|
|
113
|
+
|
|
114
|
+
describe('resolveConstructMatch', () => {
|
|
115
|
+
test('structural match is enough (no augmentation)', () => {
|
|
116
|
+
expect(resolveConstructMatch('function', 'function')).toEqual({
|
|
117
|
+
match: true,
|
|
118
|
+
});
|
|
119
|
+
});
|
|
120
|
+
|
|
121
|
+
test('plain mismatch without augmentation stays a hard failure', () => {
|
|
122
|
+
expect(resolveConstructMatch('function', 'class')).toEqual({
|
|
123
|
+
match: false,
|
|
124
|
+
});
|
|
125
|
+
});
|
|
126
|
+
|
|
127
|
+
test('unknown without augmentation is unconfirmed, not a mismatch', () => {
|
|
128
|
+
expect(resolveConstructMatch('store', 'unknown')).toEqual({ match: null });
|
|
129
|
+
});
|
|
130
|
+
|
|
131
|
+
test('accepted augmentation confirms a claim Graphify infers differently', () => {
|
|
132
|
+
expect(resolveConstructMatch('store', 'function', 'store')).toEqual({
|
|
133
|
+
match: true,
|
|
134
|
+
augmentedBy: 'store',
|
|
135
|
+
});
|
|
136
|
+
});
|
|
137
|
+
|
|
138
|
+
test('accepted augmentation confirms a claim Graphify leaves unknown', () => {
|
|
139
|
+
expect(resolveConstructMatch('interface', 'unknown', 'interface')).toEqual({
|
|
140
|
+
match: true,
|
|
141
|
+
augmentedBy: 'interface',
|
|
142
|
+
});
|
|
143
|
+
});
|
|
144
|
+
|
|
145
|
+
test('augmentation only confirms its own claim, not a different one', () => {
|
|
146
|
+
expect(resolveConstructMatch('store', 'function', 'module')).toEqual({
|
|
147
|
+
match: false,
|
|
148
|
+
});
|
|
149
|
+
expect(resolveConstructMatch('store', 'unknown', 'module')).toEqual({
|
|
150
|
+
match: null,
|
|
151
|
+
});
|
|
152
|
+
});
|
|
153
|
+
|
|
154
|
+
test('blank augmentation is ignored', () => {
|
|
155
|
+
expect(resolveConstructMatch('store', 'function', ' ')).toEqual({
|
|
156
|
+
match: false,
|
|
157
|
+
});
|
|
158
|
+
});
|
|
159
|
+
|
|
160
|
+
test('external / missing claimed still short-circuits to match', () => {
|
|
161
|
+
expect(resolveConstructMatch('external', 'function')).toEqual({
|
|
162
|
+
match: true,
|
|
163
|
+
});
|
|
164
|
+
expect(resolveConstructMatch(undefined, 'unknown')).toEqual({
|
|
165
|
+
match: true,
|
|
166
|
+
});
|
|
167
|
+
});
|
|
168
|
+
});
|
|
@@ -118,3 +118,36 @@ export function constructsMatch(
|
|
|
118
118
|
if (TYPE_FAMILY.has(claimed)) return inferred === 'type';
|
|
119
119
|
return claimed === inferred;
|
|
120
120
|
}
|
|
121
|
+
|
|
122
|
+
export interface ConstructCheckOutcome {
|
|
123
|
+
/** true = confirmed, false = known mismatch, null = unconfirmed (needs agent). */
|
|
124
|
+
match: boolean | null;
|
|
125
|
+
/** Confirming construct from an accepted augmentation, when that is what confirmed it. */
|
|
126
|
+
augmentedBy?: string;
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
/**
|
|
130
|
+
* Resolve a claimed construct against Graphify's inferred construct, allowing an
|
|
131
|
+
* accepted, agent-confirmed augmentation to stand in for Graphify when it is
|
|
132
|
+
* silent (`unknown`) or when it disagrees.
|
|
133
|
+
*
|
|
134
|
+
* Graphify's inferred construct is a *structural hint*, never ground truth: its
|
|
135
|
+
* vocabulary (`class | function | method | type | module | unknown`) has no
|
|
136
|
+
* `store` or `custom_entity`, and a call-style accessor label biases it to
|
|
137
|
+
* `function`. When source-reading confirms the model's claim, that confirmation
|
|
138
|
+
* (recorded as an accepted augmentation) wins over the hint.
|
|
139
|
+
*/
|
|
140
|
+
export function resolveConstructMatch(
|
|
141
|
+
claimed: string | undefined,
|
|
142
|
+
inferred: InferredGraphifyConstruct,
|
|
143
|
+
augmentedConstruct?: string | null,
|
|
144
|
+
): ConstructCheckOutcome {
|
|
145
|
+
const aug = augmentedConstruct?.trim();
|
|
146
|
+
if (!claimed || claimed === 'external') return { match: true };
|
|
147
|
+
const augConfirms = !!aug && aug === claimed;
|
|
148
|
+
if (inferred === 'unknown') {
|
|
149
|
+
return augConfirms ? { match: true, augmentedBy: aug } : { match: null };
|
|
150
|
+
}
|
|
151
|
+
if (constructsMatch(claimed, inferred)) return { match: true };
|
|
152
|
+
return augConfirms ? { match: true, augmentedBy: aug } : { match: false };
|
|
153
|
+
}
|