codex-session-recovery

Session recovery: restore Codex or Claude sessions from tmux panes, saved cockpit snapshots, session history, and recent agent logs without overwriting useful recovery evidence. Intended for pane crashes, detachments, loss of visible context, recovery of commands, or when a safe, targeted recovery plan is required.

Last repository push
GitHub Stars
111
Forks
9
Issues / PRs
0

Installation

Review the source and dependencies with a prompt. A package is available to download.

Install with an AI assistant

Copy the prompt so your assistant can review the pinned revision and dependencies first.

View promptHide prompt
Check whether SkillPI Skill Finder is installed for your current agent. If it is missing, install and enable it using the official instructions at https://github.com/Findskills/skillpi. Then use Skill Finder to locate and install "codex-session-recovery" from this exact SkillPI detail page: https://skillpi.com/skills/deepskill-677ddc9d3a76702abe745a2fdc6ed81d2a4abcd1d17cb1c56cb56cf0c606bb03. Verify the upstream source and version against https://github.com/vincentkoc/dotskills before installing. If they do not match, stop and report the mismatch. Report the installed path and source version.

Source and setup

github.com

Setup guidance pending

See the original source for supported tools, dependencies, and permissions.

Installation test pending

Session recovery: restore Codex or Claude sessions from tmux panes, saved cockpit snapshots, session history, and recent agent logs without overwriting useful recovery evidence. Intended for pane crashes, detachments, loss of visible context, recovery of commands, or when a safe, targeted recovery plan is required.

0 Downloads

Introduction source: third_party · vincentkoc · 0.0.1 Reference

SkillPi interpretation

Tasks
Recover Codex or Claude sessions from tmux panes, saved cockpit snapshots, session history, and recent agent logs without overwriting useful restore evidence. Use when a pane crashes, detaches, loses visible context, needs a resume command, or requires a safe targeted restore plan.
Audience
Recover a Codex, Claude, or tmux cockpit session. Find an exact `codex resume <id>` command. Preview or restore saved pane/window/session state. Repair missing snapshot history or tmux menu bindings.
Inputs and outputs
Optional tmux pane or window target. Optional saved snapshot path. Optional mode: session-ID lookup, preview, targeted restore, or menu repair. Optional local snapshot helper such as `tt`.
Software, accounts and paid services
Not specified in the source documentation.
Limits and differences
Not specified in the source documentation.
Testing
Not tested

Browse files

Browse files at the source ↗

Original SKILL.md

Open original ↗
Frontmatter
name: codex-session-recovery
description: Recover Codex or Claude sessions from tmux panes, saved cockpit snapshots, session history, and recent agent logs without overwriting useful restore evidence. Use when a pane crashes, detaches, loses visible context, needs a resume command, or requires a safe targeted restore plan.
license: MIT
metadata:
  source: "https://github.com/vincentkoc/dotskills"

Codex Session Recovery

Purpose

Recover crashed, detached, or confusing agent sessions while preserving the best restore source.

When to use

  • Recover a Codex, Claude, or tmux cockpit session.
  • Find an exact codex resume <id> command.
  • Preview or restore saved pane/window/session state.
  • Repair missing snapshot history or tmux menu bindings.

Workflow

  1. Preserve evidence before writing state.
    • Do not create a new snapshot until the restore candidate is known.
    • Do not run repair commands that overwrite history.
    • Set a recovery pane title when possible.
  2. Inspect live tmux state.
    • tmux display-message -p '#S:#I.#P #{pane_current_command} #{pane_current_path}'
    • tmux list-panes -a -F '#S:#I.#P #{pane_pid} #{pane_current_command} #{pane_current_path}'
    • Inspect relevant key bindings before re-sourcing tmux configuration.
  3. Inspect available recovery sources.
    • Prefer the operator's snapshot/history helper when installed.
    • Inspect recent ~/.codex/sessions/YYYY/MM/DD/*.jsonl metadata for session IDs and working directories.
    • Cross-check pane PIDs, cwd, and recent logs before selecting a session.
  4. Produce a dry-run plan first.
    • Prefer one-pane or one-window restore over whole-session restore.
    • Show the snapshot or session ID, target pane, and exact command.
  5. Execute only with clear intent.
    • Require explicit intent before restore commands that mutate tmux state.
    • Never kill broad Codex, Claude, tmux, or terminal processes from name matches alone.
    • Restrict cleanup to the exact pane, PID, process group, or current-task resource.
  6. Stay narrow for session-ID requests.
    • Return the concrete ID and codex resume <id> first.
    • Add the broader recovery method only when requested.

Inputs

  • Optional tmux pane or window target.
  • Optional saved snapshot path.
  • Optional mode: session-ID lookup, preview, targeted restore, or menu repair.
  • Optional local snapshot helper such as tt.

Outputs

  • Exact resume command when available.
  • Selected restore source and target.
  • Dry-run restore plan before execution.
  • Concise blocker when evidence is insufficient.

Flow

stateDiagram-v2
    [*] --> PreserveRestoreEvidence
    PreserveRestoreEvidence --> MatchSourceAndTarget
    MatchSourceAndTarget --> ReportUnknown: identity or source ambiguous
    MatchSourceAndTarget --> ReturnResumeID: session-ID lookup
    MatchSourceAndTarget --> ShowExactPlan: preview or recovery
    ShowExactPlan --> ReportPlan: preview only or mutation not authorized
    ShowExactPlan --> TargetedRecovery: exact mutation authorized
    TargetedRecovery --> VerifyTarget
    VerifyTarget --> ReportResult
    ReportUnknown --> [*]
    ReturnResumeID --> [*]
    ReportPlan --> [*]
    ReportResult --> [*]

Version history

  1. v0.4.0 GitHub ↗
    Original release notes

    ## Install `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.4.0 --skill agent-device-lab -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.4.0 --skill codebase-memory-mcp -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.4.0 --skill codex-goal-mining -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.4.0 --skill codex-session-recovery -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.4.0 --skill crabpot-perf-metrics -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.4.0 --skill crawlkit -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.4.0 --skill ghcrawl-cluster-operator -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.4.0 --skill github-airplane-mode -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.4.0 --skill graincrawl -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.4.0 --skill openclaw-github-dedupe -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.4.0 --skill openclaw-pr-batch-sweep -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.4.0 --skill operations-worktree -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.4.0 --skill opik-integrations-auditor -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.4.0 --skill opik-optimizer -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.4.0 --skill org-branch-cleanup -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.4.0 --skill semantic-slicing -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.4.0 --skill session-done -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.4.0 --skill technical-deslop -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.4.0 --skill technical-documentation -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.4.0 --skill technical-integrations -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.4.0 --skill technical-skill-finder -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.4.0 --skill tmux-agent-lane-orchestrator -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.4.0 --skill tmux-lane-orchestrator -y` ## Delta Compared to `v0.3.0`. Changed skill paths: `skills/agent-device-lab skills/codebase-memory-mcp skills/codex-goal-mining skills/codex-session-recovery skills/crabpot-perf-metrics skills/crawlkit skills/ghcrawl-cluster-operator skills/github-airplane-mode skills/graincrawl skills/openclaw-github-dedupe skills/openclaw-pr-batch-sweep skills/operations-worktree skills/opik-integrations-auditor skills/opik-optimizer skills/org-branch-cleanup skills/semantic-slicing skills/session-done skills/technical-deslop skills/technical-documentation skills/technical-integrations skills/technical-skill-finder skills/tmux-agent-lane-orchestrator skills/tmux-lane-orchestrator`

  2. v0.3.0 GitHub ↗
    Original release notes

    ## Install `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.3.0 --skill codebase-memory-mcp -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.3.0 --skill codex-goal-mining -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.3.0 --skill codex-session-recovery -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.3.0 --skill crabpot-perf-metrics -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.3.0 --skill crawlkit -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.3.0 --skill ghcrawl-cluster-operator -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.3.0 --skill github-airplane-mode -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.3.0 --skill graincrawl -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.3.0 --skill openclaw-github-dedupe -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.3.0 --skill openclaw-pr-batch-sweep -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.3.0 --skill operations-worktree -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.3.0 --skill opik-integrations-auditor -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.3.0 --skill opik-optimizer -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.3.0 --skill org-branch-cleanup -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.3.0 --skill semantic-slicing -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.3.0 --skill technical-deslop -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.3.0 --skill technical-documentation -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.3.0 --skill technical-integrations -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.3.0 --skill technical-skill-finder -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.3.0 --skill tmux-agent-lane-orchestrator -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.3.0 --skill tmux-lane-orchestrator -y` ## Delta Compared to `v0.2.1`. Changed skill paths: `skills/codebase-memory-mcp skills/github-airplane-mode skills/org-branch-cleanup`

  3. v0.2.1 GitHub ↗
    Original release notes

    ## Install `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.1 --skill codebase-memory-mcp -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.1 --skill codex-goal-mining -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.1 --skill codex-session-recovery -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.1 --skill crabpot-perf-metrics -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.1 --skill crawlkit -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.1 --skill ghcrawl-cluster-operator -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.1 --skill graincrawl -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.1 --skill openclaw-github-dedupe -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.1 --skill openclaw-pr-batch-sweep -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.1 --skill operations-worktree -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.1 --skill opik-integrations-auditor -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.1 --skill opik-optimizer -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.1 --skill semantic-slicing -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.1 --skill technical-deslop -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.1 --skill technical-documentation -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.1 --skill technical-integrations -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.1 --skill technical-skill-finder -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.1 --skill tmux-agent-lane-orchestrator -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.1 --skill tmux-lane-orchestrator -y` ## Delta Compared to `v0.2.0`. Changed skill paths: `skills/openclaw-pr-batch-sweep`

  4. v0.2.0 GitHub ↗
    Original release notes

    ## Install `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.0 --skill codebase-memory-mcp -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.0 --skill codex-goal-mining -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.0 --skill codex-session-recovery -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.0 --skill crabpot-perf-metrics -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.0 --skill crawlkit -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.0 --skill ghcrawl-cluster-operator -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.0 --skill graincrawl -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.0 --skill openclaw-github-dedupe -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.0 --skill openclaw-pr-batch-sweep -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.0 --skill operations-worktree -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.0 --skill opik-integrations-auditor -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.0 --skill opik-optimizer -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.0 --skill semantic-slicing -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.0 --skill technical-deslop -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.0 --skill technical-documentation -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.0 --skill technical-integrations -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.0 --skill technical-skill-finder -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.0 --skill tmux-agent-lane-orchestrator -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.2.0 --skill tmux-lane-orchestrator -y` ## Delta Compared to `v0.1.7`. Changed skill paths: `skills/codebase-memory-mcp skills/codex-goal-mining skills/codex-session-recovery skills/crabpot-perf-metrics skills/crawlkit skills/example-skill skills/ghcrawl-cluster-operator skills/graincrawl skills/openclaw-github-dedupe skills/openclaw-pr-batch-sweep skills/operations-worktree skills/opik-integrations-auditor skills/opik-optimizer skills/semantic-slicing skills/technical-deslop skills/technical-documentation skills/technical-integrations skills/technical-skill-finder skills/tmux-agent-lane-orchestrator skills/tmux-lane-orchestrator`

  5. v0.1.7 GitHub ↗
    Original release notes

    ## Install `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.1.7 --skill openclaw-github-dedupe -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.1.7 --skill technical-deslop -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.1.7 --skill technical-documentation -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.1.7 --skill technical-integrations -y` `npx skills add https://github.com/vincentkoc/dotskills/tree/v0.1.7 --skill technical-skill-finder -y` ## Delta Compared to `v0.1.6`. Changed skill paths: `skills/openclaw-github-dedupe`

Only the five most recent versions are shown. View full version history at the source ↗

Current listing version

0.0.1

Verify the source revision ↗

Safety and assessment details

Quality assessment

Out of 100 · Assessment report from SkillPi LAB.

Scenario Value92/100

Highlights

  • 解决开发者会话丢失的高频痛点
  • 提供安全且有针对性的恢复机制
Trigger Precision95/100

Highlights

  • 触发场景描述精准完整
  • 边界清晰无歧义
Structure and Standards90/100

Highlights

  • 流程步骤清晰且含 mermaid 图示
  • frontmatter 完整规范
Execution Reliability90/100

Highlights

  • 强调 dry-run 与显式授权
  • 避免覆盖证据与宽泛 kill
Evidence Verifiability (mean of the first four)92/100

The arithmetic mean of the first four original scores, rounded to a whole number.

Static text checks

100 / 100 · skillpi-20261123-no-r3-v1

No current rules matched the text.

This score reflects rule matches in the text and is provided for reference before use. It excludes attachments and runtime behavior.

Permissions and checks before use

Automatically summarized from this main document. Matches may be examples or defensive advice; they are not actual permission declarations. Attachments, external dependencies and runtime behavior are not covered.

These common operations were not identified in the main document. This does not mean no permissions or risks exist.

Domains or addresses referenced in the document

These addresses may be documentation links or examples, not an approved network allowlist. Verify actual destinations and outgoing data before use.

  • github.com

These notices grant no permissions. Your host tool must still confirm file changes, secrets, external transfers or costs as needed.

Security rating and access scope

safe · Static evidence review; not a runtime safety guarantee.

Not specified in the source documentation.

Before use, confirm and authorize actual file access, external services and network destinations in your host. This review grants no runtime permissions.