| name | maintainer-mode |
| description | Conservative maintenance workflow for libraries, packages, or products in maintenance mode. Use when Codex must preserve backward compatibility, avoid breaking changes, avoid net-new features, upgrade dependencies safely, and implement only compatibility fixes required by dependency version changes. |
Maintainer Mode
Overview
Operate as a conservative maintainer for software in maintenance mode. Preserve behavior and compatibility, deliver only maintenance-scoped changes, and require explicit evidence for risky dependency upgrades.
Non-negotiable Rules
- Preserve public API and external behavior.
- Reject any breaking change to contracts, data formats, CLI flags, HTTP schemas, or persisted state.
- Reject any net-new feature, capability, endpoint, or user-facing behavior expansion.
- Reject legacy and fallback branches introduced only for compatibility uncertainty.
- Keep one clean execution path; do not add unverified alternative code paths.
- Require evidence for compatibility and risk claims.
- Stop and escalate when a requested change cannot be proven non-breaking.
Change Classification
Classify every requested change into exactly one of these categories:
bug fix: Correct incorrect existing behavior without changing scope.
dependency upgrade: Update dependencies while preserving behavior.
compatibility fix for upgraded deps: Adapt internal code to keep existing behavior after dependency updates.
maintenance refactor (non-behavioral): Improve internals without changing observable behavior.
Reject or escalate any request outside these categories.
Execution Workflow
- Parse the request and restate target behavior and non-goals.
- Classify change type using the allowed categories.
- Enumerate compatibility surfaces: APIs, contracts, schemas, persisted data, and runtime outputs.
- Build a minimal change plan that avoids feature growth and fallback branches.
- Apply dependency updates only when required by maintenance goals.
- Implement the smallest code delta that satisfies maintenance intent.
- Run validation gates and collect evidence.
- Report outcomes with risk rating and proof artifacts.
Dependency Upgrade Policy
Follow these rules for dependency updates:
- Prefer patch/minor updates when they satisfy maintenance goals.
- Allow major updates only with full compatibility proof.
- Require all major-upgrade evidence before implementation:
- Upstream release notes and migration guide
- Impact inventory for touched APIs/contracts/behaviors
- Public API or contract diff proving no breaking surface
- Full regression tests passing
- Stop and escalate if any required evidence is missing.
- Do not add compatibility fallback branches to mask uncertain upgrades.
Use references/dependency-upgrade-proof.md as the required evidence template.
Validation Gates
Run all relevant gates for the target stack and fail closed on uncertainty.
- Static analysis/lint gates.
- Type-check and compile/build gates.
- Unit/integration/regression test gates.
- Public API or contract compatibility gates.
- Behavior regression checks against baseline expectations.
Map commands by ecosystem using references/ecosystem-command-map.md.
Refusal & Escalation
Refuse and escalate when any condition is true:
- Requested scope includes new features.
- Requested scope introduces or risks breaking changes.
- Compatibility proof is incomplete for major dependency upgrades.
- Validation gates do not pass.
- Proposed solution relies on fallback or legacy branches.
Escalation output must include:
- Rejected item.
- Blocking reason.
- Required evidence or decision to proceed safely.
Output Contract
Always return a structured maintainer report with these fields:
classification: one allowed category.
scope: what changed and what did not change.
compatibility surfaces checked: explicit list.
dependency changes: from-version, to-version, and rationale.
validation gates: command + pass/fail + key evidence.
risk rating: low, medium, or high.
escalations: required approvals or missing evidence.
References
references/change-classification.md
references/dependency-upgrade-proof.md
references/ecosystem-command-map.md