AI Hook — AI skill for Claude Code
Ultra-fast AI-agent hook dispatcher & autonomous rule engine (Rust + embedded QuickJS).
How to install AI Hook
This entry records only its repository, not the path inside it, so there is no
exact command to give. Open hughcube/ai-hook and copy the folder into
~/.claude/skills/, or the file into ~/.claude/agents/.
What AI Hook does
Ultra-fast AI-agent hook dispatcher & autonomous rule engine (Rust + embedded QuickJS). Write guardrail rules once, run them across Claude Code, Google Antigravity, CodeBuddy and OpenAI Codex. Sandboxed, zero-dependency, ~2-3ms per tool call.
Alternatives in AI
- Pixel Agents — Compressed Reference — VS Code extension with embedded React webview: pixel art office where AI agents (Claude Code terminals) are an 6.5k ★
- Cc Mini — Ultra-light Harness scaffolding for AI agents, a mini version of claude code 825 ★
- Embeddedskills — An open-source collection of embedded development and debugging skills for Claude Code, Copilot, TRAE, and oth 593 ★
README
ai-hook — Unified Multi-Agent Security Interceptor & Autonomous Rule Dispatcher
[](https://github.com/hughcube/ai-hook/actions/workflows/ci.yml) [](https://github.com/hughcube/ai-hook/releases) [](https://opensource.org/licenses/MIT)
**It exists for two things: hiding complexity, and making rules pleasant to write.** **① Hide the complexity** — hook-protocol differences across agents, platform quirks, and subprocess/context-fetching plumbing are all wrapped into one native binary: the same rules are written once and run everywhere, with no per-agent, per-platform script matrix. On Windows it also collapses the old one-process-per-fetch stutter into a single process with millisecond-scale in-process evaluation. **② Better rule authoring** — a rule is just plain JS: a rich `ctx` context, native microsecond `sys` primitives, one uniform deny/ask/inject decision protocol with desktop/terminal interaction, plus `list`/`test`/`bench`/`tutorial` tooling — instead of hand-written shell glue and cross-platform trial and error. Zero variable pollution, a single-process closed loop, and extreme speed all fall out of this design. Hooks for **Claude Code**, **Google Antigravity**, **CodeBuddy / WorkBuddy**, **OpenAI Codex**, **Gemini CLI**, **OpenCode** — one rule set, every agent, on Windows / macOS / Linux.
**OpenCode note:** OpenCode has no out-of-process hook protocol of its own — it loads in-process JS/TS plugins (see [opencode.ai/docs/plugins](https://opencode.ai/docs/plugins/)). ai-hook reaches it through the community bridge [`magarcia/opencode-claude-hooks`](https://github.com/magarcia/opencode-claude-hooks), which forwards Claude-Code-shaped envelopes and sets `OPENCODE_COMPAT=1`. Install the bridge (or use the in-process plugin appro
Related Skills
Micro Actinf
⚡ Ultra-fast O(1) Active Inference & Bayesian Cognitive Governor for AI Agents (Antigravity, Claude, Cursor) &
SkillTrans
A powerful CLI tool that automatically converts Claude Code Skills into native configurations for Trae, Cursor
Datafog Python
Offline PII firewall for AI agents and LLM apps: fast local detection and redaction, Claude Code hook, LiteLLM
Fast File Search
Ultra-fast file search toolkit for AI agents, Neovim, and code editors. MCP server for Claude Code/Cursor/Code
Apohara Agentguard
Anti-bypass command-safety hook, local seccomp+Landlock sandbox, and deterministic prompt-injection firewall f
AI Agent Guardrails Windows Guide
Verified guide: a global guardrail that blocks catastrophic shell commands from AI agents on Windows (Claude C
Related Agents
Sol Implementer
High-complexity implementation lane running GPT-5.6 Sol via the OpenAI Codex CLI (codex exec), at whatever rea
CLI Subagents Antigravity
Runs a task in Google Antigravity (agy, Gemini models) on the user's Google account (CLI Subagents; extra Goog
Antigravity Rescue
Proactively delegate bounded coding work to Google Antigravity CLI (agy) in headless print mode — frontier rea