agentleFS
yeaight7yeaight7/agent-powerups/skills/handoff-discipline/SKILL.md

handoff-discipline

Skill6 starsChanged 4 months agoApache-2.0View on GitHub

Use when ending a session, handing a task back to the user, or approaching the context limit with work unfinished -- the next session or engineer must be able to resume the work instantly.

1 other project uses a version of this.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

3 rules. About 0 are common, 3 are distinctive, and 0 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈3

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    When ending a session, handing a task back to the user, or preparing to swap to a new context window, you must leave a clean paper trail — …

    line 8
  2. Distinctive:

    Leave a breadcrumb: If the task is incomplete, summarize the last successful step, the current failing step, and the *exact next command* …

    line 25
  3. Distinctive:

    Commit or stash: Ensure the working directory is clean.

    line 27

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Purpose

When ending a session, handing a task back to the user, or preparing to swap to a new context window, you must leave a clean paper trail — exactly what the next session or human engineer needs to resume work instantly.

When to Use

  • A task ends (complete or not) and someone else picks it up next
  • The context window is nearly full mid-task
  • Work is blocked and must pause on an external dependency

Inputs

  • The session's actual state: what ran, what passed, what is mid-flight
  • The repo's working-tree status

Workflow

  1. State the end condition. Explain exactly why you are stopping (e.g., "Task complete", "Blocked on PR", "Context window too large").
  2. Leave a breadcrumb. If the task is incomplete, summarize the last successful step, the current failing step, and the exact next command to run. Record discovered constraints and dead ends so the next session doesn't retry them.
  3. Commit or stash. Ensure the working directory is clean. Either commit the work, tell the user to commit, or stash it. Do not leave unverified messy state:

    git status --short                     # what is uncommitted?
    git stash push -m "handoff: <task>"    # if not committing
  4. Link the work. Provide file paths to the modified files or generated artifacts so the next agent/user doesn't have to search for them.
  5. Write the handoff summary (a handoff markdown file, or the final message) using this exact structure:

    ### 1. Goal
    [1-2 sentences on what we were trying to do]
    
    ### 2. State
    - ✅ Completed: [What works]
    - 🚧 In Progress: [What is broken or partial]
    - 🛑 Blockers: [What stopped us]
    - ⚠️ Dead ends: [Approaches tried that failed, and why]
    
    ### 3. Next Steps
    1. Run `npm test ...`
    2. Fix the error in `src/foo.ts` around line X.

Output

  • A handoff summary in the Goal / State / Next Steps format
  • A clean, committed, or explicitly stashed working tree, with artifact paths linked

Verification

  • End condition stated explicitly
  • Next command is runnable verbatim by the next session — no "continue where I left off"
  • Working tree clean, committed, or stashed — confirmed with git status, not assumed
  • Every modified or generated file linked by path
  • State section separates completed, in-progress, and blocked honestly

Failure Modes

  • Vague resumption — "continue the refactor" instead of the exact failing step and next command.
  • Dirty-tree handoff — uncommitted, unexplained changes the next session must reverse-engineer.
  • Completed-only reporting — hiding the broken parts makes the handoff a trap.
  • Unlinked artifacts — the next agent burns context searching for files you could have named.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.