Skip to content
Claude Code Mods

Claude Code mod replay-theater

Source verified. Source URL responded on 2026-10-10. Not a security review.Source only
  • Workflow
  • Quality
License
Apache-2.0

Anthropic's sample mod that adds /replay, a pane that steps through the file edits Claude made in the last turn, one diff at a time.

Notice

Anthropic shares this sample mod as it is, without support. Its README says it is not an official Anthropic product and that no support or maintenance is implied. It needs Claude Code 2.1.287 or later, where mods load by default.

On this page

What it does

While a turn runs, it records each Edit, Write and MultiEdit call: the file, and the text before and after. When the turn ends, a one-line hint above the prompt gives the number of edits and a Replay button.

The pane shows one edit at a time: the file, the tool, a count of added and removed lines, and a diff in red and green. A strip of numbered cells shows every step with the current one highlighted, and the header reads, for example, step 2 of 5.

How it works

The hooks module is hooks/replay-theater.mjs, and hooks/hooks.json points to it.

session.start: registers the /replay command with $.command.register. command.run on replay: opens the pane and replies with the number of edits, or says there were no edits in the last turn.

tool.call: records each file edit and always passes the call on with next(e). For Write, it reads the old text from disk just before the write.

turn.start and turn.complete: group the edits by turn and skip subagent turns. When a turn with edits completes, the hint is drawn.

ui.render on the AbovePrompt component draws the hint, and ui.render on the Pane component draws the replay with Button elements. ui.close notes that the pane was closed, so the hint can show again.

Set up

The README asks for Claude Code 2.1.287 or later, where mods load by default. Check yours with claude --version. It needs no environment variables or configuration.

Run these from the claude-code/mods folder of a clone (see Download the source). The first command checks the plugin and lists its hooks. The second loads it for one session only.

To keep it, add the folder as a local marketplace and install it from claude-code-playground-mods, as the last two commands do. The official mods overview notes that this marketplace points at your clone, so the mod stops loading if you move or delete the clone.

If you install it from your shell while a session is open, run /reload-plugins in that session to load it. To confirm it loaded, run /plugin: a dim line under the tabs names the mods the session loaded.

It needs a terminal. The pane is placed inline above the prompt, or docked to the right in the fullscreen layout.

Ask Claude for a change that edits files, for example to rename a function everywhere. When the turn ends, type /replay and press Enter, or press ctrl+x then Tab to focus the band above the prompt and press r.

claude plugin validate ./replay-theater

claude --plugin-dir ./replay-theater

claude plugin marketplace add ./

claude plugin install replay-theater@claude-code-playground-mods --scope user

Download the source

The source lives in the claude-code/mods/replay-theater folder of the anthropics/claude-code-playground repository, beside the two other sample mods. The README's steps clone the whole repository and go to the mods folder, which is the folder the set up commands run from.

The repository's LICENSE is the Apache License 2.0, and the hooks module carries the header SPDX-License-Identifier: Apache-2.0. The repository README says the DevRel team maintains it, that entries are provided as is with no support and no guarantee they still work, and that it is not accepting outside contributions yet.

git clone https://github.com/anthropics/claude-code-playground.git

cd claude-code-playground/claude-code/mods

Using the pane

Press n for the next step, p for the previous step, and c or Escape to close the pane. Mouse clicks on the buttons work too.

The replay stays available until the next turn that edits files. A turn with no edits keeps the previous replay.

Limitations

The diff shows up to 12 lines per step. For Edit, it is between old_string and new_string, not the whole file, and line numbers aren't shown. For Write, files over 400 lines are shown as all removed, then all added.

Edits are recorded when the tool is called, so an edit you then deny, or that fails, still shows. Edits made by subagents are included in the main turn's replay. The replay is kept in memory for the current session only.

The README says the MultiEdit path and the fallback to the band above the prompt are untested, and that the band is shared: if another mod also draws there, only one of them shows.

Hooks it registers

What the badge means

Source verified means the source URL for this entry responded with HTTP 200 on . That is the whole claim. Nobody has read, scanned or run this code on your behalf, and the badge does not mean Anthropic or anyone else endorses it.

Sources change after the check date. Read the code and the publisher page before you install. How to check an extension

  • Plugin

    Source verified. Source URL responded on 2026-09-20. Not a security review.

    hookify

    Create Claude Code hooks from markdown rule files instead of editing hooks.json, or derive rules from your conversation.

    • Workflow
    • Quality
  • Mod

    Built inSource verified. Source URL responded on 2026-10-10. Not a security review.

    agents-md

    Reads AGENTS.md as project instructions the way Claude Code reads CLAUDE.md, chosen by one option, instructionFiles, with four values.

    • Workflow
    • Development
  • Mod

    Built inSource verified. Source URL responded on 2026-10-10. Not a security review.

    diff

    Adds /diff: the session's uncommitted changes in a pane beside the transcript, file by file with their hunks, refreshed as Claude edits files and runs commands.

    • Development
    • Workflow