Develop AI Agent Skills from pull requests, code reviews, and the evidence behind a merge. Preserve the alternatives a team considered, the contracts it protected, and the conditions it verified.
Keep the judgment behind the code change
Illustrative pull request / #248
Validate mode while preserving existing behavior
Follow the review
Review context
A proposed input rule changes how existing callers are handled.
request_policy.pseudoIllustrative pseudocode
1when mode is missing or unknown:
2 return a validation error
3otherwise:
4 use the selected mode
A
Author
“Reject missing and unknown values so every call has an explicit mode.”
Reasoning to retain
Find the assumption in the proposed change
The proposal treats an omitted field and an invalid value as the same case. That assumption becomes the focus of review.
request_policy.pseudoIllustrative pseudocode
1when mode is missing:
2 use the legacy default
3when mode is unknown:
4 return a validation error
5otherwise:
6 use the selected mode
R
Reviewer
“Existing clients omit this field. Keep the legacy default for those calls. An unknown value can still be rejected.”
Reasoning to retain
Preserve the reason for the exception
The default exists for callers that already rely on it. Keep that compatibility requirement attached to the code that implements it.
“Record missing, recognized, and unknown values as separate cases. Keep the result and tested revision with this review.”
Reasoning to retain
Carry the tested boundary into the skill
The cases make the expected behavior explicit. Their recorded results and the reviewed revision establish what the team actually verified.
An illustrative source study. The explanation stays attached to the change it shaped.
The opportunity
Recover the decision that survived review
The merged code records the chosen behavior. Review history explains why the team chose it, which alternatives it ruled out, and what another engineer must understand before changing it again.
Bring that judgment into AI Agent Skill development. Help an agent surface a compatibility concern, ask about an overlooked case, or point a reviewer to the source of an existing constraint.
01 / Trace the decision
The discarded proposal still explains the design
Reconstruct how the answer changed through review. A rejected approach can reveal a requirement that is difficult to infer from the final code alone.
Alternative considered
“Require an explicit mode on every call.”
The reviewer identified existing callers that omit the field. The revised proposal preserves their default behavior.
A readable history for expert examination: proposal, challenge, revision, and the evidence retained at merge.
02 / Preserve the behavior contract
Three inputs. Three decisions worth keeping distinct
The review separates omission, a recognized value, and an unknown value. Preserve those cases, their expected behavior, and the evidence an expert needs to check the reasoning.
AI Agent Skill candidate / Review a compatibility-sensitive change
Input casemode: omitted
→
Expected behavior
Legacy default
An omitted field preserves the behavior existing callers relied on. The skill should surface this contract when reviewing a similar change.
Confirm with the expert
Which callers still depend on the default?
Input casemode: recognized
→
Expected behavior
Selected behavior
A recognized value follows the explicit choice. Keep the accepted values and their meaning tied to the reviewed revision.
Confirm with the expert
Does the meaning of this value match the current contract?
Input casemode: unknown
→
Expected behavior
Validation error
An unsupported value is a separate case from omission. Preserve the review’s distinction and ask the owner how invalid input should be handled.
Confirm with the expert
Which response is expected for an unsupported value?
These illustrative expectations come from the review. Recorded test results establish what passed in a particular revision and environment.
Begin with a review worth preserving
Bring the pull request that changed the team’s thinking
Choose a change, the review that shaped it, and a maintainer who can explain the tradeoff. Explore how that engineering judgment could become an AI Agent Skill.