Skip to content
Agentmart
Submit a tool

memory

跨会话记忆管理:保存进度 + 提取经验

Skill by chengxuniucode

IndexedMIT★ 2
Write a review

Install

Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.

npx agentmarket install skill/chengxuniucode-memory

Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.

Get the weekly diff

The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.

We use your email only for this newsletter. Privacy

About

跨会话记忆管理:保存进度 + 提取经验

No reviews yet. Installed it? Reviews come from verified installers only. How reviews work

Permissions

What this skill can do and what it asks for, from its SKILL.md. Checked Oct 25, 2026.

Tools
No tools found
Secrets
None asked for
Install scripts
None found

Network hosts it talks to 1

  • codeload.github.com · found in install command

Files it touches

  • ~/.claude/skills/memory

What's inside

Skill name
memory
Description
跨会话记忆管理:保存进度 + 提取经验
License
MIT
Instructions
134 lines in SKILL.md · view on GitHub

Files (1)

  • SKILL.md

SKILL.md (first lines)

# Memory Skill

## 目标

统一管理跨会话记忆:保存当前进度(以便下次恢复)+ 提取可复用经验(让框架越用越聪明)。

## 触发时机

1. **会话结束** — 保存进度快照
2. **ship 之后** — 提取本次交付的经验
3. **debug 解决新问题后** — 记录错误模式和解法
4. **用户手动** — `/memory`

## Part 1: 进度保存(原 checkpoint)

长期记忆只保留可复用信号。每条决策、已知问题或偏好应附任务 ID、可复查证据(文件或命令)、置信度和最后验证时间;低价值或过期记录归档而不反复注入上下文。

### 收集当前状态

```yaml
snapshot:
  timestamp: "{ISO datetime}"
  active_spec: "{slug or null}"
  route_level: "{micro|standard|full}"
  current_phase: "{propose|plan|execute|review|verify|ship}"
  progress:
    total_tasks: N
    completed_tasks: M
    current_task: "{task description}"
  context:
    last_action: "{what was just done}"
    next_action: "{what should happen next}"
    blockers: ["{any blocking issues}"]
  files_modified: ["{file paths}"]
  uncommitted_changes: true|false
```

### 写入 state.md

```markdown
# Current State

## 快照
- 时间: {timestamp}
- Spec: {slug}
- 路由: {route_level}
- 阶段: {phase}
- 进度: {M}/{N} tasks
- 当前: {current task}

## 上下文
- 上一步: {last_action}
- 下一步: {next_action}
- 阻塞: {blockers or "无"}

## 恢复指令
1. 读取本文件了解上下文
2. 读取 specs/active/{slug}/tasks.md 了解完整任务
3. 从 Task {N} 继续执行
```

### 可选 WIP Commit

如果有未提交的变更且已通过编译:
```bash
git add -A
git commit -m "wip: checkpoint - {current task description}"
```

## Part 2: 经验提取(原 learn)

### 学习来源

1. **决策学习** — 非显而易见的技术决策 → `decisions.md`
2. **问题学习** — debug 解决的新问题 → `known-issues.md`
3. **偏好学习** — 用户表达的风格偏好 → `preferences.md`

### 写入格式

**decisions.md 追加**:
```markdown
---

## {date}: {决策标题}

**背景**: {context}
**选项**: {alternatives}
**决策**: {chosen approach}
**原因**: {rationale}
```

**known-issues.md 追加**:
```markdown
---

## {问题标题}

**现象**: {error pattern}
**根因**: {root cause}
**解法**: {solution}
**适用**: {when this applies}
**发现于**: {date}, {spec slug}
```

**preferences.md 更新**:
按类别(代码风格/提交规范/工具偏好/项目特定)组织。

### 去重规则

写入前检查是否已存在相同/相似记录:
- known-issues: 按错误模式匹配
- decisions: 按主题匹配
- preferences: 按类别匹配

如果已存在 → 更新而非重复添加。

## 不做的事

- 不序列化整个对话历史

From chengxuniucode/ForgeTeam, MIT.

More from chengxuniucode/ForgeTeam

Signals

Stars
2
Forks
1
Open issues
0
Last commit (this folder)
Jul 18, 2026 (3 months ago)
Last release
Aug 5, 2026 (2 months ago)

From GitHub (fetched Oct 24, 2026).

Details

License
MIT
First seen
Oct 24, 2026
Last checked
Oct 24, 2026

More from chengxuniucode

Cite this page

memory skill. Agent Mart. https://agentmart.dev/skills/chengxuniucode-memory (last updated 2026-10-24)