@documentation-robotics/cli 0.1.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/PYTHON_CLI_PARITY.md +265 -0
- package/PYTHON_CLI_STRUCTURE_UPDATE.md +246 -0
- package/README.md +926 -0
- package/biome.json +42 -0
- package/bunfig.toml +3 -0
- package/dist/ai/claude-client.js +71 -0
- package/dist/ai/claude-client.js.map +7 -0
- package/dist/ai/context-provider.js +129 -0
- package/dist/ai/context-provider.js.map +7 -0
- package/dist/ai/tools.js +231 -0
- package/dist/ai/tools.js.map +7 -0
- package/dist/cli.js +224 -0
- package/dist/cli.js.map +7 -0
- package/dist/commands/add.js +51 -0
- package/dist/commands/add.js.map +7 -0
- package/dist/commands/changeset.js +174 -0
- package/dist/commands/changeset.js.map +7 -0
- package/dist/commands/chat.js +111 -0
- package/dist/commands/chat.js.map +7 -0
- package/dist/commands/conformance.js +132 -0
- package/dist/commands/conformance.js.map +7 -0
- package/dist/commands/delete.js +31 -0
- package/dist/commands/delete.js.map +7 -0
- package/dist/commands/element.js +28 -0
- package/dist/commands/element.js.map +7 -0
- package/dist/commands/export.js +65 -0
- package/dist/commands/export.js.map +7 -0
- package/dist/commands/info.js +40 -0
- package/dist/commands/info.js.map +7 -0
- package/dist/commands/init.js +45 -0
- package/dist/commands/init.js.map +7 -0
- package/dist/commands/list.js +32 -0
- package/dist/commands/list.js.map +7 -0
- package/dist/commands/migrate.js +36 -0
- package/dist/commands/migrate.js.map +7 -0
- package/dist/commands/project.js +74 -0
- package/dist/commands/project.js.map +7 -0
- package/dist/commands/relationship.js +118 -0
- package/dist/commands/relationship.js.map +7 -0
- package/dist/commands/search.js +48 -0
- package/dist/commands/search.js.map +7 -0
- package/dist/commands/show.js +38 -0
- package/dist/commands/show.js.map +7 -0
- package/dist/commands/trace.js +60 -0
- package/dist/commands/trace.js.map +7 -0
- package/dist/commands/update.js +37 -0
- package/dist/commands/update.js.map +7 -0
- package/dist/commands/upgrade.js +152 -0
- package/dist/commands/upgrade.js.map +7 -0
- package/dist/commands/validate.js +71 -0
- package/dist/commands/validate.js.map +7 -0
- package/dist/commands/version.js +20 -0
- package/dist/commands/version.js.map +7 -0
- package/dist/commands/visualize.js +51 -0
- package/dist/commands/visualize.js.map +7 -0
- package/dist/core/active-changeset.js +52 -0
- package/dist/core/active-changeset.js.map +7 -0
- package/dist/core/changeset.js +244 -0
- package/dist/core/changeset.js.map +7 -0
- package/dist/core/dependency-tracker.js +322 -0
- package/dist/core/dependency-tracker.js.map +7 -0
- package/dist/core/element.js +65 -0
- package/dist/core/element.js.map +7 -0
- package/dist/core/layer.js +75 -0
- package/dist/core/layer.js.map +7 -0
- package/dist/core/manifest.js +57 -0
- package/dist/core/manifest.js.map +7 -0
- package/dist/core/migration-registry.js +131 -0
- package/dist/core/migration-registry.js.map +7 -0
- package/dist/core/model.js +455 -0
- package/dist/core/model.js.map +7 -0
- package/dist/core/projection-engine.js +288 -0
- package/dist/core/projection-engine.js.map +7 -0
- package/dist/core/reference-registry.js +188 -0
- package/dist/core/reference-registry.js.map +7 -0
- package/dist/core/relationship-registry.js +114 -0
- package/dist/core/relationship-registry.js.map +7 -0
- package/dist/core/relationships.js +78 -0
- package/dist/core/relationships.js.map +7 -0
- package/dist/export/archimate-exporter.js +111 -0
- package/dist/export/archimate-exporter.js.map +7 -0
- package/dist/export/export-manager.js +63 -0
- package/dist/export/export-manager.js.map +7 -0
- package/dist/export/graphml-exporter.js +39 -0
- package/dist/export/graphml-exporter.js.map +7 -0
- package/dist/export/index.js +17 -0
- package/dist/export/index.js.map +7 -0
- package/dist/export/json-schema-exporter.js +60 -0
- package/dist/export/json-schema-exporter.js.map +7 -0
- package/dist/export/markdown-exporter.js +99 -0
- package/dist/export/markdown-exporter.js.map +7 -0
- package/dist/export/openapi-exporter.js +85 -0
- package/dist/export/openapi-exporter.js.map +7 -0
- package/dist/export/plantuml-exporter.js +60 -0
- package/dist/export/plantuml-exporter.js.map +7 -0
- package/dist/export/types.js +36 -0
- package/dist/export/types.js.map +7 -0
- package/dist/schemas/bundled/01-motivation-layer.schema.json +942 -0
- package/dist/schemas/bundled/02-business-layer.schema.json +1293 -0
- package/dist/schemas/bundled/03-security-layer.schema.json +2177 -0
- package/dist/schemas/bundled/04-application-layer.schema.json +1328 -0
- package/dist/schemas/bundled/05-technology-layer.schema.json +1465 -0
- package/dist/schemas/bundled/06-api-layer.schema.json +1743 -0
- package/dist/schemas/bundled/07-data-model-layer.schema.json +1253 -0
- package/dist/schemas/bundled/08-datastore-layer.schema.json +892 -0
- package/dist/schemas/bundled/09-ux-layer.schema.json +1506 -0
- package/dist/schemas/bundled/10-navigation-layer.schema.json +843 -0
- package/dist/schemas/bundled/11-apm-observability-layer.schema.json +1430 -0
- package/dist/schemas/bundled/12-testing-layer.schema.json +1091 -0
- package/dist/schemas/bundled/common/layer-extensions.schema.json +266 -0
- package/dist/schemas/bundled/common/predicates.schema.json +493 -0
- package/dist/schemas/bundled/common/relationships.schema.json +791 -0
- package/dist/schemas/bundled/common/source-references.schema.json +71 -0
- package/dist/schemas/bundled/link-registry.json +1839 -0
- package/dist/schemas/bundled/link-registry.schema.json +339 -0
- package/dist/schemas/bundled/relationship-catalog.json +1302 -0
- package/dist/schemas/bundled/relationship-type.schema.json +221 -0
- package/dist/server/server.js +1207 -0
- package/dist/server/server.js.map +7 -0
- package/dist/server/telemetry-middleware.js +24 -0
- package/dist/server/telemetry-middleware.js.map +7 -0
- package/dist/telemetry/console-interceptor.js +34 -0
- package/dist/telemetry/console-interceptor.js.map +7 -0
- package/dist/telemetry/index.js +54 -0
- package/dist/telemetry/index.js.map +7 -0
- package/dist/telemetry/resilient-exporter.js +41 -0
- package/dist/telemetry/resilient-exporter.js.map +7 -0
- package/dist/telemetry/resilient-log-exporter.js +41 -0
- package/dist/telemetry/resilient-log-exporter.js.map +7 -0
- package/dist/telemetry/test-instrumentation.js +32 -0
- package/dist/telemetry/test-instrumentation.js.map +7 -0
- package/dist/types/index.js +1 -0
- package/dist/types/index.js.map +7 -0
- package/dist/utils/element-utils.js +11 -0
- package/dist/utils/element-utils.js.map +7 -0
- package/dist/utils/errors.js +105 -0
- package/dist/utils/errors.js.map +7 -0
- package/dist/utils/file-io.js +69 -0
- package/dist/utils/file-io.js.map +7 -0
- package/dist/utils/globals.js +28 -0
- package/dist/utils/globals.js.map +7 -0
- package/dist/utils/model-path.js +22 -0
- package/dist/utils/model-path.js.map +7 -0
- package/dist/utils/project-paths.js +45 -0
- package/dist/utils/project-paths.js.map +7 -0
- package/dist/utils/spec-installer.js +85 -0
- package/dist/utils/spec-installer.js.map +7 -0
- package/dist/utils/spec-version.js +33 -0
- package/dist/utils/spec-version.js.map +7 -0
- package/dist/validators/index.js +15 -0
- package/dist/validators/index.js.map +7 -0
- package/dist/validators/naming-validator.js +82 -0
- package/dist/validators/naming-validator.js.map +7 -0
- package/dist/validators/reference-validator.js +106 -0
- package/dist/validators/reference-validator.js.map +7 -0
- package/dist/validators/schema-validator.js +148 -0
- package/dist/validators/schema-validator.js.map +7 -0
- package/dist/validators/semantic-validator.js +80 -0
- package/dist/validators/semantic-validator.js.map +7 -0
- package/dist/validators/types.js +48 -0
- package/dist/validators/types.js.map +7 -0
- package/dist/validators/validator.js +67 -0
- package/dist/validators/validator.js.map +7 -0
- package/docs/TEST-INSTRUMENTATION.md +405 -0
- package/docs/telemetry.md +427 -0
- package/package.json +70 -0
- package/test-debug.js +33 -0
- package/test-special.mjs +46 -0
- package/test_runner.ts +7 -0
|
@@ -0,0 +1,339 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
+
"$id": "https://documentation-robotics.org/schemas/link-registry.schema.json",
|
|
4
|
+
"title": "Link Registry Schema (DEPRECATED)",
|
|
5
|
+
"description": "JSON Schema for validating the link-registry.json structure. DEPRECATED as of v0.7.0 - cross-layer relationships are now defined in layer schemas.",
|
|
6
|
+
"version": "2.0.0",
|
|
7
|
+
"deprecated": true,
|
|
8
|
+
"deprecationNotice": {
|
|
9
|
+
"since": "0.7.0",
|
|
10
|
+
"reason": "Cross-layer relationships are now defined in layer schemas using the crossLayerRelationships section",
|
|
11
|
+
"removeIn": "0.8.0",
|
|
12
|
+
"migration": "See layer schema crossLayerRelationships sections for relationship definitions"
|
|
13
|
+
},
|
|
14
|
+
|
|
15
|
+
"definitions": {
|
|
16
|
+
"linkType": {
|
|
17
|
+
"type": "object",
|
|
18
|
+
"description": "Definition of a cross-layer link type",
|
|
19
|
+
"properties": {
|
|
20
|
+
"id": {
|
|
21
|
+
"type": "string",
|
|
22
|
+
"pattern": "^[a-z][a-z0-9-]*$",
|
|
23
|
+
"description": "Unique identifier for the link type (kebab-case)"
|
|
24
|
+
},
|
|
25
|
+
"name": {
|
|
26
|
+
"type": "string",
|
|
27
|
+
"minLength": 3,
|
|
28
|
+
"description": "Human-readable name for the link type"
|
|
29
|
+
},
|
|
30
|
+
"category": {
|
|
31
|
+
"type": "string",
|
|
32
|
+
"enum": [
|
|
33
|
+
"motivation",
|
|
34
|
+
"business",
|
|
35
|
+
"security",
|
|
36
|
+
"archimate",
|
|
37
|
+
"api",
|
|
38
|
+
"data",
|
|
39
|
+
"datastore",
|
|
40
|
+
"ux",
|
|
41
|
+
"navigation",
|
|
42
|
+
"apm"
|
|
43
|
+
],
|
|
44
|
+
"description": "Category this link belongs to"
|
|
45
|
+
},
|
|
46
|
+
"sourceLayers": {
|
|
47
|
+
"type": "array",
|
|
48
|
+
"items": {
|
|
49
|
+
"type": "string",
|
|
50
|
+
"pattern": "^\\d{2}-[a-z-]+$"
|
|
51
|
+
},
|
|
52
|
+
"minItems": 1,
|
|
53
|
+
"description": "Layers where this link can originate (e.g., '02-business')"
|
|
54
|
+
},
|
|
55
|
+
"targetLayer": {
|
|
56
|
+
"type": "string",
|
|
57
|
+
"pattern": "^\\d{2}-[a-z-]+$",
|
|
58
|
+
"description": "Layer this link points to (e.g., '01-motivation')"
|
|
59
|
+
},
|
|
60
|
+
"targetElementTypes": {
|
|
61
|
+
"type": "array",
|
|
62
|
+
"items": {
|
|
63
|
+
"type": "string"
|
|
64
|
+
},
|
|
65
|
+
"minItems": 1,
|
|
66
|
+
"description": "Element types in target layer this link can point to"
|
|
67
|
+
},
|
|
68
|
+
"fieldPaths": {
|
|
69
|
+
"type": "array",
|
|
70
|
+
"items": {
|
|
71
|
+
"type": "string",
|
|
72
|
+
"pattern": "^([a-z][a-zA-Z0-9]*\\.[a-z][a-z0-9-]*|x-[a-z][a-z0-9-]*)$"
|
|
73
|
+
},
|
|
74
|
+
"minItems": 1,
|
|
75
|
+
"description": "Property paths that encode this link (e.g., 'motivation.supports-goals')"
|
|
76
|
+
},
|
|
77
|
+
"cardinality": {
|
|
78
|
+
"type": "string",
|
|
79
|
+
"enum": ["single", "array"],
|
|
80
|
+
"description": "Whether this link expects a single value or an array"
|
|
81
|
+
},
|
|
82
|
+
"format": {
|
|
83
|
+
"type": "string",
|
|
84
|
+
"enum": ["uuid", "id", "string", "duration", "percentage", "path", "enum"],
|
|
85
|
+
"description": "Expected format of the link value"
|
|
86
|
+
},
|
|
87
|
+
"description": {
|
|
88
|
+
"type": "string",
|
|
89
|
+
"minLength": 1,
|
|
90
|
+
"description": "Clear description of what this link represents"
|
|
91
|
+
},
|
|
92
|
+
"examples": {
|
|
93
|
+
"type": "array",
|
|
94
|
+
"items": {
|
|
95
|
+
"type": "object",
|
|
96
|
+
"properties": {
|
|
97
|
+
"source": {
|
|
98
|
+
"type": "object",
|
|
99
|
+
"properties": {
|
|
100
|
+
"layer": {
|
|
101
|
+
"type": "string",
|
|
102
|
+
"pattern": "^\\d{2}-[a-z-]+$"
|
|
103
|
+
},
|
|
104
|
+
"type": {
|
|
105
|
+
"type": "string"
|
|
106
|
+
},
|
|
107
|
+
"id": {
|
|
108
|
+
"type": "string"
|
|
109
|
+
}
|
|
110
|
+
},
|
|
111
|
+
"required": ["layer", "type", "id"]
|
|
112
|
+
},
|
|
113
|
+
"target": {
|
|
114
|
+
"type": "object",
|
|
115
|
+
"properties": {
|
|
116
|
+
"layer": {
|
|
117
|
+
"type": "string",
|
|
118
|
+
"pattern": "^\\d{2}-[a-z-]+$"
|
|
119
|
+
},
|
|
120
|
+
"type": {
|
|
121
|
+
"type": "string"
|
|
122
|
+
},
|
|
123
|
+
"id": {
|
|
124
|
+
"type": "string"
|
|
125
|
+
}
|
|
126
|
+
},
|
|
127
|
+
"required": ["layer", "type", "id"]
|
|
128
|
+
},
|
|
129
|
+
"value": {
|
|
130
|
+
"oneOf": [{ "type": "string" }, { "type": "array", "items": { "type": "string" } }]
|
|
131
|
+
},
|
|
132
|
+
"description": {
|
|
133
|
+
"type": "string"
|
|
134
|
+
}
|
|
135
|
+
},
|
|
136
|
+
"required": ["source", "target", "value", "description"]
|
|
137
|
+
},
|
|
138
|
+
"description": "Example usages of this link type"
|
|
139
|
+
},
|
|
140
|
+
"validationRules": {
|
|
141
|
+
"type": "object",
|
|
142
|
+
"properties": {
|
|
143
|
+
"targetExists": {
|
|
144
|
+
"type": "boolean",
|
|
145
|
+
"description": "Whether to validate that target element exists"
|
|
146
|
+
},
|
|
147
|
+
"targetType": {
|
|
148
|
+
"type": "string",
|
|
149
|
+
"description": "Expected type of target element"
|
|
150
|
+
},
|
|
151
|
+
"sourceElementTypesValid": {
|
|
152
|
+
"type": "array",
|
|
153
|
+
"items": { "type": "string" },
|
|
154
|
+
"description": "Valid source element types"
|
|
155
|
+
},
|
|
156
|
+
"minimumCardinality": {
|
|
157
|
+
"type": "integer",
|
|
158
|
+
"minimum": 0,
|
|
159
|
+
"description": "Minimum number of links required (0 = optional)"
|
|
160
|
+
},
|
|
161
|
+
"maximumCardinality": {
|
|
162
|
+
"type": ["integer", "null"],
|
|
163
|
+
"minimum": 1,
|
|
164
|
+
"description": "Maximum number of links allowed (null = unlimited)"
|
|
165
|
+
}
|
|
166
|
+
},
|
|
167
|
+
"additionalProperties": true
|
|
168
|
+
},
|
|
169
|
+
"predicate": {
|
|
170
|
+
"type": ["string", "null"],
|
|
171
|
+
"pattern": "^[a-z][a-z0-9-]*$",
|
|
172
|
+
"description": "Semantic predicate for this relationship (forward direction)"
|
|
173
|
+
},
|
|
174
|
+
"inversePredicate": {
|
|
175
|
+
"type": ["string", "null"],
|
|
176
|
+
"pattern": "^[a-z][a-z0-9-]*$",
|
|
177
|
+
"description": "Inverse predicate for bidirectional navigation"
|
|
178
|
+
},
|
|
179
|
+
"relationshipCategory": {
|
|
180
|
+
"type": ["string", "null"],
|
|
181
|
+
"enum": [
|
|
182
|
+
"structural",
|
|
183
|
+
"behavioral",
|
|
184
|
+
"dependency",
|
|
185
|
+
"traceability",
|
|
186
|
+
"governance",
|
|
187
|
+
"apm",
|
|
188
|
+
"security",
|
|
189
|
+
"ux",
|
|
190
|
+
"data",
|
|
191
|
+
null
|
|
192
|
+
],
|
|
193
|
+
"description": "Semantic category of this relationship"
|
|
194
|
+
},
|
|
195
|
+
"sourceElementTypes": {
|
|
196
|
+
"type": "array",
|
|
197
|
+
"items": {
|
|
198
|
+
"type": "string"
|
|
199
|
+
},
|
|
200
|
+
"description": "Element types in source layer(s) that can have this link"
|
|
201
|
+
},
|
|
202
|
+
"strength": {
|
|
203
|
+
"type": ["string", "null"],
|
|
204
|
+
"enum": ["critical", "high", "medium", "low", null],
|
|
205
|
+
"description": "Importance/strength of this relationship"
|
|
206
|
+
},
|
|
207
|
+
"isRequired": {
|
|
208
|
+
"type": "boolean",
|
|
209
|
+
"description": "Whether this link is mandatory for the source element"
|
|
210
|
+
},
|
|
211
|
+
"bidirectional": {
|
|
212
|
+
"type": "boolean",
|
|
213
|
+
"description": "Whether this link supports bidirectional navigation"
|
|
214
|
+
},
|
|
215
|
+
"archimateAlignment": {
|
|
216
|
+
"type": ["string", "null"],
|
|
217
|
+
"enum": [
|
|
218
|
+
"Composition",
|
|
219
|
+
"Aggregation",
|
|
220
|
+
"Specialization",
|
|
221
|
+
"Realization",
|
|
222
|
+
"Assignment",
|
|
223
|
+
"Triggering",
|
|
224
|
+
"Flow",
|
|
225
|
+
"Serving",
|
|
226
|
+
"Access",
|
|
227
|
+
"Influence",
|
|
228
|
+
null
|
|
229
|
+
],
|
|
230
|
+
"description": "Corresponding ArchiMate 3.2 relationship type, if any"
|
|
231
|
+
},
|
|
232
|
+
"deprecation": {
|
|
233
|
+
"type": ["object", "null"],
|
|
234
|
+
"properties": {
|
|
235
|
+
"deprecated": {
|
|
236
|
+
"type": "boolean"
|
|
237
|
+
},
|
|
238
|
+
"since": {
|
|
239
|
+
"type": "string",
|
|
240
|
+
"pattern": "^\\d+\\.\\d+\\.\\d+$"
|
|
241
|
+
},
|
|
242
|
+
"reason": {
|
|
243
|
+
"type": "string"
|
|
244
|
+
},
|
|
245
|
+
"replacement": {
|
|
246
|
+
"type": "string"
|
|
247
|
+
}
|
|
248
|
+
},
|
|
249
|
+
"description": "Deprecation information if this link type is being phased out"
|
|
250
|
+
}
|
|
251
|
+
},
|
|
252
|
+
"required": [
|
|
253
|
+
"id",
|
|
254
|
+
"name",
|
|
255
|
+
"category",
|
|
256
|
+
"sourceLayers",
|
|
257
|
+
"targetLayer",
|
|
258
|
+
"targetElementTypes",
|
|
259
|
+
"fieldPaths",
|
|
260
|
+
"cardinality",
|
|
261
|
+
"format",
|
|
262
|
+
"description",
|
|
263
|
+
"validationRules"
|
|
264
|
+
],
|
|
265
|
+
"additionalProperties": false
|
|
266
|
+
},
|
|
267
|
+
|
|
268
|
+
"category": {
|
|
269
|
+
"type": "object",
|
|
270
|
+
"description": "Metadata for a link category",
|
|
271
|
+
"properties": {
|
|
272
|
+
"description": {
|
|
273
|
+
"type": "string",
|
|
274
|
+
"minLength": 10
|
|
275
|
+
},
|
|
276
|
+
"color": {
|
|
277
|
+
"type": "string",
|
|
278
|
+
"pattern": "^#[0-9A-Fa-f]{6}$",
|
|
279
|
+
"description": "Hex color code for visualization"
|
|
280
|
+
},
|
|
281
|
+
"icon": {
|
|
282
|
+
"type": "string",
|
|
283
|
+
"description": "Icon identifier for this category"
|
|
284
|
+
}
|
|
285
|
+
},
|
|
286
|
+
"required": ["description"],
|
|
287
|
+
"additionalProperties": true
|
|
288
|
+
}
|
|
289
|
+
},
|
|
290
|
+
|
|
291
|
+
"type": "object",
|
|
292
|
+
"properties": {
|
|
293
|
+
"$schema": {
|
|
294
|
+
"type": "string",
|
|
295
|
+
"format": "uri"
|
|
296
|
+
},
|
|
297
|
+
"version": {
|
|
298
|
+
"type": "string",
|
|
299
|
+
"pattern": "^\\d+\\.\\d+\\.\\d+$",
|
|
300
|
+
"description": "Semantic version of the link registry"
|
|
301
|
+
},
|
|
302
|
+
"metadata": {
|
|
303
|
+
"type": "object",
|
|
304
|
+
"properties": {
|
|
305
|
+
"generatedBy": {
|
|
306
|
+
"type": "string"
|
|
307
|
+
},
|
|
308
|
+
"generatedAt": {
|
|
309
|
+
"type": "string",
|
|
310
|
+
"format": "date-time"
|
|
311
|
+
},
|
|
312
|
+
"totalLinkTypes": {
|
|
313
|
+
"type": "integer",
|
|
314
|
+
"minimum": 0
|
|
315
|
+
},
|
|
316
|
+
"schemaVersion": {
|
|
317
|
+
"type": "string",
|
|
318
|
+
"pattern": "^\\d+\\.\\d+\\.\\d+$"
|
|
319
|
+
}
|
|
320
|
+
}
|
|
321
|
+
},
|
|
322
|
+
"categories": {
|
|
323
|
+
"type": "object",
|
|
324
|
+
"additionalProperties": {
|
|
325
|
+
"$ref": "#/definitions/category"
|
|
326
|
+
},
|
|
327
|
+
"description": "Link category definitions with metadata"
|
|
328
|
+
},
|
|
329
|
+
"linkTypes": {
|
|
330
|
+
"type": "array",
|
|
331
|
+
"items": {
|
|
332
|
+
"$ref": "#/definitions/linkType"
|
|
333
|
+
},
|
|
334
|
+
"minItems": 1,
|
|
335
|
+
"description": "Array of link type definitions"
|
|
336
|
+
}
|
|
337
|
+
},
|
|
338
|
+
"required": ["$schema", "version", "linkTypes"]
|
|
339
|
+
}
|