---
name: zero-tech-debt-c40424d5a987
description: Rework a change as if the intended UX and architecture had existed from day one — deleting compatibility cruft, dead branches, and accidental complexity instead of patching around them. Use when refactoring, cleaning up after a feature lands, removing flags, collapsing legacy paths, or when the user says the code "should look like X from scratch".
user-invocable: true
---

# Zero Tech Debt

Reshape the change from the **intended end state**, not from the historical path that produced the current patch. The goal is the code that _should_ exist now, not the smallest diff from what's there.

## Steps

1. **Name the end state.** In one or two sentences, describe the product surface and architecture as if you were building it today.

2. **Find real callers before preserving anything.** Grep for actual usage of each mode, prop, wrapper, route alias, or fallback. If nothing references it, delete it — do not "improve" it.

3. **Reshape around the final surface.** Prefer one clear component or flow over mode flags. Split only when there is an obvious boundary: state, layout, controls, or domain commands.

4. **Move shared rules to one place.** Feature flags, permissions, route gating, URL state, and command naming must not be duplicated across pages or buried inside view components.

5. **Verify the intended flow.** Test the new behavior _and_ the assumptions you deleted — anything that touched navigation, permissions, or persisted state.

## Rules

- Optimize for the code that should exist, not the smallest diff from the old shape.
- Delete dead compatibility paths instead of polishing them.
- Do not invent a generic framework for a single feature.
- Keep the refactor scoped to what makes the final shape coherent — no opportunistic cleanup.
- Prefer names that describe product intent over implementation history.


---
Source attribution: susomejias
Original project: https://github.com/susomejias/rembric/blob/edc3d65c9d6a520a1f31efb03a58b0b4e53778f7/.agents/skills/zero-tech-debt/SKILL.md
License: MIT
License information: https://opensource.org/license/mit
Original upstream instructions; downloaded from Mega AI Hub.

## Upstream license notice

MIT License

Copyright (c) 2026 Rembric contributors

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.



# Mega AI Hub resource metadata

Creator / publisher: susomejias
Original project: https://github.com/susomejias/rembric/blob/edc3d65c9d6a520a1f31efb03a58b0b4e53778f7/.agents/skills/zero-tech-debt/SKILL.md
Attribution basis: Source repository record

Fields of work: Design, Development & Engineering, Product Management
Roles: Backend Developer, Frontend Developer, Product Manager, Technical Product Manager, UX Designer
Specialties: Backend, Cross Platform, Frontend
Tools: Tool not specified
Country applicability: Country not specified
Classification basis: Source catalog labels
Instruction SHA-256: 353270c5efb49a2b998dc91f30d074252edd7283f9b1064e6c83c4b097594a4f
