Thumbgate guard

From IgorGanapolsky/ThumbGate · View interactive version

Thumbgate guard is an AI agent skill from the GitHub repository IgorGanapolsky/ThumbGate. Turn the agent's most recent mistake into an enforced ThumbGate prevention rule (a PreToolUse block gate) so the same bad tool call is intercepted before it runs again, in this and every future session across Claude Code, Cursor, Codex, Gemini, Amp, and Cline. Captures the failure with the capture_f

How to use this skill

Skill file

ThumbGate Guard

Escalate the agent's most recent mistake into an enforced ThumbGate prevention rule — a

PreToolUse block gate that intercepts the same bad tool-call shape before it runs again, in this

session and every future one (Claude Code, Cursor, Codex, Gemini, Amp, Cline).

This skill wraps existing ThumbGate capability and adds no new logic — it routes to the real

capture_feedback + force-promote path.

Workflow

  1. Name the mistake. From the recent conversation, state the specific bad action in one

sentence (e.g. git push --force origin main, DROP TABLE users, deploy without tests).

  1. Capture it with the capture_feedback MCP tool: signal: "down", context,

whatWentWrong, whatToChange, tags. If the user only gave a vague signal, pass the recent

turns as conversationWindow / chatHistory for history-aware distillation instead of refusing.

  1. Promote it to an enforced gate:

```bash

npx thumbgate force-gate "<one-sentence context of the mistake>"

```

This prints the new gateId and the active gate count.

  1. Confirm enforcement. Show the user the promoted rule and state that it is now a PreToolUse

block — not just a logged note.

Full capture_feedback field contract, force-gate flags, and the guided first-rule walkthrough

(npx thumbgate quickstart) are in

references/capture-and-promote.md.

Example

Input: "the agent force-pushed to main and overwrote a teammate's commit — never again"

Action:

  1. capture_feedback → signal: down, context: "agent force-pushed to main, overwrote a teammate's commit", whatWentWrong: "destructive force-push to a shared branch", whatToChange: "block force-push to main", tags: "git,force-push".
  2. npx thumbgate force-gate "force-push to main overwrote a teammate's commit".
  3. Report: the real gateId + "force-push to main is now blocked as a PreToolUse check."

Troubleshooting

so it can distill from history.

hooks are installed (thumbgate-doctor).

Quality checklist (self-verify before delivering)

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.