skills/close-session/SKILL.md
--- name: close-session description: End-of-session durability checklist that makes clearing context safe. Runs mechanical checks (uncommitted changes, unpushed commits, open PRs, chat-only decisions, new domain terms, ROADMAP staleness, memory entries) and either resolves each inline or queues it as a GitHub issue, ADR, wiki page, or memory note. The point is to walk away knowing nothing important lives only in this conversation. Triggers on "close session", "close the session", "wrap up the se
npx skillsauth add RonanCodes/ronan-skills skills/close-sessionInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Run before clearing context, switching tasks, or stepping away. The goal: every important thing from this session lives in a durable place by the time you finish — code, GitHub issue, ADR, CONTEXT.md, wiki page, ROADMAP entry, log entry, or memory note. Nothing important left stranded in the chat transcript.
User says any of:
/clear or starting a structurally different taskDo NOT use for:
Run in order. Each check is a separate AskUserQuestion so the user can resolve, queue, or skip per item.
Checks 1–4 are the mechanical sweep, shared with /ro:handoff. Don't hand-run the git/gh commands here — invoke /ro:session-state, which prints a structured inventory (uncommitted changes, unpushed commits, open PRs, in-flight branch vs issue) and a verdict. Resolve each finding it reports using the actions documented in checks 1–4 below. Keeping detection in one skill means close-session and handoff never drift; the check bodies below are the resolution reference.
git status --porcelain
If any:
git diff --stat)./ro:commit) / stash / discard with confirmation / leave for next session (note in chat why).git log @{u}..HEAD --oneline 2>/dev/null
If any:
Memory feedback_commit_and_push.md says push regularly on ralph/autonomous work; outside those modes, "leave" is fine.
gh pr list --author @me --state open --json number,title,url,statusCheckRollup,mergeable
For each open PR:
/ro:gh-ship to drive it forward / leave for review / close.git branch --show-current
gh issue list --search "<branch-keywords>" --state all --limit 5
If the current branch's work isn't represented by an open GH issue (and the repo has a gh remote):
/ro:write-a-prd --target gh for a feature, or a quick gh issue create for a bug).ready-for-agent: offer to label it.The reflective check. Ask the user directly:
"Looking back at this session — was there anything decided in conversation that isn't yet in code, an ADR, a GH issue, a Jira ticket, a Confluence page, a CONTEXT.md entry, or a wiki page?"
If yes, for each decision:
docs/adr/000N-*.md inline)/ro:jira create/ro:confluence createPartner-visibility heuristic — auto-suggest Jira/Confluence routing when:
~/Dev/<partner-project>*)When that fires, the Atlassian options (/ro:jira create, /ro:confluence create) jump to the top of the destination list. Internal-only decisions still default to GH issue.
If the user can't recall, prompt with categories: "anything about architecture? domain terms? scope changes? things you tried and rejected? anything Taskforce should see?" Memory feedback_call_out_assumptions.md — do not invent decisions; if the user says nothing material happened, accept that.
Skip unless the session touched the dataforce repo or any DAFO ticket was referenced in chat.
If it did:
/ro:jira move <KEY> "In Review" (PR merged, not yet live) or /ro:jira move <KEY> done (live in production — the strict rule from the partnership chat)./ro:confluence link.This check enforces the partnership convention: Jira reflects partner-facing state, and the move to Done only happens when shipped.
Skill scans for capitalised domain-sounding nouns in this session's git diffs and conversation that aren't already in CONTEXT.md:
grep -Eo '\b[A-Z][a-zA-Z]+\b' <session-touched-files> | sort -u
# diff against CONTEXT.md term list
If candidates surface:
CONTEXT.md under ## Language with a one-sentence definition. Use the format in grill-with-docs/CONTEXT-FORMAT.md.If the session touched a vault under vaults/<name>/:
vaults/<name>/ROADMAP.md. Did anything move (In progress → Recently completed)? Anything new in Next up?vaults/<name>/log.md. Is the tail entry for today's session?/ingest session --vault <name> to do this properly. That skill writes the session source-note, appends ROADMAP, appends log.md, and routes graduate-worthy knowledge to Hub vaults.--vault <name> flag forces a specific vault; otherwise auto-detect by working directory or by files touched this session.
The kind of thing that earns a memory entry (per the auto-memory rules):
Ask: "Anything from this session worth saving as a persistent memory (feedback rule, project state, reference pointer, user fact)?"
If yes: skill drafts the memory entry (see ~/CLAUDE.md § auto memory for types and structure), shows to user, writes to ~/.claude/projects/<project-slug>/memory/<file>.md and appends to that project's MEMORY.md index. Per feedback_call_out_assumptions.md: do not invent. Only save what the user actually said or what is clearly load-bearing.
Did this session reveal a tool that should exist? A manual multi-step dance that should be a skill, heavy context-filling work that should be an agent, a repeatable workflow the user described, or friction on an existing skill that warrants an edit?
Invoke /ro:capability-retro (it scans this session, dedups against the live registry,
and proposes create/edit candidates; --apply to act on the approved ones). Defer to
that skill — don't re-derive the logic here. Deferred candidates land in a
ready-for-agent issue so the gap survives the clear.
After all 9 checks, print a single-line status:
✓ Clean to clear context.
• <N> commits pushed
• <N> issues created
• <N> ADRs written
• <N> wiki pages updated (vault: <name>)
• <N> memory entries saved
• <N> items deliberately left (with reasons)
If anything's still open ("there's an uncommitted change you said leave for next session"), repeat it back so the user starts the next session knowing it.
After the wrap-up summary, print a SESSION CLOSED ASCII banner via a single cat << 'EOF' heredoc. The point is a hard visual full-stop, so that when the user scans across terminal tabs it is instantly obvious this session is done. Print it even on --quick / --reflective runs.
Shape (adapt the body lines to the actual session, keep the big banner + a closing flourish):
╔══════════════════════════════════════════════════════════════════════════╗
║ ███████ ███████ ███████ ███████ ██ ██████ ███ ██ ║
║ ██ ██ ██ ██ ██ ██ ██ ████ ██ ║
║ ███████ █████ ███████ ███████ ██ ██ ██ ██ ██ ██ ║
║ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ║
║ ███████ ███████ ███████ ███████ ██ ██████ ██ ████ ║
║ ║
║ ██████ ██ ██████ ███████ ███████ ██████ ║
║ ██ ██ ██ ██ ██ ██ ██ ██ ║
║ ██ ██ ██ ██ ███████ █████ ██ ██ ║
║ ██ ██ ██ ██ ██ ██ ██ ██ ║
║ ██████ ███████ ██████ ███████ ███████ ██████ ║
╚══════════════════════════════════════════════════════════════════════════╝
.--------------------------------------------------.
| <repo / vault name> |
| ├─ pushed ✔ <N> commits → <remote> |
| ├─ <headline of what shipped> ✔ |
| ├─ ROADMAP / log / index updated ✔ |
| └─ memory saved + indexed ✔ |
'--------------------------------------------------'
\ ^__^
\ (oo)\_______
(__)\ )\/\
||----w |
|| || everything's away. go rest.
┌───────────────────────────────────────────────────────────────────────┐
│ OPEN LOOP → <the one thing waiting for next session, or "none"> │
└───────────────────────────────────────────────────────────────────────┘
Rules:
OPEN LOOP → none. clean break.SESSION CLOSED wordmark itself stays fixed so it is recognisable tab-to-tab.--quick — run only checks 1, 2, 3 (mechanical state). Skip reflective + vault + memory. Use when you're not really closing, just stepping away briefly.--reflective — run only checks 5, 6, 8, 9. Skip mechanical. Use when state is already clean but you want to capture knowledge.--vault <name> — force the vault routing in check 7 to a specific vault. Otherwise auto-detect.--skip <n> — skip a numbered check (repeatable, e.g. --skip 4 --skip 6).The LLM Wiki system is built around durable state: GH issues, ADRs, CONTEXT.md, wiki pages, ROADMAP, log, memory. The Pocock pattern operationalises that for project repos. But durability only works if there's a discipline that moves the conversation's loose state into durable form before context clears. Without it, even a perfectly-shaped system leaks knowledge every session.
This skill is the discipline.
[[session-state]] — the shared mechanical sweep (checks 1–4); also run by /ro:handoff.[[handoff]] — the "I'm continuing elsewhere" sibling: captures state to one file + ensures issues exist, then you clear. close-session is for "I'm done"; handoff is for "pick this up later".[[ingest-session]] — the vault-side counterpart; this skill delegates to it for check 7.[[agentic-e2e-flow]] — the start-of-session counterpart for feature work.[[pickup]] — the re-entry skill for vaults (project-side equivalent is on the roadmap).[[agent-native-repo-pocock]] — the pattern that makes durable state actually capture-able./ro:jira, /ro:confluence, /ro:jira-to-gh — Atlassian capture surfaces invoked from Check 5 and Check 5b for partner-visible work.testing
--- name: linear-pipeline description: The Fable orchestrator for a single dispatched Linear ticket. Holds almost no context itself; it receives `--issue <ID> --detached`, decides the stage sequence, and fans out a sub-agent per stage, passing forward only each stage's artifact (never re-derived, never inlined into its own context). Step zero, before any planning or stage routing, is a boundary triage against `canon/security-boundary.md` (#199): a match tags Ronan Connolly and stops the run, no
development
--- name: in-your-face description: Capture a chat-only answer into a durable artifact (markdown + HTML, PDF when cheap) and launch it automatically so the user cannot miss it. Use when user says "in your face", "don't let me lose this", "save that answer", "make that durable", or right after answering a substantive side question (a recipe, comparison, how-to, or generated prompt) that would otherwise die with the context. category: workflow argument-hint: [--no-open] [--vault <short>] [hint of
tools
One-shot headless OpenAI Codex CLI calls for background/admin AI tasks — summaries, classification, extraction, admin glue. The default engine for anything that runs AI constantly in the background (daemon-driven, per-event), because it bills the flat ChatGPT subscription instead of Claude usage or per-token API spend, and it keeps working while Claude is rate-limited. NEVER for coding — coding stays Claude. Use when a skill or daemon needs a cheap always-on AI call, when the user says "use codex", "ask codex", "codex as backup", or when building a background summarizer/classifier into a listener or loop. Reads auth from ~/.codex/auth.json (ChatGPT account, no API key).
research
Turn a warranty rejection, repair quote, or RMA email into a cited decision brief — legal read (NL/EU consumer law), is the part user-serviceable, live part and new-unit prices, repair-vs-DIY-vs-new economics, before-you-send-it checklist, deadlines. Use when the user pastes or screenshots a repair quote, warranty rejection, "not covered" email, onderzoekskosten fee, or asks "should I repair or replace this".