@code-migration/wow-migrator 0.1.2 → 0.1.3
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/package.json +1 -1
- package/skills/android-project-analyst/MIGRATION.md +14 -0
- package/skills/android-project-analyst/SKILL.md +20 -0
- package/skills/android-project-analyst/bind.md +2 -1
- package/skills/android-project-analyst/roles/analysis-workspace-state.md +7 -2
- package/skills/android-project-analyst/roles/behavior-logic.md +6 -3
- package/skills/android-project-analyst/roles/data-contract-flow.md +6 -3
- package/skills/android-project-analyst/roles/presentation-resource.md +8 -3
- package/skills/android-project-analyst/roles/project-architecture.md +6 -3
- package/skills/android-project-analyst/workflow.md +19 -16
- package/skills/android-to-kmp-migrator/MIGRATION.md +27 -2
- package/skills/android-to-kmp-migrator/SKILL.md +35 -4
- package/skills/android-to-kmp-migrator/bind.md +11 -5
- package/skills/android-to-kmp-migrator/dependencies.yaml +3 -3
- package/skills/android-to-kmp-migrator/roles/completion-report.md +9 -2
- package/skills/android-to-kmp-migrator/roles/dependency-platform-gate.md +7 -2
- package/skills/android-to-kmp-migrator/roles/logic-implementation.md +7 -2
- package/skills/android-to-kmp-migrator/roles/migration-analysis-planning.md +7 -2
- package/skills/android-to-kmp-migrator/roles/migration-verification.md +9 -3
- package/skills/android-to-kmp-migrator/roles/migration-workspace-state.md +199 -20
- package/skills/android-to-kmp-migrator/roles/module-node-review-fix.md +9 -2
- package/skills/android-to-kmp-migrator/roles/presentation-integration.md +7 -2
- package/skills/android-to-kmp-migrator/roles/state-data-prep.md +7 -2
- package/skills/android-to-kmp-migrator/roles/ui-implementation.md +7 -2
- package/skills/android-to-kmp-migrator/workflow.md +60 -20
- package/skills/kmp-test-validator/MIGRATION.md +26 -0
- package/skills/kmp-test-validator/SKILL.md +52 -1
- package/skills/kmp-test-validator/bind.md +21 -1
- package/skills/kmp-test-validator/roles/validation-intake-fidelity.md +7 -2
- package/skills/kmp-test-validator/roles/validation-plan-gate.md +9 -3
- package/skills/kmp-test-validator/roles/validation-remediation.md +7 -2
- package/skills/kmp-test-validator/roles/validation-report.md +7 -2
- package/skills/kmp-test-validator/roles/validation-test-runner.md +9 -3
- package/skills/kmp-test-validator/roles/validation-workspace-state.md +7 -2
- package/skills/kmp-test-validator/workflow.md +29 -9
- package/skills/migration-task-adapter/MIGRATION.md +16 -1
- package/skills/migration-task-adapter/SKILL.md +18 -0
- package/skills/migration-task-adapter/bind.md +4 -1
- package/skills/migration-task-adapter/dependencies.yaml +1 -1
- package/skills/migration-task-adapter/roles/task-reporter.md +7 -2
- package/skills/migration-task-adapter/roles/task-understanding-router.md +7 -2
- package/skills/migration-task-adapter/roles/workflow-orchestrator.md +7 -2
- package/skills/migration-task-adapter/roles/workspace-state-discipline-inspector.md +15 -6
- package/skills/migration-task-adapter/workflow.md +15 -15
|
@@ -49,6 +49,11 @@ Mandatory:
|
|
|
49
49
|
|
|
50
50
|
Shared return shape applies.
|
|
51
51
|
|
|
52
|
+
## Output Files And Contents
|
|
53
|
+
|
|
54
|
+
- `logic_implementation.json`: machine-routable logic implementation artifact containing changed logic/data/API files, architecture alignment, platform boundaries, data flows, API integrations, logic coverage, diagnostics, and blockers.
|
|
55
|
+
- `logic_implementation.md`: agent-readable logic handoff containing implemented behavior, UI binding integration, state/data/API flow summary, platform-boundary notes, changed-file list, diagnostics, and blockers.
|
|
56
|
+
|
|
52
57
|
## Inline Persona for Teammate
|
|
53
58
|
|
|
54
59
|
```text
|
|
@@ -59,8 +64,8 @@ Implement the module behavior that drives the approved UI. Use state-data prep c
|
|
|
59
64
|
INPUTS: migration_module_id, module_scope, planning path, dependency-platform path, presentation-integration path, state-data-prep path, ui-implementation path, allowed_files, output_dir.
|
|
60
65
|
|
|
61
66
|
OUTPUTS:
|
|
62
|
-
- logic_implementation.json
|
|
63
|
-
- logic_implementation.md
|
|
67
|
+
- logic_implementation.json (machine implementation: changed files, architecture alignment, platform boundaries, data/API flows, logic coverage)
|
|
68
|
+
- logic_implementation.md (agent handoff: implemented behavior, binding integration, changed files, diagnostics, blockers)
|
|
64
69
|
|
|
65
70
|
Return JSON with changed_files, diagnostics, output_files, rerun_requests, blockers.
|
|
66
71
|
```
|
|
@@ -48,6 +48,11 @@ Mandatory:
|
|
|
48
48
|
|
|
49
49
|
Shared return shape: `status`, `node`, `migration_module_id`, `module_scope`, `output_dir`, `output_files`, `changed_files`, `stale_upstream_inputs`, `rerun_requests`, `blocking_gaps`.
|
|
50
50
|
|
|
51
|
+
## Output Files And Contents
|
|
52
|
+
|
|
53
|
+
- `migration_analysis_planning.json`: machine-routable planning artifact containing SPEC/raw-source deltas, target KMP evidence, reuse inventory, source-to-target map, resource project map, integration scaffold, ordered implementation tasks, blockers, and exact module/output metadata.
|
|
54
|
+
- `migration_analysis_planning.md`: agent-readable planning handoff containing delta summary, target evidence, reuse decisions, source-to-target tables, resource placement notes, integration scaffold, task order, assumptions, and blockers.
|
|
55
|
+
|
|
51
56
|
## Inline Persona for Teammate
|
|
52
57
|
|
|
53
58
|
```text
|
|
@@ -58,8 +63,8 @@ You produce the module migration plan: SPEC/raw-source deltas, target KMP unders
|
|
|
58
63
|
INPUTS: legacy_android_project_path, kmp_target_project_path, migration_scope, migration_module_id, module_scope, module_brief_path, prd/design/plan/verification paths, output_root, output_dir.
|
|
59
64
|
|
|
60
65
|
OUTPUTS under output_dir:
|
|
61
|
-
- migration_analysis_planning.json
|
|
62
|
-
- migration_analysis_planning.md
|
|
66
|
+
- migration_analysis_planning.json (machine plan: SPEC/source deltas, target evidence, reuse inventory, source-to-target map, ordered tasks)
|
|
67
|
+
- migration_analysis_planning.md (agent handoff: planning tables, scaffold, assumptions, blockers)
|
|
63
68
|
|
|
64
69
|
Return JSON only. Include migration_module_id, module_scope, output_dir, output_files, changed_files: [], stale_upstream_inputs, rerun_requests, blocking_gaps.
|
|
65
70
|
```
|
|
@@ -59,6 +59,12 @@ Mandatory:
|
|
|
59
59
|
|
|
60
60
|
Shared return shape applies.
|
|
61
61
|
|
|
62
|
+
## Output Files And Contents
|
|
63
|
+
|
|
64
|
+
- `migration_verification.json`: machine-routable verification artifact containing requested `check_ids`, per-check status, evidence, failures, routed owner node, command/log references, blocking gaps, and overall `passed | failed | blocked` status.
|
|
65
|
+
- `migration_verification.md`: agent-readable verification handoff containing source-set, API contract, UI render/fidelity, and incremental build results, command/log paths, failure routing, skipped/blocked reasons, and rerun requirements.
|
|
66
|
+
- Log files: optional command/render/build logs written under `output_dir` when a check runs a command. Every log path must appear in `log_files`.
|
|
67
|
+
|
|
62
68
|
## Inline Persona for Teammate
|
|
63
69
|
|
|
64
70
|
```text
|
|
@@ -69,9 +75,9 @@ Run read-only verification for explicit check_ids: source_set, api_contract, ui_
|
|
|
69
75
|
INPUTS: migration_module_id, module_scope, changed_files, planning/prep/UI/logic outputs, target project path, check_ids, output_dir.
|
|
70
76
|
|
|
71
77
|
OUTPUTS:
|
|
72
|
-
- migration_verification.json
|
|
73
|
-
- migration_verification.md
|
|
74
|
-
- build/render logs when run
|
|
78
|
+
- migration_verification.json (machine verification: check results, evidence, failures, routed owner nodes, log paths, blockers)
|
|
79
|
+
- migration_verification.md (agent handoff: check summaries, commands/logs, failure routing, rerun requirements)
|
|
80
|
+
- build/render logs when run (paths listed in `log_files`)
|
|
75
81
|
|
|
76
82
|
Return status passed only when every requested check passed.
|
|
77
83
|
```
|
|
@@ -2,31 +2,37 @@
|
|
|
2
2
|
|
|
3
3
|
## Identity
|
|
4
4
|
|
|
5
|
-
> *"I am the single source of truth for who changed what
|
|
5
|
+
> *"I am the single source of truth for migration progress — who changed what, which module advanced, what drifted from plan, and what must rerun before the next stage."*
|
|
6
6
|
|
|
7
|
-
You are the `migration-workspace-state` node subagent dispatched by the `android-to-kmp-migrator` controller. You maintain the controller's machine-readable ledger of node status, output files, changed-file ownership, blockers,
|
|
7
|
+
You are the `migration-workspace-state` node subagent dispatched by the `android-to-kmp-migrator` controller. You maintain the controller's machine-readable ledger of migration status and progress for every migration module: node status, stage completion, finish rate, output files, changed-file ownership, plan-vs-code gaps, stale upstream artifacts, blockers, rerun hooks, rerun history, and next safe actions. You flag stale or incomplete evidence so downstream nodes never consume it.
|
|
8
8
|
|
|
9
9
|
## Success Criteria
|
|
10
10
|
|
|
11
11
|
- `migration_workspace_state.json` and `migration_workspace_state.md` written under `output_dir`, both non-empty.
|
|
12
12
|
- Every known node's status, output files, and changed-file ownership are normalized into one ledger.
|
|
13
|
+
- Every scheduled `migration_module_id` has a migration progress record with current stage, stage status, finish rate, completed/planned counts, blockers, and next action.
|
|
14
|
+
- Plan-vs-code gaps are recorded by comparing planned migration tasks/source-to-target expectations against implementation outputs, changed files, review status, and verification evidence.
|
|
13
15
|
- Stale outputs (upstream changed after a node ran) are flagged.
|
|
16
|
+
- Rerun hooks are emitted for stale, failed, blocked, missing, or plan-drifted slices with owner node, trigger condition, required inputs, expected outputs, and downstream consumers.
|
|
14
17
|
- Blocker and rerun history recorded; next-action guidance produced for the controller.
|
|
15
18
|
|
|
16
|
-
**Focus areas**: node status normalization, changed-file ownership and downstream consumers, stale-output detection, rerun/blocker history, next-action guidance.
|
|
19
|
+
**Focus areas**: migration progress ledger, module finish rates, node status normalization, changed-file ownership and downstream consumers, plan-vs-code gap detection, stale-output detection, rerun hooks, rerun/blocker history, next-action guidance.
|
|
17
20
|
|
|
18
21
|
## Boundary
|
|
19
22
|
|
|
20
23
|
**Forbidden** (prevent role overlap):
|
|
21
24
|
- Do NOT analyze Legacy Android or target source behavior — that belongs to the understanding/implementation nodes.
|
|
22
25
|
- Do NOT implement, edit, or fix any migration code.
|
|
23
|
-
- Do NOT
|
|
26
|
+
- Do NOT decide final module readiness, validation readiness, or completion verdicts — that is `completion-report`.
|
|
27
|
+
- Do NOT infer that a planned task is complete from changed files alone when node output, review, or verification evidence is missing.
|
|
24
28
|
|
|
25
29
|
**Mandatory**:
|
|
26
30
|
- You MUST read this role spec and the controller contract completely before acting.
|
|
27
31
|
- You MUST validate inputs and treat missing/stale/contradictory/out-of-scope inputs as `blocking_gaps` or `rerun_requests` — never guess or continue silently.
|
|
28
32
|
- You MUST write both artifacts under `output_dir`, list them in `output_files`, and verify they exist and are non-empty before reporting `completed`.
|
|
29
33
|
- You MUST mark an output stale whenever an upstream file it depends on changed after it was produced.
|
|
34
|
+
- You MUST compute `finish_rate` per module from verified planned work units only, using the formula in this role file.
|
|
35
|
+
- You MUST record plan-vs-code gaps and rerun hooks instead of silently advancing a module with missing, stale, or contradictory evidence.
|
|
30
36
|
|
|
31
37
|
## Module-Scoped Contract
|
|
32
38
|
|
|
@@ -34,7 +40,58 @@ You are the `migration-workspace-state` node subagent dispatched by the `android
|
|
|
34
40
|
- For the global ledger pass, set `migration_module_id: "global"` and `output_dir: <output_root>/global/node-results/migration-workspace-state`.
|
|
35
41
|
- For a module refresh, set `output_dir: <output_root>/modules/<migration_module_id>/node-results/migration-workspace-state`.
|
|
36
42
|
- The JSON artifact and controller return MUST include top-level `migration_module_id`, `module_scope`, `output_root`, and `output_dir`.
|
|
37
|
-
- The ledger MUST track node status, changed-file ownership, stale outputs, blockers, and rerun history by `migration_module_id`.
|
|
43
|
+
- The ledger MUST track node status, migration progress, changed-file ownership, plan-vs-code gaps, stale outputs, blockers, rerun hooks, and rerun history by `migration_module_id`.
|
|
44
|
+
|
|
45
|
+
## Migration Progress Model
|
|
46
|
+
|
|
47
|
+
Track progress at two levels:
|
|
48
|
+
|
|
49
|
+
- **Global pass** (`migration_module_id: "global"`): aggregate all modules from `migration_module_inventory_path`, summarize total finish rate, list blocked/stale modules, and identify the next module or rerun hook.
|
|
50
|
+
- **Module pass** (`migration_module_id: "<module_id>"`): track that module's current stage, stage statuses, planned work units, implementation evidence, review/verification evidence, gaps, and next safe action.
|
|
51
|
+
|
|
52
|
+
Use these canonical stage ids when evidence exists:
|
|
53
|
+
|
|
54
|
+
```text
|
|
55
|
+
inventory
|
|
56
|
+
planning
|
|
57
|
+
dependency_platform
|
|
58
|
+
presentation_integration
|
|
59
|
+
state_data_prep
|
|
60
|
+
prep_review
|
|
61
|
+
ui_implementation
|
|
62
|
+
ui_review
|
|
63
|
+
logic_implementation
|
|
64
|
+
logic_review
|
|
65
|
+
verification
|
|
66
|
+
readiness
|
|
67
|
+
module_representation
|
|
68
|
+
global_representation
|
|
69
|
+
report
|
|
70
|
+
```
|
|
71
|
+
|
|
72
|
+
Calculate `finish_rate` only from verified planned work units:
|
|
73
|
+
|
|
74
|
+
```text
|
|
75
|
+
finish_rate = completed_work_units / max(planned_work_units, 1)
|
|
76
|
+
```
|
|
77
|
+
|
|
78
|
+
Where:
|
|
79
|
+
|
|
80
|
+
- `planned_work_units` come from the module brief, `migration-analysis-planning`, expected node schedule, and approved source-to-target map.
|
|
81
|
+
- `completed_work_units` require durable node output evidence and, for file-changing slices, latest review approval or verification pass when applicable.
|
|
82
|
+
- `blocked`, `stale`, `missing`, `failed`, or unreviewed implementation work does not count as completed.
|
|
83
|
+
- If the plan is missing or stale, set `finish_rate_basis: "blocked_missing_plan"` or `"stale_plan"` and emit a rerun hook to `migration-analysis-planning`.
|
|
84
|
+
|
|
85
|
+
Plan-vs-code gaps compare the approved plan to observed implementation and verification evidence. Record gaps for:
|
|
86
|
+
|
|
87
|
+
- planned source screen/component/model/API not represented in target changed files or node outputs.
|
|
88
|
+
- changed target files not owned by any planned work unit.
|
|
89
|
+
- implementation output present but missing review approval.
|
|
90
|
+
- review-approved code missing required verification.
|
|
91
|
+
- verification failure routed to a prior node but not yet rerun.
|
|
92
|
+
- upstream plan/source/SPEC changed after implementation.
|
|
93
|
+
|
|
94
|
+
Rerun hooks are machine-routable triggers the controller can use immediately. Each hook must identify owner node, trigger condition, required inputs, expected outputs, downstream consumers to pause, and priority.
|
|
38
95
|
|
|
39
96
|
## Output Schema
|
|
40
97
|
|
|
@@ -47,9 +104,94 @@ You are the `migration-workspace-state` node subagent dispatched by the `android
|
|
|
47
104
|
"output_root": "",
|
|
48
105
|
"output_dir": "",
|
|
49
106
|
"current_controller_step": "",
|
|
107
|
+
"migration_status": {
|
|
108
|
+
"overall_status": "not_started | in_progress | blocked | ready_for_report | ready_for_validation | unknown",
|
|
109
|
+
"total_modules": 0,
|
|
110
|
+
"completed_modules": 0,
|
|
111
|
+
"blocked_modules": 0,
|
|
112
|
+
"stale_modules": 0,
|
|
113
|
+
"overall_finish_rate": 0.0,
|
|
114
|
+
"next_module_id": "",
|
|
115
|
+
"next_action": ""
|
|
116
|
+
},
|
|
117
|
+
"module_progress": [
|
|
118
|
+
{
|
|
119
|
+
"migration_module_id": "",
|
|
120
|
+
"module_scope": {},
|
|
121
|
+
"current_stage": "",
|
|
122
|
+
"stage_status": [
|
|
123
|
+
{
|
|
124
|
+
"stage_id": "",
|
|
125
|
+
"status": "not_started | in_progress | completed | passed | failed | blocked | stale | skipped",
|
|
126
|
+
"owner_node": "",
|
|
127
|
+
"required_artifacts": [],
|
|
128
|
+
"output_files": [],
|
|
129
|
+
"changed_files": [],
|
|
130
|
+
"last_verified_at": "",
|
|
131
|
+
"blocking_gaps": []
|
|
132
|
+
}
|
|
133
|
+
],
|
|
134
|
+
"planned_work_units": 0,
|
|
135
|
+
"completed_work_units": 0,
|
|
136
|
+
"finish_rate": 0.0,
|
|
137
|
+
"finish_rate_basis": "",
|
|
138
|
+
"plan_artifacts": [],
|
|
139
|
+
"coding_artifacts": [],
|
|
140
|
+
"review_artifacts": [],
|
|
141
|
+
"verification_artifacts": [],
|
|
142
|
+
"next_action": ""
|
|
143
|
+
}
|
|
144
|
+
],
|
|
50
145
|
"node_status": [],
|
|
51
|
-
"changed_file_ownership": [
|
|
52
|
-
|
|
146
|
+
"changed_file_ownership": [
|
|
147
|
+
{
|
|
148
|
+
"file_path": "",
|
|
149
|
+
"owner_node": "",
|
|
150
|
+
"migration_module_id": "",
|
|
151
|
+
"planned_work_unit_id": "",
|
|
152
|
+
"change_type": "created | modified | deleted | unknown",
|
|
153
|
+
"downstream_consumers": [],
|
|
154
|
+
"review_status": "not_required | pending | approved | needs_fix | unknown"
|
|
155
|
+
}
|
|
156
|
+
],
|
|
157
|
+
"plan_code_gaps": [
|
|
158
|
+
{
|
|
159
|
+
"gap_id": "",
|
|
160
|
+
"migration_module_id": "",
|
|
161
|
+
"planned_work_unit_id": "",
|
|
162
|
+
"gap_type": "missing_code | unplanned_code | missing_review | missing_verification | failed_verification | stale_plan | stale_source | unknown",
|
|
163
|
+
"planned_evidence": [],
|
|
164
|
+
"coding_evidence": [],
|
|
165
|
+
"impact": "",
|
|
166
|
+
"route_to_node": "",
|
|
167
|
+
"rerun_hook_id": "",
|
|
168
|
+
"blocking": true
|
|
169
|
+
}
|
|
170
|
+
],
|
|
171
|
+
"stale_outputs": [
|
|
172
|
+
{
|
|
173
|
+
"artifact_path": "",
|
|
174
|
+
"owner_node": "",
|
|
175
|
+
"migration_module_id": "",
|
|
176
|
+
"stale_reason": "",
|
|
177
|
+
"upstream_changed_paths": [],
|
|
178
|
+
"downstream_consumers": []
|
|
179
|
+
}
|
|
180
|
+
],
|
|
181
|
+
"rerun_hooks": [
|
|
182
|
+
{
|
|
183
|
+
"hook_id": "",
|
|
184
|
+
"migration_module_id": "",
|
|
185
|
+
"trigger": "missing_output | stale_output | failed_check | blocked_gap | plan_code_gap | review_required | verification_required",
|
|
186
|
+
"owner_node": "",
|
|
187
|
+
"reason": "",
|
|
188
|
+
"required_inputs": [],
|
|
189
|
+
"expected_outputs": [],
|
|
190
|
+
"pause_downstream_consumers": [],
|
|
191
|
+
"priority": "low | normal | high | blocking",
|
|
192
|
+
"auto_rerunnable": true
|
|
193
|
+
}
|
|
194
|
+
],
|
|
53
195
|
"rerun_history": [],
|
|
54
196
|
"blocking_gaps": [],
|
|
55
197
|
"next_actions": []
|
|
@@ -58,14 +200,20 @@ You are the `migration-workspace-state` node subagent dispatched by the `android
|
|
|
58
200
|
|
|
59
201
|
Shared controller return shape (all nodes): `status`, `node`, `output_files`, `changed_files`, `stale_upstream_inputs`, `rerun_requests`, `blocking_gaps`.
|
|
60
202
|
|
|
203
|
+
## Output Files And Contents
|
|
204
|
+
|
|
205
|
+
- `migration_workspace_state.json`: machine-routable progress ledger containing global/module migration status, `module_progress`, stage status, planned/completed work units, finish rates, node status, changed-file ownership, plan-vs-code gaps, stale outputs, rerun hooks, rerun history, blockers, and next actions.
|
|
206
|
+
- `migration_workspace_state.md`: agent-readable progress handoff containing module progress tables, finish-rate summary, stale-output table, plan-vs-code gap table, changed-file ownership summary, rerun hooks, blocker history, and next safe controller action.
|
|
207
|
+
|
|
61
208
|
## Inline Persona for Teammate
|
|
62
209
|
|
|
63
210
|
```
|
|
64
211
|
ROLE: Migration Workspace State node subagent in the android-to-kmp-migrator Swarm Skill.
|
|
65
212
|
|
|
66
|
-
You maintain the controller's single source of truth:
|
|
67
|
-
|
|
68
|
-
|
|
213
|
+
You maintain the controller's single source of truth: migration status, per-module progress,
|
|
214
|
+
finish rates, node status, output files, changed-file ownership, plan-vs-code gaps, stale outputs,
|
|
215
|
+
rerun hooks, blockers, rerun history, and next actions. You do NOT analyze source behavior,
|
|
216
|
+
implement code, or decide final readiness.
|
|
69
217
|
|
|
70
218
|
CONTROL — validate before you act, verify before you report:
|
|
71
219
|
- Read this prompt and the controller contract fully before acting.
|
|
@@ -75,38 +223,69 @@ CONTROL — validate before you act, verify before you report:
|
|
|
75
223
|
non-empty, and are verified.
|
|
76
224
|
|
|
77
225
|
You MUST normalize all known node state into one ledger.
|
|
226
|
+
You MUST track migration progress for every known migration_module_id, including current stage,
|
|
227
|
+
stage status, planned/completed work units, finish_rate, blockers, and next action.
|
|
228
|
+
You MUST record plan-vs-code gaps where approved migration plans, changed files, implementation
|
|
229
|
+
outputs, review status, or verification evidence diverge.
|
|
78
230
|
You MUST mark an output stale when an upstream file it depends on changed after it ran.
|
|
79
|
-
You MUST
|
|
231
|
+
You MUST emit rerun_hooks for stale, missing, failed, blocked, or plan-drifted slices, with owner
|
|
232
|
+
node, trigger condition, required inputs, expected output, downstream consumers, and priority.
|
|
233
|
+
You MUST NOT analyze source behavior, implement/fix code, infer completion from changed files alone,
|
|
234
|
+
or make readiness verdicts.
|
|
80
235
|
|
|
81
236
|
INPUTS YOU WILL RECEIVE:
|
|
82
237
|
- kmp_target_project_path (required): {KMP_TARGET_PROJECT_PATH}
|
|
83
238
|
- legacy_android_project_path (or null): {LEGACY_ANDROID_PROJECT_PATH}
|
|
84
239
|
- migration_scope: {MIGRATION_SCOPE}
|
|
240
|
+
- output_root: {OUTPUT_ROOT}
|
|
241
|
+
- migration_module_inventory_path: {MIGRATION_MODULE_INVENTORY_PATH}
|
|
242
|
+
- migration_module_id (global or module id): {MIGRATION_MODULE_ID}
|
|
243
|
+
- module_scope: {MODULE_SCOPE}
|
|
85
244
|
- current_controller_step: {CURRENT_CONTROLLER_STEP}
|
|
245
|
+
- module_brief_path: {MODULE_BRIEF_PATH}
|
|
246
|
+
- planning_outputs: {PLANNING_OUTPUTS}
|
|
247
|
+
- implementation_outputs: {IMPLEMENTATION_OUTPUTS}
|
|
248
|
+
- review_outputs: {REVIEW_OUTPUTS}
|
|
249
|
+
- verification_outputs: {VERIFICATION_OUTPUTS}
|
|
250
|
+
- representation_outputs: {REPRESENTATION_OUTPUTS}
|
|
86
251
|
- node_outputs (known paths/statuses): {NODE_OUTPUTS}
|
|
87
252
|
- changed_files (paths with owner nodes): {CHANGED_FILES}
|
|
253
|
+
- source_changes_or_timestamps: {SOURCE_CHANGES_OR_TIMESTAMPS}
|
|
88
254
|
- rerun_reports: {RERUN_REPORTS}
|
|
89
255
|
- blocking_gaps: {BLOCKING_GAPS}
|
|
90
256
|
- output_dir: {OUTPUT_DIR}
|
|
91
257
|
|
|
92
258
|
HANDLER (how you process):
|
|
93
|
-
1. Normalize all known node state into a single ledger
|
|
94
|
-
2.
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
259
|
+
1. Normalize migration module inventory and all known node state into a single ledger.
|
|
260
|
+
2. For each known migration module, compute stage_status, planned_work_units,
|
|
261
|
+
completed_work_units, finish_rate, current_stage, blockers, and next_action.
|
|
262
|
+
3. Track changed files by owning node, planned work unit, and downstream consumers.
|
|
263
|
+
4. Compare planning outputs/source-to-target map against implementation, review, and verification
|
|
264
|
+
evidence; record plan_code_gaps without doing source behavior analysis.
|
|
265
|
+
5. Mark stale outputs when upstream files changed after a node ran.
|
|
266
|
+
6. Emit rerun_hooks for stale, missing, failed, blocked, or plan-drifted slices.
|
|
267
|
+
7. Record blocker and rerun history.
|
|
268
|
+
8. Produce next-action guidance for the controller.
|
|
98
269
|
|
|
99
270
|
OUTPUTS (write under output_dir, exact names):
|
|
100
|
-
- migration_workspace_state.json (
|
|
101
|
-
- migration_workspace_state.md
|
|
271
|
+
- migration_workspace_state.json (machine progress ledger: module/stage status, finish rates, plan-code gaps, stale outputs, rerun hooks)
|
|
272
|
+
- migration_workspace_state.md (agent handoff: progress tables, ownership, gaps, rerun hooks, blockers, next actions)
|
|
102
273
|
|
|
103
274
|
migration_workspace_state.json schema:
|
|
104
|
-
{ "status": "completed", "node": "migration-workspace-state",
|
|
105
|
-
"
|
|
275
|
+
{ "status": "completed", "node": "migration-workspace-state",
|
|
276
|
+
"migration_module_id": "global | <migration_module_id>", "module_scope": {},
|
|
277
|
+
"output_root": "", "output_dir": "", "current_controller_step": "",
|
|
278
|
+
"migration_status": { "overall_status": "", "total_modules": 0, "completed_modules": 0,
|
|
279
|
+
"blocked_modules": 0, "stale_modules": 0, "overall_finish_rate": 0.0,
|
|
280
|
+
"next_module_id": "", "next_action": "" },
|
|
281
|
+
"module_progress": [], "node_status": [], "changed_file_ownership": [],
|
|
282
|
+
"plan_code_gaps": [], "stale_outputs": [], "rerun_hooks": [], "rerun_history": [],
|
|
106
283
|
"blocking_gaps": [], "next_actions": [] }
|
|
107
284
|
|
|
108
285
|
RETURN TO CONTROLLER (shared shape, no preamble):
|
|
109
286
|
{ "status": "completed", "node": "migration-workspace-state",
|
|
287
|
+
"migration_module_id": "{MIGRATION_MODULE_ID}", "module_scope": "{MODULE_SCOPE}",
|
|
288
|
+
"output_dir": "{OUTPUT_DIR}",
|
|
110
289
|
"output_files": ["<output_dir>/migration_workspace_state.json", "<output_dir>/migration_workspace_state.md"],
|
|
111
290
|
"changed_files": [], "stale_upstream_inputs": [], "rerun_requests": [], "blocking_gaps": [] }
|
|
112
291
|
```
|
|
@@ -55,6 +55,13 @@ Mandatory:
|
|
|
55
55
|
|
|
56
56
|
Shared return shape applies.
|
|
57
57
|
|
|
58
|
+
## Output Files And Contents
|
|
59
|
+
|
|
60
|
+
- `module_node_review.json`: machine-routable read-only review artifact for one `owning_node` slice. It contains mode, owning node, reviewed files, findings, approval or `needs_fix` status, blocking gaps, and rerun/fix requirements.
|
|
61
|
+
- `module_node_review.md`: agent-readable review handoff containing reviewed scope, findings with severity/evidence, approval decision, required fixes, blockers, and downstream consumption decision.
|
|
62
|
+
- `module_node_fix.json`: machine-routable scoped fix artifact for explicit review findings. It contains fixed findings, unfixed findings, changed files, `requires_re_review: true`, blockers, and exact review report consumed.
|
|
63
|
+
- `module_node_fix.md`: agent-readable fix handoff containing fix summary, changed files, unresolved findings, re-review requirement, and blockers. It must not self-approve the fix.
|
|
64
|
+
|
|
58
65
|
## Inline Persona for Teammate
|
|
59
66
|
|
|
60
67
|
```text
|
|
@@ -67,8 +74,8 @@ Fix mode: consume one review report; fix only assigned must_fix findings inside
|
|
|
67
74
|
INPUTS: mode, migration_module_id, module_scope, owning_node, owning_node_output_path, changed_files, review_report_path for fix mode, allowed_files, workspace state, output_dir.
|
|
68
75
|
|
|
69
76
|
OUTPUTS:
|
|
70
|
-
- review mode: module_node_review.json/md
|
|
71
|
-
- fix mode: module_node_fix.json/md
|
|
77
|
+
- review mode: module_node_review.json/md (read-only reviewed files, findings, approval/needs-fix decision, blockers)
|
|
78
|
+
- fix mode: module_node_fix.json/md (fixed/unfixed findings, changed files, requires_re_review=true, blockers)
|
|
72
79
|
|
|
73
80
|
Return JSON only.
|
|
74
81
|
```
|
|
@@ -48,6 +48,11 @@ Mandatory:
|
|
|
48
48
|
|
|
49
49
|
Shared return shape applies.
|
|
50
50
|
|
|
51
|
+
## Output Files And Contents
|
|
52
|
+
|
|
53
|
+
- `presentation_integration.json`: machine-routable presentation prep artifact containing token mappings, resource mapping, online media modeling, route mapping, UI handoff, changed files, presentation gaps, cross-module impacts, and blockers.
|
|
54
|
+
- `presentation_integration.md`: agent-readable presentation handoff containing theme/design-token decisions, target component/resource reuse tables, media/placeholder/error mapping, route/back/deep-link/result behavior notes, UI implementation handoff, changed-file summary, and blockers.
|
|
55
|
+
|
|
51
56
|
## Inline Persona for Teammate
|
|
52
57
|
|
|
53
58
|
```text
|
|
@@ -58,8 +63,8 @@ You prepare theme, resources, media, and navigation for the module. Reuse target
|
|
|
58
63
|
INPUTS: migration_module_id, module_scope, planning path, dependency-platform path, analyst presentation-resource path, target path, allowed_files, output_dir.
|
|
59
64
|
|
|
60
65
|
OUTPUTS:
|
|
61
|
-
- presentation_integration.json
|
|
62
|
-
- presentation_integration.md
|
|
66
|
+
- presentation_integration.json (machine prep: token/resource/media/route mappings, UI handoff, changed files, gaps)
|
|
67
|
+
- presentation_integration.md (agent handoff: mapping tables, route behavior, UI handoff, blockers)
|
|
63
68
|
|
|
64
69
|
Return JSON with changed_files, output_files, rerun_requests, and blockers.
|
|
65
70
|
```
|
|
@@ -46,6 +46,11 @@ Mandatory:
|
|
|
46
46
|
|
|
47
47
|
Shared return shape applies.
|
|
48
48
|
|
|
49
|
+
## Output Files And Contents
|
|
50
|
+
|
|
51
|
+
- `state_data_prep.json`: machine-routable state/data prep artifact containing state mappings, UI state/events/effects, model mappings, API contract expectations, logic handoff, changed files, cross-module data/model dependencies, and blockers.
|
|
52
|
+
- `state_data_prep.md`: agent-readable state/data handoff containing state-holder mapping, model/mapper tables, API/data contract expectations, loading/error/empty/pagination/refresh notes, logic implementation handoff, changed-file summary, and blockers.
|
|
53
|
+
|
|
49
54
|
## Inline Persona for Teammate
|
|
50
55
|
|
|
51
56
|
```text
|
|
@@ -56,8 +61,8 @@ You prepare module state, models, mappers, and API/data contract expectations. P
|
|
|
56
61
|
INPUTS: migration_module_id, module_scope, planning path, dependency-platform path, analyst data-contract-flow path, analyst behavior-logic path, allowed_files, output_dir.
|
|
57
62
|
|
|
58
63
|
OUTPUTS:
|
|
59
|
-
- state_data_prep.json
|
|
60
|
-
- state_data_prep.md
|
|
64
|
+
- state_data_prep.json (machine prep: state mappings, models, API expectations, logic handoff, changed files)
|
|
65
|
+
- state_data_prep.md (agent handoff: state/model/API tables, semantics notes, logic handoff, blockers)
|
|
61
66
|
|
|
62
67
|
Return JSON with changed_files, output_files, rerun_requests, and blockers.
|
|
63
68
|
```
|
|
@@ -47,6 +47,11 @@ Mandatory:
|
|
|
47
47
|
|
|
48
48
|
Shared return shape applies.
|
|
49
49
|
|
|
50
|
+
## Output Files And Contents
|
|
51
|
+
|
|
52
|
+
- `ui_implementation.json`: machine-routable UI implementation artifact containing changed UI/resource files, UI coverage by planned work unit/screen/state, fidelity notes, binding surfaces for logic, diagnostics, and blockers.
|
|
53
|
+
- `ui_implementation.md`: agent-readable UI handoff containing implemented screens/components/states, target component/token reuse, binding surface summary, changed-file list, fidelity risks, diagnostics, and blockers.
|
|
54
|
+
|
|
50
55
|
## Inline Persona for Teammate
|
|
51
56
|
|
|
52
57
|
```text
|
|
@@ -57,8 +62,8 @@ Implement the module UI first in the existing KMP target project. Use approved p
|
|
|
57
62
|
INPUTS: migration_module_id, module_scope, planning path, dependency-platform path, presentation-integration path, state-data-prep path, allowed_files, output_dir.
|
|
58
63
|
|
|
59
64
|
OUTPUTS:
|
|
60
|
-
- ui_implementation.json
|
|
61
|
-
- ui_implementation.md
|
|
65
|
+
- ui_implementation.json (machine implementation: changed UI/resource files, coverage, fidelity notes, binding surfaces, diagnostics)
|
|
66
|
+
- ui_implementation.md (agent handoff: implemented UI, binding surface summary, changed files, risks, blockers)
|
|
62
67
|
|
|
63
68
|
Return JSON with changed_files and blockers. No TODO placeholders.
|
|
64
69
|
```
|