Codex Session Handoff
Purpose
Keep a project-local restart document current so a fresh coding agent can resume work without replaying the full conversation.
Treat the handoff as an engineering checkpoint, not as a narrative recap.
When To Use
handoff 만들어줘
HANDOFF.md 갱신해줘
새 채팅으로 넘길 개발 요약 작성해줘
continue in a new Codex chat
leave a restart note for the next agent
prepare a transfer artifact for this coding task
Do not use this skill for resumes, career documents, investing discussions, or casual conversation summaries.
Operating Model
- Confirm the request is about preserving development context.
- Choose the handoff location.
- Read the current handoff file first if it already exists.
- Rebuild the current state from the thread and the local repo.
- Replace stale notes with current facts.
- Write the refreshed handoff file.
- Tell the user what file was created or updated and what still needs verification.
Target File Policy
- Default target: project root
HANDOFF.md
- If
docs/HANDOFF.md already exists, update that file instead of creating a second document
- If the user explicitly asks for a different location, use the requested path
- Never create both
HANDOFF.md and docs/HANDOFF.md unless the user explicitly asks for duplicate copies
Source Material
Prefer confirmed local state over memory. Pull from:
- the latest user goal and scope changes
- files changed, inspected, or still pending
- repo status and recent command results
- test, build, lint, or runtime verification already performed
- blockers, rejected approaches, assumptions, and constraints
- currently relevant services, ports, and environment details
If local repo state is available, these checks are usually enough:
git status --short --branch
git diff --stat
- targeted reads of touched files
- fast verification commands only when they are already known, cheap, or necessary to avoid writing something false
Do not inflate the handoff with speculative details or expensive reconnaissance.
Writing Rules
- Prefer concrete facts over prose.
- If something is unknown, write
unknown.
- Remove outdated next steps when they no longer match reality.
- Preserve decisions that matter for future work.
- Call out anything the next agent should avoid repeating.
- Never include secrets, tokens, passwords, or credential values.
Handoff Template
Write the handoff file in Markdown using these sections and this order.
OBJECTIVE
- Original user goal
- Latest user instruction or scope change
SESSION SNAPSHOT
- One of
complete, in_progress, blocked, iterating
- One sentence on current progress
WORK COMPLETED
- Concrete completed work
- Important findings and conclusions
- Work explicitly ruled out
- Work that must not be redone
PROJECT SURFACE
changed: path and what changed
inspected: path and why it mattered
pending: path and what still needs work
- Include line references when useful
REPO CHECKPOINT
- Current branch
- Staged changes
- Unstaged changes
- Recent commits if relevant
- Conflict, merge, or rebase state if relevant
VALIDATION
- Important commands run
- Build, test, lint, and runtime checks
- Separate
verified from not_verified
- Include error text only when it affects continuation
DECISIONS
- Key technical decisions and rationale
- Rejected approaches that should not be retried without new evidence
- Constraints, assumptions, blockers, and risks
OPERATING CONTEXT
- Running dev servers, ports, background processes, and required services
- Local environment assumptions
- Never include credentials
RESUME HERE
- The exact first thing the next Codex turn should do
- Mention what remains unverified
Response To The User
After writing the file:
- Report the exact path written.
- Summarize whether this was a create or update.
- Mention any important unknowns or unverified areas.
- Do not dump the entire handoff file into chat unless the user asks.
Style
- Use short bullets, not long paragraphs.
- Prefer exact paths, commands, branch names, statuses, and ports.
- Be concise and operational.
- Preserve momentum and avoid reopening settled decisions.
- If code changed, explicitly state what changed, what was verified, and what still needs verification.
1---2name: codex-session-handoff3description: Maintain a resume-ready transition file for active software projects. Use when the user asks to prepare a handoff, refresh HANDOFF.md, capture current engineering state before switching chats, preserve progress before a major refactor, or leave a clean restart point for another Codex session or coding agent. Reconcile any existing HANDOFF.md with the latest repo state, verification results, constraints, and next move. Do not use for generic summaries or non-development topics.4---56# Codex Session Handoff78## Purpose910Keep a project-local restart document current so a fresh coding agent can resume work without replaying the full conversation.11Treat the handoff as an engineering checkpoint, not as a narrative recap.1213## When To Use1415- `handoff 만들어줘`16- `HANDOFF.md 갱신해줘`17- `새 채팅으로 넘길 개발 요약 작성해줘`18- `continue in a new Codex chat`19- `leave a restart note for the next agent`20- `prepare a transfer artifact for this coding task`2122Do not use this skill for resumes, career documents, investing discussions, or casual conversation summaries.2324## Operating Model25261. Confirm the request is about preserving development context.272. Choose the handoff location.283. Read the current handoff file first if it already exists.294. Rebuild the current state from the thread and the local repo.305. Replace stale notes with current facts.316. Write the refreshed handoff file.327. Tell the user what file was created or updated and what still needs verification.3334## Target File Policy3536- Default target: project root `HANDOFF.md`37- If `docs/HANDOFF.md` already exists, update that file instead of creating a second document38- If the user explicitly asks for a different location, use the requested path39- Never create both `HANDOFF.md` and `docs/HANDOFF.md` unless the user explicitly asks for duplicate copies4041## Source Material4243Prefer confirmed local state over memory. Pull from:4445- the latest user goal and scope changes46- files changed, inspected, or still pending47- repo status and recent command results48- test, build, lint, or runtime verification already performed49- blockers, rejected approaches, assumptions, and constraints50- currently relevant services, ports, and environment details5152If local repo state is available, these checks are usually enough:5354- `git status --short --branch`55- `git diff --stat`56- targeted reads of touched files57- fast verification commands only when they are already known, cheap, or necessary to avoid writing something false5859Do not inflate the handoff with speculative details or expensive reconnaissance.6061## Writing Rules6263- Prefer concrete facts over prose.64- If something is unknown, write `unknown`.65- Remove outdated next steps when they no longer match reality.66- Preserve decisions that matter for future work.67- Call out anything the next agent should avoid repeating.68- Never include secrets, tokens, passwords, or credential values.6970## Handoff Template7172Write the handoff file in Markdown using these sections and this order.7374### OBJECTIVE7576- Original user goal77- Latest user instruction or scope change7879### SESSION SNAPSHOT8081- One of `complete`, `in_progress`, `blocked`, `iterating`82- One sentence on current progress8384### WORK COMPLETED8586- Concrete completed work87- Important findings and conclusions88- Work explicitly ruled out89- Work that must not be redone9091### PROJECT SURFACE9293- `changed`: path and what changed94- `inspected`: path and why it mattered95- `pending`: path and what still needs work96- Include line references when useful9798### REPO CHECKPOINT99100- Current branch101- Staged changes102- Unstaged changes103- Recent commits if relevant104- Conflict, merge, or rebase state if relevant105106### VALIDATION107108- Important commands run109- Build, test, lint, and runtime checks110- Separate `verified` from `not_verified`111- Include error text only when it affects continuation112113### DECISIONS114115- Key technical decisions and rationale116- Rejected approaches that should not be retried without new evidence117- Constraints, assumptions, blockers, and risks118119### OPERATING CONTEXT120121- Running dev servers, ports, background processes, and required services122- Local environment assumptions123- Never include credentials124125### RESUME HERE126127- The exact first thing the next Codex turn should do128- Mention what remains unverified129130## Response To The User131132After writing the file:133134- Report the exact path written.135- Summarize whether this was a create or update.136- Mention any important unknowns or unverified areas.137- Do not dump the entire handoff file into chat unless the user asks.138139## Style140141- Use short bullets, not long paragraphs.142- Prefer exact paths, commands, branch names, statuses, and ports.143- Be concise and operational.144- Preserve momentum and avoid reopening settled decisions.145- If code changed, explicitly state what changed, what was verified, and what still needs verification.