GPT 6 PROMPT
Hand off a reviewed code change
Give the next engineer a concise, verifiable implementation handoff.
Complete prompt
Task
Give the next engineer a concise, verifiable implementation handoff.
Instructions
Prepare a handoff for [CHANGE] in [REPOSITORY]. Lead with the behavior that changed and why. Name files and key decisions, show the command and observed result for each relevant test, and separate verified behavior from unresolved risks. Identify what the reviewer should inspect and any deployment or migration step that remains. Do not claim a release or API test from a local pass.
Expected output
Behavior summary, evidence links or file paths, verification table, and remaining work.
Checks
- A reviewer can rerun the reported checks.
- The handoff distinguishes local verification from release status.
- Open issues have an owner or explicit next step.Expected output and checks
Expected output
Behavior summary, evidence links or file paths, verification table, and remaining work.
Checks
- A reviewer can rerun the reported checks.
- The handoff distinguishes local verification from release status.
- Open issues have an owner or explicit next step.
Worked example
Worked example: Hand off a reviewed code change
Original input
Prepare a handoff for the synthetic pagination helper repair from original.js to corrected.js in the isolated gpt6-family-refresh/evidence/family-refresh/sol fixture. Lead with the behavior that changed and why. Name files and key decisions, show the command and observed result for each relevant test, and separate verified behavior from unresolved risks. Identify what the reviewer should inspect and any deployment or migration step that remains. Do not claim a release or API test from a local pass.
Contract and task input:
# Frozen task input — synthetic pagination review
Date: 2026-09-24. Runner: Codex delegated task using GPT-6 Sol. This is a local sample, not a paid API request or a model benchmark.
Review `original.js` as a JavaScript helper for an item list. The public contract is `paginate(items, { page = 1, pageSize = 10, status })`, returning `{ items, page, pageSize, total, totalPages }`. `status`, when supplied, matches `item.status` exactly. `page` and `pageSize` must be positive integers; invalid values should throw `RangeError`. Filter the complete input before slicing. `total` counts matching items, `totalPages` is based on that count, and a page beyond the end returns an empty `items` array. Do not mutate the input.
Find concrete correctness defects with reproductions. Then write `corrected.js` and automated tests that cover `page = 0`, invalid sizes, filtering before pagination, matching total, and useful nearby boundaries. Run the test command and retain its raw output. Explain exactly which behavior was observed. Use only the synthetic fixture; do not change the live site helper or claim that an API benchmark was run.
Input source: `original.js` in this directory, saved before correction.
Original source:
```js
// Synthetic review fixture. Intentionally defective; do not use in production.
function paginate(items, { page = 1, pageSize = 10, status } = {}) {
const start = (page - 1) * pageSize;
const pageItems = items.slice(start, start + pageSize);
const visibleItems = status
? pageItems.filter((item) => item.status === status)
: pageItems;
return {
items: visibleItems,
page,
pageSize,
total: items.length,
totalPages: Math.ceil(items.length / pageSize),
};
}
module.exports = { paginate };
```
Corrected source:
```js
function paginate(items, { page = 1, pageSize = 10, status } = {}) {
if (!Number.isInteger(page) || page < 1) {
throw new RangeError('page must be a positive integer');
}
if (!Number.isInteger(pageSize) || pageSize < 1) {
throw new RangeError('pageSize must be a positive integer');
}
const matchingItems = status === undefined
? items
: items.filter((item) => item.status === status);
const total = matchingItems.length;
const start = (page - 1) * pageSize;
return {
items: matchingItems.slice(start, start + pageSize),
page,
pageSize,
total,
totalPages: Math.ceil(total / pageSize),
};
}
module.exports = { paginate };
```
Recorded test-run.txt:
runAtUtc=2026-09-24T07:14:05Z
v26.3.0
originalExit=1
correctedExit=0
Raw logs: original-test-output.txt and corrected-test-output.txt. This is a local fixture with no service deployment.What the checks found
- Handoff names behavior, source files, and repeatable commands.
- Observed status is distinct from remaining integration checks.
- No deployment or API execution was inferred.
Original output
## Behavior delivered
The synthetic `paginate` helper now rejects invalid page inputs and forms each page from the full set of matching records. For `open, closed, open, closed, open` with page 1 and size 2, output changes from ID 1 / `total: 5` / `totalPages: 3` to IDs 1 and 3 / `total: 3` / `totalPages: 2`.
## Files and decisions
`original.js` is the frozen defective fixture; `corrected.js` contains the repair; `pagination.test.js` covers six behavior groups. `task-input.md` records the contract. The decision to treat `status: ''` as supplied comes from the contract's “when supplied” wording. Empty matching sets return `totalPages: 0`; pages past the end return empty items.
## Verification for reviewer
From `evidence/family-refresh/sol`, run `PAGINATION_TARGET=./original.js node --test pagination.test.js` (observed exit 1, 1/6 pass) and `node --test pagination.test.js` (observed exit 0, 6/6 pass). The handoff rerun at 2026-09-24T07:24:38Z exited 0; see `handoff-test.txt` and `handoff-run.txt`. Review the validation and filter/slice order in `corrected.js`, then inspect the no-match and out-of-range tests. This isolated fixture has no endpoint or deployment step; integration behavior remains outside this handoff.Files from this run