aprende-disable-hooks

aprende-disable-hooks is a command for Claude Code from Hainrixz/aprende-skill. It costs 42 tokens per session (636 once invoked), scanned B, original, MIT.

A command that removes the aprende learning hooks from the user's global Claude settings while preserving unrelated hooks.

In plain words
What is it for?
Use it to uninstall the aprende PostToolUse and Stop hooks, confirm when they are absent, or restore them later with the corresponding enable command.
Why use it?
It lets users turn off the automatic learning behavior and keeps a backup of the settings before changing them.

Command for Claude Code

Written for Claude Code: allowed-tools in frontmatter. Also seen: reads .claude/ paths.

Part of the aprende plugin — 2 skills, 3 commands, 2 hooks shipped together

Good fit Use it to uninstall the aprende PostToolUse and Stop hooks, confirm when they are absent, or restore them later with the corresponding enable command.

Compare 6 commands from other repositories ↓
Install with agentmods
npx agentmods add commands/hainrixz/aprende-skill/aprende-disable-hooks
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.

Clone the repo
git clone --depth 1 https://github.com/Hainrixz/aprende-skill

Made for: Claude Code.

Or install aprende, the plugin that ships this one along with the rest of its 2 skills, 3 commands, 2 hooks.

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 aprende-disable-hooks

README.md
[![agentmods](https://agentmods.dev/badge/commands/hainrixz/aprende-skill/aprende-disable-hooks.svg)](https://agentmods.dev/commands/hainrixz/aprende-skill/aprende-disable-hooks)
Your own site
<a href="https://agentmods.dev/commands/hainrixz/aprende-skill/aprende-disable-hooks"><img src="https://agentmods.dev/badge/commands/hainrixz/aprende-skill/aprende-disable-hooks.svg" alt="Measured on agentmods" height="20"></a>
Per session 42 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 636 The whole file, excluding the scripts and references it only reads on demand.
Security scan B 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.00042 $0.00636
Opus 5 $0.00021 $0.00318
Sonnet 5 $0.00008 $0.00127
Haiku 4.5 $0.00004 $0.00064

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

Security

Grade B, and why

aprende-disable-hooks scanned grade B 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 8d 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.

Reads agent configuration directoriesmediumAgent snooping

.claude/, .codex/, .gemini/ hold keys, settings and other credentials a mod has no legitimate need for.

Remove the aprende PostToolUse + Stop hooks from ~/.claude/settings.json.
commands/aprende-disable-hooks.md · 74 lines

How it starts

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

/aprende-disable-hooks

When invoked, remove the aprende hooks from the user's global ~/.claude/settings.json. Leaves other hooks (from other plugins or manually added) untouched.

Procedure

  1. Backup. Copy ~/.claude/settings.json to ~/.claude/settings.json.aprende-backup-<YYYY-MM-DD-HHMM> before any write.

  2. Read settings. Parse ~/.claude/settings.json. If the file doesn't exist or doesn't contain "aprende-hooks-installed": true, print:

    aprende hooks are not installed. Nothing to do.
    

    and exit cleanly.

  3. Remove aprende entries. From hooks.PostToolUse, drop any entry whose hooks[].command contains aprende or capture-signal.sh. From hooks.Stop, drop entries containing stop-suggest.sh. Keep all other hook entries intact. If an array becomes empty, remove the array.

  4. Remove the marker. Delete the top-level "aprende-hooks-installed" field.

  5. Write back. Save the cleaned JSON. Pretty-print (2-space indent).

  6. Confirm. Print:

    ✓ aprende hooks removed from ~/.claude/settings.json
    ✓ Backup at ~/.claude/settings.json.aprende-backup-<timestamp>
    ✓ Other hooks (if any) preserved.
    To reinstall, run /aprende-enable-hooks.
    

Safety

  • Always back up before editing.
  • Surgical removal only — touch only entries that match aprende's hook scripts (capture-signal.sh, stop-suggest.sh) or the aprende-hooks-installed marker.
  • Be idempotent. Running this when nothing is installed is a no-op.
  • Refuse to run if ~/.claude/settings.json parses as invalid JSON.
  • Never delete the file. Always leave at least {}.

Note on manual cleanup

If the user installed the plugin via marketplace, hook entries also live in the plugin's own hooks/hooks.json (loaded automatically). To fully disable hooks in that case, the user uninstalls the plugin (/plugin uninstall aprende). This command only removes entries from the user's global settings.

Read the full file on GitHub · 74 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. 8d ago First seen · 74 lines · 42 tokens per session scan B 07115f68c26d

Subscribe to this mod's changes

aprende-disable-hooks is a command published in the GitHub repository Hainrixz/aprende-skill (23 stars, last pushed 1mo ago), licensed MIT. It adds 42 tokens to every session and 636 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it B with 1 finding (reads agent configuration directories). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.