工作进度保存与恢复
work-session
跨中断的会话保留工作进度。结束工作时使用 ‘/work-session save’,重新开始时使用的 ‘/work-session restore’。
- License 许可
- Apache-2.0
- 最近更新
- 2026-11-14
- Stars
- ★ 0
- Forks
- 0
01 前言 Front Matter
- name
- work-session
- license
- Apache-2.0
- metadata
- { "author": "wangxu-dev", "version": "0.0.1", "argument-hint": "<save|restore>" }
- description
- Preserve work progress across disconnected sessions. Use '/work-session save' when ending work, '/work-session restore' when starting fresh.
02 资源文件 3
- 参考文档metadata.json520 B
- 参考文档README.md1.6 KB
- 参考文档skill.meta.json344 B
03 SKILL.md 正文
Work Session Context Preservation
Maintain development continuity across disconnected conversations by preserving progress, modified files, TODOs, and git state in a durable session file, with minimal console output.
Commands
| Command | When to Use | Behavior |
|---|---|---|
/work-session save |
End of work session | Write current state to .session.md (primary output). Console output should be a short confirmation only. |
/work-session restore |
Start of new session | If .session.md exists: read → display summary to user → load context → delete file |
How It Works
End of session (with context):
/work-session save
→ Analyze conversation → Save to .session.md (rich detail) → Print brief confirmation only
Start of new session (file exists):
/work-session restore
→ Read .session.md → Display summary → Delete file
Start of new session (no file found):
/work-session restore
→ Report "No saved session found" and explain how to save at end of work
Session File Format
.session.md is stored at project root (gitignored). It should be detailed and practical, capturing concrete work done and what remains. Keep it concise enough to scan, but not overly compressed.
# Work Session (2026-01-18 18:45)
## Summary
- Completed JWT token refresh logic in auth module
## Files Modified
- apps/back/src/modules/auth/routes.ts:75-82
- apps/back/src/modules/auth/middleware.ts
## TODOs
- [ ] Add token expiration error handling
## Next Steps
- Implement error handling for expired tokens
## Git State
- Branch: feature/auth-refresh
- Uncommitted changes: true
Save Behavior (End of Work)
When saving, analyze the full working context (conversation + commands run + files touched + decisions made) and extract:
- Summary: What was accomplished (2-5 sentences)
- Developer-Style Notes: Capture the developer's phrasing, priorities, and intent when clear; keep tone plain and factual
- Detailed Progress: Concrete steps taken, decisions made, partial implementations, and current status
- Files Modified: List files with line numbers if applicable
- Current TODOs: Capture any tracked TODOs
- Next Steps Hint: Predict what might come next based on context
- Open Questions: Any unresolved questions, blockers, or ambiguity
- Git State: Current branch and uncommitted status
Output format (file content):
Session saved at 18:45
Summary:
- Completed JWT token refresh logic in auth module
- Modified apps/back/src/modules/auth/routes.ts:75-82
Developer-Style Notes:
- Keep responses terse, avoid console spam; focus on practical next actions
Detailed Progress:
- Added refresh flow with rotation
- Updated middleware to read new token location
- Left TODO comments for error edge cases
TODOs preserved:
- [ ] Add token expiration error handling
Next session may continue with error handling implementation.
Open Questions:
- Decide whether to expire refresh token on login or on first use
Git State:
- Branch: feature/auth-refresh
- Uncommitted changes: true
Console output (save):
Session saved to .session.md
Restore Behavior (Start of Work)
When restoring, display the saved context, load it into the assistant's working context, state that it was consumed, and immediately delete the file.
Output format:
Restoring session from 18:45 (2 days ago)
Previous work:
- Completed JWT token refresh logic in auth module
- Modified apps/back/src/modules/auth/routes.ts:75-82
Detailed Progress:
- Added refresh flow with rotation
- Updated middleware to read new token location
- Left TODO comments for error edge cases
TODOs:
- [ ] Add token expiration error handling
Context hints:
- Branch: feature/auth-refresh
- Uncommitted changes detected
Session record consumed and deleted.
Ready to continue with error handling, or something else?
If no session file is found:
No saved session found.
Tip: Use /work-session save at the end of work to preserve context.
Strict Guidelines
Prohibited Behaviors
- Do not use flattery or self-aggrandizing language
- Do not ask "Do you want to do this?" repeatedly
- Do not output irrelevant or tangential information
- Do not make assumptions about user preferences during save
- Do not keep the session file after restore (must delete)
- Do not store secrets, credentials, tokens, personal data, or private file contents
Required Behaviors
- Save: Automatically analyze and summarize without asking questions; write a detailed, practical record to
.session.md - Restore: Load context, display it, delete file, then wait for user direction
- Privacy: If sensitive data appears in context, omit it and keep only safe, high-level summaries
- Tone: Neutral, concise, factual
- Focus: Maximum context preservation with minimum noise; avoid console spam
Accuracy and Voice
- Prefer concrete facts over guesswork; if unsure, mark as "uncertain".
- Preserve the developer's intent and preferred style when it is clearly expressed.
- Avoid flattery, moralizing, or euphemisms; keep it plain and direct.
Usage
# End of work (save current session)
/work-session save
# Start of new work (restore previous session)
/work-session restore
Workflow:
Day 1 Evening: /work-session save
Day 2 Morning: /work-session restore
04 同仓库更多 Skills
Excel 电子表格处理
xlsx
当电子表格文件是主要输入或输出时,使用本技能。即用户想要执行以下任意任务:打开、读取、编辑或修复现有的 .xlsx、.xlsm、.xltx、.csv 或 .tsv 文件(例如添加列、计算公式、设置格式、制作图表、清理杂乱数据);从零开始或从其他数据源创建新的电子表格;或在表格文件格式之间进行转换。尤其当用户按名称或路径提及某个电子表格文件时触发——即使是随意提及(如“我下载文件夹里的 xlsx”)——并希望对其进行处理或从中生成内容。也适用于将杂乱的表格数据文件(格式错误的数据行、错位的表头、垃圾数据)清理或重组为规范的电子表格。交付物必须是电子表格文件。当主要交付物是 Word 文档、HTML 报告、独立的 Python 脚本、数据库管道或 Google Sheets API 集成时,不要触发,即使涉及表格数据。
Web 应用自动化测试工具
webapp-testing
使用 Playwright 与本地 Web 应用程序进行交互和测试的工具包。支持验证前端功能、调试 UI 行为、捕获浏览器截图以及查看浏览器日志。
Web 工件构建工具
web-artifacts-builder
一套工具,用于使用现代前端 Web 技术(React、Tailwind CSS、shadcn/ui)创建精细的、多组件的 claude.ai HTML 工件。适用于需要状态管理、路由或 shadcn/ui 组件的复杂工件,不适用于简单的单文件 HTML/JSX 工件。
作品主题样式设置
theme-factory
用于为作品应用主题样式的工具包。这些作品可以是幻灯片、文档、报告、HTML 落地页等。提供 10 个包含颜色和字体的预设主题,可应用于任何已创建的作品,也可以即时生成新主题。
Slack 动图 GIF 制作
slack-gif-creator
用于创建针对 Slack 优化的动画 GIF 的知识和工具。提供相关约束条件、验证工具和动画概念。当用户请求制作用于 Slack 的动画 GIF 时使用,例如“帮我做一个 X 做 Y 的 GIF 用于 Slack”。
技能创建与优化
skill-creator
创建新技能、修改和改进现有技能,并衡量技能性能。当用户想要从零开始创建技能、编辑或优化现有技能、运行评测以测试技能、通过方差分析对技能性能进行基准测试,或优化技能描述以提高触发准确率时使用。