AgentSkillsCN

remember_session

在工作 session 结束时,回顾当前会话内容,并将重要信息持久化至Obsidian vault中。当用户说“记住这次会话”、“做笔记”或“保存我们所做的一切”时,此技能将发挥重要作用。但切勿在会话进行中使用。

SKILL.md
--- frontmatter
name: remember_session
description: >
  Review the current session and persist what matters to the obsidian vault.
  Use at the end of a work session, when the user says "remember this session",
  "take notes", or "save what we did". Do NOT use mid-session.
allowed-tools: Bash(uv run *), Bash(git *), Read, Write, Glob, Grep

End-of-session ritual. Review what happened, persist what matters, aggregate.

Steps

1. Review the session

Scan the full conversation. Identify:

  • What was done: features built, bugs fixed, decisions made, files changed
  • What was learned: new tools, patterns, preferences, corrections
  • What changed: facts about the user, project, or environment that updated
  • What's pending: TODOs, deferred work, open questions

2. Read today's existing notes

Before writing anything, read today's daily file to see what's already been saved:

bash
uv run --directory MEMORY_SKILL_DIR python scripts/memory.py read-day

Only write notes for topics NOT already captured. Skip duplicates.

3. Save new daily notes

Use the hierarchical_memory skill to save timestamped notes to today's daily file:

bash
uv run --directory MEMORY_SKILL_DIR python scripts/memory.py note "NOTE_TEXT"

Save one note per distinct topic that isn't already in today's file. Include:

  • Completed work (prefix with DONE:)
  • Decisions and their rationale
  • New preferences or corrections the user made
  • Remaining TODOs (prefix with TODO:)
  • Facts that changed (new job, new tool, moved repo, etc.)

Be specific. "Updated auth" is useless. "Replaced JWT middleware with session cookies because latency was too high on mobile" is useful.

Use [[wiki-links]] to connect related notes. Link to existing obsidian notes by filename (without .md). For example: See [[authentication-architecture]] or Related to [[2026-02-08]].

4. Save big-picture items to obsidian notes

If the session produced anything worth finding later — a new project, an architectural decision, a research finding, a personal milestone — create or update a note in the obsidian vault using the obsidian skill.

Daily work goes to memory/ subdirectory via hierarchical_memory. Durable knowledge goes to knowledge_graph/ topic notes in the vault.

5. Aggregate memory

If any note outputs showed stale aggregations (e.g. Aggregation stale: 2026-02 CREATE, overall UPDATE), run the monthly and overall memory aggregation sub-agents from the hierarchical_memory skill for those items. If all notes said Aggregation: up to date, skip this step.

6. Commit and push

Everything is in the obsidian vault now — one commit covers both memory and notes:

bash
git -C $CLAUDE_OBSIDIAN_DIR add -A && git -C $CLAUDE_OBSIDIAN_DIR commit -m "session update" && git -C $CLAUDE_OBSIDIAN_DIR push