grimoire-execute

grimoire-execute is a skill for Claude Code from ojCezarFerreira/Grimoire. It costs 35 tokens per session (2,605 once invoked), scanned C, original, MIT.

A procedure for running a previously planned Grimoire page, where each step is handled by a separate helper agent. After successful execution, it marks that page as finished in the project's history file.

In plain words
What is it for?
Use it to execute step files for a planned Grimoire page, run the prescribed workflow, coordinate helper agents, and update the page status from planned to finished.
Why use it?
It provides a controlled way to carry out documented work while following the project's conventions for tests, comments, commits, and progress tracking. It stops when required planning files or history records are missing.

Skill for Claude Code

Written for Claude Code: argument-hint in frontmatter. Also seen: mentions subagents.

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 grimoire plugin — 11 skills shipped together

Good fit Use it to execute step files for a planned Grimoire page, run the prescribed workflow, coordinate helper agents, and update the page status from planned to finished.

Compare 6 skills 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 ojCezarFerreira/Grimoire
Claude Code
/plugin install grimoire

Made for: Claude Code.

Or install grimoire, the plugin that ships this one along with the rest of its 11 skills.

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 grimoire-execute

README.md
[![agentmods](https://agentmods.dev/badge/skills/ojcezarferreira/grimoire/grimoire-execute.svg)](https://agentmods.dev/skills/ojcezarferreira/grimoire/grimoire-execute)
Your own site
<a href="https://agentmods.dev/skills/ojcezarferreira/grimoire/grimoire-execute"><img src="https://agentmods.dev/badge/skills/ojcezarferreira/grimoire/grimoire-execute.svg" alt="Measured on agentmods" height="20"></a>
Per session 35 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,605 The whole file, excluding the scripts and references it only reads on demand.
Security scan C 1 finding. 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.00035 $0.02605
Opus 5 $0.00017 $0.01303
Sonnet 5 $0.00007 $0.00521
Haiku 4.5 $0.00003 $0.00261

Measured 7d ago against content hash 45ccbdf63cb6, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-08, from the pricing page.

Security

Grade C, and why

grimoire-execute scanned grade C with 1 finding 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 7d 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.

Recursive force deletehighDestructive command

rm -rf with a variable or a broad path is one typo away from removing the wrong tree.

- Run a defensive filesystem `rm -rf` on the worktree directory in case `git worktree remove --force` left residue behind.
skills/grimoire-execute/SKILL.md · 96 lines

How it starts

The opening of the file, as written. The whole thing — 96 lines — stays where its author put it; the contents beside it link to each section on GitHub.

[Required Reading]

  1. Read ${CLAUDE_PLUGIN_ROOT}/GRIMOIRE-CONVENTIONS.md. Its rules (§ TDD, § Code comments, § Sub-agent spawning, § Skill composition, § Parallel execution, § Commits, § .grimoire/ layout, § Project context, § Historic, § User-facing language, § Pause-point pattern) are load-bearing for this skill. Note: this skill only updates the page's HISTORIC.md entry status from [planned] to [finished] — it never appends new entries and never rotates. Bootstrap, append, and rotation are owned by grimoire-spec. This skill requires the page to already be planned ([planned] status in HISTORIC.md, step files present); if not, hard-stop per § Pause-point pattern (grimoire-execute: precondition check).
  2. If .grimoire/PROJECT.md exists in the project root, read it for project context. If it does not exist, proceed without it and suggest the user run grimoire-init once this task is complete.
  3. If .grimoire/HISTORIC.md exists, read it for recent-page context. If older context seems relevant, browse .grimoire/bag/historic/ (newest suffix first). Missing → the page-status check below requires it; treat as a hard-stop unless the page is verifiable through step files alone (see Phase 1).

[Objective] Execute the page identified by:

$ARGUMENTS

[Phase 1: Page Resolution & Precondition Check (HARD STOP)] Per § Pause-point pattern (grimoire-execute: precondition check). Run these checks before spawning any sub-agent; STOP on the first failure with the literal message shown.

  1. Parse the page number. Accept $ARGUMENTS as a bare integer with or without zero-padding (42 or 042); normalize to NNN. Reject anything not parseable as an integer.
  2. Locate the page folder. Glob .grimoire/pages/NNN-*/. Exactly one match expected.
    • No match → ❌ Page NNN does not exist. and STOP.
  3. Confirm step files. Verify at least 1-*.md exists inside the folder.
    • No step files → ❌ Page NNN has no plan yet. Run /grimoire-plan NNN first. and STOP.
  4. Check HISTORIC status. Find the entry whose <page-name> matches the folder.
    • Status [spec]❌ Page NNN is still in spec. Run /grimoire-plan NNN first. and STOP.
    • Status [finished]❌ Page NNN has already been finished. and STOP.
    • Entry missing entirely (rotated mid-execution) → proceed; this is the non-blocking "skip silently if rotated" rule from § Historic. Note this in the run summary.
    • Status [planned] → proceed.
  5. Read all step files in the page folder to understand the full scope of execution. If any step or requirement seems contradictory, ask the user for clarification before starting.
  6. Detect execution mode. Parse each step file's YAML frontmatter:
    • If no step file carries depends-on frontmatter (or the field is missing/empty on every step), select the legacy strict-serial path — proceed to Phase 2A unchanged from prior behavior.
    • If at least one step file carries depends-on frontmatter, select the parallel-wave path per § Parallel execution:
      • Build the DAG (nodes = step files, edges = depends-on references).
      • Run cycle detection. If a cycle is found → ❌ Page NNN has cyclic dependencies between steps. Run /grimoire-plan NNN to fix. and STOP.
      • Verify every depends-on reference points to an existing step file. Dangling reference → ❌ Page NNN references a non-existent step in depends-on. Run /grimoire-plan NNN to fix. and STOP.
      • Compute waves (Kahn-style topological levels per § Parallel execution).
      • Proceed to Phase 2B's wave loop.

[Phase 2A: Legacy strict-serial execution] Selected at Phase 1 step 6 when no step file carries depends-on frontmatter. Behavior is byte-identical to the pre-0.8.0 implementation.

  • Spawn sub-agents per § Sub-agent spawning: one sub-agent per step file, strictly sequential. Never start step N+1 until the sub-agent for step N has fully completed its assignment.
  • Each sub-agent must execute its step file step-by-step per § TDD.
  • Each sub-agent makes its own atomic Conventional Commits directly in the main workspace per § Commits.

Read the full file on GitHub · 96 lines

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. 7d ago First seen · 96 lines · 35 tokens per session scan C 45ccbdf63cb6

Subscribe to this mod's changes

grimoire-execute is a skill published in the GitHub repository ojCezarFerreira/Grimoire (2 stars, last pushed 2mo ago), licensed MIT. It adds 35 tokens to every session and 2,605 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it C with 1 finding (recursive force delete). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other skills, from other repositories

systematic-debugging

Use when encountering any bug, test failure, or unexpected behavior, before proposing fixes.

obra/superpowers · 21 tokens

local-ai-agents

Build local-first AI agents that run entirely on a developer workstation with Microsoft Foundry Local and Qwen function-calling models. Covers Small Language Models (SLMs), the OpenAI-compatible local endpoint, sandboxed local tools, local RAG with Chroma, local MCP servers, hybrid cloud/local routing, and the…

microsoft/ai-agents-for-beginners · 200 tokens

next-cache-components-adoption

Turn on Cache Components in a Next.js app and resolve the blocking routes it surfaces. Use when the user wants to enable, adopt, or migrate to Cache Components, flip the cacheComponents flag, work through a flood of blocking-prerender / instant validation errors, run the cache-components-instant-false codemod, or…

vercel/next.js · 95 tokens

next-cache-components-optimizer

Drive a Next.js route to instant navigation by setting up an agentic loop, under Cache Components / PPR, on initial load (hard navigation) and client-side navigation (soft navigation). Encode the goal as a failing @next/playwright instant() e2e and work it to green, one verified route at a time; the shipped test then…

vercel/next.js · 170 tokens

next-partial-prefetching-adoption

Turn on Partial Prefetching in a Next.js app and work through the insights it surfaces. Use when the user wants to enable or adopt Partial Prefetching, flip the partialPrefetching flag, opt routes in with export const prefetch = 'partial', audit Link prefetch={true} behavior, preserve existing prefetched UI with…

vercel/next.js · 103 tokens

chronicle

Analyze Copilot session history for standup reports, usage tips, session search, and session reindexing. Use when the user asks for a standup, daily summary, usage tips, workflow recommendations, wants to search or find past sessions by keyword/file/PR, wants to reindex their session store, or asks about deleting…

microsoft/vscode · 72 tokens