edit

edit is a command for Claude Code from arielaizn/grok-plugin-cc. It costs 11 tokens per session (388 once invoked), scanned A, original, MIT.

A command that edits an existing image with Grok while preserving parts not mentioned in the instruction.

In plain words
What is it for?
Use it to make targeted changes to one or more image files, with the edited copies saved separately.
Why use it?
It changes a source image without recreating the whole scene, reducing the risk of losing the original subject or details.

Command for Claude Code

Written for Claude Code: allowed-tools in frontmatter.

Runs only inside its plugin — its command needs a path that Claude Code sets for a plugin’s own hooks and for nothing else. Install the plugin, not this.

Part of the grok plugin — 3 skills, 9 commands, 1 agent shipped together

Good fit Use it to make targeted changes to one or more image files, with the edited copies saved separately.

Compare 6 commands from other repositories ↓
Install

Getting it into your agent

This one installs as part of its plugin. Adding the marketplace and installing the plugin brings it with everything else the plugin ships.

Claude Code
/plugin marketplace add arielaizn/grok-plugin-cc
Claude Code
/plugin install grok

Made for: Claude Code.

Or install grok, the plugin that ships this one along with the rest of its 3 skills, 9 commands, 1 agent.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for edit

README.md
[![agentmods](https://agentmods.dev/badge/commands/arielaizn/grok-plugin-cc/edit/github.svg)](https://agentmods.dev/commands/arielaizn/grok-plugin-cc/edit)
Your own site
<a href="https://agentmods.dev/commands/arielaizn/grok-plugin-cc/edit"><img src="https://agentmods.dev/badge/commands/arielaizn/grok-plugin-cc/edit/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for edit

Your own site · 80×15
<a href="https://agentmods.dev/commands/arielaizn/grok-plugin-cc/edit"><img src="https://agentmods.dev/badge/commands/arielaizn/grok-plugin-cc/edit.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 11 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 388 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00011 $0.00388
Opus 5.5 $0.00004 $0.00155
Sonnet 5.5 $0.00002 $0.00078
Haiku 4.5 $0.00001 $0.00039

Measured 1mo ago against content hash 3b4fdbdbf3fa, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

edit scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

plugins/grok/commands/edit.md · 41 lines

What it actually says

Edit an existing image with Grok's image_edit tool.

Raw slash-command arguments: $ARGUMENTS

Argument handling:

  • --image is required and repeatable; each one is a path to a source image, or a data: URL.
  • If the user described an image but gave no --image, find the file first (Glob) and confirm the path with them rather than guessing.
  • Pass the instruction through verbatim. Describe only what changes — image_edit preserves everything the instruction does not mention, so extra scene description works against the edit.
  • Use this, not /grok:image, whenever there is a source image: re-generating from scratch will not preserve the subject.

Execution — foreground by default, roughly 25 seconds:

node "${CLAUDE_PLUGIN_ROOT}/scripts/grok-companion.mjs" edit $ARGUMENTS

Background, when the user asked for it or requested several variations:

Bash({
  command: `node "${CLAUDE_PLUGIN_ROOT}/scripts/grok-companion.mjs" edit $ARGUMENTS`,
  description: "Grok image edit",
  run_in_background: true
})

Output rules:

  • Relay the companion's output, then Read each saved file so the user can see the result.
  • The source image is never modified; edits are written as new files.
  • To iterate, run /grok:edit again against the newest output rather than re-running the original edit.
  • If the run failed, relay the reason verbatim and do not retry automatically.
Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 1mo ago First seen · 41 lines · 11 tokens per session scan A 3b4fdbdbf3fa

Subscribe to this mod's changes

edit is a command published in the GitHub repository arielaizn/grok-plugin-cc (6 stars, last pushed 2mo ago), licensed MIT. It adds 11 tokens to every session and 388 once invoked, about $0.0000 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.