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.
npx agentmods add hooks/azalio/map-framework/pre-tool-usegit clone --depth 1 https://github.com/azalio/map-frameworkGrade A, and why
PreToolUse 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 3d ago.
A static scan of the commands this hook runs, not an audit. A hook is shell that executes on your machine at the event it names, which is why every command in it is printed with what was found.
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.
What it actually says
{
"PreToolUse": [
{
"matcher": "Edit|Write|Read|MultiEdit|Bash",
"description": "Safety Guardrails - block sensitive files and dangerous commands",
"hooks": [
{
"type": "command",
"command": "\"$CLAUDE_PROJECT_DIR\"/.claude/hooks/safety-guardrails.py",
"timeout": 5,
"description": "Blocks .env, credentials, private keys, and dangerous bash commands"
}
]
},
{
"matcher": "Edit|Write|MultiEdit",
"description": "Workflow Gate - enforce Actor+Monitor before edits (MAP)",
"hooks": [
{
"type": "command",
"command": "\"$CLAUDE_PROJECT_DIR\"/.claude/hooks/workflow-gate.py",
"timeout": 5,
"description": "Blocks Edit/Write/MultiEdit until workflow_state indicates Actor+Monitor completed"
}
]
},
{
"matcher": "Edit|Write|MultiEdit|Bash",
"description": "Workflow Context Injection (Tiered) - inject reminders for significant operations",
"hooks": [
{
"type": "command",
"command": "\"$CLAUDE_PROJECT_DIR\"/.claude/hooks/workflow-context-injector.py",
"timeout": 3,
"description": "Injects workflow context only for Edit/Write/MultiEdit and significant Bash commands"
}
]
}
]
}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.
- 3d ago First seen · 40 lines scan A 54aa040f050f
PreToolUse is a hook published in the GitHub repository azalio/map-framework (153 stars, last pushed 5d ago), licensed MIT. Its token cost is not measured: a hook is shell that never enters the context. 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-30.
Other hooks, from other repositories
SessionStart
Runs when a session starts on startup, resume, clear, compact, startup, startup, resume, clear, compact, startup, clear, compact, clear and compact, executing license_check.py, licensed_assets_sync.py, codex_skill_sync.py, cc_skill_sync.py and run_if_licensed.py via uv with --no-project, --python and --exec (13…
PostToolUse
Runs after a tool call finishes for Write, Edit, MultiEdit, EnterPlanMode, ExitPlanMode, Write, Edit and MultiEdit tool calls, executing run_if_licensed.py via uv with --no-project, --python and --exec (5 commands). From maxritter/pilot-shell.
PreToolUse
Runs before the agent uses a tool for Write, Edit, MultiEdit, EnterPlanMode, Edit, Write, MultiEdit, Bash, WebSearch, WebFetch, Grep, Glob and Bash tool calls, executing run_if_licensed.py via uv with --no-project and --python (4 commands). From maxritter/pilot-shell.
UserPromptSubmit
Runs when you submit a prompt, before the agent sees it, executing license_prompt_guard.py and run_if_licensed.py via uv with --no-project, --python and --exec (3 commands). From maxritter/pilot-shell.
Stop
Runs when the agent finishes a response, executing run_if_licensed.py via uv with --no-project, --python and --exec (3 commands). From maxritter/pilot-shell.
UserPromptExpansion
Runs to expand your prompt before the agent sees it for benchmark, build, cleanup, create-skill, fix, investigate, prd, setup-rules, spec, spec-bugfix-plan, spec-bugfix-verify, spec-implement, spec-plan and spec-verify tool calls, executing license_prompt_guard.py via uv with --no-project and --python. From…