agentleFS
youcislayoucisla/Agent-Foundry/skills/core/session-closeout/SKILL.md

session-closeout

Skill1 starsChanged 23 days agoMITView on GitHub

'Before ending a session: reconcile changed files, update docs and changelog,

4 other projects use a version of this.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

4 rules. 0 are common, 2 are distinctive, and 2 are very specific to this project.

  • 0

    Common

    Most of the 4 edited versions we read keep these.

  • 2

    Distinctive

    This author's own choices. Worth a look.

  • 2

    Very specific

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

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    If a surface isn't applicable, tag it n/a — don't fabricate evidence.

    line 31
  2. Distinctive:

    Do the closeout. The cost is 2 minutes.

    line 57
  3. Very specific:

    Every exit path writes a terminal status: completed, failed, or interrupted.

    line 77
  4. Distinctive:

    Check that every output reference resolves before closeout.

    line 79

“Common” is measured: kept by at least 6 in 10 of the 4 edited versions of this file we could read. “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

Session Closeout

A session that ends without closeout is work that has to be redone. Apply at the end of any multi-step project, before /reset, before stopping for the day, or before handing to someone else.

Procedure

The 6 surfaces

Reconcile each before declaring done. Tag with status: verified / pending / not-applicable.

SurfaceQuestionEvidence
CodeWhat did we actually change?git diff + tests passing
RuntimeDoes it actually work?Live URL, deployed artifact, manual test
DocsCan a new person understand what we built?README, changelog, inline comments
RulesAre the constraints the next session will see still correct?CLAUDE.md / hooks
MemoryIs there anything the next session should know that isn't in code or docs?Note to self, vault entry
WorkspaceAny untracked files, stale branches, temp dirs?git status clean, no .tmp

If a surface isn't applicable, tag it n/a — don't fabricate evidence.

The handoff note

End every multi-step session with a handoff. Format:

## Handoff — <date>

**Done:** [list of completed work, with PR/branch links]
**In progress:** [what was started but not finished]
**Loose ends:** [bugs, tech debt, follow-ups]
**Decisions:** [non-obvious choices and why]
**Next steps:** [what to do first next session, in order]

Save it: commit to the repo, paste it as the session's last message, both.

When to skip

  • Single-question Q&A
  • Throwaway experiments
  • Sessions that produced nothing (deleted the work, no code change)

When in doubt

Do the closeout. The cost is 2 minutes. The cost of NOT doing it is the next session starting from zero.

Anti-patterns

  • Ending with "done" while work sits uncommitted or untested.
  • Fabricating evidence for a surface that was not checked.
  • Deleting artifacts instead of recording retention.
  • Leaving a running status as a permanent state.

Verification Checklist

  • All six surfaces are tagged verified, pending, or n/a.
  • Runtime behavior was checked, not inferred.
  • Handoff note has done, in-progress, loose ends, next steps.
  • Every output reference resolves.
  • Workspace has no unexplained untracked or temp files.

Terminal State

  • Every exit path writes a terminal status: completed, failed, or interrupted. A crash must leave running as an unambiguous signal, not a permanent lie.
  • Repair stale running rows at startup with an explicit age threshold.
  • Check that every output reference resolves before closeout; a dangling locator is a data-loss report.
  • Recompute derived aggregates only after the terminal write, and record the config fingerprint used.
  • Closeout is not deletion: keep summaries and artifact references, drop only what retention policy names.

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.