@documentation-robotics/cli 0.1.0 → 0.1.7
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/LICENSE +21 -0
- package/README.md +466 -693
- package/dist/analysis/data-model-analyzer.js +189 -0
- package/dist/analysis/data-model-analyzer.js.map +7 -0
- package/dist/analysis/index.js +3 -0
- package/dist/analysis/index.js.map +7 -0
- package/dist/analysis/relationship-classifier.js +181 -0
- package/dist/analysis/relationship-classifier.js.map +7 -0
- package/dist/analyzers/base-analyzer.js +1 -0
- package/dist/analyzers/base-analyzer.js.map +7 -0
- package/dist/analyzers/call-graph-utils.js +39 -0
- package/dist/analyzers/call-graph-utils.js.map +7 -0
- package/dist/analyzers/cbm-analyzer.js +1205 -0
- package/dist/analyzers/cbm-analyzer.js.map +7 -0
- package/dist/analyzers/heuristic-utils.js +55 -0
- package/dist/analyzers/heuristic-utils.js.map +7 -0
- package/dist/analyzers/mapping-loader.js +146 -0
- package/dist/analyzers/mapping-loader.js.map +7 -0
- package/dist/analyzers/registry.js +124 -0
- package/dist/analyzers/registry.js.map +7 -0
- package/dist/analyzers/session-state.js +176 -0
- package/dist/analyzers/session-state.js.map +7 -0
- package/dist/analyzers/stdio-client.js +208 -0
- package/dist/analyzers/stdio-client.js.map +7 -0
- package/dist/analyzers/types.js +15 -0
- package/dist/analyzers/types.js.map +7 -0
- package/dist/analyzers/verify-engine.js +209 -0
- package/dist/analyzers/verify-engine.js.map +7 -0
- package/dist/analyzers/verify-ignore.js +130 -0
- package/dist/analyzers/verify-ignore.js.map +7 -0
- package/dist/analyzers/version.js +8 -0
- package/dist/analyzers/version.js.map +7 -0
- package/dist/audit/ai/runner.js +41 -0
- package/dist/audit/ai/runner.js.map +7 -0
- package/dist/audit/differential-analyzer.js +183 -0
- package/dist/audit/differential-analyzer.js.map +7 -0
- package/dist/audit/index.js +32 -0
- package/dist/audit/index.js.map +7 -0
- package/dist/audit/nodes/ai/evaluator.js +49 -0
- package/dist/audit/nodes/ai/evaluator.js.map +7 -0
- package/dist/audit/nodes/ai/parser.js +55 -0
- package/dist/audit/nodes/ai/parser.js.map +7 -0
- package/dist/audit/nodes/ai/prompts.js +103 -0
- package/dist/audit/nodes/ai/prompts.js.map +7 -0
- package/dist/audit/nodes/analysis/node-completeness-checker.js +32 -0
- package/dist/audit/nodes/analysis/node-completeness-checker.js.map +7 -0
- package/dist/audit/nodes/analysis/node-definition-analyzer.js +47 -0
- package/dist/audit/nodes/analysis/node-definition-analyzer.js.map +7 -0
- package/dist/audit/nodes/analysis/node-overlap-detector.js +79 -0
- package/dist/audit/nodes/analysis/node-overlap-detector.js.map +7 -0
- package/dist/audit/nodes/model/orchestrator.js +82 -0
- package/dist/audit/nodes/model/orchestrator.js.map +7 -0
- package/dist/audit/nodes/spec/loader.js +116 -0
- package/dist/audit/nodes/spec/loader.js.map +7 -0
- package/dist/audit/nodes/spec/orchestrator.js +68 -0
- package/dist/audit/nodes/spec/orchestrator.js.map +7 -0
- package/dist/audit/nodes/types.js +1 -0
- package/dist/audit/nodes/types.js.map +7 -0
- package/dist/audit/pipeline/index.js +5 -0
- package/dist/audit/pipeline/index.js.map +7 -0
- package/dist/audit/pipeline/pipeline-orchestrator.js +218 -0
- package/dist/audit/pipeline/pipeline-orchestrator.js.map +7 -0
- package/dist/audit/relationships/ai/evaluator.js +235 -0
- package/dist/audit/relationships/ai/evaluator.js.map +7 -0
- package/dist/audit/relationships/ai/parser.js +197 -0
- package/dist/audit/relationships/ai/parser.js.map +7 -0
- package/dist/audit/relationships/ai/prompts.js +274 -0
- package/dist/audit/relationships/ai/prompts.js.map +7 -0
- package/dist/audit/relationships/analysis/balance-assessor.js +115 -0
- package/dist/audit/relationships/analysis/balance-assessor.js.map +7 -0
- package/dist/audit/relationships/analysis/coverage-analyzer.js +99 -0
- package/dist/audit/relationships/analysis/coverage-analyzer.js.map +7 -0
- package/dist/audit/relationships/analysis/duplicate-detector.js +95 -0
- package/dist/audit/relationships/analysis/duplicate-detector.js.map +7 -0
- package/dist/audit/relationships/analysis/gap-analyzer.js +99 -0
- package/dist/audit/relationships/analysis/gap-analyzer.js.map +7 -0
- package/dist/audit/relationships/analysis/layer-templates.js +294 -0
- package/dist/audit/relationships/analysis/layer-templates.js.map +7 -0
- package/dist/audit/relationships/graph/connectivity.js +129 -0
- package/dist/audit/relationships/graph/connectivity.js.map +7 -0
- package/dist/audit/relationships/graph/relationship-graph.js +179 -0
- package/dist/audit/relationships/graph/relationship-graph.js.map +7 -0
- package/dist/audit/relationships/model/balance-assessor.js +49 -0
- package/dist/audit/relationships/model/balance-assessor.js.map +7 -0
- package/dist/audit/relationships/model/coverage-analyzer.js +34 -0
- package/dist/audit/relationships/model/coverage-analyzer.js.map +7 -0
- package/dist/audit/relationships/model/duplicate-detector.js +68 -0
- package/dist/audit/relationships/model/duplicate-detector.js.map +7 -0
- package/dist/audit/relationships/model/gap-analyzer.js +41 -0
- package/dist/audit/relationships/model/gap-analyzer.js.map +7 -0
- package/dist/audit/relationships/model/orchestrator.js +126 -0
- package/dist/audit/relationships/model/orchestrator.js.map +7 -0
- package/dist/audit/relationships/spec/orchestrator.js +157 -0
- package/dist/audit/relationships/spec/orchestrator.js.map +7 -0
- package/dist/audit/reports/index.js +5 -0
- package/dist/audit/reports/index.js.map +7 -0
- package/dist/audit/reports/report-generator.js +118 -0
- package/dist/audit/reports/report-generator.js.map +7 -0
- package/dist/audit/snapshot-storage.js +163 -0
- package/dist/audit/snapshot-storage.js.map +7 -0
- package/dist/audit/types.js +21 -0
- package/dist/audit/types.js.map +7 -0
- package/dist/cli.js +223 -92
- package/dist/cli.js.map +3 -3
- package/dist/coding-agents/agents/claude-code.js +147 -0
- package/dist/coding-agents/agents/claude-code.js.map +7 -0
- package/dist/coding-agents/agents/index.js +5 -0
- package/dist/coding-agents/agents/index.js.map +7 -0
- package/dist/coding-agents/agents/types.js +1 -0
- package/dist/coding-agents/agents/types.js.map +7 -0
- package/dist/coding-agents/base-chat-client.js +45 -0
- package/dist/coding-agents/base-chat-client.js.map +7 -0
- package/dist/coding-agents/chat-utils.js +23 -0
- package/dist/coding-agents/chat-utils.js.map +7 -0
- package/dist/coding-agents/claude-code-client.js +246 -0
- package/dist/coding-agents/claude-code-client.js.map +7 -0
- package/dist/coding-agents/copilot-client.js +209 -0
- package/dist/coding-agents/copilot-client.js.map +7 -0
- package/dist/commands/add.js +95 -33
- package/dist/commands/add.js.map +2 -2
- package/dist/commands/analyzer.js +511 -0
- package/dist/commands/analyzer.js.map +7 -0
- package/dist/commands/audit-diff.js +49 -0
- package/dist/commands/audit-diff.js.map +7 -0
- package/dist/commands/audit-snapshots.js +62 -0
- package/dist/commands/audit-snapshots.js.map +7 -0
- package/dist/commands/audit.js +81 -0
- package/dist/commands/audit.js.map +7 -0
- package/dist/commands/catalog.js +248 -0
- package/dist/commands/catalog.js.map +7 -0
- package/dist/commands/changeset.js +577 -66
- package/dist/commands/changeset.js.map +2 -2
- package/dist/commands/chat.js +106 -83
- package/dist/commands/chat.js.map +2 -2
- package/dist/commands/claude.js +74 -0
- package/dist/commands/claude.js.map +7 -0
- package/dist/commands/conformance.js +71 -68
- package/dist/commands/conformance.js.map +2 -2
- package/dist/commands/copilot.js +75 -0
- package/dist/commands/copilot.js.map +7 -0
- package/dist/commands/delete.js +125 -11
- package/dist/commands/delete.js.map +3 -3
- package/dist/commands/discover-logic.js +44 -0
- package/dist/commands/discover-logic.js.map +7 -0
- package/dist/commands/docs.js +87 -0
- package/dist/commands/docs.js.map +7 -0
- package/dist/commands/element.js +14 -20
- package/dist/commands/element.js.map +2 -2
- package/dist/commands/export.js +13 -3
- package/dist/commands/export.js.map +2 -2
- package/dist/commands/import.js +51 -0
- package/dist/commands/import.js.map +7 -0
- package/dist/commands/info.js +30 -24
- package/dist/commands/info.js.map +2 -2
- package/dist/commands/init.js +27 -11
- package/dist/commands/init.js.map +2 -2
- package/dist/commands/list.js +63 -13
- package/dist/commands/list.js.map +3 -3
- package/dist/commands/relationship.js +225 -37
- package/dist/commands/relationship.js.map +2 -2
- package/dist/commands/report.js +54 -0
- package/dist/commands/report.js.map +7 -0
- package/dist/commands/reports.js +45 -0
- package/dist/commands/reports.js.map +7 -0
- package/dist/commands/schema.js +135 -0
- package/dist/commands/schema.js.map +7 -0
- package/dist/commands/search.js +40 -12
- package/dist/commands/search.js.map +2 -2
- package/dist/commands/show.js +58 -27
- package/dist/commands/show.js.map +2 -2
- package/dist/commands/stats.js +35 -0
- package/dist/commands/stats.js.map +7 -0
- package/dist/commands/trace.js +39 -16
- package/dist/commands/trace.js.map +2 -2
- package/dist/commands/update.js +141 -14
- package/dist/commands/update.js.map +2 -2
- package/dist/commands/upgrade.js +210 -46
- package/dist/commands/upgrade.js.map +3 -3
- package/dist/commands/validate.js +142 -23
- package/dist/commands/validate.js.map +3 -3
- package/dist/commands/version.js +8 -12
- package/dist/commands/version.js.map +2 -2
- package/dist/commands/visualize.js +162 -25
- package/dist/commands/visualize.js.map +2 -2
- package/dist/core/base-snapshot-manager.js +84 -0
- package/dist/core/base-snapshot-manager.js.map +7 -0
- package/dist/core/changeset-exporter.js +305 -0
- package/dist/core/changeset-exporter.js.map +7 -0
- package/dist/core/changeset-validator.js +41 -0
- package/dist/core/changeset-validator.js.map +7 -0
- package/dist/core/changeset.js +88 -173
- package/dist/core/changeset.js.map +2 -2
- package/dist/core/dependency-tracker.js +4 -2
- package/dist/core/dependency-tracker.js.map +2 -2
- package/dist/core/element.js +98 -27
- package/dist/core/element.js.map +2 -2
- package/dist/core/golden-copy-cache.js +290 -0
- package/dist/core/golden-copy-cache.js.map +7 -0
- package/dist/core/graph-model.js +266 -0
- package/dist/core/graph-model.js.map +7 -0
- package/dist/core/layer.js +159 -16
- package/dist/core/layer.js.map +2 -2
- package/dist/core/layers.js +32 -0
- package/dist/core/layers.js.map +7 -0
- package/dist/core/manifest.js +32 -11
- package/dist/core/manifest.js.map +2 -2
- package/dist/core/migration-registry.js +56 -1
- package/dist/core/migration-registry.js.map +2 -2
- package/dist/core/model.js +424 -217
- package/dist/core/model.js.map +3 -3
- package/dist/core/mutation-handler.js +179 -0
- package/dist/core/mutation-handler.js.map +7 -0
- package/dist/core/reference-registry.js +29 -21
- package/dist/core/reference-registry.js.map +2 -2
- package/dist/core/relationship-catalog.js +189 -0
- package/dist/core/relationship-catalog.js.map +7 -0
- package/dist/core/relationship-registry.js.map +2 -2
- package/dist/core/relationships.js.map +1 -1
- package/dist/core/report-data-model.js +285 -0
- package/dist/core/report-data-model.js.map +7 -0
- package/dist/core/spec-data-service.js +185 -0
- package/dist/core/spec-data-service.js.map +7 -0
- package/dist/core/spec-loader-types.js +1 -0
- package/dist/core/spec-loader-types.js.map +7 -0
- package/dist/core/spec-loader.js +234 -0
- package/dist/core/spec-loader.js.map +7 -0
- package/dist/core/staged-changeset-storage.js +282 -0
- package/dist/core/staged-changeset-storage.js.map +7 -0
- package/dist/core/staging-area.js +1002 -0
- package/dist/core/staging-area.js.map +7 -0
- package/dist/core/stats-collector.js +169 -0
- package/dist/core/stats-collector.js.map +7 -0
- package/dist/core/virtual-projection.js +443 -0
- package/dist/core/virtual-projection.js.map +7 -0
- package/dist/export/archimate-exporter.js +99 -60
- package/dist/export/archimate-exporter.js.map +2 -2
- package/dist/export/audit-formatters.js +479 -0
- package/dist/export/audit-formatters.js.map +7 -0
- package/dist/export/diff-formatters.js +99 -0
- package/dist/export/diff-formatters.js.map +7 -0
- package/dist/export/export-manager.js.map +2 -2
- package/dist/export/graphml-exporter.js +44 -27
- package/dist/export/graphml-exporter.js.map +2 -2
- package/dist/export/index.js +4 -0
- package/dist/export/index.js.map +2 -2
- package/dist/export/json-schema-exporter.js +55 -42
- package/dist/export/json-schema-exporter.js.map +2 -2
- package/dist/export/markdown-exporter.js +92 -70
- package/dist/export/markdown-exporter.js.map +2 -2
- package/dist/export/markdown-generator.js +248 -0
- package/dist/export/markdown-generator.js.map +7 -0
- package/dist/export/markdown-utils.js +30 -0
- package/dist/export/markdown-utils.js.map +7 -0
- package/dist/export/mermaid-markdown-exporter.js +37 -0
- package/dist/export/mermaid-markdown-exporter.js.map +7 -0
- package/dist/export/openapi-exporter.js +119 -71
- package/dist/export/openapi-exporter.js.map +2 -2
- package/dist/export/plantuml-exporter.js +104 -39
- package/dist/export/plantuml-exporter.js.map +2 -2
- package/dist/export/report-formatters.js +111 -0
- package/dist/export/report-formatters.js.map +7 -0
- package/dist/export/stats-formatters.js +98 -0
- package/dist/export/stats-formatters.js.map +7 -0
- package/dist/export/types.js +2 -14
- package/dist/export/types.js.map +2 -2
- package/dist/export/verify-formatters.js +153 -0
- package/dist/export/verify-formatters.js.map +7 -0
- package/dist/generated/compiled-validators.js +17 -0
- package/dist/generated/compiled-validators.js.map +7 -0
- package/dist/generated/index.js +31 -0
- package/dist/generated/index.js.map +7 -0
- package/dist/generated/layer-registry.js +190 -0
- package/dist/generated/layer-registry.js.map +7 -0
- package/dist/generated/layer-types.js +7 -0
- package/dist/generated/layer-types.js.map +7 -0
- package/dist/generated/node-types.js +1719 -0
- package/dist/generated/node-types.js.map +7 -0
- package/dist/generated/relationship-index.js +14552 -0
- package/dist/generated/relationship-index.js.map +7 -0
- package/dist/import/archimate-importer.js +166 -0
- package/dist/import/archimate-importer.js.map +7 -0
- package/dist/import/index.js +47 -0
- package/dist/import/index.js.map +7 -0
- package/dist/import/openapi-importer.js +143 -0
- package/dist/import/openapi-importer.js.map +7 -0
- package/dist/import/types.js +1 -0
- package/dist/import/types.js.map +7 -0
- package/dist/integrations/base-manager.js +311 -0
- package/dist/integrations/base-manager.js.map +7 -0
- package/dist/integrations/claude-manager.js +360 -0
- package/dist/integrations/claude-manager.js.map +7 -0
- package/dist/integrations/claude_code/agents/dr-advisor.md +253 -0
- package/dist/integrations/claude_code/agents/dr-architect.md +278 -0
- package/dist/integrations/claude_code/agents/dr-extractor.md +286 -0
- package/dist/integrations/claude_code/commands/dr-changeset.md +657 -0
- package/dist/integrations/claude_code/commands/dr-design.md +373 -0
- package/dist/integrations/claude_code/commands/dr-info.md +132 -0
- package/dist/integrations/claude_code/commands/dr-init.md +251 -0
- package/dist/integrations/claude_code/commands/dr-map.md +936 -0
- package/dist/integrations/claude_code/commands/dr-model.md +493 -0
- package/dist/integrations/claude_code/commands/dr-relate.md +814 -0
- package/dist/integrations/claude_code/commands/dr-sync.md +279 -0
- package/dist/integrations/claude_code/commands/dr-validate.md +654 -0
- package/dist/integrations/claude_code/commands/dr-verify.md +559 -0
- package/dist/integrations/claude_code/docs/END_TO_END_WALKTHROUGH.md +903 -0
- package/dist/integrations/claude_code/docs/QUICK_START.md +271 -0
- package/dist/integrations/claude_code/docs/README.md +347 -0
- package/dist/integrations/claude_code/skills/dr_01_motivation_layer/SKILL.md +550 -0
- package/dist/integrations/claude_code/skills/dr_02_business_layer/SKILL.md +620 -0
- package/dist/integrations/claude_code/skills/dr_03_security_layer/SKILL.md +642 -0
- package/dist/integrations/claude_code/skills/dr_04_application_layer/SKILL.md +911 -0
- package/dist/integrations/claude_code/skills/dr_05_technology_layer/SKILL.md +836 -0
- package/dist/integrations/claude_code/skills/dr_06_api_layer/SKILL.md +933 -0
- package/dist/integrations/claude_code/skills/dr_07_data_model_layer/SKILL.md +210 -0
- package/dist/integrations/claude_code/skills/dr_08_dataset_layer/SKILL.md +319 -0
- package/dist/integrations/claude_code/skills/dr_09_ux_layer/SKILL.md +319 -0
- package/dist/integrations/claude_code/skills/dr_10_navigation_layer/SKILL.md +318 -0
- package/dist/integrations/claude_code/skills/dr_11_apm_layer/SKILL.md +273 -0
- package/dist/integrations/claude_code/skills/dr_12_testing_layer/SKILL.md +273 -0
- package/dist/integrations/claude_code/skills/dr_changeset_reviewer/SKILL.md +187 -0
- package/dist/integrations/claude_code/skills/dr_codebase_memory/SKILL.md +590 -0
- package/dist/integrations/claude_code/skills/dr_engineering_guide/SKILL.md +295 -0
- package/dist/integrations/copilot-manager.js +328 -0
- package/dist/integrations/copilot-manager.js.map +7 -0
- package/dist/integrations/github_copilot/agents/dr-advisor.md +243 -0
- package/dist/integrations/github_copilot/agents/dr-architect.md +1567 -0
- package/dist/integrations/github_copilot/skills/dr_01_motivation_layer/SKILL.md +491 -0
- package/dist/integrations/github_copilot/skills/dr_02_business_layer/SKILL.md +539 -0
- package/dist/integrations/github_copilot/skills/dr_03_security_layer/SKILL.md +667 -0
- package/dist/integrations/github_copilot/skills/dr_04_application_layer/SKILL.md +670 -0
- package/dist/integrations/github_copilot/skills/dr_05_technology_layer/SKILL.md +660 -0
- package/dist/integrations/github_copilot/skills/dr_06_api_layer/SKILL.md +855 -0
- package/dist/integrations/github_copilot/skills/dr_07_data_model_layer/SKILL.md +171 -0
- package/dist/integrations/github_copilot/skills/dr_08_dataset_layer/SKILL.md +216 -0
- package/dist/integrations/github_copilot/skills/dr_09_ux_layer/SKILL.md +230 -0
- package/dist/integrations/github_copilot/skills/dr_10_navigation_layer/SKILL.md +228 -0
- package/dist/integrations/github_copilot/skills/dr_11_apm_layer/SKILL.md +234 -0
- package/dist/integrations/github_copilot/skills/dr_12_testing_layer/SKILL.md +230 -0
- package/dist/integrations/github_copilot/skills/dr_changeset_reviewer/SKILL.md +187 -0
- package/dist/integrations/hash-utils.js +51 -0
- package/dist/integrations/hash-utils.js.map +7 -0
- package/dist/integrations/types.js +16 -0
- package/dist/integrations/types.js.map +7 -0
- package/dist/reports/model-layer-report-generator.js +278 -0
- package/dist/reports/model-layer-report-generator.js.map +7 -0
- package/dist/reports/model-report-data.js +57 -0
- package/dist/reports/model-report-data.js.map +7 -0
- package/dist/reports/model-report-orchestrator.js +103 -0
- package/dist/reports/model-report-orchestrator.js.map +7 -0
- package/dist/schemas/bundled/analyzers/cbm.json +595 -0
- package/dist/schemas/bundled/analyzers/manifest.json +9 -0
- package/dist/schemas/bundled/api.json +3411 -0
- package/dist/schemas/bundled/apm.json +2371 -0
- package/dist/schemas/bundled/application.json +1253 -0
- package/dist/schemas/bundled/base.json +1622 -0
- package/dist/schemas/bundled/business.json +1279 -0
- package/dist/schemas/bundled/data-model.json +1298 -0
- package/dist/schemas/bundled/data-store.json +2025 -0
- package/dist/schemas/bundled/manifest.json +93 -0
- package/dist/schemas/bundled/motivation.json +1360 -0
- package/dist/schemas/bundled/navigation.json +1874 -0
- package/dist/schemas/bundled/security.json +3488 -0
- package/dist/schemas/bundled/technology.json +2067 -0
- package/dist/schemas/bundled/testing.json +3120 -0
- package/dist/schemas/bundled/ux.json +3592 -0
- package/dist/server/schemas.js +202 -0
- package/dist/server/schemas.js.map +7 -0
- package/dist/server/server.js +1336 -252
- package/dist/server/server.js.map +3 -3
- package/dist/server/telemetry-middleware.js +22 -15
- package/dist/server/telemetry-middleware.js.map +2 -2
- package/dist/server-entry.js +65 -0
- package/dist/server-entry.js.map +7 -0
- package/dist/telemetry/config.js +89 -0
- package/dist/telemetry/config.js.map +7 -0
- package/dist/telemetry/console-interceptor.js.map +1 -1
- package/dist/telemetry/detect.js +24 -0
- package/dist/telemetry/detect.js.map +7 -0
- package/dist/telemetry/fetch-otlp-exporter.js +112 -0
- package/dist/telemetry/fetch-otlp-exporter.js.map +7 -0
- package/dist/telemetry/index.js +153 -3
- package/dist/telemetry/index.js.map +2 -2
- package/dist/telemetry/resilient-exporter.js +22 -8
- package/dist/telemetry/resilient-exporter.js.map +2 -2
- package/dist/telemetry/resilient-log-exporter.js +17 -8
- package/dist/telemetry/resilient-log-exporter.js.map +2 -2
- package/dist/telemetry/test-instrumentation.js.map +2 -2
- package/dist/types/index.js +84 -0
- package/dist/types/index.js.map +3 -3
- package/dist/types/source-reference.js +1 -0
- package/dist/types/source-reference.js.map +7 -0
- package/dist/utils/chat-logger.js +292 -0
- package/dist/utils/chat-logger.js.map +7 -0
- package/dist/utils/claude-stream.js +8 -0
- package/dist/utils/claude-stream.js.map +7 -0
- package/dist/utils/date-utils.js +7 -0
- package/dist/utils/date-utils.js.map +7 -0
- package/dist/utils/element-utils.js.map +1 -1
- package/dist/utils/errors.js +88 -15
- package/dist/utils/errors.js.map +3 -3
- package/dist/utils/export-python-annotations.js +82 -0
- package/dist/utils/export-python-annotations.js.map +7 -0
- package/dist/utils/file-io.js +7 -2
- package/dist/utils/file-io.js.map +2 -2
- package/dist/utils/file-lock.js +156 -0
- package/dist/utils/file-lock.js.map +7 -0
- package/dist/utils/id-generator.js +18 -0
- package/dist/utils/id-generator.js.map +7 -0
- package/dist/utils/layer-name-formatter.js +16 -0
- package/dist/utils/layer-name-formatter.js.map +7 -0
- package/dist/utils/markdown-anchor.js +7 -0
- package/dist/utils/markdown-anchor.js.map +7 -0
- package/dist/utils/markdown-link.js +12 -0
- package/dist/utils/markdown-link.js.map +7 -0
- package/dist/utils/markdown-table.js +17 -0
- package/dist/utils/markdown-table.js.map +7 -0
- package/dist/utils/mermaid-utils.js +11 -0
- package/dist/utils/mermaid-utils.js.map +7 -0
- package/dist/utils/project-paths.js.map +2 -2
- package/dist/utils/source-reference.js +52 -0
- package/dist/utils/source-reference.js.map +7 -0
- package/dist/utils/spec-installer.js +40 -53
- package/dist/utils/spec-installer.js.map +2 -2
- package/dist/utils/spec-version.js +5 -1
- package/dist/utils/spec-version.js.map +2 -2
- package/dist/utils/string-utils.js +12 -0
- package/dist/utils/string-utils.js.map +7 -0
- package/dist/utils/table-formatting.js +19 -0
- package/dist/utils/table-formatting.js.map +7 -0
- package/dist/validators/index.js +4 -0
- package/dist/validators/index.js.map +2 -2
- package/dist/validators/naming-validator.js +20 -23
- package/dist/validators/naming-validator.js.map +2 -2
- package/dist/validators/reference-validator.js +23 -38
- package/dist/validators/reference-validator.js.map +2 -2
- package/dist/validators/relationship-schema-validator.js +243 -0
- package/dist/validators/relationship-schema-validator.js.map +7 -0
- package/dist/validators/schema-validator.js +168 -68
- package/dist/validators/schema-validator.js.map +2 -2
- package/dist/validators/semantic-validator.js +36 -60
- package/dist/validators/semantic-validator.js.map +2 -2
- package/dist/validators/types.js.map +2 -2
- package/dist/validators/validation-formatter.js +159 -0
- package/dist/validators/validation-formatter.js.map +7 -0
- package/dist/validators/validator.js +24 -38
- package/dist/validators/validator.js.map +2 -2
- package/dist/viewer/README.md +139 -0
- package/dist/viewer/assets/main-CY0Xufuj.css +1 -0
- package/dist/viewer/assets/main-DtgErnwF.js +81 -0
- package/dist/viewer/assets/vendor-CxKvDp2x.js +17 -0
- package/dist/viewer/favicon.svg +11 -0
- package/dist/viewer/fonts/inter/Inter-Black.woff2 +0 -0
- package/dist/viewer/fonts/inter/Inter-Bold.woff2 +0 -0
- package/dist/viewer/fonts/inter/Inter-ExtraBold.woff2 +0 -0
- package/dist/viewer/fonts/inter/Inter-Light.woff2 +0 -0
- package/dist/viewer/fonts/inter/Inter-Medium.woff2 +0 -0
- package/dist/viewer/fonts/inter/Inter-Regular.woff2 +0 -0
- package/dist/viewer/fonts/inter/Inter-SemiBold.woff2 +0 -0
- package/dist/viewer/fonts/jetbrains-mono/JetBrainsMono-Medium.woff2 +0 -0
- package/dist/viewer/fonts/jetbrains-mono/JetBrainsMono-Regular.woff2 +0 -0
- package/dist/viewer/fonts/jetbrains-mono/JetBrainsMono-SemiBold.woff2 +0 -0
- package/dist/viewer/index.html +15 -0
- package/dist/viewer/manifest.json +99 -0
- package/dist/viewer/version.json +1 -0
- package/package.json +42 -16
- package/PYTHON_CLI_PARITY.md +0 -265
- package/PYTHON_CLI_STRUCTURE_UPDATE.md +0 -246
- package/biome.json +0 -42
- package/bunfig.toml +0 -3
- package/dist/ai/claude-client.js +0 -71
- package/dist/ai/claude-client.js.map +0 -7
- package/dist/ai/context-provider.js +0 -129
- package/dist/ai/context-provider.js.map +0 -7
- package/dist/ai/tools.js +0 -231
- package/dist/ai/tools.js.map +0 -7
- package/dist/commands/migrate.js +0 -36
- package/dist/commands/migrate.js.map +0 -7
- package/dist/commands/project.js +0 -74
- package/dist/commands/project.js.map +0 -7
- package/dist/core/active-changeset.js +0 -52
- package/dist/core/active-changeset.js.map +0 -7
- package/dist/core/projection-engine.js +0 -288
- package/dist/core/projection-engine.js.map +0 -7
- package/dist/schemas/bundled/01-motivation-layer.schema.json +0 -942
- package/dist/schemas/bundled/02-business-layer.schema.json +0 -1293
- package/dist/schemas/bundled/03-security-layer.schema.json +0 -2177
- package/dist/schemas/bundled/04-application-layer.schema.json +0 -1328
- package/dist/schemas/bundled/05-technology-layer.schema.json +0 -1465
- package/dist/schemas/bundled/06-api-layer.schema.json +0 -1743
- package/dist/schemas/bundled/07-data-model-layer.schema.json +0 -1253
- package/dist/schemas/bundled/08-datastore-layer.schema.json +0 -892
- package/dist/schemas/bundled/09-ux-layer.schema.json +0 -1506
- package/dist/schemas/bundled/10-navigation-layer.schema.json +0 -843
- package/dist/schemas/bundled/11-apm-observability-layer.schema.json +0 -1430
- package/dist/schemas/bundled/12-testing-layer.schema.json +0 -1091
- package/dist/schemas/bundled/common/layer-extensions.schema.json +0 -266
- package/dist/schemas/bundled/common/predicates.schema.json +0 -493
- package/dist/schemas/bundled/common/relationships.schema.json +0 -791
- package/dist/schemas/bundled/common/source-references.schema.json +0 -71
- package/dist/schemas/bundled/link-registry.json +0 -1839
- package/dist/schemas/bundled/link-registry.schema.json +0 -339
- package/dist/schemas/bundled/relationship-catalog.json +0 -1302
- package/dist/schemas/bundled/relationship-type.schema.json +0 -221
- package/dist/utils/model-path.js +0 -22
- package/dist/utils/model-path.js.map +0 -7
- package/docs/TEST-INSTRUMENTATION.md +0 -405
- package/docs/telemetry.md +0 -427
- package/test-debug.js +0 -33
- package/test-special.mjs +0 -46
- package/test_runner.ts +0 -7
|
@@ -0,0 +1,273 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: LAYER_11_APM
|
|
3
|
+
description: Expert knowledge for APM (Observability) Layer modeling in Documentation Robotics
|
|
4
|
+
triggers:
|
|
5
|
+
[
|
|
6
|
+
"APM",
|
|
7
|
+
"observability",
|
|
8
|
+
"monitoring",
|
|
9
|
+
"metrics",
|
|
10
|
+
"spans",
|
|
11
|
+
"traces",
|
|
12
|
+
"logs",
|
|
13
|
+
"OpenTelemetry",
|
|
14
|
+
"telemetry"
|
|
15
|
+
]
|
|
16
|
+
version: 0.8.3
|
|
17
|
+
---
|
|
18
|
+
|
|
19
|
+
# APM Layer Skill
|
|
20
|
+
|
|
21
|
+
**Layer Number:** 11
|
|
22
|
+
**Specification:** Metadata Model Spec v0.8.3
|
|
23
|
+
**Purpose:** Defines observability using OpenTelemetry 1.0+, specifying traces, metrics, logs, and instrumentation.
|
|
24
|
+
|
|
25
|
+
---
|
|
26
|
+
|
|
27
|
+
## Layer Overview
|
|
28
|
+
|
|
29
|
+
The APM Layer captures **application performance monitoring**:
|
|
30
|
+
|
|
31
|
+
- **TRACES** - Distributed tracing with spans
|
|
32
|
+
- **METRICS** - Performance and business metrics
|
|
33
|
+
- **LOGS** - Structured logging
|
|
34
|
+
- **INSTRUMENTATION** - Code instrumentation configuration
|
|
35
|
+
- **RESOURCES** - Telemetry resource attributes
|
|
36
|
+
- **ALERTING** - Alert rules and monitoring dashboards
|
|
37
|
+
|
|
38
|
+
This layer uses **OpenTelemetry 1.0+** (industry standard for observability).
|
|
39
|
+
|
|
40
|
+
**Central Entity:** The **Span** (unit of work in trace) is the core modeling unit.
|
|
41
|
+
|
|
42
|
+
---
|
|
43
|
+
|
|
44
|
+
## Pre-Extraction Verification
|
|
45
|
+
|
|
46
|
+
Before extracting APM elements, verify what level of observability the codebase ACTUALLY implements. Do not model aspirational instrumentation.
|
|
47
|
+
|
|
48
|
+
### Step 1: Check for OTel SDK
|
|
49
|
+
|
|
50
|
+
```bash
|
|
51
|
+
grep "@opentelemetry" package.json
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
**If NO OTel SDK found:**
|
|
55
|
+
|
|
56
|
+
- Do NOT add `MetricInstrument`, `Span`, `TraceConfiguration`, or `ExporterConfig` elements as if they are implemented
|
|
57
|
+
- ONLY model what exists: browser console logging (`LogConfiguration`), UI-displayed metrics (describe in element description that export is absent)
|
|
58
|
+
- Mark all elements `provenance: inferred` and add a note in the description: "Metric concept identified; no OTel export implemented."
|
|
59
|
+
|
|
60
|
+
**If OTel SDK IS found:**
|
|
61
|
+
|
|
62
|
+
- Proceed with full extraction of all APM types
|
|
63
|
+
|
|
64
|
+
### Step 2: Identify what observability actually exists
|
|
65
|
+
|
|
66
|
+
Even without OTel, codebases may have:
|
|
67
|
+
|
|
68
|
+
- Browser console error logging → `apm.logconfiguration`
|
|
69
|
+
- UI-visible token/usage counters → `apm.metricinstrument` (with note: display-only, not exported)
|
|
70
|
+
- Error tracking utilities → `apm.instrumentationconfig` (type: manual)
|
|
71
|
+
- In-memory state tracking → `apm.metricinstrument` (inferred, note: in-memory only)
|
|
72
|
+
|
|
73
|
+
### In-UI Observability vs. OTel Instrumentation
|
|
74
|
+
|
|
75
|
+
| Pattern | Model as | provenance |
|
|
76
|
+
| ------------------------------- | ----------------------------------------- | ---------- |
|
|
77
|
+
| `console.error()` logging | `logconfiguration` | extracted |
|
|
78
|
+
| UI badge showing token count | `metricinstrument` (note: display-only) | inferred |
|
|
79
|
+
| Store tracks reconnection count | `metricinstrument` (note: in-memory only) | inferred |
|
|
80
|
+
| `opentelemetry.createCounter()` | `metricinstrument` | extracted |
|
|
81
|
+
| Prometheus export endpoint | `exporterconfig` | extracted |
|
|
82
|
+
|
|
83
|
+
---
|
|
84
|
+
|
|
85
|
+
## Entity Types
|
|
86
|
+
|
|
87
|
+
> **CLI Introspection:** Run `dr schema types apm` for the authoritative, always-current list of node types.
|
|
88
|
+
> Run `dr schema node <type-id>` for full attribute details on any type.
|
|
89
|
+
|
|
90
|
+
### Core APM Entities (15 entities)
|
|
91
|
+
|
|
92
|
+
| Entity Type | Description |
|
|
93
|
+
| ------------------------- | ----------------------------------------------------------------- |
|
|
94
|
+
| **TraceConfiguration** | Distributed tracing configuration |
|
|
95
|
+
| **Span** | Unit of work in distributed trace |
|
|
96
|
+
| **SpanEvent** | Timestamped event within span |
|
|
97
|
+
| **SpanLink** | Link between spans from different traces |
|
|
98
|
+
| **MetricConfiguration** | Metrics collection configuration |
|
|
99
|
+
| **MetricInstrument** | Specific metric instrument (Counter, Gauge, Histogram, etc.) |
|
|
100
|
+
| **LogConfiguration** | Structured logging configuration |
|
|
101
|
+
| **LogRecord** | Individual log record |
|
|
102
|
+
| **LogProcessor** | Log processing pipeline step (simple, batch, custom) |
|
|
103
|
+
| **Resource** | Telemetry resource attributes |
|
|
104
|
+
| **InstrumentationScope** | Scope of instrumentation |
|
|
105
|
+
| **InstrumentationConfig** | Code instrumentation configuration (library, auto/manual type) |
|
|
106
|
+
| **ExporterConfig** | Telemetry exporter configuration (OTLP, Jaeger, Prometheus, etc.) |
|
|
107
|
+
| **Alert** | Alert rule with severity, condition, and notification channels |
|
|
108
|
+
| **Dashboard** | Monitoring dashboard definition (Grafana, Datadog, etc.) |
|
|
109
|
+
|
|
110
|
+
---
|
|
111
|
+
|
|
112
|
+
## Type Decision Tree
|
|
113
|
+
|
|
114
|
+
Use this decision tree **before assigning a type** to any APM element.
|
|
115
|
+
|
|
116
|
+
- Is this an alert rule with severity and condition? → `apm.alert`
|
|
117
|
+
- Is this a monitoring dashboard definition (Grafana, Datadog, etc.)? → `apm.dashboard`
|
|
118
|
+
- Is this an exporter configuration (OTLP, Jaeger, Prometheus endpoint)? → `apm.exporterconfig`
|
|
119
|
+
- Is this a code instrumentation configuration (library name, auto/manual)? → `apm.instrumentationconfig`
|
|
120
|
+
- Is this the instrumentation scope (library version, schema URL)? → `apm.instrumentationscope`
|
|
121
|
+
- Is this logging pipeline configuration (service name, minimum severity)? → `apm.logconfiguration`
|
|
122
|
+
- Is this a log processor step (batch, simple, custom)? → `apm.logprocessor`
|
|
123
|
+
- Is this an individual structured log record with body and severity? → `apm.logrecord`
|
|
124
|
+
- Is this a metrics collection configuration (export interval, cardinality limit)? → `apm.metricconfiguration`
|
|
125
|
+
- Is this a specific metric instrument (counter, gauge, histogram, observable)? → `apm.metricinstrument`
|
|
126
|
+
- Is this a telemetry resource (service name, deployment environment attributes)? → `apm.resource`
|
|
127
|
+
- Is this a unit of work/operation in a distributed trace? → `apm.span`
|
|
128
|
+
- Is this an event that occurred within a span? → `apm.spanevent`
|
|
129
|
+
- Is this a link between spans from different traces? → `apm.spanlink`
|
|
130
|
+
- Is this distributed tracing configuration (sampler type, propagators)? → `apm.traceconfiguration`
|
|
131
|
+
|
|
132
|
+
---
|
|
133
|
+
|
|
134
|
+
## When to Use This Skill
|
|
135
|
+
|
|
136
|
+
Activate when the user:
|
|
137
|
+
|
|
138
|
+
- Mentions "APM", "observability", "monitoring", "telemetry"
|
|
139
|
+
- Wants to add tracing, metrics, or logging
|
|
140
|
+
- Asks about performance monitoring or SLOs
|
|
141
|
+
- Needs to instrument code or track business metrics
|
|
142
|
+
- Wants to link observability to application services
|
|
143
|
+
|
|
144
|
+
---
|
|
145
|
+
|
|
146
|
+
## Cross-Layer Relationships
|
|
147
|
+
|
|
148
|
+
**Outgoing (APM → Other Layers):**
|
|
149
|
+
|
|
150
|
+
- `instrumented-service` → Application Layer (which service is being monitored?)
|
|
151
|
+
- `business-metrics` → Business Layer (business KPIs)
|
|
152
|
+
|
|
153
|
+
**Incoming (Other Layers → APM):**
|
|
154
|
+
|
|
155
|
+
- Application Layer → APM (services reference metrics)
|
|
156
|
+
- API Layer → APM (operations set SLA targets)
|
|
157
|
+
- Business Layer → APM (processes reference business metrics)
|
|
158
|
+
- Data Model Layer → APM (metric instruments tracking data quality KPIs)
|
|
159
|
+
- Data Store Layer → APM (query performance metrics)
|
|
160
|
+
|
|
161
|
+
---
|
|
162
|
+
|
|
163
|
+
## Observability Best Practices
|
|
164
|
+
|
|
165
|
+
1. **Traces** - Add spans for critical operations
|
|
166
|
+
2. **Metrics** - Track both technical and business metrics
|
|
167
|
+
3. **Logs** - Use structured logging (JSON)
|
|
168
|
+
4. **Context** - Propagate trace context across services
|
|
169
|
+
5. **Sampling** - Configure appropriate sampling rates
|
|
170
|
+
6. **SLOs** - Define service level objectives
|
|
171
|
+
7. **Alerting** - Set up alerts for critical metrics
|
|
172
|
+
8. **Cardinality** - Avoid high-cardinality attributes
|
|
173
|
+
|
|
174
|
+
---
|
|
175
|
+
|
|
176
|
+
## Common Commands
|
|
177
|
+
|
|
178
|
+
```bash
|
|
179
|
+
# Add span
|
|
180
|
+
dr add apm span "Process Order"
|
|
181
|
+
|
|
182
|
+
# Add metric instrument
|
|
183
|
+
dr add apm metricinstrument "order_rate" --description "Order processing rate counter"
|
|
184
|
+
|
|
185
|
+
# Add log record
|
|
186
|
+
dr add apm logrecord "Error Log"
|
|
187
|
+
|
|
188
|
+
# List APM elements
|
|
189
|
+
dr list apm --type span
|
|
190
|
+
|
|
191
|
+
# Validate APM layer
|
|
192
|
+
dr validate --layers apm
|
|
193
|
+
|
|
194
|
+
# Export APM configuration
|
|
195
|
+
dr export markdown --layers apm
|
|
196
|
+
```
|
|
197
|
+
|
|
198
|
+
---
|
|
199
|
+
|
|
200
|
+
## Example: Order Processing Span
|
|
201
|
+
|
|
202
|
+
```yaml
|
|
203
|
+
id: apm.span.process-order
|
|
204
|
+
name: "Process Order Span"
|
|
205
|
+
type: span
|
|
206
|
+
properties:
|
|
207
|
+
traceId: "4bf92f3577b34da6a3ce929d0e0e4736"
|
|
208
|
+
spanId: "00f067aa0ba902b7"
|
|
209
|
+
traceState: ""
|
|
210
|
+
parentSpanId: "b9c7c989f97918e1"
|
|
211
|
+
spanKind: INTERNAL
|
|
212
|
+
startTimeUnixNano: "1544712660000000000"
|
|
213
|
+
endTimeUnixNano: "1544712661000000000"
|
|
214
|
+
droppedAttributesCount: 0
|
|
215
|
+
droppedEventsCount: 0
|
|
216
|
+
droppedLinksCount: 0
|
|
217
|
+
statusCode: OK
|
|
218
|
+
attributes:
|
|
219
|
+
order.id: "ord-12345"
|
|
220
|
+
order.total: 99.99
|
|
221
|
+
customer.id: "cust-67890"
|
|
222
|
+
```
|
|
223
|
+
|
|
224
|
+
---
|
|
225
|
+
|
|
226
|
+
## Example: Business Metrics
|
|
227
|
+
|
|
228
|
+
```yaml
|
|
229
|
+
id: apm.metricinstrument.order-rate
|
|
230
|
+
name: "Order Rate Metric"
|
|
231
|
+
type: metricinstrument
|
|
232
|
+
properties:
|
|
233
|
+
type: Counter
|
|
234
|
+
unit: orders
|
|
235
|
+
description: "Number of orders processed per minute"
|
|
236
|
+
enabled: true
|
|
237
|
+
```
|
|
238
|
+
|
|
239
|
+
---
|
|
240
|
+
|
|
241
|
+
## Coverage Completeness Checklist
|
|
242
|
+
|
|
243
|
+
Before declaring APM layer extraction complete, verify each type was considered:
|
|
244
|
+
|
|
245
|
+
- [ ] `apm.alert` — Alert rule with severity and notification channels
|
|
246
|
+
- [ ] `apm.dashboard` — Monitoring dashboard (Grafana, Datadog, etc.)
|
|
247
|
+
- [ ] `apm.exporterconfig` — Telemetry exporter configuration (OTLP, Prometheus, etc.)
|
|
248
|
+
- [ ] `apm.instrumentationconfig` — Code instrumentation configuration
|
|
249
|
+
- [ ] `apm.instrumentationscope` — Instrumentation scope (library version and schema URL)
|
|
250
|
+
- [ ] `apm.logconfiguration` — Logging configuration per service
|
|
251
|
+
- [ ] `apm.logprocessor` — Log processing pipeline step
|
|
252
|
+
- [ ] `apm.logrecord` — Individual structured log record
|
|
253
|
+
- [ ] `apm.metricconfiguration` — Metrics collection configuration per service
|
|
254
|
+
- [ ] `apm.metricinstrument` — Specific metric instrument (Counter, Gauge, Histogram, etc.)
|
|
255
|
+
- [ ] `apm.resource` — Telemetry resource attributes (service name, environment)
|
|
256
|
+
- [ ] `apm.span` — Unit of work in a distributed trace
|
|
257
|
+
- [ ] `apm.spanevent` — Timestamped event within a span
|
|
258
|
+
- [ ] `apm.spanlink` — Link between spans from different traces
|
|
259
|
+
- [ ] `apm.traceconfiguration` — Distributed tracing configuration
|
|
260
|
+
|
|
261
|
+
If any type has ZERO elements, explicitly decide:
|
|
262
|
+
"This type doesn't apply to this codebase" with reasoning.
|
|
263
|
+
|
|
264
|
+
---
|
|
265
|
+
|
|
266
|
+
## Pitfalls to Avoid
|
|
267
|
+
|
|
268
|
+
- ❌ Not propagating trace context across services
|
|
269
|
+
- ❌ High-cardinality attributes (e.g., unique IDs in tags)
|
|
270
|
+
- ❌ Missing business metrics (only technical metrics)
|
|
271
|
+
- ❌ Not setting SLOs/SLAs
|
|
272
|
+
- ❌ Over-instrumentation (too many spans)
|
|
273
|
+
- ❌ Missing cross-layer links to instrumented services
|
|
@@ -0,0 +1,273 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: LAYER_12_TESTING
|
|
3
|
+
description: Expert knowledge for Testing Layer modeling in Documentation Robotics
|
|
4
|
+
triggers:
|
|
5
|
+
[
|
|
6
|
+
"testing",
|
|
7
|
+
"test coverage",
|
|
8
|
+
"test case",
|
|
9
|
+
"input partition",
|
|
10
|
+
"ISP",
|
|
11
|
+
"test strategy",
|
|
12
|
+
"coverage model"
|
|
13
|
+
]
|
|
14
|
+
version: 0.8.3
|
|
15
|
+
---
|
|
16
|
+
|
|
17
|
+
# Testing Layer Skill
|
|
18
|
+
|
|
19
|
+
**Layer Number:** 12
|
|
20
|
+
**Specification:** Metadata Model Spec v0.8.3
|
|
21
|
+
**Purpose:** Defines test coverage using ISP (Input Space Partitioning) Coverage Model, specifying coverage requirements, test cases, and input partitions.
|
|
22
|
+
|
|
23
|
+
---
|
|
24
|
+
|
|
25
|
+
## Layer Overview
|
|
26
|
+
|
|
27
|
+
The Testing Layer captures **test coverage strategy**:
|
|
28
|
+
|
|
29
|
+
- **COVERAGE MODELS** - Overall test coverage requirements
|
|
30
|
+
- **COVERAGE TARGETS** - What needs testing (APIs, features, data)
|
|
31
|
+
- **INPUT PARTITIONS** - Partition input space for systematic coverage
|
|
32
|
+
- **TEST CASES** - Concrete test case sketches
|
|
33
|
+
- **CONTEXT VARIATIONS** - Test strategy variation types (functional, load, security, regression, smoke, exploratory)
|
|
34
|
+
- **COVERAGE GAPS** - Identified gaps in coverage
|
|
35
|
+
|
|
36
|
+
This layer uses **ISP Coverage Model** (systematic input space partitioning).
|
|
37
|
+
|
|
38
|
+
**Central Entity:** The **TestCoverageModel** is the core modeling unit.
|
|
39
|
+
|
|
40
|
+
---
|
|
41
|
+
|
|
42
|
+
## Entity Types
|
|
43
|
+
|
|
44
|
+
> **CLI Introspection:** Run `dr schema types testing` for the authoritative, always-current list of node types.
|
|
45
|
+
> Run `dr schema node <type-id>` for full attribute details on any type.
|
|
46
|
+
|
|
47
|
+
### Core Testing Entities (17 types)
|
|
48
|
+
|
|
49
|
+
| Entity Type | Description |
|
|
50
|
+
| --------------------------- | ------------------------------------------------------------------------------ |
|
|
51
|
+
| **TestCoverageModel** | Root coverage model for system/component |
|
|
52
|
+
| **TestCoverageTarget** | What needs testing (API, feature, data) |
|
|
53
|
+
| **InputSpacePartition** | Partition of input space |
|
|
54
|
+
| **PartitionValue** | Value/range within partition |
|
|
55
|
+
| **InputPartitionSelection** | Selected partition values for coverage |
|
|
56
|
+
| **InputSelection** | Concrete resolved input value chosen from a partition for a specific test case |
|
|
57
|
+
| **CoverageRequirement** | Specific coverage requirement |
|
|
58
|
+
| **TestCaseSketch** | High-level test case description |
|
|
59
|
+
| **OutcomeCategory** | Expected outcome categories |
|
|
60
|
+
| **ContextVariation** | Environmental/contextual variation |
|
|
61
|
+
| **EnvironmentFactor** | Environment-specific factor |
|
|
62
|
+
| **PartitionDependency** | Dependencies between partitions |
|
|
63
|
+
| **CoverageGap** | Identified gap in coverage |
|
|
64
|
+
| **CoverageExclusion** | Explicitly excluded coverage |
|
|
65
|
+
| **CoverageSummary** | Summary of coverage status |
|
|
66
|
+
| **TargetCoverageSummary** | Coverage summary for target |
|
|
67
|
+
| **TargetInputField** | Input field for target |
|
|
68
|
+
|
|
69
|
+
---
|
|
70
|
+
|
|
71
|
+
## Type Decision Tree
|
|
72
|
+
|
|
73
|
+
Use this decision tree **before assigning a type** to any testing concept.
|
|
74
|
+
|
|
75
|
+
```
|
|
76
|
+
IS this the root coverage plan for a system, service, or feature?
|
|
77
|
+
→ testing.testcoveragemodel
|
|
78
|
+
|
|
79
|
+
IS this a specific thing being tested (an API operation, feature, workflow, data field)?
|
|
80
|
+
→ testing.testcoveragetarget
|
|
81
|
+
|
|
82
|
+
IS this a division of an input field's possible values (valid/invalid/boundary ranges)?
|
|
83
|
+
→ testing.inputspacepartition
|
|
84
|
+
|
|
85
|
+
IS this one specific value or boundary within a partition?
|
|
86
|
+
→ testing.partitionvalue
|
|
87
|
+
|
|
88
|
+
IS this a constraint that links partition values to other partitions (e.g., field B depends on field A)?
|
|
89
|
+
→ testing.partitiondependency
|
|
90
|
+
|
|
91
|
+
IS this a declarative selection of which partition values to exercise in a test run?
|
|
92
|
+
→ testing.inputpartitionselection
|
|
93
|
+
|
|
94
|
+
IS this a single concrete resolved value chosen from a partition for a specific test case?
|
|
95
|
+
→ testing.inputselection
|
|
96
|
+
|
|
97
|
+
IS this an overall coverage requirement (criteria like "each-choice", "pairwise")?
|
|
98
|
+
→ testing.coveragerequirement
|
|
99
|
+
|
|
100
|
+
IS this a concrete high-level description of a single test case?
|
|
101
|
+
→ testing.testcasesketch
|
|
102
|
+
|
|
103
|
+
IS this a category of expected outcomes (success, error, edge-case)?
|
|
104
|
+
→ testing.outcomecategory
|
|
105
|
+
|
|
106
|
+
IS this a test strategy variation type — functional, load, security, regression, smoke, or exploratory testing?
|
|
107
|
+
→ testing.contextvariation
|
|
108
|
+
|
|
109
|
+
IS this a concrete environmental setting with a specific value (e.g., os=Linux, locale=en-US, network=low-bandwidth)?
|
|
110
|
+
→ testing.environmentfactor
|
|
111
|
+
|
|
112
|
+
IS this an input field on a target that is mapped to partitions?
|
|
113
|
+
→ testing.targetinputfield
|
|
114
|
+
|
|
115
|
+
IS this an identified gap — something that should be tested but is not?
|
|
116
|
+
→ testing.coveragegap
|
|
117
|
+
|
|
118
|
+
IS this a deliberate decision to NOT test something, with documented rationale?
|
|
119
|
+
→ testing.coverageexclusion
|
|
120
|
+
|
|
121
|
+
IS this a rollup of coverage metrics across all targets?
|
|
122
|
+
→ testing.coveragesummary
|
|
123
|
+
|
|
124
|
+
IS this a per-target rollup of sketch/implementation/automation counts?
|
|
125
|
+
→ testing.targetcoveragesummary
|
|
126
|
+
```
|
|
127
|
+
|
|
128
|
+
---
|
|
129
|
+
|
|
130
|
+
## When to Use This Skill
|
|
131
|
+
|
|
132
|
+
Activate when the user:
|
|
133
|
+
|
|
134
|
+
- Mentions "testing", "test coverage", "test cases", "ISP"
|
|
135
|
+
- Wants to define test strategy or coverage requirements
|
|
136
|
+
- Asks about input partitioning or systematic testing
|
|
137
|
+
- Needs to model test cases for APIs, features, or data
|
|
138
|
+
- Wants to link testing to requirements or business goals
|
|
139
|
+
|
|
140
|
+
---
|
|
141
|
+
|
|
142
|
+
## Cross-Layer Relationships
|
|
143
|
+
|
|
144
|
+
**Outgoing (Testing → Other Layers):**
|
|
145
|
+
|
|
146
|
+
- `motivation.supports-goals` → Motivation Layer (quality goals)
|
|
147
|
+
- `motivation.fulfills-requirements` → Motivation Layer (test requirements)
|
|
148
|
+
- `business.covers-process` → Business Layer (process coverage)
|
|
149
|
+
- `api.tests-operation` → API Layer (API endpoint testing)
|
|
150
|
+
- `data.validates-schema` → Data Model Layer (data validation)
|
|
151
|
+
- `ux.tests-view` → UX Layer (UI testing)
|
|
152
|
+
|
|
153
|
+
**Incoming (Other Layers → Testing):**
|
|
154
|
+
|
|
155
|
+
- Motivation Layer → Testing (requirements drive coverage)
|
|
156
|
+
- API Layer → Testing (operations need test coverage)
|
|
157
|
+
- Business Layer → Testing (processes need testing)
|
|
158
|
+
|
|
159
|
+
---
|
|
160
|
+
|
|
161
|
+
## Testing Best Practices
|
|
162
|
+
|
|
163
|
+
1. **Systematic partitioning** - Use ISP to partition input space
|
|
164
|
+
2. **Coverage criteria** - Define clear coverage criteria
|
|
165
|
+
3. **Context variations** - Test across different contexts
|
|
166
|
+
4. **Traceability** - Link tests to requirements and features
|
|
167
|
+
5. **Gap analysis** - Identify and document coverage gaps
|
|
168
|
+
6. **Exclusions** - Explicitly document what's not tested
|
|
169
|
+
7. **Outcome categories** - Define expected outcomes clearly
|
|
170
|
+
|
|
171
|
+
---
|
|
172
|
+
|
|
173
|
+
## Common Commands
|
|
174
|
+
|
|
175
|
+
```bash
|
|
176
|
+
# Add coverage model
|
|
177
|
+
dr add testing testcoveragemodel "API Coverage Model"
|
|
178
|
+
|
|
179
|
+
# Add coverage target
|
|
180
|
+
dr add testing testcoveragetarget "Login API Coverage"
|
|
181
|
+
|
|
182
|
+
# Add test case sketch
|
|
183
|
+
dr add testing testcasesketch "Valid Login Test"
|
|
184
|
+
|
|
185
|
+
# List coverage models
|
|
186
|
+
dr list testing --type testcoveragemodel
|
|
187
|
+
|
|
188
|
+
# Validate testing layer
|
|
189
|
+
dr validate --layers testing
|
|
190
|
+
|
|
191
|
+
# Export coverage report
|
|
192
|
+
dr export markdown --layers testing
|
|
193
|
+
```
|
|
194
|
+
|
|
195
|
+
---
|
|
196
|
+
|
|
197
|
+
## Example: Login API Coverage Model
|
|
198
|
+
|
|
199
|
+
```yaml
|
|
200
|
+
id: testing.testcoveragemodel.login-api
|
|
201
|
+
name: "Login API Coverage Model"
|
|
202
|
+
type: testcoveragemodel
|
|
203
|
+
properties:
|
|
204
|
+
version: "1.0"
|
|
205
|
+
application: application.service.auth-service
|
|
206
|
+
description: "ISP coverage model for the Login API"
|
|
207
|
+
```
|
|
208
|
+
|
|
209
|
+
---
|
|
210
|
+
|
|
211
|
+
## Example: Login Test Coverage Target
|
|
212
|
+
|
|
213
|
+
```yaml
|
|
214
|
+
id: testing.testcoveragetarget.login-endpoint
|
|
215
|
+
name: "Login Endpoint Coverage"
|
|
216
|
+
type: testcoveragetarget
|
|
217
|
+
properties:
|
|
218
|
+
targetType: api-endpoint
|
|
219
|
+
description: "POST /auth/login — validates credentials and returns a JWT"
|
|
220
|
+
priority: critical
|
|
221
|
+
```
|
|
222
|
+
|
|
223
|
+
---
|
|
224
|
+
|
|
225
|
+
## Example: Test Case Sketch
|
|
226
|
+
|
|
227
|
+
```yaml
|
|
228
|
+
id: testing.testcasesketch.valid-login
|
|
229
|
+
name: "Valid Login Test Case"
|
|
230
|
+
type: testcasesketch
|
|
231
|
+
properties:
|
|
232
|
+
status: draft
|
|
233
|
+
description: "Successful login with valid email and password returns 200 with JWT"
|
|
234
|
+
implementationFormat: automated
|
|
235
|
+
```
|
|
236
|
+
|
|
237
|
+
---
|
|
238
|
+
|
|
239
|
+
## Coverage Completeness Checklist
|
|
240
|
+
|
|
241
|
+
Before declaring testing layer extraction complete, verify each type was considered:
|
|
242
|
+
|
|
243
|
+
- [ ] **testcoveragemodel** — Root coverage model exists for each major system or component under test
|
|
244
|
+
- [ ] **testcoveragetarget** — All APIs, features, workflows, and data paths being tested are captured
|
|
245
|
+
- [ ] **inputspacepartition** — Input fields on each target have their value space partitioned
|
|
246
|
+
- [ ] **partitionvalue** — Each partition has concrete representative values and boundary cases
|
|
247
|
+
- [ ] **partitiondependency** — Cross-field constraints between partitions are documented
|
|
248
|
+
- [ ] **inputpartitionselection** — Coverage selections specify which partition values are exercised
|
|
249
|
+
- [ ] **inputselection** — Concrete resolved inputs are selected for each test case sketch
|
|
250
|
+
- [ ] **coveragerequirement** — Coverage criteria (each-choice, pairwise, etc.) are specified
|
|
251
|
+
- [ ] **testcasesketch** — High-level test case sketches cover the required combinations
|
|
252
|
+
- [ ] **outcomecategory** — Expected outcome categories (success, error, edge) are defined per target
|
|
253
|
+
- [ ] **contextvariation** — Test strategy variation types (functional, load, security, regression, smoke, exploratory) are captured
|
|
254
|
+
- [ ] **environmentfactor** — Specific factor values for each context variation are recorded
|
|
255
|
+
- [ ] **targetinputfield** — Input fields on coverage targets are explicitly mapped to partitions
|
|
256
|
+
- [ ] **coveragegap** — Known gaps in coverage are documented with severity and affected requirements
|
|
257
|
+
- [ ] **coverageexclusion** — Deliberate out-of-scope decisions are recorded with rationale and approver
|
|
258
|
+
- [ ] **coveragesummary** — An overall coverage summary exists if aggregated metrics are needed
|
|
259
|
+
- [ ] **targetcoveragesummary** — Per-target coverage rollups exist for targets with tracked implementation
|
|
260
|
+
|
|
261
|
+
If any type has ZERO elements, explicitly decide:
|
|
262
|
+
"This type doesn't apply to this codebase" with reasoning.
|
|
263
|
+
|
|
264
|
+
---
|
|
265
|
+
|
|
266
|
+
## Pitfalls to Avoid
|
|
267
|
+
|
|
268
|
+
- ❌ Ad-hoc testing without systematic partitioning
|
|
269
|
+
- ❌ Missing context variations (only testing happy path)
|
|
270
|
+
- ❌ Not documenting coverage gaps
|
|
271
|
+
- ❌ No traceability to requirements
|
|
272
|
+
- ❌ Missing cross-layer links to tested elements
|
|
273
|
+
- ❌ Incomplete outcome categories
|