wrap

An end-of-session command for harvesting learning from the current conversation into a knowledge graph. It also updates the spaced-repetition schedule and can optionally create a snapshot.

In plain words
What is it for?
Use it to review demonstrated knowledge, update topic notes and review timing, and optionally save a snapshot of the learning state.
Why use it?
It helps preserve useful lessons from a coding session instead of leaving them only in the conversation history.

Command

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add commands/gf-labs/ramp/wrap
Clone the repo
git clone --depth 1 https://github.com/gf-labs/ramp
Per session 15 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,290 The whole file, excluding the scripts and references it only reads on demand.
Security scan B 1 finding. Scan, not verified.
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 $0.00015 $0.01290
Opus 5 $0.00008 $0.00645
Sonnet 5 $0.00003 $0.00258
Haiku 4.5 $0.00002 $0.00129

Measured 2d ago against content hash 900a33db72e6, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade B, and why

wrap scanned grade B with 1 finding 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 2d 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.

Reads agent configuration directoriesmediumAgent snooping

.claude/, .codex/, .gemini/ hold keys, settings and other credentials a mod has no legitimate need for.

!`FIRST=$(echo "$ARGUMENTS" | awk '{print tolower($1)}'); if [ -n "$FIRST" ] && { [ -f "$HOME/.claude/ramp/schemas/$FIRST.md" ] || [ -f ".claude/knowledge-graphs/schemas/$FIRST.md" ]; }; then TOPIC="$FIRST"; else TOPIC="
commands/wrap.md · 122 lines

How it starts

The opening of the file, as written. The whole thing — 122 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Context

Requested topic: $ARGUMENTS

Active topic: !FIRST=$(echo "$ARGUMENTS" | awk '{print tolower($1)}'); if [ -n "$FIRST" ] && { [ -f "$HOME/.claude/ramp/schemas/$FIRST.md" ] || [ -f ".claude/knowledge-graphs/schemas/$FIRST.md" ]; }; then echo "$FIRST"; else echo "claude-code"; fi

Today's date: !date +%Y-%m-%d

Knowledge graph (active topic): !FIRST=$(echo "$ARGUMENTS" | awk '{print tolower($1)}'); if [ -n "$FIRST" ] && { [ -f "$HOME/.claude/ramp/schemas/$FIRST.md" ] || [ -f ".claude/knowledge-graphs/schemas/$FIRST.md" ]; }; then TOPIC="$FIRST"; else TOPIC="claude-code"; fi; cat ~/.claude/ramp/graphs/$TOPIC.md 2>/dev/null || echo "NO_TREE_FILE:$TOPIC"

All available topics: !ls ~/.claude/ramp/graphs/*.md 2>/dev/null | xargs -I{} basename {} .md | sort || echo "none"


Your role

You are the end-of-session knowledge harvester for ramp. Work through the steps below in order. Each step waits for the user's reply before proceeding. Do not skip steps unless the user says skip.


Step 0 — Reflect

Scan the current session's conversation for evidence of demonstrated knowledge:

  • Tool use patterns (Write, Edit, Bash, MCP calls, Agent launches)
  • Exercises completed, configurations made, commands run
  • Teaching-level explanations given (not just "I've used this")
  • Artifacts created or modified

Produce a private working list of candidate nodes (do not show yet). Each entry:

[node name] | current status | proposed status | one-line evidence

If no demonstrable activity detected for any knowledge graph node: say "No node upgrades detected this session — nothing to harvest." Offer Step 3 (optional snapshot) anyway.


Step 1 — Propose upgrades

Show the candidate list one topic group at a time:

Proposed upgrades for [topic] — [date]:

[ ] Node name → [✓|exercise] — [evidence note]
[~] Node name → [✓|exercise] — [evidence note]
...

Rules:

  • Only propose [ ][✓|exercise] or [~][✓|exercise] (never downgrade)
  • Evidence note must be specific: what was done, not just "used in session"
  • [✓] nodes already demonstrated: skip unless SR interval should reset (rare)

Read the full file on GitHub · 122 lines

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. 2d ago First seen · 122 lines · 15 tokens per session scan B 900a33db72e6

Subscribe to this mod's changes

wrap is a command published in the GitHub repository gf-labs/ramp (2 stars, last pushed 1mo ago), licensed MIT. It adds 15 tokens to every session and 1,290 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it B with 1 finding (reads agent configuration directories). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.