Skip to content

docs(skills): add the minimal-code decision ladder to /feature Phase 0 - #4008

Merged
PierreBrisorgueil merged 2 commits into
masterfrom
chore/feature-minimal-code-ladder
Jul 31, 2026
Merged

docs(skills): add the minimal-code decision ladder to /feature Phase 0#4008
PierreBrisorgueil merged 2 commits into
masterfrom
chore/feature-minimal-code-ladder

Conversation

@PierreBrisorgueil

@PierreBrisorgueil PierreBrisorgueil commented Jul 31, 2026

Copy link
Copy Markdown
Contributor

Closes #3944
Part of #3943

Adds the minimal-code decision ladder to the /feature skill, run before an implementation is proposed.

Placement — deliberate change vs the issue text

The issue asked for the ladder in Phase 1 ("before writing new code"). It landed at the end of Phase 0 instead, as §4b, immediately before §5 Present plan & ask questions.

Reason: the first rung is a product question ("does a decision remove this mechanism?"), and §5 is the one place the skill already stops and talks to the user. Running the ladder in Phase 1 would mean discovering the answer after the plan was already validated. The ladder outcome is now carried into §5 as an explicit bullet, so a rejected mechanism is visible at the moment the user validates.

Rungs

Product decision → reuse → stdlib → native platform → installed dependency → one-liner → minimal code. Stop at the first rung that holds.

Two additions beyond the original 7-rung list:

  • Rung 0 — the product decision. The other rungs all ask "what is the cheapest way to build this?". Rung 0 asks whether the requirement can be dropped: accept the cost, accept the failure, do nothing, or surface it to the user. It is the only rung that removes code rather than shrinking it.
  • Persisted state is the expensive rung. A schema field, collection or flag encoding a policy is not a code choice — code is deleted, data is migrated. Rung 0 is mandatory for it, and it needs explicit user confirmation in §5 before it is built.

Guardrails unchanged

Understanding the problem before picking a rung, validation at trust boundaries, error handling that prevents data loss, security, and anything the user explicitly asked for are never traded away. The ladder prunes gratuitous mechanisms, never guardrails.

Docs-only: one file, no runtime code, no dependency change.

https://claude.ai/code/session_019Cow7oT71FcBKpD5brmwBs

Summary by CodeRabbit

  • Documentation
    • Added guidance to evaluate simpler alternatives before introducing new mechanisms.
    • Added requirements to document product decisions and explicit confirmation for persisted policy state.
    • Updated the Phase 0 planning checklist to capture these evaluations and decisions.

Challenge every mechanism a change would introduce before proposing an
implementation, stopping at the first rung that holds: product decision ->
reuse -> stdlib -> native platform -> installed dependency -> one-liner ->
minimal code.

Persisted state gets its own rule: state encoding a policy is not a code
choice, since code is deleted while data has to be migrated, so it requires
explicit user confirmation before it is built. The ladder outcome is carried
into the "present plan" step as one line per rejected mechanism.

Guardrails stay non-negotiable: understanding the problem, trust-boundary
validation, data-loss handling, security, accessibility, and anything the
user explicitly asked for are never traded away.

Claude-Session: https://claude.ai/code/session_019Cow7oT71FcBKpD5brmwBs
@coderabbitai

coderabbitai Bot commented Jul 31, 2026

Copy link
Copy Markdown

Review Change Stack

Warning

Review limit reached

@PierreBrisorgueil, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 44 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: 52f5293e-6b8b-4914-8320-2c8f1db8ae70

📥 Commits

Reviewing files that changed from the base of the PR and between 5575cfa and adc0972.

📒 Files selected for processing (1)
  • .claude/skills/feature/SKILL.md

Walkthrough

The feature skill adds a minimal-code ladder. It requires persisted policy-state decisions and explicit confirmation. The Phase 0 checklist records the ladder outcome and pending decisions.

Changes

Feature workflow guidance

Layer / File(s) Summary
Minimal-code ladder and Phase 0 checklist
.claude/skills/feature/SKILL.md
The skill evaluates reuse, standard-library and platform features, dependencies, configuration, and minimal code. It records the ladder outcome and pending persisted-state decisions before implementation.

Estimated code review effort: 1 (Trivial) | ~5 minutes

Possibly related issues

  • #3943 — It also adds a minimal-code decision ladder to the /feature skill and extends Phase 0 planning.
  • #4401 — It specifies a similar minimal-code ladder for the /feature workflow.
🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Linked Issues check ⚠️ Warning The ladder meets the issue intent, but issue #3944 explicitly requires placement in /feature Phase 1 rather than Phase 0. Move the ladder to Phase 1, or update issue #3944 to approve the earlier Phase 0 placement before merging.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly identifies the documentation change and the affected /feature Phase 0 workflow.
Description check ✅ Passed The description explains the change, rationale, scope, guardrails, validation impact, and linked issues, so it is mostly complete.
Out of Scope Changes check ✅ Passed The changes remain limited to the minimal-code ladder, persisted-state guidance, planning integration, and unchanged guardrails.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch chore/feature-minimal-code-ladder

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 3

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In @.claude/skills/feature/SKILL.md:
- Line 141: Update the Phase 0 “Ladder outcome (§4b)” requirement in SKILL.md to
include a “Selected rung” entry identifying the chosen mechanism or explicitly
stating when rung 0 removes it, while retaining the existing rejected-mechanism
and pending-state details.
- Line 124: Update the decision ladder in SKILL.md so rung 0 is terminal only
when the product decision removes the mechanism; when the mechanism remains
required, including accepting its cost or failure, continue through rung 1 and
subsequent reuse, standard-library, and native-platform checks.
- Line 132: Update §5 in SKILL.md to add a distinct, explicit confirmation step
for every persisted policy decision identified by the ladder, and state that
implementation must not begin until the user approves each one. Keep the
existing “awaiting confirmation” tracking, but make approval a blocking
prerequisite rather than part of general validation.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: 5b55bcb6-e724-4279-be95-0950aa301000

📥 Commits

Reviewing files that changed from the base of the PR and between 5d41fe2 and 5575cfa.

📒 Files selected for processing (1)
  • .claude/skills/feature/SKILL.md

Comment thread .claude/skills/feature/SKILL.md Outdated
Comment thread .claude/skills/feature/SKILL.md Outdated
Comment thread .claude/skills/feature/SKILL.md Outdated
…confirmation

Address review feedback on the minimal-code ladder:

Rung 0 now holds only when the mechanism actually disappears. "Accept the
cost" or "surface it to the user" can leave the mechanism required, and the
stop-at-the-first-rung rule would then skip reuse, stdlib, platform features
and the one-liner rung.

Persisted state needs a blocking yes on that specific state, stated both in
the ladder and in the present-plan step, so it is never covered by a general
"plan validated". On the frontend side the rule is scoped to state that is
actually retained or restored: a transient request or response field is not
persisted state.

The presented plan now reports the selected rung, not only the rejected
options, so the decision that was made survives into the implementation.

Claude-Session: https://claude.ai/code/session_019Cow7oT71FcBKpD5brmwBs
@PierreBrisorgueil
PierreBrisorgueil merged commit c5feb80 into master Jul 31, 2026
3 checks passed
@PierreBrisorgueil
PierreBrisorgueil deleted the chore/feature-minimal-code-ladder branch July 31, 2026 07:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

🔧 /feature Phase 1: minimal-code decision ladder

1 participant