microsoft/github-vteam-industry-demos/session-recovery
Claude Code and agent skill by microsoft/github-vteam-industry-demos
- vendor
Checking that the SKILL.md file is still in the repository.
Find and resume interrupted Copilot CLI sessions using session_store queries
Install
npx vskill@latest install microsoft/github-vteam-industry-demos/session-recoverySKILL.md
The same SKILL.md was published earlier as github/gh-aw/session-recovery.
Context
Squad agents run in Copilot CLI sessions that can be interrupted — terminal crashes, network drops, machine restarts, or accidental window closes. When this happens, in-progress work may be left in a partially-completed state: branches with uncommitted changes, issues marked in-progress with no active agent, or checkpoints that were never finalized.
Copilot CLI stores session history in a SQLite database called session_store (read-only, accessed via the sql tool with database: "session_store"). This skill teaches agents how to query that store to detect interrupted sessions and resume work.
Patterns
1. Find Recent Sessions
Query the sessions table filtered by time window. Include the last checkpoint to understand where the session stopped:
2. Filter Out Automated Sessions
Automated agents (monitors, keep-alive, heartbeat) create high-volume sessions that obscure human-initiated work. Exclude them:
3. Search by Topic (FTS5)
Use the search_index FTS5 table for keyword search. Expand queries with synonyms since this is keyword-based, not semantic:
4. Search by Working Directory
5. Get Full Session Context Before Resuming
Before resuming, inspect what the session was doing:
6. Detect Orphaned Issue Work
Find sessions that were working on issues but may not have completed:
Cross-reference with gh issue list --label "status:in-progress" to find issues that are marked in-progress but have no active session.
7. Resume a Session
Once you have the session ID:
Examples
Recovering from a crash during PR creation:
- Query recent sessions filtered by branch name
- Find the session that was working on the PR
- Check its last checkpoint — was the code committed? Was the PR created?
- Resume or manually complete the remaining steps
Finding yesterday's work on a feature:
- Use FTS5 search with feature keywords
- Filter to the relevant working directory
- Review checkpoint progress to see how far the session got
- Resume if work remains, or start fresh with the context
Anti-Patterns
- ❌ Searching by partial session IDs — always use full UUIDs
- ❌ Resuming sessions that completed successfully — they have no pending work
- ❌ Using
MATCHwith special characters without escaping — wrap paths in double quotes - ❌ Skipping the automated-session filter — high-volume automated sessions will flood results
- ❌ Assuming FTS5 is semantic search — it's keyword-based; always expand queries with synonyms
- ❌ Ignoring checkpoint data — checkpoints show exactly where the session stopped
Security
- Security scanPassed, 100 of 100Pattern checks on the skill's files. Certified 17 Nov 2026.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingindustries/professional-services/ai-proposal-factory/.github/skills/session-recovery/SKILL.md
Popularity
- Repository stars
- 3
- 7-day trend score
- 0
Stars and forks are for the whole GitHub repository, not this skill alone. 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/microsoft/github-vteam-industry-demos/session-recovery)