gapmiss/claude-sessions/distill
Claude Code and agent skill by gapmiss/claude-sessions
- community
Checking that the SKILL.md file is still in the repository.
Distills the current Claude Code session into a structured Obsidian note with queryable YAML frontmatter. Use when the user wants to capture, summarize, or archive a coding session, for example at the end of a session, when wrapping up work, when asked to save session notes, or when using the /distill command. Produces a markdown file with session metadata, decisions, learnings, and key exchanges.
Install
npx vskill@latest install gapmiss/claude-sessions/distillSKILL.md
/distill: live session distillation
Distill the current Claude Code session into a structured Obsidian note with queryable frontmatter.
CRITICAL: Output the markdown content directly in your text response. Do NOT use Write, Edit, or any file-writing tools. The user will copy the output themselves.
Workflow
- Gather metadata: extract session_id, cwd, git branch, model, start time, token counts, cost, tool usage, and files touched from what is already visible in the conversation (system reminders, git status, prior tool results). Do NOT run Bash or other tools to fetch metadata. Use fallbacks for anything unavailable.
- Classify session type: review the conversation and assign one or more types from the vocabulary below.
- Synthesize content: extract key decisions (with reasoning), non-obvious learnings, and the most important exchanges from the full conversation.
- Write output: output the markdown content directly in your response (NOT using Write or Edit tools). Include the suggested filename per the naming convention.
- Validate output: verify the YAML frontmatter parses correctly and all required fields are present before finalizing. Confirm
session_id,schema_version,project,cwd, andsource_pathare populated; check thatsession_typecontains at least one valid vocabulary term.
Handling Missing Metadata
When a metadata field cannot be determined, apply the following fallbacks rather than omitting the field:
| Field | Fallback value | |
|---|---|---|
session_id | "unknown" | |
branch | "unknown" | |
source_path | "unknown" | |
cost_usd | 0 | |
context_tokens / input_tokens / output_tokens / cache_read_tokens | 0 | |
duration_min | 0 | |
error_count | 0 | |
tools_used | [] | |
files_touched | (omit field) | |
title | (omit field) |
If start_time is unavailable, use the current timestamp and note it is approximate.
Output Format
Write a single markdown file to stdout with this exact structure:
Session Type Vocabulary
Use one or more of these values for session_type:
bug-fix | feature | refactor | exploration | discussion | config | docs | test | review | deploy
Note Naming Convention
{project}--{YYYY-MM-DD}--{short-id}.md
project: sanitized project name (non-alphanumeric → hyphens, lowercase)YYYY-MM-DD: from start_timeshort-id: first 8 characters of session_id
Example: claude-sessions--2026-04-08--a1b2c3d4.md
Frontmatter Field Rules
- Exact values required for:
session_id,schema_version,project,cwd,source_path - Approximate OK for:
duration_min,cost_usd, token counts (Layer 0 will correct) - LLM-only fields:
session_type(you classify), Summary/Decisions/Learnings/Key Exchanges sections - Wikilinks:
files_toucheduses[[path]]syntax for Obsidian linking
Security
- Security scanPassed, 95 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingskills/distill/SKILL.md
Popularity
- 7-day trend score
- 0
Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/gapmiss/claude-sessions/distill)