@code-migration/wow-migrator 0.1.0 → 0.1.2
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/README.md +59 -58
- package/bin/{kmp-skills.js → wow-migrator.js} +65 -17
- package/package.json +16 -8
- package/skills/android-project-analyst/MIGRATION.md +39 -23
- package/skills/android-project-analyst/SKILL.md +54 -44
- package/skills/android-project-analyst/bind.md +22 -14
- package/skills/android-project-analyst/dependencies.yaml +8 -4
- package/skills/android-project-analyst/roles/analysis-workspace-state.md +118 -0
- package/skills/android-project-analyst/roles/behavior-logic.md +163 -0
- package/skills/android-project-analyst/roles/data-contract-flow.md +167 -0
- package/skills/android-project-analyst/roles/presentation-resource.md +296 -0
- package/skills/android-project-analyst/roles/project-architecture.md +171 -0
- package/skills/android-project-analyst/workflow.md +118 -70
- package/skills/android-to-kmp-migrator/MIGRATION.md +61 -1
- package/skills/android-to-kmp-migrator/SKILL.md +96 -134
- package/skills/android-to-kmp-migrator/bind.md +33 -11
- package/skills/android-to-kmp-migrator/roles/completion-report.md +72 -0
- package/skills/android-to-kmp-migrator/roles/dependency-platform-gate.md +63 -0
- package/skills/android-to-kmp-migrator/roles/logic-implementation.md +66 -0
- package/skills/android-to-kmp-migrator/roles/migration-analysis-planning.md +65 -0
- package/skills/android-to-kmp-migrator/roles/migration-verification.md +77 -0
- package/skills/android-to-kmp-migrator/roles/migration-workspace-state.md +13 -1
- package/skills/android-to-kmp-migrator/roles/module-node-review-fix.md +74 -0
- package/skills/android-to-kmp-migrator/roles/presentation-integration.md +65 -0
- package/skills/android-to-kmp-migrator/roles/state-data-prep.md +63 -0
- package/skills/android-to-kmp-migrator/roles/ui-implementation.md +64 -0
- package/skills/android-to-kmp-migrator/workflow.md +175 -149
- package/skills/kmp-test-validator/MIGRATION.md +18 -3
- package/skills/kmp-test-validator/SKILL.md +44 -79
- package/skills/kmp-test-validator/bind.md +8 -8
- package/skills/kmp-test-validator/dependencies.yaml +3 -3
- package/skills/kmp-test-validator/roles/validation-intake-fidelity.md +67 -0
- package/skills/kmp-test-validator/roles/validation-plan-gate.md +66 -0
- package/skills/kmp-test-validator/roles/validation-remediation.md +7 -7
- package/skills/kmp-test-validator/roles/validation-report.md +8 -10
- package/skills/kmp-test-validator/roles/validation-test-runner.md +61 -0
- package/skills/kmp-test-validator/roles/validation-workspace-state.md +2 -2
- package/skills/kmp-test-validator/workflow.md +87 -119
- package/skills/migration-task-adapter/MIGRATION.md +34 -0
- package/skills/migration-task-adapter/SKILL.md +134 -0
- package/skills/migration-task-adapter/bind.md +113 -0
- package/skills/migration-task-adapter/dependencies.yaml +26 -0
- package/skills/migration-task-adapter/roles/task-reporter.md +129 -0
- package/skills/migration-task-adapter/roles/task-understanding-router.md +134 -0
- package/skills/migration-task-adapter/roles/workflow-orchestrator.md +140 -0
- package/skills/migration-task-adapter/roles/workspace-state-discipline-inspector.md +189 -0
- package/skills/migration-task-adapter/workflow.md +183 -0
- package/skills/android-project-analyst/roles/android-ecosystem.md +0 -141
- package/skills/android-project-analyst/roles/api-list.md +0 -136
- package/skills/android-project-analyst/roles/architecture-pattern.md +0 -131
- package/skills/android-project-analyst/roles/data-flow.md +0 -143
- package/skills/android-project-analyst/roles/logic-understand.md +0 -154
- package/skills/android-project-analyst/roles/resource-understand.md +0 -151
- package/skills/android-project-analyst/roles/ui-understand.md +0 -136
- package/skills/android-to-kmp-migrator/roles/api-contract-parity.md +0 -95
- package/skills/android-to-kmp-migrator/roles/dataflow-logic-implementation.md +0 -130
- package/skills/android-to-kmp-migrator/roles/dependency-resolution.md +0 -106
- package/skills/android-to-kmp-migrator/roles/incremental-build-check.md +0 -105
- package/skills/android-to-kmp-migrator/roles/legacy-spec-delta-review.md +0 -104
- package/skills/android-to-kmp-migrator/roles/migration-alignment.md +0 -119
- package/skills/android-to-kmp-migrator/roles/migration-report.md +0 -108
- package/skills/android-to-kmp-migrator/roles/module-node-migration-fix.md +0 -111
- package/skills/android-to-kmp-migrator/roles/module-node-migration-review.md +0 -108
- package/skills/android-to-kmp-migrator/roles/navigation-migration.md +0 -104
- package/skills/android-to-kmp-migrator/roles/platform-api-replacement.md +0 -104
- package/skills/android-to-kmp-migrator/roles/prd-completion-check.md +0 -124
- package/skills/android-to-kmp-migrator/roles/resource-migration.md +0 -109
- package/skills/android-to-kmp-migrator/roles/source-set-placement-guard.md +0 -95
- package/skills/android-to-kmp-migrator/roles/state-model-mapping.md +0 -109
- package/skills/android-to-kmp-migrator/roles/target-project-understand.md +0 -118
- package/skills/android-to-kmp-migrator/roles/theme-design-system-mapping.md +0 -101
- package/skills/android-to-kmp-migrator/roles/ui-mockup-implementation.md +0 -121
- package/skills/android-to-kmp-migrator/roles/ui-render-fidelity-check.md +0 -100
- package/skills/kmp-test-validator/roles/android-kmp-fidelity-audit.md +0 -102
- package/skills/kmp-test-validator/roles/build-preview-gate.md +0 -109
- package/skills/kmp-test-validator/roles/kmp-validation-plan.md +0 -108
- package/skills/kmp-test-validator/roles/test-case-decomposition.md +0 -103
- package/skills/kmp-test-validator/roles/test-execution.md +0 -104
- package/skills/kmp-test-validator/roles/validation-input-contract.md +0 -111
|
@@ -6,8 +6,8 @@
|
|
|
6
6
|
|---|---|---|
|
|
7
7
|
| `max_parallel_teammates` | 1 | The validator is a strict serial pipeline — each node consumes the prior node's verified artifact; no stage fans out in parallel. |
|
|
8
8
|
| `total_wall_clock_budget` | 45 min | Upper bound for one full validation run including the build/preview gate, test execution, and one remediation loop on a feature-scoped migration. |
|
|
9
|
-
| `total_token_budget` |
|
|
10
|
-
| `per_node_token_budget` |
|
|
9
|
+
| `total_token_budget` | 600k tokens | Budget across 6 reduced roles + Leader integration + remediation iterations. |
|
|
10
|
+
| `per_node_token_budget` | 130k tokens | Consolidated roles carry broader context; `validation-intake-fidelity`, `validation-test-runner`, and `validation-report` may use the upper end. |
|
|
11
11
|
| `max_remediation_cycles` | 3 | Max `remediation → rerun gate/tests` iterations before escalating remaining failures as `blocked` to the controller/user. |
|
|
12
12
|
| `build_test_runs` | bounded per gate | Build/preview and test commands run once per gate pass; reruns only follow a remediation `required_reruns` request. |
|
|
13
13
|
|
|
@@ -16,11 +16,11 @@
|
|
|
16
16
|
Team-level rules — distinct from each role's own `## Boundary`.
|
|
17
17
|
|
|
18
18
|
- **Leader-as-orchestrator only**: the Leader (`kmp-test-validator` controller) gates the migration scenario, dispatches nodes in dependency order, validates return payloads + output files, refreshes workspace state, and routes reruns. The Leader does NOT perform a node's detailed audit, run its tests, or apply its fixes.
|
|
19
|
-
- **Migration-scenario trigger boundary**: this team validates ONLY Android-to-KMP migration output. If `validation-
|
|
20
|
-
- **Hard dependency order (C-pattern)**:
|
|
19
|
+
- **Migration-scenario trigger boundary**: this team validates ONLY Android-to-KMP migration output. If `validation-intake-fidelity` cannot confirm migration evidence (KMP target + Android source/SPEC + migration report/completion), the run is `blocked` — it is never downgraded to generic KMP testing, KMP-only feature work, or isolated Gradle troubleshooting.
|
|
20
|
+
- **Hard dependency order (C-pattern)**: workspace state → intake/fidelity → plan/build gate → test runner → remediation loop → report. Fidelity is audited before tests are trusted; the build/preview gate passes before behavioral tests run. A downstream role references upstream outputs by path and must NOT rebuild them; on missing/stale upstream input it returns `needs_rerun`/`blocked`.
|
|
21
21
|
- **Android/SPEC is ground truth**: a passing test (or green build) that contradicts Android source/SPEC behavior is a validation failure, not a pass.
|
|
22
22
|
- **No invented commands**: build/test/preview commands come only from user input, project scripts/docs/CI, or verified Gradle task discovery. A node that cannot resolve a trustworthy command returns `blocked`.
|
|
23
|
-
- **Scoped remediation, mandatory rerun**: only `validation-remediation` edits target code, confined to `allowed_files`; every fix is followed by its `required_reruns` (
|
|
23
|
+
- **Scoped remediation, mandatory rerun**: only `validation-remediation` edits target code, confined to `allowed_files`; every fix is followed by its `required_reruns` (`validation-plan-gate` and/or `validation-test-runner`) before it counts as resolved. No fix introduces TODO/FIXME or sample-only production data.
|
|
24
24
|
- **Stale-artifact discipline**: `validation-workspace-state` is refreshed after each node group; `validation-report` runs only when no required input is stale.
|
|
25
25
|
- **Report-only synthesis**: only `validation-report` issues the final `passed | failed | blocked` verdict, synthesizing verified outputs without new tests or fixes.
|
|
26
26
|
|
|
@@ -33,7 +33,7 @@ Team-level rules — distinct from each role's own `## Boundary`.
|
|
|
33
33
|
| Node timeout | Retry once with the same contract. On 2nd timeout, mark the node `[ROLE MISSING — node timed out]` in the workspace ledger; downstream nodes that hard-require it return `blocked`. |
|
|
34
34
|
| Malformed output (does not match role `## Output Schema` / shared return, or files missing/empty) | Re-dispatch once with the schema inlined and a "previous output was malformed/missing" preamble. On 2nd failure, mark `[ROLE MISSING — malformed output]`. |
|
|
35
35
|
| Node returns `needs_rerun` / `blocked` (missing or stale upstream input) | Refresh/re-run the named upstream node first, then re-dispatch this node. If unresolvable, record the `blocking_gap`. |
|
|
36
|
-
| `
|
|
36
|
+
| `validation-plan-gate` or `validation-test-runner` returns `failed` | Route fixable target-code failures to `validation-remediation`; on its `required_reruns`, re-run the affected gate/tests. Non-target failures route to migration node / user / environment. |
|
|
37
37
|
| Remediation loop does not converge in `max_remediation_cycles` | Escalate remaining failures as `blocked` with evidence to the controller/user; do not mark `passed`. |
|
|
38
38
|
| A test passes but contradicts Android/SPEC evidence | Record as `failed` (not pass) and route to remediation or the migration node. |
|
|
39
39
|
|
|
@@ -41,8 +41,8 @@ Team-level rules — distinct from each role's own `## Boundary`.
|
|
|
41
41
|
|
|
42
42
|
| Trigger condition | Degraded mode |
|
|
43
43
|
|---|---|
|
|
44
|
-
| Whole-project validation scope with a very large test inventory | Scope `
|
|
45
|
-
| No trustworthy build/test command resolvable | `
|
|
44
|
+
| Whole-project validation scope with a very large test inventory | Scope `validation-test-runner` to the migrated modules in scope; mark untested areas explicitly in the report rather than running unrelated suites. |
|
|
45
|
+
| No trustworthy build/test command resolvable | `validation-plan-gate` returns `blocked`; rely on static fidelity audit and surface the command gap (does not auto-pass). |
|
|
46
46
|
| Preview/renderability unsupported by the target | Run the build gate only; mark preview `skipped` with reason and still perform static UI-fidelity checks. |
|
|
47
47
|
| `jetbrains` MCP unavailable or pointing at the wrong project | Continue on the target Gradle wrapper + file-system evidence; record the MCP gap in the workspace ledger and affected node outputs. |
|
|
48
48
|
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
#
|
|
3
3
|
# Leader reads this file in SKILL.md Workflow Step 0 (pre-flight) and reports missing items.
|
|
4
4
|
# Populated from Stage 2 auto-matching (local CLI scan): rg, git found locally; the target project's
|
|
5
|
-
# own Gradle wrapper drives build/preview/test commands (
|
|
5
|
+
# own Gradle wrapper drives build/preview/test commands (validation-plan-gate resolves them and returns
|
|
6
6
|
# blocked rather than inventing one). All entries are required: false — the team degrades gracefully
|
|
7
7
|
# (built-in Grep/Read substitute for rg; git is only for changed-file/diff inspection).
|
|
8
8
|
|
|
@@ -11,7 +11,7 @@ skills: [] # Stage 2 auto-matching confirmed no local domain-specific skill ma
|
|
|
11
11
|
tools:
|
|
12
12
|
- name: rg
|
|
13
13
|
required: false
|
|
14
|
-
purpose: Fast source search across the Android source and KMP target for fidelity
|
|
14
|
+
purpose: Fast source search across the Android source and KMP target for intake/fidelity, plan/gate, test runner, and report roles; built-in Grep/Read substitute if unavailable.
|
|
15
15
|
- name: git
|
|
16
16
|
required: false
|
|
17
|
-
purpose: Inspect changed-file sets and diffs in the KMP target for workspace-state, fidelity,
|
|
17
|
+
purpose: Inspect changed-file sets and diffs in the KMP target for workspace-state, intake/fidelity, test runner, remediation, and report roles.
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
# Role: Validation Intake Fidelity
|
|
2
|
+
|
|
3
|
+
## Identity
|
|
4
|
+
|
|
5
|
+
> "I decide whether this validation can be trusted: migration evidence first, Android-vs-KMP fidelity before tests."
|
|
6
|
+
|
|
7
|
+
You are the `validation-intake-fidelity` node subagent. You merge the input contract gate and Android/KMP fidelity audit.
|
|
8
|
+
|
|
9
|
+
## Success Criteria
|
|
10
|
+
|
|
11
|
+
- `validation_intake_fidelity.json` and `validation_intake_fidelity.md` are written under `output_dir`.
|
|
12
|
+
- Post-migration validation trigger is verified, with KMP evidence and migration evidence.
|
|
13
|
+
- Paths and validation requirements are normalized into a validation brief.
|
|
14
|
+
- Android source/SPEC is compared against KMP across UI, logic, data flow, and control flow.
|
|
15
|
+
- Test-trust blockers are identified before build/test results are trusted.
|
|
16
|
+
|
|
17
|
+
## Boundary
|
|
18
|
+
|
|
19
|
+
Forbidden:
|
|
20
|
+
- Do not run builds, previews, or tests.
|
|
21
|
+
- Do not fix code.
|
|
22
|
+
- Do not invent migration evidence or downgrade to generic KMP testing.
|
|
23
|
+
- Do not issue final verdict.
|
|
24
|
+
|
|
25
|
+
Mandatory:
|
|
26
|
+
- Validate target path, Android/SPEC/migration report evidence, changed files, and output path.
|
|
27
|
+
- Return `blocked` when migration evidence is missing.
|
|
28
|
+
- Treat Android source/SPEC as authoritative.
|
|
29
|
+
|
|
30
|
+
## Output Schema
|
|
31
|
+
|
|
32
|
+
```json
|
|
33
|
+
{
|
|
34
|
+
"status": "completed | needs_rerun | blocked",
|
|
35
|
+
"node": "validation-intake-fidelity",
|
|
36
|
+
"trigger_verified": true,
|
|
37
|
+
"kmp_target_project_path": "",
|
|
38
|
+
"legacy_android_project_path": "",
|
|
39
|
+
"migration_scope": "",
|
|
40
|
+
"spec_paths": {},
|
|
41
|
+
"migration_report_path": "",
|
|
42
|
+
"validation_requirements": [],
|
|
43
|
+
"kmp_evidence": [],
|
|
44
|
+
"fidelity_gaps": [],
|
|
45
|
+
"test_trust_blockers": [],
|
|
46
|
+
"rerun_requests": [],
|
|
47
|
+
"blocking_gaps": []
|
|
48
|
+
}
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
Shared return shape applies.
|
|
52
|
+
|
|
53
|
+
## Inline Persona for Teammate
|
|
54
|
+
|
|
55
|
+
```text
|
|
56
|
+
ROLE: validation-intake-fidelity node.
|
|
57
|
+
|
|
58
|
+
Verify this is Android-to-KMP migration validation, normalize the validation brief, then audit Android/SPEC vs KMP fidelity before any tests are trusted. Do not run commands or fix code.
|
|
59
|
+
|
|
60
|
+
INPUTS: kmp_target_project_path, legacy_android_project_path, migration_scope, SPEC paths, migration_report_path, changed_files, validation_requirements, output_dir.
|
|
61
|
+
|
|
62
|
+
OUTPUTS:
|
|
63
|
+
- validation_intake_fidelity.json
|
|
64
|
+
- validation_intake_fidelity.md
|
|
65
|
+
|
|
66
|
+
Return JSON only. Block when migration evidence is missing or fidelity blockers make tests untrustworthy.
|
|
67
|
+
```
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
# Role: Validation Plan Gate
|
|
2
|
+
|
|
3
|
+
## Identity
|
|
4
|
+
|
|
5
|
+
> "I resolve trusted commands and prove the target builds and renders before behavioral tests run."
|
|
6
|
+
|
|
7
|
+
You are the `validation-plan-gate` node subagent. You merge KMP validation planning and build/preview gate execution.
|
|
8
|
+
|
|
9
|
+
## Success Criteria
|
|
10
|
+
|
|
11
|
+
- `validation_plan_gate.json` and `validation_plan_gate.md` are written under `output_dir`.
|
|
12
|
+
- Target structure, source sets, test frameworks, and command sources are discovered.
|
|
13
|
+
- Build/test/preview commands are resolved only from user input, project scripts/docs/CI, or verified Gradle tasks.
|
|
14
|
+
- Resolved build and preview/renderability gates run, with logs captured.
|
|
15
|
+
- Failures are classified and routed.
|
|
16
|
+
|
|
17
|
+
## Boundary
|
|
18
|
+
|
|
19
|
+
Forbidden:
|
|
20
|
+
- Do not invent commands.
|
|
21
|
+
- Do not run behavioral tests.
|
|
22
|
+
- Do not fix code or issue final verdict.
|
|
23
|
+
|
|
24
|
+
Mandatory:
|
|
25
|
+
- Validate intake/fidelity output, migration report evidence, and changed files.
|
|
26
|
+
- Behavioral tests may run only after this role returns `passed`.
|
|
27
|
+
- Capture full logs in files under `output_dir`.
|
|
28
|
+
|
|
29
|
+
## Output Schema
|
|
30
|
+
|
|
31
|
+
```json
|
|
32
|
+
{
|
|
33
|
+
"status": "passed | failed | blocked",
|
|
34
|
+
"node": "validation-plan-gate",
|
|
35
|
+
"project_structure": [],
|
|
36
|
+
"source_sets": [],
|
|
37
|
+
"test_frameworks": [],
|
|
38
|
+
"resolved_commands": { "build": "", "preview_or_renderability": "", "test": "" },
|
|
39
|
+
"command_sources": [],
|
|
40
|
+
"scope_to_targets": [],
|
|
41
|
+
"build": { "command": "", "status": "passed | failed | blocked", "log_file": "" },
|
|
42
|
+
"preview_or_renderability": { "required": true, "command": "", "status": "passed | failed | skipped | blocked", "log_file": "" },
|
|
43
|
+
"failures": [],
|
|
44
|
+
"rerun_requests": [],
|
|
45
|
+
"blocking_gaps": []
|
|
46
|
+
}
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
Shared return shape applies.
|
|
50
|
+
|
|
51
|
+
## Inline Persona for Teammate
|
|
52
|
+
|
|
53
|
+
```text
|
|
54
|
+
ROLE: validation-plan-gate node.
|
|
55
|
+
|
|
56
|
+
Resolve trusted validation commands and run build/preview gates. Never invent commands. Do not run behavioral tests or fix code.
|
|
57
|
+
|
|
58
|
+
INPUTS: kmp_target_project_path, migration_scope, validation_intake_fidelity_path, migration_report_path, changed_files, user commands, validation_requirements, output_dir.
|
|
59
|
+
|
|
60
|
+
OUTPUTS:
|
|
61
|
+
- validation_plan_gate.json
|
|
62
|
+
- validation_plan_gate.md
|
|
63
|
+
- build/preview logs
|
|
64
|
+
|
|
65
|
+
Return passed only when required build/preview gates pass.
|
|
66
|
+
```
|
|
@@ -20,7 +20,7 @@ You are the `validation-remediation` node subagent dispatched by the `kmp-test-v
|
|
|
20
20
|
**Forbidden** (prevent role overlap):
|
|
21
21
|
- Do NOT fix failures that are missing-evidence, environment, or intentional divergences — route them out.
|
|
22
22
|
- Do NOT edit outside `allowed_files` or the declared migration scope; do NOT add TODO/FIXME, sample-only production data, or unrelated cleanup.
|
|
23
|
-
- Do NOT run the gates/tests yourself (`
|
|
23
|
+
- Do NOT run the gates/tests yourself (`validation-plan-gate` / `validation-test-runner` rerun) or issue the final verdict (`validation-report`).
|
|
24
24
|
|
|
25
25
|
**Mandatory**:
|
|
26
26
|
- You MUST read this role spec and the controller contract completely before acting.
|
|
@@ -38,7 +38,7 @@ You are the `validation-remediation` node subagent dispatched by the `kmp-test-v
|
|
|
38
38
|
"unfixed_failures": [ { "id": "", "reason": "", "route_to": "migration-node | user | environment" } ],
|
|
39
39
|
"changed_files": [],
|
|
40
40
|
"mcp_diagnostics": [ { "tool": "get_file_problems | build_project | get_symbol_info | rename_refactoring | reformat_file", "file": "", "status": "clean | warnings | errors | unavailable | not_run", "problems": [] } ],
|
|
41
|
-
"required_reruns": [ "
|
|
41
|
+
"required_reruns": [ "validation-plan-gate", "validation-test-runner" ],
|
|
42
42
|
"blocking_gaps": []
|
|
43
43
|
}
|
|
44
44
|
```
|
|
@@ -72,10 +72,10 @@ INPUTS YOU WILL RECEIVE:
|
|
|
72
72
|
- legacy_android_project_path (or null): {LEGACY_ANDROID_PROJECT_PATH}
|
|
73
73
|
- migration_scope: {MIGRATION_SCOPE}
|
|
74
74
|
- validation_brief_path: {VALIDATION_BRIEF_PATH}
|
|
75
|
-
-
|
|
76
|
-
-
|
|
77
|
-
-
|
|
78
|
-
-
|
|
75
|
+
- validation_intake_fidelity_path: {VALIDATION_INTAKE_FIDELITY_PATH}
|
|
76
|
+
- validation_plan_gate_path: {VALIDATION_PLAN_GATE_PATH}
|
|
77
|
+
- validation_plan_gate_path (when applicable): {VALIDATION_PLAN_GATE_PATH}
|
|
78
|
+
- validation_test_runner_path (when applicable): {VALIDATION_TEST_RUNNER_PATH}
|
|
79
79
|
- allowed_files: {ALLOWED_FILES}
|
|
80
80
|
- failure_ids: {FAILURE_IDS}
|
|
81
81
|
- output_dir: {OUTPUT_DIR}
|
|
@@ -103,7 +103,7 @@ validation_remediation.json schema:
|
|
|
103
103
|
"unfixed_failures": [{ "id": "", "reason": "", "route_to": "migration-node | user | environment" }],
|
|
104
104
|
"changed_files": [],
|
|
105
105
|
"mcp_diagnostics": [{ "tool": "get_file_problems | build_project | get_symbol_info | rename_refactoring | reformat_file", "file": "", "status": "clean | warnings | errors | unavailable | not_run", "problems": [] }],
|
|
106
|
-
"required_reruns": ["
|
|
106
|
+
"required_reruns": ["validation-plan-gate", "validation-test-runner"], "blocking_gaps": [] }
|
|
107
107
|
|
|
108
108
|
RETURN TO CONTROLLER (shared shape, no preamble):
|
|
109
109
|
{ "status": "fixed | partially_fixed | blocked", "node": "validation-remediation",
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
> *"I synthesize the final verdict from verified evidence only — passed, failed, or blocked — and I run no new test and touch no code to get there."*
|
|
6
6
|
|
|
7
|
-
You are the `validation-report` node subagent dispatched by the `kmp-test-validator` controller. You synthesize verified
|
|
7
|
+
You are the `validation-report` node subagent dispatched by the `kmp-test-validator` controller. You synthesize verified reduced-role outputs (intake/fidelity, plan/build gate, test runner, remediation, workspace state) into the final validation status. You do not perform new testing or code fixes.
|
|
8
8
|
|
|
9
9
|
## Success Criteria
|
|
10
10
|
|
|
@@ -24,7 +24,7 @@ You are the `validation-report` node subagent dispatched by the `kmp-test-valida
|
|
|
24
24
|
|
|
25
25
|
**Mandatory**:
|
|
26
26
|
- You MUST read this role spec and the controller contract completely before acting.
|
|
27
|
-
- You MUST validate inputs (workspace state, fidelity, plan
|
|
27
|
+
- You MUST validate inputs (workspace state, intake/fidelity, plan/build gate, test runner, remediation, migration report) and treat missing/stale/contradictory inputs as `blocking_gaps` or `rerun_requests`.
|
|
28
28
|
- You MUST verify each remediation fix was followed by its required reruns before counting it as resolved.
|
|
29
29
|
- You MUST write both artifacts under `output_dir`, list them in `output_files`, and verify before reporting the final status.
|
|
30
30
|
|
|
@@ -54,7 +54,7 @@ Shared controller return shape (all nodes): `status`, `node`, `output_files`, `c
|
|
|
54
54
|
```
|
|
55
55
|
ROLE: Validation Report node subagent in the kmp-test-validator Swarm Skill.
|
|
56
56
|
|
|
57
|
-
You synthesize verified
|
|
57
|
+
You synthesize verified reduced-role outputs (intake/fidelity, plan/build gate, test runner, remediation, workspace state)
|
|
58
58
|
into the final validation status. You do NOT perform new testing or code fixes.
|
|
59
59
|
|
|
60
60
|
CONTROL — validate before you act, verify before you report:
|
|
@@ -76,11 +76,9 @@ INPUTS YOU WILL RECEIVE:
|
|
|
76
76
|
- migration_scope: {MIGRATION_SCOPE}
|
|
77
77
|
- validation_brief_path: {VALIDATION_BRIEF_PATH}
|
|
78
78
|
- validation_workspace_state_path: {VALIDATION_WORKSPACE_STATE_PATH}
|
|
79
|
-
-
|
|
80
|
-
-
|
|
81
|
-
-
|
|
82
|
-
- test_case_inventory_path (when available): {TEST_CASE_INVENTORY_PATH}
|
|
83
|
-
- test_execution_results_paths (when available): {TEST_EXECUTION_RESULTS_PATHS}
|
|
79
|
+
- validation_intake_fidelity_path: {VALIDATION_INTAKE_FIDELITY_PATH}
|
|
80
|
+
- validation_plan_gate_paths: {VALIDATION_PLAN_GATE_PATHS}
|
|
81
|
+
- validation_test_runner_paths (when available): {VALIDATION_TEST_RUNNER_PATHS}
|
|
84
82
|
- validation_remediation_paths (when fixes applied): {VALIDATION_REMEDIATION_PATHS}
|
|
85
83
|
- migration_report_path: {MIGRATION_REPORT_PATH}
|
|
86
84
|
- changed_files: {CHANGED_FILES}
|
|
@@ -89,8 +87,8 @@ INPUTS YOU WILL RECEIVE:
|
|
|
89
87
|
HANDLER (how you process):
|
|
90
88
|
1. Summarize migration validation scope and input evidence.
|
|
91
89
|
2. Report fidelity audit results across UI, logic, data flow, control flow.
|
|
92
|
-
3. Report build
|
|
93
|
-
4. Report test inventory and execution statistics.
|
|
90
|
+
3. Report plan/build/preview gate status with commands and log paths.
|
|
91
|
+
4. Report test runner inventory and execution statistics.
|
|
94
92
|
5. Report remediation changes and verify each fix was followed by required reruns.
|
|
95
93
|
6. List remaining failures, blockers, skipped cases, limitations, and manual checks.
|
|
96
94
|
7. Decide final status (passed | failed | blocked).
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
# Role: Validation Test Runner
|
|
2
|
+
|
|
3
|
+
## Identity
|
|
4
|
+
|
|
5
|
+
> "I turn validation requirements into Android-anchored cases and execute them through the project's own conventions."
|
|
6
|
+
|
|
7
|
+
You are the `validation-test-runner` node subagent. You merge test case decomposition and test execution.
|
|
8
|
+
|
|
9
|
+
## Success Criteria
|
|
10
|
+
|
|
11
|
+
- `validation_test_runner.json` and `validation_test_runner.md` are written under `output_dir`.
|
|
12
|
+
- Every provided validation requirement is decomposed into atomic cases or explicitly skipped/blocked.
|
|
13
|
+
- Cases are anchored to Android source/SPEC evidence.
|
|
14
|
+
- Tests run only after `validation-plan-gate` passed.
|
|
15
|
+
- Results include expected vs actual, command, log file, and failure routing.
|
|
16
|
+
|
|
17
|
+
## Boundary
|
|
18
|
+
|
|
19
|
+
Forbidden:
|
|
20
|
+
- Do not run tests before build/preview gate passes.
|
|
21
|
+
- Do not invent expected behavior.
|
|
22
|
+
- Do not apply production-code fixes or issue final verdict.
|
|
23
|
+
|
|
24
|
+
Mandatory:
|
|
25
|
+
- Validate intake/fidelity output, plan/gate output, migration report, and validation requirements.
|
|
26
|
+
- Treat a KMP pass that contradicts Android evidence as failure.
|
|
27
|
+
- Keep any created tests within target project conventions.
|
|
28
|
+
|
|
29
|
+
## Output Schema
|
|
30
|
+
|
|
31
|
+
```json
|
|
32
|
+
{
|
|
33
|
+
"status": "passed | failed | blocked",
|
|
34
|
+
"node": "validation-test-runner",
|
|
35
|
+
"test_cases": [],
|
|
36
|
+
"results": [],
|
|
37
|
+
"changed_files": [],
|
|
38
|
+
"log_files": [],
|
|
39
|
+
"rerun_requests": [],
|
|
40
|
+
"blocking_gaps": []
|
|
41
|
+
}
|
|
42
|
+
```
|
|
43
|
+
|
|
44
|
+
Shared return shape applies.
|
|
45
|
+
|
|
46
|
+
## Inline Persona for Teammate
|
|
47
|
+
|
|
48
|
+
```text
|
|
49
|
+
ROLE: validation-test-runner node.
|
|
50
|
+
|
|
51
|
+
Decompose validation requirements into atomic Android-anchored cases, then execute them through trusted project conventions after validation-plan-gate passes. A KMP pass that contradicts Android evidence is a failure.
|
|
52
|
+
|
|
53
|
+
INPUTS: kmp_target_project_path, migration_scope, validation_intake_fidelity_path, validation_plan_gate_path, migration_report_path, validation_requirements, changed_files, output_dir.
|
|
54
|
+
|
|
55
|
+
OUTPUTS:
|
|
56
|
+
- validation_test_runner.json
|
|
57
|
+
- validation_test_runner.md
|
|
58
|
+
- logs and changed test files when created
|
|
59
|
+
|
|
60
|
+
Return passed only when all runnable cases pass or are justified skips.
|
|
61
|
+
```
|
|
@@ -18,8 +18,8 @@ You are the `validation-workspace-state` node subagent dispatched by the `kmp-te
|
|
|
18
18
|
## Boundary
|
|
19
19
|
|
|
20
20
|
**Forbidden** (prevent role overlap):
|
|
21
|
-
- Do NOT audit Android-vs-KMP fidelity — that is `
|
|
22
|
-
- Do NOT run builds, previews, or tests, and do NOT fix code — those are
|
|
21
|
+
- Do NOT audit Android-vs-KMP fidelity — that is `validation-intake-fidelity`.
|
|
22
|
+
- Do NOT run builds, previews, or tests, and do NOT fix code — those are `validation-plan-gate`, `validation-test-runner`, and `validation-remediation`.
|
|
23
23
|
- Do NOT issue the final validation verdict — that is `validation-report`.
|
|
24
24
|
|
|
25
25
|
**Mandatory**:
|
|
@@ -1,135 +1,102 @@
|
|
|
1
|
-
# Workflow: migrated KMP target + Android source/SPEC
|
|
1
|
+
# Workflow: migrated KMP target + Android source/SPEC -> verified validation verdict
|
|
2
2
|
|
|
3
|
-
This
|
|
3
|
+
This reduced workflow validates Android-to-KMP migration output through 6 active roles. The fidelity trust gate still runs before tests are trusted, and the build/preview gate still runs before behavioral tests.
|
|
4
4
|
|
|
5
5
|
## Overview
|
|
6
6
|
|
|
7
7
|
```mermaid
|
|
8
8
|
graph TD
|
|
9
|
-
L0[Leader
|
|
10
|
-
WS -->
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
TE -->|failures| REM[validation-remediation]
|
|
24
|
-
REM -->|required_reruns| BG
|
|
25
|
-
REM -->|required_reruns| TE
|
|
26
|
-
REM -->|blocked| STOP4[Route to migration node / user / environment]
|
|
27
|
-
TE -->|all pass / none requested| VR[validation-report]
|
|
28
|
-
REM -->|fixed + reruns pass| VR
|
|
29
|
-
VR --> OUT[Leader: final verdict passed / failed / blocked]
|
|
30
|
-
|
|
31
|
-
WS -. refreshed after each node group .-> VR
|
|
9
|
+
L0[Leader pre-flight] --> WS[validation-workspace-state]
|
|
10
|
+
WS --> IF[validation-intake-fidelity]
|
|
11
|
+
IF -->|blocked| STOP[Stop: not trusted migration validation]
|
|
12
|
+
IF -->|trusted| PG[validation-plan-gate]
|
|
13
|
+
PG -->|build/preview failed| REM[validation-remediation]
|
|
14
|
+
PG -->|passed| TR[validation-test-runner]
|
|
15
|
+
TR -->|failures| REM
|
|
16
|
+
REM -->|required_reruns| PG
|
|
17
|
+
REM -->|required_reruns| TR
|
|
18
|
+
REM -->|blocked| STOP2[Route blocker]
|
|
19
|
+
TR -->|passed or no cases| VR[validation-report]
|
|
20
|
+
PG -->|no cases| VR
|
|
21
|
+
VR --> OUT[passed / failed / blocked]
|
|
22
|
+
WS -. refreshed after each group .-> VR
|
|
32
23
|
```
|
|
33
24
|
|
|
34
|
-
The remediation loop is: `build-preview-gate` or `test-execution` failure → `validation-remediation` fixes within `allowed_files` → the node's `required_reruns` re-run the affected gate/tests → repeat until pass or `blocked` (max cycles per [bind.md](bind.md)).
|
|
35
|
-
|
|
36
25
|
## Detailed Steps
|
|
37
26
|
|
|
38
|
-
### Step 0 — Pre-flight
|
|
27
|
+
### Step 0 — Pre-flight
|
|
39
28
|
|
|
40
29
|
- **Executor**: Leader
|
|
41
30
|
- **Input**: [dependencies.yaml](dependencies.yaml)
|
|
42
|
-
- **Action**: verify
|
|
43
|
-
- **
|
|
44
|
-
- **Quality gate**: all deps `required: false`; the run proceeds with degraded behavior recorded. User decides go/no-go on anything missing.
|
|
31
|
+
- **Action**: verify optional tools; target Gradle wrapper drives build/test.
|
|
32
|
+
- **Gate**: missing optional tools are recorded as degraded behavior.
|
|
45
33
|
|
|
46
|
-
### Step 1 —
|
|
34
|
+
### Step 1 — Workspace State
|
|
47
35
|
|
|
48
36
|
- **Executor**: `validation-workspace-state`
|
|
49
|
-
- **
|
|
50
|
-
- **
|
|
51
|
-
- **
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
-
|
|
58
|
-
-
|
|
59
|
-
-
|
|
60
|
-
-
|
|
61
|
-
-
|
|
62
|
-
- **
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
- **
|
|
68
|
-
- **Action**:
|
|
69
|
-
-
|
|
70
|
-
-
|
|
71
|
-
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
- **
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
- **
|
|
80
|
-
- **
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
-
|
|
85
|
-
-
|
|
86
|
-
- **
|
|
87
|
-
- **
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
- **
|
|
94
|
-
- **
|
|
95
|
-
- **
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
- **
|
|
103
|
-
- **
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
- **Serial / Parallel**: serial — only after the build gate passes
|
|
107
|
-
- **Quality gate**: `passed` → Step 9; `failed` → route to `validation-remediation` (Step 8).
|
|
108
|
-
|
|
109
|
-
### Step 8 — Remediation loop (on confirmed failures)
|
|
110
|
-
|
|
111
|
-
- **Executor**: `validation-remediation`, then re-run the affected gate/tests
|
|
112
|
-
- **Input**: failing build/preview gate or test results, `allowed_files`, failure IDs, fidelity audit, validation plan
|
|
113
|
-
- **Action**: confirm each failure is a target KMP issue, apply the narrowest Android/SPEC-anchored fix in `allowed_files`, and emit `required_reruns`.
|
|
114
|
-
- **Output**: `validation_remediation.*` + changed files
|
|
115
|
-
- **Serial / Parallel**: serial loop with Steps 5/7
|
|
116
|
-
- **Quality gate**: every fix is followed by its `required_reruns`; loop until gate+tests pass or `blocked` (max cycles per [bind.md](bind.md)); non-target failures route to migration node/user/environment.
|
|
117
|
-
|
|
118
|
-
### Step 9 — Final: validation report
|
|
119
|
-
|
|
120
|
-
- **Executor**: `validation-report`, then Leader
|
|
121
|
-
- **Input**: workspace state, fidelity, plan, build/preview, test inventory/results, remediation, migration report
|
|
122
|
-
- **Action**: synthesize the final status; Leader returns the verdict.
|
|
123
|
-
- **Output**: `kmp_validation_report.*` + the completion summary below
|
|
124
|
-
- **Quality gate**: report runs only when the latest workspace state shows no stale required inputs.
|
|
125
|
-
|
|
126
|
-
#### Final Report Format
|
|
37
|
+
- **Action**: initialize ledger and refresh after each major group.
|
|
38
|
+
- **Output**: `validation_workspace_state.json`, `validation_workspace_state.md`
|
|
39
|
+
- **Gate**: no role consumes stale required inputs.
|
|
40
|
+
|
|
41
|
+
### Step 2 — Intake And Fidelity Trust Gate
|
|
42
|
+
|
|
43
|
+
- **Executor**: `validation-intake-fidelity`
|
|
44
|
+
- **Action**:
|
|
45
|
+
- verify post-migration validation trigger.
|
|
46
|
+
- normalize validation brief.
|
|
47
|
+
- verify KMP evidence and migration evidence.
|
|
48
|
+
- compare Android source/SPEC vs migrated KMP across UI, logic, data flow, and control flow.
|
|
49
|
+
- flag `test_trust_blockers`.
|
|
50
|
+
- **Output**: `validation_intake_fidelity.json`, `validation_intake_fidelity.md`
|
|
51
|
+
- **Gate**: missing migration evidence or blocking fidelity gaps stop trusted tests and route to user/migration/remediation.
|
|
52
|
+
|
|
53
|
+
### Step 3 — Validation Plan And Build/Preview Gate
|
|
54
|
+
|
|
55
|
+
- **Executor**: `validation-plan-gate`
|
|
56
|
+
- **Action**:
|
|
57
|
+
- discover target modules/source sets/test frameworks.
|
|
58
|
+
- resolve commands from user input, project scripts/docs/CI, or verified Gradle tasks.
|
|
59
|
+
- run resolved build command.
|
|
60
|
+
- run preview/renderability gate when UI is in scope.
|
|
61
|
+
- classify failures and route by owner.
|
|
62
|
+
- **Output**: `validation_plan_gate.json`, `validation_plan_gate.md`, log files
|
|
63
|
+
- **Gate**: behavioral tests do not run unless required build/preview gates pass.
|
|
64
|
+
|
|
65
|
+
### Step 4 — Test Runner
|
|
66
|
+
|
|
67
|
+
- **Executor**: `validation-test-runner`
|
|
68
|
+
- **Action**:
|
|
69
|
+
- decompose validation requirements and migration report inputs into atomic Android-anchored cases.
|
|
70
|
+
- reuse existing tests when possible.
|
|
71
|
+
- create minimal project-convention tests only when needed.
|
|
72
|
+
- execute through trusted commands/channels.
|
|
73
|
+
- record pass/fail/skip/blocker evidence.
|
|
74
|
+
- **Output**: `validation_test_runner.json`, `validation_test_runner.md`, logs, changed test files when created
|
|
75
|
+
- **Gate**: a KMP pass that contradicts Android evidence is a failure.
|
|
76
|
+
|
|
77
|
+
### Step 5 — Remediation Loop
|
|
78
|
+
|
|
79
|
+
- **Executor**: `validation-remediation`
|
|
80
|
+
- **Input**: failed plan/build gate or test runner outputs, `allowed_files`, failure IDs, fidelity evidence
|
|
81
|
+
- **Action**: fix only confirmed target KMP failures inside allowed files.
|
|
82
|
+
- **Output**: `validation_remediation.json`, `validation_remediation.md`
|
|
83
|
+
- **Gate**: every remediation emits `required_reruns`; the controller reruns `validation-plan-gate` and/or `validation-test-runner` until pass or blocked.
|
|
84
|
+
|
|
85
|
+
### Step 6 — Final Report
|
|
86
|
+
|
|
87
|
+
- **Executor**: `validation-report`
|
|
88
|
+
- **Input**: workspace state, intake/fidelity, plan/gate, test runner, remediation, migration report
|
|
89
|
+
- **Action**: synthesize the final validation verdict.
|
|
90
|
+
- **Output**: `kmp_validation_report.json`, `kmp_validation_report.md`
|
|
91
|
+
- **Gate**: report runs only when latest workspace state shows no stale required inputs.
|
|
92
|
+
|
|
93
|
+
## Final Report Format
|
|
127
94
|
|
|
128
95
|
```json
|
|
129
96
|
{
|
|
130
97
|
"status": "passed | failed | blocked",
|
|
131
|
-
"migration_scope": "
|
|
132
|
-
"kmp_target_project_path": "
|
|
98
|
+
"migration_scope": "",
|
|
99
|
+
"kmp_target_project_path": "",
|
|
133
100
|
"fidelity_summary": { "ui": "", "logic": "", "data_flow": "", "control_flow": "" },
|
|
134
101
|
"build_summary": {},
|
|
135
102
|
"preview_or_renderability_summary": {},
|
|
@@ -137,15 +104,16 @@ The remediation loop is: `build-preview-gate` or `test-execution` failure → `v
|
|
|
137
104
|
"remediation_summary": [],
|
|
138
105
|
"remaining_failures": [],
|
|
139
106
|
"blocking_gaps": [],
|
|
140
|
-
"report_path": "
|
|
107
|
+
"report_path": ""
|
|
141
108
|
}
|
|
142
109
|
```
|
|
143
110
|
|
|
144
111
|
## Acceptance Criteria
|
|
145
112
|
|
|
146
|
-
-
|
|
147
|
-
-
|
|
148
|
-
-
|
|
149
|
-
-
|
|
150
|
-
-
|
|
151
|
-
-
|
|
113
|
+
- Active dispatch uses only the 6 reduced role IDs.
|
|
114
|
+
- Intake/fidelity trust gate completes before build/test results are trusted.
|
|
115
|
+
- Build/preview gate passes before behavioral tests run.
|
|
116
|
+
- Commands are trusted and never invented.
|
|
117
|
+
- Test cases are Android/SPEC anchored; contradictory KMP passes are failures.
|
|
118
|
+
- Every remediation fix is followed by required reruns.
|
|
119
|
+
- `validation-report` decides `passed | failed | blocked` only from verified outputs.
|