swarm: Skill for Claude Code

.skills/session-close/SKILL.md

session-close is a skill for Claude Code from swarm-ai-research/swarm. It costs 38 tokens per session (508 once invoked), scanned A, original, MIT.

An end-of-session checklist for a research repository. It reviews changes and findings, updates project memory files, and commits and pushes the work.

In plain words
What is it for?
Use it to summarize changed files and research findings, update persistent session notes, record run references, and save the session's work to version control.
Why use it?
It reduces the chance of losing important context, results, or unfinished plans when a work session ends.

Skill for Claude Code

Written for Claude Code: allowed-tools in frontmatter.

This is swarm-ai-research/swarm's own configuration. It tells Claude Code how to work on swarm itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything swarm configures →

Reuse

Borrowing it

Nothing to install: this file belongs to swarm-ai-research/swarm. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/swarm-ai-research/swarm/main/.skills/session-close/SKILL.md
Clone the repo
git clone --depth 1 https://github.com/swarm-ai-research/swarm

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for session-close

README.md
[![agentmods](https://agentmods.dev/badge/skills/swarm-ai-research/swarm/session-close.svg)](https://agentmods.dev/skills/swarm-ai-research/swarm/session-close)
Your own site
<a href="https://agentmods.dev/skills/swarm-ai-research/swarm/session-close"><img src="https://agentmods.dev/badge/skills/swarm-ai-research/swarm/session-close.svg" alt="Measured on agentmods" height="20"></a>
Per session 38 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 508 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00038 $0.00508
Opus 5 $0.00019 $0.00254
Sonnet 5 $0.00008 $0.00102
Haiku 4.5 $0.00004 $0.00051

Measured 4d ago against content hash 52027ac792e9, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-08, from the pricing page.

Security

Grade A, and why

session-close scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 4d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.skills/session-close/SKILL.md · 86 lines

What it actually says

EXECUTE NOW

Run all steps sequentially. Do not skip any step.


Step 1: Inventory changes

git status
git diff --stat

List all modified, added, and deleted files.

Step 2: Summarize the session

Answer these questions by reviewing the conversation history and current state:

  1. What changed? — files modified, runs completed, claims updated
  2. What did we learn? — key findings, surprises, pattern changes
  3. What's next? — the most valuable next experiment or task
  4. What should I remember? — decisions made, preferences expressed, context that would be lost

Step 3: Update memory

Update .letta/memory/threads/research-log.md

Append a session entry:

## {date} — {session focus}

**Ran:** {experiments or tasks completed}
**Found:** {key results}
**Learned:** {insights}
**Next:** {next steps}
**Run pointers:** {run_ids if any}

Update .letta/memory/threads/current.md

Replace the content with:

  • Current hypothesis (carried forward or updated)
  • What we're testing next
  • This session's summary (moved to "Last session summary")
  • Next experiment
  • Any blockers

Update .letta/memory/runs/latest.md

Add any new run pointers to the table.

Step 4: Commit and push

git add <changed files>         # stage code changes
bd sync                         # sync beads
git commit -m "<summary>"       # commit with descriptive message
bd sync                         # sync any new beads changes
git push                        # push to remote

Step 5: Confirm

Print:

Session closed.

Summary: {one-line summary}
Memory updated: threads/current.md, threads/research-log.md
Committed: {commit hash}
Pushed: {branch}

Next session: {what to do first}
Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 4d ago First seen · 86 lines · 38 tokens per session scan A 52027ac792e9

Subscribe to this mod's changes

session-close is a skill published in the GitHub repository swarm-ai-research/swarm (41 stars, last pushed today), licensed MIT. It adds 38 tokens to every session and 508 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.