Simon-rss

Undokey — AI skill for Claude Code

AI community

A universal undo key for AI coding agents (Codex, OpenCode, Claude Code, Antigravity) — filesystem checkpoints + Codex conversation rewind.

How to install Undokey

This entry records only its repository, not the path inside it, so there is no exact command to give. Open Simon-rss/undokey and copy the folder into ~/.claude/skills/, or the file into ~/.claude/agents/.

What Undokey does

A universal undo key for AI coding agents (Codex, OpenCode, Claude Code, Antigravity) — filesystem checkpoints + Codex conversation rewind.

Alternatives in AI

  • Codesight — Universal AI context generator 979 ★
  • Engrim — The Universal Cross-Model Episodic Memory Standard 219 ★
  • Agent Manager X — A macOS desktop app to monitor your Claude Code, Codex, OpenCode AI coding agents in real-time with voice or b 73 ★

README

undokey

[![CI](https://github.com/Simon-rss/undokey/actions/workflows/ci.yml/badge.svg)](https://github.com/Simon-rss/undokey/actions/workflows/ci.yml) [![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](./LICENSE) [![Python 3.9+](https://img.shields.io/badge/Python-3.9%2B-3776AB.svg)](./pyproject.toml)

**A universal undo key for AI coding agents.**

Every tool call your agent makes becomes a restorable filesystem checkpoint — across **Codex CLI**, **OpenCode**, **Claude Code**, and **Antigravity** — without ever touching your project's `.git`.

For **Codex**, `undokey rewind --chat` rewinds **both your files and the conversation** (by forking the rollout into a new session; the original session stays untouched).

[中文文档](./README.zh-CN.md)

![undokey demo](./docs/demo.gif)


Why

  • Codex removed /undo (and /rewind for code + chat is still one of the top open requests).
  • You switch between agents — Codex, Claude Code, OpenCode, Antigravity — and each one has a different (or missing) checkpoint story.
  • git checkout isn't enough when an agent edits uncommitted work, creates new files, deletes untracked files, or runs destructive shell commands mid-turn.

`undokey` sits at the filesystem layer behind your agents' native lifecycle hooks. It snapshots into an isolated shadow git repository under `~/.undokey/`, so:

  • Your project's .git, staging index, commits, and stashes are never touched.
  • Every restore takes a snapshot first — even an undo can be undone.
  • Pure Python standard library, zero runtime dependencies (Python ≥ 3.9 + git).

Install

With [uv](https://docs.astral.sh/uv/) (recommended):

uv tool install git+https://github.com/Simon-rss/undokey.git

With `pipx` or `pip`:

pipx install git+https://github.com/Simon-rss/undokey.git
# or
pip install git+https://github.com/Simon-rss/undokey.git

Or from a local clone:

git clone https://github.com/Simon-rss/und