| name | python-retrofit-plan-authoring |
| description | Author a review-ready Retrofit V2 `retrofit-plan.md` for an existing Python repository, with locked section order, machine-readable migration risk metadata, and strict separation between planning strategy and runtime gate decisions. |
| complexity | high |
| risk_profile | ["ambiguity_sensitive","multi_agent_handoff","destructive_action"] |
| inputs | ["current repository facts (entrypoints, packages, config surfaces, toolchain remnants)","concrete target paths, files, entrypoints, and tool choices for the post-retrofit state","known conflict surfaces or destructive candidates the strategy must acknowledge","verifiable acceptance targets for yaml [sensing-assertions]","lane-fit facts proving this is retrofit work rather than greenfield initialization","explicit human clarification when the request is abstract, contradictory, or missing locatable detail"] |
| outputs | ["review-ready Retrofit V2 retrofit-plan.md for an existing Python repository","locked section order with machine-readable migration-strategy and sensing-assertions blocks","explicit risk metadata that executor can consume without a compatibility layer","concrete stop-and-ask feedback when the requested contract is too abstract or misrouted"] |
| use_when | ["an existing Python repository needs a retrofit contract before execution starts","the task is to author or repair retrofit-plan.md to the locked Retrofit V2 shape","the plan must encode risk_level, destructive_actions, backup_required, and acceptance assertions","the workflow needs explicit stop-and-ask handling for abstract, contradictory, or misrouted retrofit requests"] |
| do_not_use_when | ["the repository is greenfield or baseline-only; use python-project-init-greenfield","the task is to execute retrofit steps; use python-project-retrofit","the task is to review or approve an existing retrofit plan","the requested contract lacks concrete paths, concrete tool names, or verifiable targets"] |