hookify

A workflow that turns a user’s instruction such as “never do X” into a rule applied before future tool actions. The rule can block or warn about actions such as force-pushing or editing certain files.

In plain words
What is it for?
Use it to restrict commands, file edits, package installation, or commits. It cannot enforce preferences about the wording or content of the agent’s messages.
Why use it?
It prevents repeated mistakes by enforcing action-related corrections automatically, without requiring the user to write code.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/andrewcigan/vibe-dev-plugin/hookify
Any agent
npx skills add andrewcigan/vibe-dev-plugin --skill hookify
Clone the repo
git clone --depth 1 https://github.com/andrewcigan/vibe-dev-plugin

Made for: Claude Code, Codex.

Per session 79 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,115 The whole file, excluding the scripts and references it only reads on demand.
Security scan C 1 finding. Scan, not verified.
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 $0.00079 $0.01115
Opus 5 $0.00039 $0.00558
Sonnet 5 $0.00016 $0.00223
Haiku 4.5 $0.00008 $0.00112

Measured 2d ago against content hash e64464d84667, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade C, and why

hookify 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 2d 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.

- ✅ **Захукиваемо** (действие): «не делай force-push», «не правь файлы в `migrations/` без ревью», «не запускай `rm -rf` вслепую», «не ставь пакеты глобально», «не коммить прямо в main».
skills/hookify/SKILL.md · 59 lines

How it starts

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

/hookify — заморозить коррекцию в правило

Берёт «больше не делай X» и превращает в правило .harness/user-rules.json, которое PreToolUse-хук (hooks/checks/user-rules.sh) применяет ко всем будущим действиям. Непрограммист получает реальный enforcement без написания кода. Закрывает R6/H9/H18.

Шаг 0: Граница — действие или контент сообщения?

Хук видит ДЕЙСТВИЯ (команды Bash, пути файлов в Write/Edit), НЕ контент моих сообщений.

  • Захукиваемо (действие): «не делай force-push», «не правь файлы в migrations/ без ревью», «не запускай rm -rf вслепую», «не ставь пакеты глобально», «не коммить прямо в main».
  • НЕ захукиваемо (контент сообщения): «не давай технические развилки A/B без объяснения», «не используй жаргон», «не оценивай в человеко-днях», «пиши короче». Это display-only — я читаю оригинал своего текста, хук не может его enforce'ить (ограничение SDK; см. отложенный H5).

Если коррекция про контент сообщения — честно сказать: «это правило хуком не enforce'ится, могу записать как discipline-заметку в SESSION.md / memory, но это не механизм, а напоминание». НЕ фабриковать правило-пустышку, которое не сработает (декларация под видом enforcement).

Шаг 1: Извлечь намерение

  • tool — какой инструмент ловим: Bash (команды), Write/Edit/MultiEdit (файлы), или * (любой целевой).
  • match — regex по subject (Bash → по тексту команды; Write/Edit → по пути файла). Паттерн ТОЧНЫЙ, чтобы не ловить лишнее.
  • actionwarn (по умолчанию, мягко: предупреждение, действие проходит) или block (жёстко: действие отменяется). block — только если пользователь явно хочет жёсткий запрет.
  • message — текст при срабатывании (по-русски, по-человечески, без жаргона).

Шаг 2: Показать правило и подтвердить

Показать готовое правило простым языком + вариант, спросить «такое записать?». Для block подтверждение обязательно (это жёсткая отмена действий).

Пример: «Запрещу force-push: любая Bash-команда с push … --force будет ОТМЕНЕНА с пояснением. Записать как жёсткий запрет?»

Read the full file on GitHub · 59 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. 2d ago First seen · 59 lines · 0 tokens per session scan C e64464d84667

Subscribe to this mod's changes

hookify is a skill published in the GitHub repository andrewcigan/vibe-dev-plugin (5 stars, last pushed 1mo ago), licensed MIT. It adds 79 tokens to every session and 1,115 once invoked, about $0.0004 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

harness-engineering-guide

Audit, design, and implement AI agent harnesses for any codebase. A harness is the constraints, feedback loops, and verification systems surrounding AI coding agents — improving it is the highest-leverage way to improve AI code quality. Three modes: Audit (scorecard), Implement (set up components), Design (full…

OdradekAI/harness-engineering-guide · 182 tokens

google-drive-sheets

Find, read, export, edit, and manage the user's Google Drive, Docs, Sheets, and Slides through per-user OAuth.

yc-software/qm · 31 tokens

github-gitlab

Work with GitHub and GitLab repositories through resident gh/glab/git auth on the agent computer.

yc-software/qm · 25 tokens

harness-creator

Build, audit, and improve harnesses that make AI coding agents reliable: AGENTS.md/CLAUDE.md instruction files, feature/state tracking, verification gates, scope boundaries, session handoff, memory persistence, context budgets, tool-permission safety, and multi-agent coordination. Use this whenever a coding agent is…

walkinglabs/learn-harness-engineering · 142 tokens

miniapp

Build a tiny interactive HTML playground only when someone asks to see, play with, or step through a mechanism.

yc-software/qm · 25 tokens

commit-push-pr

Commit selected local changes, push the branch, and create or update a GitHub pull request with BitFun attribution. Use when the user asks to 提交 PR、提代码、commit and push、开 PR、create a pull request, or wants a Claude Code-like one-command PR publishing flow from BitFun.

GCWing/BitFun · 68 tokens