@harmonyos-arkts/d2h 0.1.11 → 0.1.13

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (126) hide show
  1. package/.claude-plugin/marketplace.json +15 -13
  2. package/.claude-plugin/plugin.json +13 -7
  3. package/AGENTS.md +5 -5
  4. package/README.md +212 -212
  5. package/agents/android-to-hmos-00-orchestrator.md +318 -318
  6. package/agents/d2h.md +157 -157
  7. package/dist/bin/install-opencode.js +30 -30
  8. package/docs/environment-check.md +86 -86
  9. package/install-opencode.sh +160 -160
  10. package/opencode/agents.json +16 -16
  11. package/opencode/vscode-d2h-package.json +7 -7
  12. package/opencode/vscode-d2h-plugin.mjs +29 -29
  13. package/package.json +54 -54
  14. package/schemas/android-source-manifest.schema.json +25 -25
  15. package/schemas/checkpoint-provenance.schema.json +67 -67
  16. package/schemas/final-acceptance.schema.json +29 -29
  17. package/schemas/managed-evidence-index.schema.json +15 -15
  18. package/schemas/managed-evidence.schema.json +114 -114
  19. package/schemas/migration-config.schema.json +51 -51
  20. package/schemas/migration-report-index.schema.json +39 -39
  21. package/schemas/migration-report-item.schema.json +51 -51
  22. package/schemas/migration-report-summary.schema.json +25 -25
  23. package/schemas/migration-status.schema.json +202 -202
  24. package/schemas/preflight.schema.json +60 -60
  25. package/schemas/source-order-audit.schema.json +16 -16
  26. package/schemas/source-provenance-event.schema.json +19 -19
  27. package/schemas/spec-app-shard.schema.json +45 -45
  28. package/schemas/spec-fact-corrections-shard.schema.json +13 -13
  29. package/schemas/spec-features-shard.schema.json +43 -43
  30. package/schemas/spec-index.schema.json +26 -26
  31. package/schemas/spec-interactions-shard.schema.json +40 -40
  32. package/schemas/spec-page.schema.json +98 -98
  33. package/schemas/spec-pages-index.schema.json +1 -1
  34. package/schemas/spec-unresolved-shard.schema.json +1 -1
  35. package/schemas/task-envelope.schema.json +109 -109
  36. package/schemas/task-plan.schema.json +341 -341
  37. package/scripts/check-environment.mjs +320 -320
  38. package/skills/android2hmos_resources_convert/SKILL.md +180 -180
  39. package/skills/android2hmos_resources_convert/references/image-conversion-rules.md +230 -230
  40. package/skills/android2hmos_resources_convert/references/svg-fix-patterns.md +175 -175
  41. package/skills/android2hmos_resources_convert/references/xml-drawable-to-svg-rules.md +513 -513
  42. package/skills/arkts-app-identity/SKILL.md +238 -238
  43. package/skills/arkts-i18n/SKILL.md +496 -496
  44. package/skills/arkts-i18n/evals/evals.json +84 -84
  45. package/skills/arkts-i18n/references/code-examples.md +302 -302
  46. package/skills/arkts-i18n/references/common-pitfalls.md +391 -391
  47. package/skills/arkts-i18n/references/dynamic-language-switch.md +604 -604
  48. package/skills/arkts-i18n/references/hardcoded-string-scanner.md +348 -348
  49. package/skills/arkts-i18n/references/language-codes.md +104 -104
  50. package/skills/arkts-i18n/references/resource-file-structure.md +775 -775
  51. package/skills/arkts-i18n/references/static-vs-dynamic.md +242 -242
  52. package/skills/arkts-i18n/references/v1-compat.md +244 -244
  53. package/skills/arkts-i18n/scripts/audit_i18n_completeness.sh +174 -174
  54. package/skills/arkts-icon-sizing/SKILL.md +211 -211
  55. package/skills/arkts-icon-sizing/scripts/icon_audit.py +131 -131
  56. package/skills/arkts-icon-sizing/scripts/icon_autofix.py +88 -88
  57. package/skills/arkts-icon-sizing/scripts/icon_dims.py +179 -179
  58. package/skills/arkts-icon-sizing/scripts/icon_fix.py +119 -119
  59. package/skills/arkts-mvvm-architecture/SKILL.md +613 -613
  60. package/skills/d2h-hypium-forge/SKILL.md +309 -309
  61. package/skills/d2h-hypium-forge/references/functional-spec-template.md +140 -140
  62. package/skills/d2h-hypium-forge/references/official-api.md +135 -135
  63. package/skills/d2h-hypium-forge/references/pitfalls.md +98 -98
  64. package/skills/d2h-hypium-forge/references/testability-template.md +71 -71
  65. package/skills/d2h-hypium-forge/scripts/_common_template.py +659 -659
  66. package/skills/d2h-hypium-forge/scripts/analyze_results.py +165 -165
  67. package/skills/d2h-hypium-forge/scripts/assert_audit.py +107 -107
  68. package/skills/d2h-hypium-forge/scripts/collect_runtime_pages.py +169 -169
  69. package/skills/d2h-hypium-forge/scripts/forge_report.py +325 -325
  70. package/skills/d2h-hypium-forge/scripts/inject_resource_ids.py +114 -114
  71. package/skills/d2h-hypium-forge/scripts/lint_asserts.py +80 -80
  72. package/skills/d2h-hypium-forge/scripts/lint_locate.py +60 -60
  73. package/skills/d2h-hypium-forge/scripts/merge_appgraph.py +249 -249
  74. package/skills/d2h-hypium-forge/scripts/precondition.py +140 -140
  75. package/skills/d2h-hypium-forge/scripts/preinject_ids.py +232 -232
  76. package/skills/d2h-hypium-forge/scripts/probe.py +197 -197
  77. package/skills/d2h-hypium-forge/scripts/run_direct.py +823 -823
  78. package/skills/d2h-hypium-forge/scripts/run_parallel.py +121 -121
  79. package/skills/d2h-hypium-forge/scripts/scan_features.py +255 -255
  80. package/skills/d2h-hypium-forge/scripts/upgrade_asserts.py +66 -66
  81. package/skills/d2h-hypium-forge/scripts/validate_scenarios.py +84 -84
  82. package/skills/d2h-page-develop/SKILL.md +112 -112
  83. package/skills/d2h-page-develop/agents/openai.yaml +7 -7
  84. package/skills/d2h-page-spec-generate/SKILL.md +206 -206
  85. package/skills/d2h-page-spec-generate/scripts/build_batch_report.py +227 -227
  86. package/skills/d2h-utg-ai-generate/SKILL.md +128 -128
  87. package/skills/d2h-utg-ai-generate/references/click-paths-schema.json +76 -76
  88. package/skills/d2h-utg-ai-generate/references/extraction-guide.md +34 -34
  89. package/skills/d2h-utg-ai-generate/references/facts-contract.md +96 -96
  90. package/skills/d2h-utg-ai-generate/references/page-schema.json +61 -61
  91. package/skills/d2h-utg-ai-generate/references/utg-schema.json +89 -89
  92. package/skills/d2h-utg-ai-generate/scripts/build_page_json.py +314 -314
  93. package/skills/d2h-utg-ai-generate/scripts/build_utg.py +123 -123
  94. package/skills/d2h-utg-ai-generate/scripts/capture_from_page_json.ts +280 -280
  95. package/skills/d2h-utg-ai-generate/scripts/utg_common.py +524 -524
  96. package/skills/d2h-utg-ai-generate/scripts/utg_html.py +489 -489
  97. package/skills/d2h-utg-ai-generate/scripts/validate_utg.py +69 -69
  98. package/skills/d2h-utg-ai-generate/scripts/vendor/D3-LICENSE +13 -13
  99. package/skills/d2h-utg-ai-generate/scripts/vendor/d3-7.9.0.min.js +2 -2
  100. package/skills/d2h-utg-ai-generate/tests/test_pipeline.py +369 -369
  101. package/skills/d2h-utg-static-generate/SKILL.md +73 -73
  102. package/skills/d2h-utg-static-generate/references/discoveries.md +38 -38
  103. package/skills/d2h-utg-static-generate/scripts/generate.py +499 -499
  104. package/skills/d2h-utg-static-generate/tests/test_static.py +335 -335
  105. package/skills/d2h-utg-static-generate/tests/verify-offline-html.py +60 -60
  106. package/skills/d2h-utg-static-generate/tests/verify-produced-fixture.py +131 -131
  107. package/skills/harmonyos-migration-playbook/SKILL.md +83 -83
  108. package/skills/harmonyos-migration-playbook/agents/openai.yaml +7 -7
  109. package/skills/harmonyos-migration-playbook/references/arkts-compile.md +24 -24
  110. package/skills/harmonyos-migration-playbook/references/harmony-runtime.md +53 -53
  111. package/skills/harmonyos-migration-playbook/references/lesson-lifecycle.md +45 -45
  112. package/skills/harmonyos-migration-playbook/references/protocol-e2e.md +23 -23
  113. package/skills/harmonyos-migration-playbook/references/ui-automation.md +53 -53
  114. package/skills/harmonyos-migration-playbook/references/windows-environment.md +38 -38
  115. package/skills/maintaining-migration-report/SKILL.md +144 -144
  116. package/skills/maintaining-migration-report/references/final-acceptance.md +48 -48
  117. package/skills/maintaining-migration-report/references/source-provenance.md +66 -66
  118. package/skills/managing-d2h-toolchain/SKILL.md +24 -24
  119. package/skills/managing-d2h-toolchain/environment-requirements.json +16 -16
  120. package/skills/managing-d2h-toolchain/scripts/manage-toolchain.mjs +98 -98
  121. package/skills/managing-d2h-toolchain/toolchain.json +16 -16
  122. package/skills/native-library-substitution/SKILL.md +384 -384
  123. package/skills/native-library-substitution/references/native-library-substitution.json +56905 -56905
  124. package/skills/native-library-substitution/references/native-library-substitution.md +163 -163
  125. package/skills/preparing-migration-workspace/SKILL.md +131 -131
  126. package/skills/reviewing-migration-process/SKILL.md +62 -62
@@ -1,96 +1,96 @@
1
- # `utg-facts.json` contract
2
-
3
- The facts file is the only AI-authored data input. It describes source evidence; it is not the final UTG format.
4
-
5
- ```json
6
- {
7
- "schema_version": "d2h-utg-facts/v1",
8
- "graph": {
9
- "app": "Example",
10
- "package": "com.example.app",
11
- "architecture": "jetpack-compose/navigation-compose",
12
- "root": "MainActivity",
13
- "start_destination": "home",
14
- "version_name": "1.4.2",
15
- "build_variant": "debug"
16
- },
17
- "nodes": [
18
- {
19
- "id": "MainActivity",
20
- "kind": "activity",
21
- "label": "MainActivity (launcher)",
22
- "declared_at": "app/src/main/java/com/example/MainActivity.kt:20",
23
- "widgets": [],
24
- "expected": {"activity_any": ["com.example.app/.MainActivity"]},
25
- "required_state": [],
26
- "extra": {"launcher": true},
27
- "confidence": 1.0
28
- }
29
- ],
30
- "edges": [
31
- {
32
- "source": "MainActivity",
33
- "target": "home",
34
- "mechanism": "navhost-start",
35
- "trigger": "app/src/main/java/com/example/MainActivity.kt:45",
36
- "guard": null,
37
- "args": {
38
- "action": "default",
39
- "label": "Example",
40
- "label_source": "string"
41
- },
42
- "confidence": 0.98
43
- }
44
- ],
45
- "unresolved": [
46
- {
47
- "subject": "dynamic route from server config",
48
- "reason": "target value is not present in source",
49
- "evidence": "app/src/main/java/com/example/Router.kt:81"
50
- }
51
- ]
52
- }
53
- ```
54
-
55
- ## Graph
56
-
57
- Required fields are `app`, `architecture`, and `root`. `package` and `start_destination` may be empty only when the source ecosystem genuinely has no equivalent. Record `version_name` and `build_variant` when they are determinable from the analyzed source/build configuration; runtime replay refuses a non-empty version that differs from the installed package. Additional graph metadata is preserved.
58
-
59
- ## Nodes
60
-
61
- Required:
62
-
63
- - `id`: stable, unique code identity. Do not use display text as identity.
64
- - `kind`: framework-independent semantic kind such as `activity`, `fragment`, `compose-route`, `voyager-screen`, `dialog`, `sheet`, `menu`, `mode`, `nav-graph`, `hybrid`, or `hybrid-page`.
65
- - `label`: human-readable description.
66
- - `declared_at`: project-relative `file:line` that declares or hosts the UI.
67
-
68
- Optional fields default to `status="static-only"`, `provenance="ai-source-analysis"`, empty `widgets`, empty `expected`, empty `required_state`, and `extra=null`. Use an object for `extra` only when the node has extension metadata. A node intended for runtime capture must not leave `expected` empty. Supported arrival rules are string arrays: `text_any`, `text_all`, `content_desc_any`, `resource_id_any`, and `activity_any`. Derive them from source literals/resources or stable component identities, not guesses.
69
-
70
- Use `required_state` only for a node-level state axis, such as `content`, `login`, `permission`, or `network`. Put edge-specific conditions on the edge guard.
71
-
72
- ## Edges
73
-
74
- Required:
75
-
76
- - `source`, `target`: existing node IDs.
77
- - `mechanism`: navigation mechanism, not a prose summary.
78
- - `trigger`: project-relative navigation call-site `file:line`.
79
- - `confidence`: numeric `[0, 1]`.
80
-
81
- `guard` is either `null` or an object containing non-empty `kind` and `text`. `args` may contain:
82
-
83
- - `action`: `tap`, `back`, `default`, `launch`, `home`, `swipe`, or another concrete driver action.
84
- - `label`: visible text or URI. It is a compatibility selector only when `selector` is absent.
85
- - `label_source`: normally `string`, `content-description`, `system`, `code-name`, or `nl_hint`.
86
- - `label_ambiguous`: boolean.
87
- - `nl_hint`: source-grounded instruction for human interpretation. It is not executable.
88
- - `selector`: deterministic ADB selector. It may contain `text`, `text_any`, `content_desc`, `content_desc_any`, `resource_id`, or `resource_id_any`. `normalized_point: [x, y]` uses 0–1 screen fractions and is an explicitly enabled last resort, never an inferred default.
89
- - `direction`, `distance`, `duration_ms`, and `max_scrolls`: optional deterministic parameters for swipe/search behavior.
90
- - route arguments or other mechanism-specific metadata.
91
-
92
- The generator assigns parallel-edge `key` values. Do not supply them.
93
-
94
- ## Unresolved findings
95
-
96
- Use `unresolved` when the source proves a boundary but not a safe graph fact: runtime/server routes, reflection, computed destinations, missing bundles, build-flavor-only pages, or ambiguous callback ownership. These entries remain in `generation-report.json` and never enter the graph silently.
1
+ # `utg-facts.json` contract
2
+
3
+ The facts file is the only AI-authored data input. It describes source evidence; it is not the final UTG format.
4
+
5
+ ```json
6
+ {
7
+ "schema_version": "d2h-utg-facts/v1",
8
+ "graph": {
9
+ "app": "Example",
10
+ "package": "com.example.app",
11
+ "architecture": "jetpack-compose/navigation-compose",
12
+ "root": "MainActivity",
13
+ "start_destination": "home",
14
+ "version_name": "1.4.2",
15
+ "build_variant": "debug"
16
+ },
17
+ "nodes": [
18
+ {
19
+ "id": "MainActivity",
20
+ "kind": "activity",
21
+ "label": "MainActivity (launcher)",
22
+ "declared_at": "app/src/main/java/com/example/MainActivity.kt:20",
23
+ "widgets": [],
24
+ "expected": {"activity_any": ["com.example.app/.MainActivity"]},
25
+ "required_state": [],
26
+ "extra": {"launcher": true},
27
+ "confidence": 1.0
28
+ }
29
+ ],
30
+ "edges": [
31
+ {
32
+ "source": "MainActivity",
33
+ "target": "home",
34
+ "mechanism": "navhost-start",
35
+ "trigger": "app/src/main/java/com/example/MainActivity.kt:45",
36
+ "guard": null,
37
+ "args": {
38
+ "action": "default",
39
+ "label": "Example",
40
+ "label_source": "string"
41
+ },
42
+ "confidence": 0.98
43
+ }
44
+ ],
45
+ "unresolved": [
46
+ {
47
+ "subject": "dynamic route from server config",
48
+ "reason": "target value is not present in source",
49
+ "evidence": "app/src/main/java/com/example/Router.kt:81"
50
+ }
51
+ ]
52
+ }
53
+ ```
54
+
55
+ ## Graph
56
+
57
+ Required fields are `app`, `architecture`, and `root`. `package` and `start_destination` may be empty only when the source ecosystem genuinely has no equivalent. Record `version_name` and `build_variant` when they are determinable from the analyzed source/build configuration; runtime replay refuses a non-empty version that differs from the installed package. Additional graph metadata is preserved.
58
+
59
+ ## Nodes
60
+
61
+ Required:
62
+
63
+ - `id`: stable, unique code identity. Do not use display text as identity.
64
+ - `kind`: framework-independent semantic kind such as `activity`, `fragment`, `compose-route`, `voyager-screen`, `dialog`, `sheet`, `menu`, `mode`, `nav-graph`, `hybrid`, or `hybrid-page`.
65
+ - `label`: human-readable description.
66
+ - `declared_at`: project-relative `file:line` that declares or hosts the UI.
67
+
68
+ Optional fields default to `status="static-only"`, `provenance="ai-source-analysis"`, empty `widgets`, empty `expected`, empty `required_state`, and `extra=null`. Use an object for `extra` only when the node has extension metadata. A node intended for runtime capture must not leave `expected` empty. Supported arrival rules are string arrays: `text_any`, `text_all`, `content_desc_any`, `resource_id_any`, and `activity_any`. Derive them from source literals/resources or stable component identities, not guesses.
69
+
70
+ Use `required_state` only for a node-level state axis, such as `content`, `login`, `permission`, or `network`. Put edge-specific conditions on the edge guard.
71
+
72
+ ## Edges
73
+
74
+ Required:
75
+
76
+ - `source`, `target`: existing node IDs.
77
+ - `mechanism`: navigation mechanism, not a prose summary.
78
+ - `trigger`: project-relative navigation call-site `file:line`.
79
+ - `confidence`: numeric `[0, 1]`.
80
+
81
+ `guard` is either `null` or an object containing non-empty `kind` and `text`. `args` may contain:
82
+
83
+ - `action`: `tap`, `back`, `default`, `launch`, `home`, `swipe`, or another concrete driver action.
84
+ - `label`: visible text or URI. It is a compatibility selector only when `selector` is absent.
85
+ - `label_source`: normally `string`, `content-description`, `system`, `code-name`, or `nl_hint`.
86
+ - `label_ambiguous`: boolean.
87
+ - `nl_hint`: source-grounded instruction for human interpretation. It is not executable.
88
+ - `selector`: deterministic ADB selector. It may contain `text`, `text_any`, `content_desc`, `content_desc_any`, `resource_id`, or `resource_id_any`. `normalized_point: [x, y]` uses 0–1 screen fractions and is an explicitly enabled last resort, never an inferred default.
89
+ - `direction`, `distance`, `duration_ms`, and `max_scrolls`: optional deterministic parameters for swipe/search behavior.
90
+ - route arguments or other mechanism-specific metadata.
91
+
92
+ The generator assigns parallel-edge `key` values. Do not supply them.
93
+
94
+ ## Unresolved findings
95
+
96
+ Use `unresolved` when the source proves a boundary but not a safe graph fact: runtime/server routes, reflection, computed destinations, missing bundles, build-flavor-only pages, or ambiguous callback ownership. These entries remain in `generation-report.json` and never enter the graph silently.
@@ -1,61 +1,61 @@
1
- {
2
- "$schema": "https://json-schema.org/draft/2020-12/schema",
3
- "$id": "https://hometrans.local/schemas/page-plan-v1.json",
4
- "title": "HomeTrans UTG-directed runtime capture plan",
5
- "type": "object",
6
- "required": ["schema_version", "source", "summary", "pages"],
7
- "properties": {
8
- "schema_version": {"const": "d2h-page-plan/v1"},
9
- "source": {
10
- "type": "object",
11
- "required": ["utg", "click_paths", "root", "app", "package", "architecture", "version_name", "build_variant"],
12
- "properties": {
13
- "utg": {"type": "string", "minLength": 1},
14
- "click_paths": {"type": "string", "minLength": 1},
15
- "root": {"type": "string", "minLength": 1},
16
- "app": {"type": "string", "minLength": 1},
17
- "package": {"type": "string"},
18
- "architecture": {"type": "string", "minLength": 1},
19
- "version_name": {"type": "string"},
20
- "build_variant": {"type": "string"}
21
- },
22
- "additionalProperties": false
23
- },
24
- "summary": {
25
- "type": "object",
26
- "required": ["nodes", "capture_planned", "unreachable", "excluded_by_kind"],
27
- "properties": {
28
- "nodes": {"type": "integer", "minimum": 1},
29
- "capture_planned": {"type": "integer", "minimum": 0},
30
- "unreachable": {"type": "integer", "minimum": 0},
31
- "excluded_by_kind": {"type": "object", "additionalProperties": {"type": "integer", "minimum": 0}}
32
- },
33
- "additionalProperties": false
34
- },
35
- "pages": {
36
- "type": "array",
37
- "items": {
38
- "type": "object",
39
- "required": ["node_id", "kind", "label", "declared_at", "required_state", "expected", "reachable", "capture", "capture_key", "depth", "ui_sequence", "path_text", "steps", "skip_reason"],
40
- "properties": {
41
- "node_id": {"type": "string", "minLength": 1},
42
- "kind": {"type": "string", "minLength": 1},
43
- "label": {"type": "string", "minLength": 1},
44
- "declared_at": {"type": "string", "pattern": ":[1-9][0-9]*$"},
45
- "required_state": {"type": "array", "items": {"type": "string"}, "uniqueItems": true},
46
- "expected": {"type": "object"},
47
- "reachable": {"type": "boolean"},
48
- "capture": {"type": "boolean"},
49
- "capture_key": {"type": ["string", "null"]},
50
- "depth": {"type": ["integer", "null"], "minimum": 0},
51
- "ui_sequence": {"type": "string", "minLength": 1},
52
- "path_text": {"type": ["string", "null"]},
53
- "steps": {"type": "array"},
54
- "skip_reason": {"type": ["string", "null"]}
55
- },
56
- "additionalProperties": false
57
- }
58
- }
59
- },
60
- "additionalProperties": false
61
- }
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://hometrans.local/schemas/page-plan-v1.json",
4
+ "title": "HomeTrans UTG-directed runtime capture plan",
5
+ "type": "object",
6
+ "required": ["schema_version", "source", "summary", "pages"],
7
+ "properties": {
8
+ "schema_version": {"const": "d2h-page-plan/v1"},
9
+ "source": {
10
+ "type": "object",
11
+ "required": ["utg", "click_paths", "root", "app", "package", "architecture", "version_name", "build_variant"],
12
+ "properties": {
13
+ "utg": {"type": "string", "minLength": 1},
14
+ "click_paths": {"type": "string", "minLength": 1},
15
+ "root": {"type": "string", "minLength": 1},
16
+ "app": {"type": "string", "minLength": 1},
17
+ "package": {"type": "string"},
18
+ "architecture": {"type": "string", "minLength": 1},
19
+ "version_name": {"type": "string"},
20
+ "build_variant": {"type": "string"}
21
+ },
22
+ "additionalProperties": false
23
+ },
24
+ "summary": {
25
+ "type": "object",
26
+ "required": ["nodes", "capture_planned", "unreachable", "excluded_by_kind"],
27
+ "properties": {
28
+ "nodes": {"type": "integer", "minimum": 1},
29
+ "capture_planned": {"type": "integer", "minimum": 0},
30
+ "unreachable": {"type": "integer", "minimum": 0},
31
+ "excluded_by_kind": {"type": "object", "additionalProperties": {"type": "integer", "minimum": 0}}
32
+ },
33
+ "additionalProperties": false
34
+ },
35
+ "pages": {
36
+ "type": "array",
37
+ "items": {
38
+ "type": "object",
39
+ "required": ["node_id", "kind", "label", "declared_at", "required_state", "expected", "reachable", "capture", "capture_key", "depth", "ui_sequence", "path_text", "steps", "skip_reason"],
40
+ "properties": {
41
+ "node_id": {"type": "string", "minLength": 1},
42
+ "kind": {"type": "string", "minLength": 1},
43
+ "label": {"type": "string", "minLength": 1},
44
+ "declared_at": {"type": "string", "pattern": ":[1-9][0-9]*$"},
45
+ "required_state": {"type": "array", "items": {"type": "string"}, "uniqueItems": true},
46
+ "expected": {"type": "object"},
47
+ "reachable": {"type": "boolean"},
48
+ "capture": {"type": "boolean"},
49
+ "capture_key": {"type": ["string", "null"]},
50
+ "depth": {"type": ["integer", "null"], "minimum": 0},
51
+ "ui_sequence": {"type": "string", "minLength": 1},
52
+ "path_text": {"type": ["string", "null"]},
53
+ "steps": {"type": "array"},
54
+ "skip_reason": {"type": ["string", "null"]}
55
+ },
56
+ "additionalProperties": false
57
+ }
58
+ }
59
+ },
60
+ "additionalProperties": false
61
+ }
@@ -1,89 +1,89 @@
1
- {
2
- "$schema": "https://json-schema.org/draft/2020-12/schema",
3
- "$id": "https://hometrans.local/schemas/utg-v2.json",
4
- "title": "HomeTrans source-derived UTG",
5
- "type": "object",
6
- "required": ["directed", "multigraph", "graph", "nodes", "links"],
7
- "properties": {
8
- "directed": {"const": true},
9
- "multigraph": {"const": true},
10
- "graph": {
11
- "type": "object",
12
- "required": ["app", "architecture", "root"],
13
- "properties": {
14
- "app": {"type": "string", "minLength": 1},
15
- "package": {"type": "string"},
16
- "architecture": {"type": "string", "minLength": 1},
17
- "root": {"type": "string", "minLength": 1},
18
- "start_destination": {"type": "string"},
19
- "version_name": {"type": "string"},
20
- "build_variant": {"type": "string"}
21
- },
22
- "additionalProperties": true
23
- },
24
- "nodes": {
25
- "type": "array",
26
- "items": {
27
- "type": "object",
28
- "required": ["id", "kind", "label", "declared_at", "status", "provenance", "widgets", "expected", "required_state", "extra"],
29
- "properties": {
30
- "id": {"type": "string", "minLength": 1},
31
- "kind": {"type": "string", "minLength": 1},
32
- "label": {"type": "string", "minLength": 1},
33
- "declared_at": {"type": "string", "pattern": ":[1-9][0-9]*$"},
34
- "status": {"type": "string", "minLength": 1},
35
- "provenance": {"type": "string", "minLength": 1},
36
- "widgets": {"type": "array"},
37
- "expected": {
38
- "type": "object",
39
- "properties": {
40
- "text_any": {"type": "array", "minItems": 1, "items": {"type": "string", "minLength": 1}},
41
- "text_all": {"type": "array", "minItems": 1, "items": {"type": "string", "minLength": 1}},
42
- "content_desc_any": {"type": "array", "minItems": 1, "items": {"type": "string", "minLength": 1}},
43
- "resource_id_any": {"type": "array", "minItems": 1, "items": {"type": "string", "minLength": 1}},
44
- "activity_any": {"type": "array", "minItems": 1, "items": {"type": "string", "minLength": 1}}
45
- },
46
- "additionalProperties": false
47
- },
48
- "required_state": {"type": "array", "items": {"type": "string"}, "uniqueItems": true},
49
- "extra": {"type": ["object", "null"]}
50
- },
51
- "additionalProperties": true
52
- }
53
- },
54
- "links": {
55
- "type": "array",
56
- "items": {
57
- "type": "object",
58
- "required": ["source", "target", "mechanism", "trigger", "guard", "args", "confidence", "provenance", "key", "status"],
59
- "properties": {
60
- "source": {"type": "string", "minLength": 1},
61
- "target": {"type": "string", "minLength": 1},
62
- "mechanism": {"type": "string", "minLength": 1},
63
- "trigger": {"type": "string", "pattern": ":[1-9][0-9]*$"},
64
- "guard": {
65
- "oneOf": [
66
- {"type": "null"},
67
- {
68
- "type": "object",
69
- "required": ["kind", "text"],
70
- "properties": {
71
- "kind": {"type": "string", "minLength": 1},
72
- "text": {"type": "string", "minLength": 1}
73
- },
74
- "additionalProperties": true
75
- }
76
- ]
77
- },
78
- "args": {"type": "object"},
79
- "confidence": {"type": "number", "minimum": 0, "maximum": 1},
80
- "provenance": {"type": "string", "minLength": 1},
81
- "key": {"type": "integer", "minimum": 0},
82
- "status": {"type": "string", "minLength": 1}
83
- },
84
- "additionalProperties": true
85
- }
86
- }
87
- },
88
- "additionalProperties": false
89
- }
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://hometrans.local/schemas/utg-v2.json",
4
+ "title": "HomeTrans source-derived UTG",
5
+ "type": "object",
6
+ "required": ["directed", "multigraph", "graph", "nodes", "links"],
7
+ "properties": {
8
+ "directed": {"const": true},
9
+ "multigraph": {"const": true},
10
+ "graph": {
11
+ "type": "object",
12
+ "required": ["app", "architecture", "root"],
13
+ "properties": {
14
+ "app": {"type": "string", "minLength": 1},
15
+ "package": {"type": "string"},
16
+ "architecture": {"type": "string", "minLength": 1},
17
+ "root": {"type": "string", "minLength": 1},
18
+ "start_destination": {"type": "string"},
19
+ "version_name": {"type": "string"},
20
+ "build_variant": {"type": "string"}
21
+ },
22
+ "additionalProperties": true
23
+ },
24
+ "nodes": {
25
+ "type": "array",
26
+ "items": {
27
+ "type": "object",
28
+ "required": ["id", "kind", "label", "declared_at", "status", "provenance", "widgets", "expected", "required_state", "extra"],
29
+ "properties": {
30
+ "id": {"type": "string", "minLength": 1},
31
+ "kind": {"type": "string", "minLength": 1},
32
+ "label": {"type": "string", "minLength": 1},
33
+ "declared_at": {"type": "string", "pattern": ":[1-9][0-9]*$"},
34
+ "status": {"type": "string", "minLength": 1},
35
+ "provenance": {"type": "string", "minLength": 1},
36
+ "widgets": {"type": "array"},
37
+ "expected": {
38
+ "type": "object",
39
+ "properties": {
40
+ "text_any": {"type": "array", "minItems": 1, "items": {"type": "string", "minLength": 1}},
41
+ "text_all": {"type": "array", "minItems": 1, "items": {"type": "string", "minLength": 1}},
42
+ "content_desc_any": {"type": "array", "minItems": 1, "items": {"type": "string", "minLength": 1}},
43
+ "resource_id_any": {"type": "array", "minItems": 1, "items": {"type": "string", "minLength": 1}},
44
+ "activity_any": {"type": "array", "minItems": 1, "items": {"type": "string", "minLength": 1}}
45
+ },
46
+ "additionalProperties": false
47
+ },
48
+ "required_state": {"type": "array", "items": {"type": "string"}, "uniqueItems": true},
49
+ "extra": {"type": ["object", "null"]}
50
+ },
51
+ "additionalProperties": true
52
+ }
53
+ },
54
+ "links": {
55
+ "type": "array",
56
+ "items": {
57
+ "type": "object",
58
+ "required": ["source", "target", "mechanism", "trigger", "guard", "args", "confidence", "provenance", "key", "status"],
59
+ "properties": {
60
+ "source": {"type": "string", "minLength": 1},
61
+ "target": {"type": "string", "minLength": 1},
62
+ "mechanism": {"type": "string", "minLength": 1},
63
+ "trigger": {"type": "string", "pattern": ":[1-9][0-9]*$"},
64
+ "guard": {
65
+ "oneOf": [
66
+ {"type": "null"},
67
+ {
68
+ "type": "object",
69
+ "required": ["kind", "text"],
70
+ "properties": {
71
+ "kind": {"type": "string", "minLength": 1},
72
+ "text": {"type": "string", "minLength": 1}
73
+ },
74
+ "additionalProperties": true
75
+ }
76
+ ]
77
+ },
78
+ "args": {"type": "object"},
79
+ "confidence": {"type": "number", "minimum": 0, "maximum": 1},
80
+ "provenance": {"type": "string", "minLength": 1},
81
+ "key": {"type": "integer", "minimum": 0},
82
+ "status": {"type": "string", "minLength": 1}
83
+ },
84
+ "additionalProperties": true
85
+ }
86
+ }
87
+ },
88
+ "additionalProperties": false
89
+ }