thumbgate 1.35.0 → 1.37.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.agents/skills/cyberstrike-compare-not-clone/SKILL.md +36 -0
- package/.agents/skills/gitlab-sandbox-allowlist-not-trust/SKILL.md +77 -0
- package/.agents/skills/jit-harness-compare-not-clone/SKILL.md +34 -0
- package/.agents/skills/openui-catalog-compose-honesty/SKILL.md +64 -0
- package/.agents/skills/zvec-grep-compare-not-clone/SKILL.md +34 -0
- package/.claude-plugin/plugin.json +1 -1
- package/.well-known/llms.txt +1 -0
- package/.well-known/mcp/server-card.json +1 -1
- package/CONTRIBUTING.md +95 -0
- package/README.md +195 -632
- package/THIRD_PARTY_NOTICES.md +89 -0
- package/adapters/claude/.mcp.json +2 -2
- package/adapters/forge/forge.yaml +3 -3
- package/adapters/future-agi/.mcp.json +8 -0
- package/adapters/future-agi/FUTURE_AGI.md +23 -0
- package/adapters/future-agi/config.toml +3 -0
- package/adapters/future-agi/future-agi-bridge.js +9 -0
- package/adapters/future-agi/opencode.json +8 -0
- package/adapters/herdr/herdr-plugin.toml +18 -0
- package/adapters/mcp/server-stdio.js +238 -25
- package/adapters/opencode/opencode.json +1 -1
- package/adapters/workos/WORKOS.md +52 -0
- package/bin/cli.js +336 -3
- package/bin/futureagi-bridge +9 -0
- package/config/gate-templates.json +581 -4
- package/config/gates/actor-critic-audit.json +34 -0
- package/config/gates/default.json +9 -3
- package/config/gates/five-walls-governance.json +34 -0
- package/config/gates/future-agi-guardrails.json +34 -0
- package/config/gates/radware-threat-defense-2026.json +61 -0
- package/config/gates/simatree-data-governance.json +33 -0
- package/config/mcp-allowlists.json +4 -0
- package/config/merge-quality-checks.json +6 -0
- package/config/model-candidates.json +312 -29
- package/config/model-tiers.json +18 -0
- package/config/post-deploy-marketing-pages.json +10 -0
- package/config/progressive/01-wire-only.json +11 -0
- package/config/progressive/02-dashboard-empty-ok.json +10 -0
- package/config/progressive/03-one-lesson.json +10 -0
- package/config/progressive/04-warn-fires.json +11 -0
- package/config/progressive/05-strict-optional.json +11 -0
- package/config/progressive/README.md +15 -0
- package/config/schemas/broker-execution-receipt.schema.json +139 -0
- package/config/schemas/provider-execution-attestation-v1.schema.json +58 -0
- package/conformance/provider-attestation/vectors.json +320 -0
- package/docs/specs/provider-execution-attestation-v1.md +69 -0
- package/openapi/openapi.yaml +15 -0
- package/package.json +390 -148
- package/public/about.html +2 -2
- package/public/ai-malpractice-prevention.html +7 -7
- package/public/blog/a-10-dollar-vps-is-not-a-computer.html +143 -0
- package/public/blog/a-receipt-is-not-world-state.html +388 -0
- package/public/blog/git-at-agent-scale.html +374 -0
- package/public/blog/no-llm-in-the-gate.html +133 -0
- package/public/blog.html +80 -0
- package/public/case-studies.html +16 -1
- package/public/compare.html +28 -0
- package/public/diagnostic.html +216 -7
- package/public/docs/connectors.html +39 -0
- package/public/federal.html +2 -2
- package/public/founders.html +639 -0
- package/public/index.html +87 -9
- package/public/install.html +8 -8
- package/public/learn.html +39 -0
- package/public/numbers.html +2 -2
- package/public/peter.html +310 -0
- package/public/platform-partners.html +119 -0
- package/public/pricing.html +24 -3
- package/public/privacy.html +117 -0
- package/public/pro.html +17 -0
- package/public/support.html +62 -0
- package/public/terms.html +130 -0
- package/public/third-party-notices.html +95 -0
- package/public/yt.html +351 -0
- package/scripts/action-receipts.js +133 -3
- package/scripts/adaptive-governance-arena.js +349 -0
- package/scripts/admin-override.js +205 -0
- package/scripts/agent-action-inventory.js +869 -0
- package/scripts/agent-audit-trace.js +42 -2
- package/scripts/agent-egress-policy.js +1117 -0
- package/scripts/agent-memory-lifecycle.js +141 -2
- package/scripts/agent-operations-planner.js +441 -1
- package/scripts/agent-readiness.js +68 -0
- package/scripts/agent-security-central.js +647 -0
- package/scripts/allowlist-bridge-honesty.js +417 -0
- package/scripts/async-job-runner.js +102 -11
- package/scripts/audit-trail.js +212 -0
- package/scripts/billing.js +1 -1
- package/scripts/broker-execution-receipts.js +719 -0
- package/scripts/budget-aware-gates-proof.js +423 -0
- package/scripts/claude-feedback-sync.js +29 -3
- package/scripts/claw-harness-production.js +237 -0
- package/scripts/cli-schema.js +163 -1
- package/scripts/codex-runbook-flywheel.js +318 -0
- package/scripts/context-footprint.js +186 -0
- package/scripts/contextfs.js +143 -61
- package/scripts/dashboard.js +251 -32
- package/scripts/deepseek-v4-runtime-guardrails.js +72 -6
- package/scripts/docker-sandbox-planner.js +18 -0
- package/scripts/double-blind-eval-protocol.js +252 -0
- package/scripts/edotenv-rl-gateway.js +259 -0
- package/scripts/ensure-production-search-corpus.js +162 -0
- package/scripts/eval-holdout.js +311 -0
- package/scripts/feedback-aggregate.js +21 -2
- package/scripts/feedback-loop.js +87 -5
- package/scripts/feedback-quality.js +9 -0
- package/scripts/file-ledger-lock.js +4 -1
- package/scripts/financial-control-plane.js +41 -1
- package/scripts/find-dormant-requires.js +118 -0
- package/scripts/fs-utils.js +84 -8
- package/scripts/gates-engine.js +810 -63
- package/scripts/generate-case-study-outreach.js +24 -15
- package/scripts/git-at-scale.js +628 -0
- package/scripts/governance-conflict-audit.js +1650 -0
- package/scripts/governance-difficulty-curriculum.js +328 -0
- package/scripts/graphrag-retrieval.js +275 -0
- package/scripts/gurobi-optimizer.js +324 -0
- package/scripts/gurobi_optimizer.py +485 -0
- package/scripts/harness-selector.js +82 -1
- package/scripts/hidden-entry-points.js +284 -0
- package/scripts/human-escalation.js +199 -1
- package/scripts/hybrid-feedback-context.js +152 -19
- package/scripts/intent-governed-execution.js +602 -0
- package/scripts/intervention-policy.js +123 -20
- package/scripts/jit-harness-compose.js +628 -0
- package/scripts/jsonl-watcher.js +10 -0
- package/scripts/lesson-embedding-index.js +95 -12
- package/scripts/lesson-retrieval.js +105 -19
- package/scripts/local-model-profile.js +19 -2
- package/scripts/mailer/resend-mailer.js +1 -1
- package/scripts/matryoshka-embedding.js +235 -0
- package/scripts/mcp-oauth.js +42 -4
- package/scripts/mcp-session-handles.js +1016 -0
- package/scripts/mcp-wiring-doctor.js +314 -0
- package/scripts/memory-firewall.js +115 -2
- package/scripts/memory-scope-readiness.js +299 -0
- package/scripts/memory-vs-rag-route.js +161 -0
- package/scripts/model-tier-router.js +148 -21
- package/scripts/nvidia-specdecode-al-doctor.js +536 -0
- package/scripts/openui-catalog-compose-honesty.js +593 -0
- package/scripts/operational-integrity.js +19 -1
- package/scripts/override-audit.js +213 -0
- package/scripts/package-manager-honesty-doctor.js +458 -0
- package/scripts/pr-manager.js +63 -1
- package/scripts/prove-herdr-adapter.js +52 -0
- package/scripts/prove-memory-pyramid-and-symbolic-canvas.js +95 -0
- package/scripts/prove-workos.js +73 -0
- package/scripts/provider-attestation-conformance.js +192 -0
- package/scripts/provider-receipt-contract.js +136 -0
- package/scripts/qwen38-max-cost-optimizer.js +401 -0
- package/scripts/radware-threat-defense.js +280 -0
- package/scripts/rag-embedding-identity.js +221 -0
- package/scripts/rag-precision-guardrails.js +112 -2
- package/scripts/remote-feedback-capture.js +159 -0
- package/scripts/research-agent-harness.js +256 -0
- package/scripts/rsi-safety-hillclimb.js +200 -0
- package/scripts/rule-sprawl.js +188 -0
- package/scripts/schedule-manager.js +147 -0
- package/scripts/self-heal.js +8 -0
- package/scripts/session-lease.js +415 -0
- package/scripts/simatree-data-governance.js +347 -0
- package/scripts/slo-alert-engine.js +172 -7
- package/scripts/solver-parity.js +539 -0
- package/scripts/stealth-memory-injection-gate.js +333 -0
- package/scripts/switchyard-router.js +366 -0
- package/scripts/telemetry-analytics.js +84 -27
- package/scripts/temporal-decay-weighting.js +138 -0
- package/scripts/test-all.js +165 -0
- package/scripts/token-savings.js +42 -0
- package/scripts/tool-kpi-tracker.js +108 -5
- package/scripts/tool-registry.js +193 -5
- package/scripts/universal-claim-evaluator.js +14 -2
- package/scripts/vector-store.js +279 -9
- package/scripts/workflow-notebook.js +391 -0
- package/scripts/workflow-sentinel.js +111 -12
- package/scripts/workos-production-guard.js +260 -0
- package/scripts/workspace-search-route.js +515 -0
- package/server.json +2 -2
- package/src/agent-identity-boundary.js +76 -0
- package/src/agent-retrieval-cache.js +155 -0
- package/src/alert-noise-ledger.js +502 -0
- package/src/api/server.js +724 -153
- package/src/git-fast-cache.js +220 -0
- package/src/git-wal-sync.js +156 -0
- package/src/hash-anchored-edit.js +82 -0
- package/src/hermes-platform-protocol.js +475 -0
- package/src/hermes-sync-plane.js +241 -0
- package/src/index.js +30 -1
- package/src/iso42001-compliance-guard.js +97 -0
- package/src/latency-budget.js +244 -0
- package/src/mcp-writeguard.js +316 -0
- package/src/miminions-adapter.js +106 -0
- package/src/pipeline-compass.js +104 -0
- package/src/ppl-alert-pipeline.js +284 -0
- package/src/rendezvous-router.js +90 -0
- package/src/security-questionnaire.js +195 -0
package/README.md
CHANGED
|
@@ -1,637 +1,292 @@
|
|
|
1
|
-
# ThumbGate
|
|
2
|
-
|
|
3
|
-
[](https://mcptoplist.com/server/glama%2FIgorGanapolsky%2FThumbGate)
|
|
1
|
+
# ThumbGate 👍 👎
|
|
4
2
|
|
|
5
3
|
<p align="center">
|
|
6
4
|
<a href="https://thumbgate.ai">
|
|
7
|
-
<img src="
|
|
5
|
+
<img src="docs/media/thumbgate-hero-banner.svg" alt="ThumbGate Infrastructure Firewall with Thumbs Up and Thumbs Down" width="100%" />
|
|
8
6
|
</a>
|
|
9
7
|
</p>
|
|
10
8
|
|
|
11
|
-
**Self-Improving Firewall for Your AI Agents.** AI coding agents repeat mistakes — and one wrong tool call can wipe a directory, leak a key, or push broken code.
|
|
12
|
-
|
|
13
|
-
ThumbGate is the local-first Pre-Action Checks engine for AI coding agents. It runs in the PreToolUse hook on your machine: it evaluates a proposed tool call and logs the decision before tool execution. It **hard-blocks detected secret leaks and two direct self-disable command classes by default** — commands that terminate the ThumbGate gate process or enable its bypass environment override. Other high-risk classes, including destructive deletes (`rm -rf`), force-push, fetch-and-run, direct guardrail-file edits, off-scope edits, and deploys, **warn and log by default**. Set `THUMBGATE_STRICT_ENFORCEMENT=1` to preserve deny decisions for every matched blocking rule. Works across configured Claude Code, Cursor, Codex, Gemini, Amp, Cline, and OpenCode integrations. No server is required on the local enforcement path. (Regulated-industry policy templates are roadmap directions, not shipped compliance claims.)
|
|
14
|
-
|
|
15
|
-
Accepted feedback is stored as local lessons. Repeated concrete failures can become prevention rules that promote from warnings to blocking gates; relevant lessons are re-ranked for each proposed action; stale auto-promoted gates expire; and stale lessons archive. The firewall improves from operations without retraining the model.
|
|
16
|
-
|
|
17
9
|
<p align="center">
|
|
18
|
-
<
|
|
10
|
+
<b>ThumbGate is the self-improving pre-action firewall for AI coding agents</b><br>
|
|
11
|
+
AI coding agents repeat mistakes — and one wrong tool call can wipe a directory, leak a key, or push broken code.
|
|
19
12
|
</p>
|
|
20
13
|
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
ThumbGate
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
npx thumbgate init # auto-detects the supported agent and wires its integration
|
|
31
|
-
```
|
|
32
|
-
|
|
33
|
-
### MCP / Glama / registry install (stdio)
|
|
34
|
-
|
|
35
|
-
Directories and clients that install ThumbGate as an MCP server must start **stdio MCP**, not the HTTP API:
|
|
36
|
-
|
|
37
|
-
```bash
|
|
38
|
-
npx -y thumbgate serve
|
|
39
|
-
```
|
|
40
|
-
|
|
41
|
-
- Equivalent: `npx -y thumbgate mcp`
|
|
42
|
-
- Do **not** use `npm start` for MCP — that launches the hosted HTTP API (`src/api/server.js`), not the agent-facing stdio server.
|
|
43
|
-
- Canonical package metadata: `server.json` (`runtimeHint: npx` + `packageArguments: ["serve"]`), Smithery: `smithery.yaml`, maintainers: `glama.json`.
|
|
44
|
-
- Product name is **ThumbGate** only (npm: `thumbgate`). Retired legacy package aliases are not active product surfaces.
|
|
45
|
-
|
|
46
|
-
Works with **Claude Code, Cursor, Codex, Gemini CLI, Amp, Cline, OpenCode** and MCP-compatible agents after their integration is configured. Free tier: 2 feedback captures/day (10 total) and up to 3 active auto-promoted prevention rules. [Pro: $19/mo or $149/yr](https://thumbgate.ai/checkout/pro?utm_source=github&utm_medium=readme) is the individual tier for unlimited rules, history-aware lessons, feedback sessions, a personal dashboard, and DPO export. Enterprise is custom and scoped after intake; hosted team sync and a hosted org dashboard are not in the current general-availability runtime.
|
|
47
|
-
|
|
48
|
-
[](https://github.com/IgorGanapolsky/ThumbGate/actions/workflows/ci.yml)
|
|
49
|
-
[](https://www.npmjs.com/package/thumbgate)
|
|
50
|
-
[](LICENSE)
|
|
51
|
-
|
|
52
|
-
---
|
|
53
|
-
|
|
54
|
-
> *"A better dashboard doesn't make the agents more reliable. The hard part isn't visibility. It's trust."*
|
|
55
|
-
>
|
|
56
|
-
> — **Rob May**, CEO & co-founder, Neurometric AI, quoted in [The New Stack](https://thenewstack.io/claude-code-agent-view/) on Anthropic's Claude Code Agent View (May 2026).
|
|
57
|
-
>
|
|
58
|
-
> ThumbGate is our open-source attempt at that trust problem: inspectable PreToolUse decisions, accepted feedback captured as lessons, and recurring failures promoted into reviewable rules.
|
|
59
|
-
|
|
60
|
-
---
|
|
61
|
-
|
|
62
|
-
## Agentic development cycle fit
|
|
63
|
-
|
|
64
|
-
Agentic development is becoming a loop: **Guide → Generate → Verify → Solve**. ThumbGate adds a pre-action decision point before tool execution.
|
|
65
|
-
|
|
66
|
-
- **Guide:** standards, prior thumbs-downs, and approval policies become concrete context.
|
|
67
|
-
- **Generate:** Claude Code, Cursor, Codex, Gemini, Amp, Cline, OpenCode, and MCP agents keep producing plans and tool calls.
|
|
68
|
-
- **Verify:** risky actions need evidence before execution, not just after PR review.
|
|
69
|
-
- **Solve:** flagged or denied failures can become reusable lessons, prevention rules, DPO exports, and audit events.
|
|
70
|
-
|
|
71
|
-
In that stack, ThumbGate is the pre-action gate between generated intent and executed action.
|
|
72
|
-
|
|
73
|
-
---
|
|
74
|
-
|
|
75
|
-
## Discoverable slash-commands — the guardrail layer for spec-driven agents
|
|
76
|
-
|
|
77
|
-
Spec-driven agent frameworks like **GSD** (get-shit-done) and **GitHub Spec Kit** are great at *planning and generating* work — they expose dozens of discoverable `/gsd-*` / `/specify` commands in the agent command palette. ThumbGate is the **guardrail layer for spec-driven agents**: it sits *after* the plan, on the boundary between a generated tool call and its execution. It works **alongside GSD / Spec-Kit, not instead of them** — they decide *what* to build; configured ThumbGate policies evaluate the proposed actions used to build it.
|
|
78
|
-
|
|
79
|
-
`npx thumbgate init` installs these commands into your agent's palette (`.claude/commands/`, `.gemini/commands/`, `.antigravitycli/commands/`) so the enforcement layer is as browsable as the planning layer:
|
|
80
|
-
|
|
81
|
-
| Command | What it does | Wraps (existing capability) |
|
|
82
|
-
|---------|--------------|------------------------------|
|
|
83
|
-
| **`/thumbgate-dashboard`** | **Open the local project dashboard in your browser** (lessons, checks, tokens saved) | **`npx thumbgate dashboard --open`** (global bin after `npm i -g`) |
|
|
84
|
-
| `/thumbgate-guard` | Turn the last agent mistake into a hard prevention rule | `capture_feedback` + `thumbgate force-gate` |
|
|
85
|
-
| `/thumbgate-rules` | List the active prevention rules + lessons guarding this repo | `prevention_rules`, `get_reliability_rules`, `search_lessons` |
|
|
86
|
-
| `/thumbgate-blocked` | Show what's actually been blocked — gate stats + enforcement matrix | `gate_stats`, `enforcement_matrix` |
|
|
87
|
-
| `/thumbgate-protect` | Show branch/release governance; grant a scoped, expiring approval | `get_branch_governance`, `approve_protected_action` |
|
|
88
|
-
| `/thumbgate-doctor` | Health-check the wiring (hooks, MCP, agent-readiness) | `thumbgate doctor` |
|
|
89
|
-
|
|
90
|
-
> **Open the dashboard anytime:** after `npx thumbgate init`, run **`npx thumbgate dashboard --open`** (works without a global install). Type **`/thumbgate-dashboard`** in Claude Code / Cursor, or **`/project:thumbgate-dashboard`** in Grok. After `npm i -g thumbgate`, the **`thumbgate-dashboard`** bin is also on your PATH.
|
|
91
|
-
|
|
92
|
-
Each is a thin wrapper over an existing MCP tool or CLI command — **no new enforcement logic, just discoverability**.
|
|
93
|
-
|
|
94
|
-
---
|
|
95
|
-
|
|
96
|
-
## 🎬 90-second demo
|
|
97
|
-
|
|
98
|
-
Watch the force-push scenario: an agent proposes `git push --force`, the matching rule is flagged and logged by default, and the tool call is denied when you run with `THUMBGATE_STRICT_ENFORCEMENT=1`.
|
|
99
|
-
|
|
100
|
-
[**▶ Watch the 90-second demo**](https://thumbgate.ai/#demo?utm_source=github&utm_medium=readme&utm_campaign=demo_video) · [Script](docs/marketing/demo-video-script.md) · [ElevenLabs narration: `npm run demo:voiceover`](scripts/generate-demo-voiceover.js)
|
|
14
|
+
<p align="center">
|
|
15
|
+
<a href="https://mcptoplist.com/server/glama%2FIgorGanapolsky%2FThumbGate"><img src="https://mcptoplist.com/badge/glama%2FIgorGanapolsky%2FThumbGate.svg" alt="MCP Toplist" /></a>
|
|
16
|
+
<a href="https://github.com/IgorGanapolsky/ThumbGate/actions/workflows/ci.yml"><img src="https://github.com/IgorGanapolsky/ThumbGate/actions/workflows/ci.yml/badge.svg" alt="CI" /></a>
|
|
17
|
+
<a href="https://www.npmjs.com/package/thumbgate"><img src="https://img.shields.io/npm/v/thumbgate" alt="npm version" /></a>
|
|
18
|
+
<a href="https://www.npmjs.com/package/thumbgate"><img src="https://img.shields.io/npm/dw/thumbgate" alt="npm weekly downloads" /></a>
|
|
19
|
+
<a href="https://github.com/IgorGanapolsky/ThumbGate"><img src="https://img.shields.io/github/stars/IgorGanapolsky/ThumbGate" alt="GitHub stars" /></a>
|
|
20
|
+
<a href="https://github.com/marketplace/actions/thumbgate-agent-governance"><img src="https://img.shields.io/badge/GitHub_Marketplace-ThumbGate_Agent_Governance-0969da" alt="GitHub Marketplace: ThumbGate Agent Governance" /></a>
|
|
21
|
+
<a href="LICENSE"><img src="https://img.shields.io/badge/License-MIT-green.svg" alt="License: MIT" /></a>
|
|
22
|
+
</p>
|
|
101
23
|
|
|
102
|
-
|
|
24
|
+
<p align="center">
|
|
25
|
+
<a href="#quick-start"><img src="https://img.shields.io/badge/⚡_Quick_Start-npx_thumbgate_init-22d3ee?style=for-the-badge" alt="Quick Start" /></a>
|
|
26
|
+
<a href="https://thumbgate.ai/#demo?utm_source=github&utm_medium=readme"><img src="https://img.shields.io/badge/🎬_Watch-90s_Demo-ff647c?style=for-the-badge" alt="Watch Demo" /></a>
|
|
27
|
+
<a href="https://thumbgate.ai/go/gpt?utm_source=github&utm_medium=readme"><img src="https://img.shields.io/badge/💬_Try-ThumbGate_GPT-56e39f?style=for-the-badge" alt="Try GPT" /></a>
|
|
28
|
+
<a href="https://thumbgate.ai/checkout/pro?utm_source=github&utm_medium=readme"><img src="https://img.shields.io/badge/💼_Pro-$19/mo-ffd166?style=for-the-badge" alt="Pro Tier" /></a>
|
|
29
|
+
</p>
|
|
103
30
|
|
|
104
31
|
---
|
|
105
32
|
|
|
106
|
-
##
|
|
33
|
+
## What it does
|
|
107
34
|
|
|
108
|
-
|
|
35
|
+
ThumbGate is the local-first **Pre-Action Checks** engine for AI coding agents. It runs in the PreToolUse hook to evaluate the proposed tool call before execution — so costly mistakes can be caught before they happen.
|
|
109
36
|
|
|
110
|
-
|
|
111
|
-
2. **Capture the lesson:** type `thumbs down:` or `thumbs up:` with one concrete sentence. Native ChatGPT rating buttons are not the ThumbGate capture path; typed feedback is.
|
|
112
|
-
3. **Enforce the repeat:** run `npx thumbgate init` where the agent executes so the lesson can become one of your Pre-Action Checks instead of another reminder.
|
|
113
|
-
4. **Upgrade only after proof:** Solo Pro is for the dashboard, DPO export, reviewable evidence, and higher capture limits after one real caught repeat. Enterprise starts with the Workflow Hardening Sprint around one repeated failure, one owner, and one proof review.
|
|
37
|
+
ThumbGate GitHub star growth is measured with GitHub's privacy-safe [`GET /repos/{owner}/{repo}/stargazers/history`](https://docs.github.com/en/rest/activity/starring#get-repository-star-history) endpoint (weekly counts, no stargazer identities). Run `npm run stars:history -- --fixture tests/fixtures/github-star-history.json --json` for the local proof. Stars are not npm installs and not revenue. The live GitHub Marketplace Action is [ThumbGate Agent Governance](https://github.com/marketplace/actions/thumbgate-agent-governance) (`uses: IgorGanapolsky/ThumbGate@v1`).
|
|
114
38
|
|
|
115
|
-
|
|
39
|
+
**Usage over star count.** Evaluate ThumbGate from the install path and live usage badges above (`npx thumbgate init`, Marketplace `uses:`, npm weekly downloads, GitHub clones), not from whether the repo has twenty stars or twenty thousand. No pitch deck is required. We do not farm GitHub profile badges (no YOLO-merge of protected `main`, no 5-minute Issue close theater, no fake `Co-authored-by`). Galaxy Brain needs real accepted answers in [Discussions Q&A](https://github.com/IgorGanapolsky/ThumbGate/discussions/categories/q-a). `npm run github:achievements -- --fixture tests/fixtures/github-achievements.json --json` inventories what is already earned vs what we refuse to farm.
|
|
116
40
|
|
|
117
|
-
|
|
41
|
+
### Who it's for
|
|
118
42
|
|
|
119
|
-
|
|
43
|
+
ThumbGate is for operators whose AI coding agents can leak a secret or destroy a checkout before a human sees the tool call (Claude Code, Cursor, Codex, Gemini CLI, MCP). Discovery should reach those operators — not a star campaign.
|
|
120
44
|
|
|
121
|
-
|
|
45
|
+
ThumbGate is **not** a GitHub star package, not fake engagement, and not a substitute for npm installs or merged PRs. Real engagement is `npx thumbgate init` and a PreToolUse hook that actually fires.
|
|
122
46
|
|
|
123
|
-
|
|
47
|
+
### Tech memes (shareable)
|
|
124
48
|
|
|
125
|
-
|
|
49
|
+
Lightweight visuals for how agents fail without a pre-action gate:
|
|
126
50
|
|
|
127
|
-
|
|
51
|
+
| Meme | Meaning |
|
|
52
|
+
|------|---------|
|
|
53
|
+
|  | Unchecked tool calls ship destructive commands. |
|
|
54
|
+
|  | A prompt is advice; a PreToolUse hook is enforcement. |
|
|
128
55
|
|
|
129
|
-
## The Problem — repeated failures consume model, tool, and review time
|
|
130
56
|
|
|
131
|
-
When an agent repeats a failed action, the cost is not just the model call. It is also the attempted tool action, diagnosis, remediation, and review. ThumbGate records concrete corrections so recurring failures can become explicit checks instead of relying on the model to remember a prior session.
|
|
132
57
|
|
|
133
|
-
|
|
58
|
+
It **hard-blocks detected secret leaks and two direct self-disable command classes by default** — commands that terminate the ThumbGate gate process or enable its bypass environment override. Other high-risk classes (`rm -rf`, force-push, fetch-and-run, direct guardrail edits) **warn and log by default**. Set `THUMBGATE_STRICT_ENFORCEMENT=1` for strict enforcement (warnings become hard denies).
|
|
134
59
|
|
|
135
|
-
|
|
60
|
+
| Verdict | Default behavior |
|
|
61
|
+
|---------|------------------|
|
|
62
|
+
| ⛔ **Hard-block** | Detected secret leaks; process-kill/environment-override self-disable |
|
|
63
|
+
| 👎 **Warn + log** | `rm -rf`, `git push --force`, fetch-and-run, direct guardrail edits — **warn by default** |
|
|
64
|
+
| 👍 **Allow** | Everything else |
|
|
136
65
|
|
|
137
|
-
|
|
66
|
+
**Accepted feedback is stored as local lessons.** Repeated concrete failures can become prevention rules that promote from warnings to blocking gates. The firewall improves from operations without retraining the model. Prompt evaluation (`npx thumbgate eval`) turns accepted feedback into reusable eval cases and local proof reports.
|
|
138
67
|
|
|
139
|
-
|
|
68
|
+
**Honest disclaimer:** ThumbGate does not update model weights. It intercepts tool calls at runtime. Local-first — no cloud required for the enforcement path.
|
|
140
69
|
|
|
141
|
-
|
|
70
|
+
Works with **Claude Code, Cursor, Codex, Gemini CLI, Amp, Cline, OpenCode**, and other MCP agents.
|
|
142
71
|
|
|
143
|
-
|
|
72
|
+
[](https://thumbgate.ai/#demo?utm_source=github&utm_medium=readme_meme)
|
|
144
73
|
|
|
145
|
-
ThumbGate gives your repo a **context brain**: a single, versioned, agent-readable artifact that consolidates everything the agent should know *before it acts* — the lessons it has learned, the guardrails it must not cross, the gates that are enforced, and the project's own instruction files.
|
|
146
|
-
|
|
147
|
-
```bash
|
|
148
|
-
npx thumbgate brain --write # → .thumbgate/BRAIN.md
|
|
149
74
|
```
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
## What this codebase taught its agents (lessons)
|
|
156
|
-
- ⛔ Force-pushing to main was rejected — use --force-with-lease on feature branches only
|
|
157
|
-
## Guardrails — do NOT repeat these (prevention rules)
|
|
158
|
-
- Never run DROP on production tables
|
|
159
|
-
## Active enforcement (gates)
|
|
160
|
-
- `DROP.*production` → warn + log (hard-block under strict enforcement)
|
|
75
|
+
Agent tries: rm -rf tests/
|
|
76
|
+
ThumbGate: 👎 WARN + LOG — "Never delete test directories"
|
|
77
|
+
Pattern matched: rm.*-rf.*tests
|
|
78
|
+
Source: your thumbs-down from last Tuesday
|
|
79
|
+
Strict mode: ⛔ DENY before tool execution
|
|
161
80
|
```
|
|
162
81
|
|
|
163
|
-
|
|
82
|
+
### Agentic development cycle fit
|
|
83
|
+
|
|
84
|
+
Agentic development is becoming a loop: **Guide → Generate → Verify → Solve**. ThumbGate is the pre-action gate / pre-action boundary between generated intent and executed action.
|
|
164
85
|
|
|
165
86
|
---
|
|
166
87
|
|
|
167
88
|
## Quick Start
|
|
168
89
|
|
|
90
|
+
> Want a phased walkthrough with a verify step at every stage? Follow the [Progressive Setup Guide](GUIDE.md).
|
|
91
|
+
|
|
92
|
+
Progressive wiring — prove the pipe before you turn matching on. Empty dashboard is success.
|
|
93
|
+
|
|
169
94
|
```bash
|
|
170
|
-
npx thumbgate init
|
|
171
|
-
npx thumbgate
|
|
95
|
+
npx thumbgate init # Phase 1: hooks only
|
|
96
|
+
npx thumbgate doctor # verify: exits 0 only when PreToolUse hook is wired (hidden metric = hook install, not gate count)
|
|
97
|
+
npx thumbgate dashboard --open # Phase 2: open local HTML; empty stats are OK
|
|
98
|
+
npx thumbgate capture --feedback=down --context="Never run DROP on production tables" --what-went-wrong="agent proposed DROP" --what-to-change="require review for DROP"
|
|
172
99
|
```
|
|
173
100
|
|
|
174
|
-
|
|
101
|
+
Later `DROP` attempts in the same scope surface the check:
|
|
175
102
|
|
|
176
103
|
```
|
|
177
104
|
⚠️ Check fired: "Never run DROP on production tables"
|
|
178
105
|
Pattern: DROP.*production
|
|
179
|
-
Verdict: WARN + LOG (BLOCK when THUMBGATE_STRICT_ENFORCEMENT=1)
|
|
106
|
+
Verdict: 👎 WARN + LOG (⛔ BLOCK when THUMBGATE_STRICT_ENFORCEMENT=1)
|
|
180
107
|
```
|
|
181
108
|
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
## Architecture
|
|
185
|
-
|
|
186
|
-
ThumbGate operates as a 4-layer enforcement stack between your AI agent and your codebase:
|
|
187
|
-
|
|
188
|
-

|
|
189
|
-
|
|
190
|
-
### Layer 1: Feedback Capture
|
|
191
|
-
Concrete thumbs-up/down feedback can be captured through the MCP protocol, CLI, or a configured GPT Action. Accepted feedback is stored as a structured local lesson with the available context, timestamp, and severity.
|
|
192
|
-
|
|
193
|
-
### Layer 2: Check Engine
|
|
194
|
-
The check engine can promote qualifying recurring lessons into rules. **The runtime gate decision is deterministic** — literal pattern match → AST match → scoped rule lookup. No LLM call runs on the enforcement path.
|
|
195
|
-
|
|
196
|
-
Where retrieval is needed (an agent is about to run a destructive command not on the literal block list, but semantically similar to a prior rule), ThumbGate uses local CPU-only `bge-small` embeddings via LanceDB's built-in pipeline. That path makes no external inference API call. So **"no LLM in enforcement"** holds: the gate decision uses no LLM; the rule corpus is searchable via local embeddings.
|
|
109
|
+
Numbered configs: [`config/progressive/`](config/progressive/). Guide: [progressive wiring](https://thumbgate.ai/guides/progressive-wiring).
|
|
197
110
|
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
Rules stay in local ThumbGate runtime state.
|
|
201
|
-
|
|
202
|
-
### Layer 3: Pre-Action Interception
|
|
203
|
-
For agents wired to the hook, ThumbGate evaluates each proposed tool call against active checks before tool execution and records the resulting decision. Detected secret leaks and the self-protect process-kill/environment-override gates deny by default. Direct guardrail-file edits, `rm -rf`, force-push, and fetch-and-run warn and log by default; strict mode preserves matched deny decisions.
|
|
204
|
-
|
|
205
|
-
### Layer 4: Multi-Agent Distribution (why not a hand-rolled hook?)
|
|
206
|
-
Claude Code already ships `permissions.deny` and `PreToolUse` hooks. Cursor and Codex have their own. So why ThumbGate over a hand-written hook?
|
|
207
|
-
|
|
208
|
-
Two things hand-written hooks structurally cannot do:
|
|
209
|
-
|
|
210
|
-
1. **Cross-agent reuse.** A `permissions.deny` pattern lives in one agent's config and stays there. ThumbGate integrations configured to use the same local install scope can read the same lesson and rule store across Claude Code, Codex, Gemini CLI, Cline, OpenCode, and Amp.
|
|
211
|
-
2. **Learning loop.** A hand-written hook covers exactly the patterns you wrote. ThumbGate can promote qualifying recurring failures into rules, tune soft-rule confidence weights from outcomes (Thompson Sampling, see Layer 2), and retrieve semantically near patterns with local embeddings.
|
|
212
|
-
|
|
213
|
-
Hand-rolled hooks are the right tool for a small, static denylist you maintain by hand. ThumbGate is useful when configured agent integrations should evaluate the same local lessons and rules.
|
|
214
|
-
|
|
215
|
-
Prompt engineering still matters, but it is only the starting point. ThumbGate adds prompt evaluation on top: proof lanes, benchmarks, and self-heal checks produce reviewable evidence about whether a prompt and workflow held up under execution. Run `npx thumbgate eval --from-feedback --write-report=.thumbgate/prompt-eval-proof.md` to turn accepted thumbs-up/down feedback into reusable eval cases and a local proof report.
|
|
216
|
-
|
|
217
|
-
### How ThumbGate knows an AI agent is working
|
|
218
|
-
|
|
219
|
-
ThumbGate does not treat a plausible response, a successful tool call, or a
|
|
220
|
-
demo as task success. The `record_task_outcome` MCP tool and
|
|
221
|
-
`POST /v1/task-outcomes` API require a task-level receipt. A receipt is marked
|
|
222
|
-
`working: true` only when the task is completed, verification passed, evidence
|
|
223
|
-
is present, tool contracts and policy checks passed, no unsupported claim was
|
|
224
|
-
recorded, and no side effect was duplicated.
|
|
225
|
-
|
|
226
|
-
The metrics remain separate so a strong average cannot conceal an unsafe
|
|
227
|
-
failure:
|
|
228
|
-
|
|
229
|
-
| Layer | Measured signals |
|
|
230
|
-
|-------|------------------|
|
|
231
|
-
| Task | verified completion, evidence-backed completion, first-attempt success, repeated failure, recovery, rollback |
|
|
232
|
-
| Tool | contract accuracy, execution success, retry rate, duplicate side effects |
|
|
233
|
-
| Safety | unsafe escapes, policy violations, safe-action false blocks |
|
|
234
|
-
| Escalation | correct escalation rate and human decision latency |
|
|
235
|
-
| Efficiency | p50/p95 latency, total cost, cost per verified success |
|
|
236
|
-
| Business | explicit KPI values grouped by unit; no inferred revenue |
|
|
237
|
-
|
|
238
|
-
```bash
|
|
239
|
-
npm run eval:agent-outcomes # 8 reviewed golden cases; fails on regression
|
|
240
|
-
npm run monitor:agent-outcomes # local production receipts; fails on missing evidence
|
|
241
|
-
npm run monitor:agent-outcomes -- --hosted
|
|
242
|
-
npm run monitor:agent-outcomes -- --install-schedule
|
|
243
|
-
```
|
|
244
|
-
|
|
245
|
-
Prompt evaluation is deterministic first. JSON outputs are validated against
|
|
246
|
-
their declared schema. An LLM judge may add a separate score, but an unavailable
|
|
247
|
-
or failed judge is reported as `deterministic_only`; it is never converted into
|
|
248
|
-
a neutral pass. Empty feedback or task-outcome datasets return
|
|
249
|
-
`insufficient_evidence`.
|
|
250
|
-
|
|
251
|
-
Task outcome receipts are stored locally in
|
|
252
|
-
`.thumbgate/task-outcome-receipts.jsonl`. Observable tool traces exclude raw
|
|
253
|
-
hidden reasoning and deterministic tool-argument fingerprints. Human
|
|
254
|
-
escalation requests are append-only, must carry evidence and requester
|
|
255
|
-
identity, and expire. Decisions require both the ordinary API credential and
|
|
256
|
-
an independently revocable `X-ThumbGate-Human-Reviewer-Key`; the decision
|
|
257
|
-
actor comes from server-side `THUMBGATE_HUMAN_REVIEWER_ID` configuration, not
|
|
258
|
-
from caller-controlled JSON.
|
|
259
|
-
|
|
260
|
-
The installed daily monitor runs through ThumbGate's local scheduler rather
|
|
261
|
-
than consuming a GitHub-hosted cron runner. It reads operator authentication
|
|
262
|
-
from the existing environment or local operator config, never from command-line
|
|
263
|
-
arguments, and writes a machine-readable report under
|
|
264
|
-
`~/.thumbgate/reports/agent-outcome-monitor.json`. The GitHub workflow remains
|
|
265
|
-
manual for release-time verification.
|
|
266
|
-
|
|
267
|
-
The complete five-system architecture review—local RAG, tool-using agents,
|
|
268
|
-
multi-agent handoffs, MCP enterprise integration, and production
|
|
269
|
-
evaluation/observability—is maintained in
|
|
270
|
-
[`VERIFICATION_EVIDENCE.md`](./VERIFICATION_EVIDENCE.md). It answers why each
|
|
271
|
-
architecture exists, what can fail, how it is measured and secured, how it is
|
|
272
|
-
deployed, and what evidence is required before claiming it works.
|
|
273
|
-
|
|
274
|
-
The full framework decision and one end-to-end RAG request—tenant authorization,
|
|
275
|
-
query transformation, parent-child retrieval, hybrid fusion, reranking,
|
|
276
|
-
structured generation, evaluation, and tracing—are documented in
|
|
277
|
-
[`docs/RAG_PRODUCTION_ARCHITECTURE.md`](./docs/RAG_PRODUCTION_ARCHITECTURE.md).
|
|
278
|
-
|
|
279
|
-
### Retrieval & latency: local-first, zero network hops
|
|
280
|
-
|
|
281
|
-
ThumbGate's latency advantage is structural, not a tuned cloud cluster: there is no retrieval service and no model on the enforcement path, so the gate decision never leaves your machine.
|
|
282
|
-
|
|
283
|
-
```mermaid
|
|
284
|
-
flowchart LR
|
|
285
|
-
A["Agent about to run<br/>a tool call"] --> B{"Literal / AST match<br/>on an active rule?"}
|
|
286
|
-
B -- "exact match" --> D["Deterministic gate decision<br/>(no model, on-device)"]
|
|
287
|
-
B -- "no exact match, but<br/>semantically near a<br/>blocked pattern" --> C["Local CPU embeddings<br/>bge-small via LanceDB<br/>(no external API)"]
|
|
288
|
-
C --> D
|
|
289
|
-
D -- "secret exfil / self-protect" --> E["⛔ Hard-block before execution"]
|
|
290
|
-
D -- "other known-bad" --> G["⚠️ Warn + log<br/>(hard-block under strict)"]
|
|
291
|
-
D -- "safe" --> F["✓ Allow"]
|
|
292
|
-
```
|
|
293
|
-
|
|
294
|
-
- **Deterministic first.** Most decisions are a local literal or AST pattern match against active rules and do not require embeddings.
|
|
295
|
-
- **Local semantic fallback.** When an action isn't on the literal block list but is semantically near one you've blocked before, ThumbGate searches the rule corpus with CPU-only `bge-small` embeddings via LanceDB — still local, still no external API call.
|
|
296
|
-
- **No LLM on the enforcement path.** The gate never calls a model to decide allow, warn, or deny. Thompson Sampling only tunes soft-rule confidence weights; hard-pattern matching remains deterministic, and the enforcement posture determines whether a match warns or denies (see Layer 2).
|
|
297
|
-
|
|
298
|
-
The enforcement decision is local: there is no cloud retrieval or model-inference hop on that path. Measure end-to-end latency in your own agent and machine configuration.
|
|
299
|
-
|
|
300
|
-
### Managed model benchmark lane
|
|
111
|
+
### MCP / Glama / registry install (stdio)
|
|
301
112
|
|
|
302
|
-
|
|
113
|
+
Directories and clients that install ThumbGate as an MCP server must start **stdio MCP**, not the HTTP API:
|
|
303
114
|
|
|
304
115
|
```bash
|
|
305
|
-
npx
|
|
306
|
-
npx thumbgate model-candidates --workload=long-trace-review --provider=openai-compatible --gateway=tinker --json
|
|
116
|
+
npx -y thumbgate serve
|
|
307
117
|
```
|
|
308
118
|
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
- `tinker/qwen3.6-35b-a3b` for pre-action gating, agentic coding, and tool-use
|
|
312
|
-
- `tinker/qwen3.6-27b` for the cheap fast-path
|
|
313
|
-
- `tinker/kimi-k2.6-128k` for long-trace review and multi-agent sessions
|
|
314
|
-
|
|
315
|
-
Each recommendation ships with the benchmark commands to run next: feedback-derived prompt eval, `gate-eval`, and `thumbgate bench`. For whole-repo clone claims, add `npx thumbgate bench --programbench-smoke` to generate a ProgramBench-style cleanroom proof report without claiming an official ProgramBench score. That keeps model selection evidence-backed instead of hype-driven.
|
|
316
|
-
|
|
317
|
-

|
|
119
|
+
- Equivalent: `npx -y thumbgate mcp`
|
|
120
|
+
- Do **not** use `npm start` for MCP — that launches the hosted HTTP API (`src/api/server.js`), not the agent-facing stdio server.
|
|
318
121
|
|
|
319
|
-
|
|
122
|
+
[**▶ 90-second demo**](https://thumbgate.ai/#demo?utm_source=github&utm_medium=readme&utm_campaign=demo_video) · [GIF walkthrough](docs/media/thumbgate-demo.gif)
|
|
320
123
|
|
|
321
124
|
---
|
|
322
125
|
|
|
323
|
-
## Install for
|
|
324
|
-
|
|
325
|
-
Enforcement depends on what the harness lets us intercept, so the table says which
|
|
326
|
-
you get. This distinction is real: with a pre-tool hook ThumbGate stops the action
|
|
327
|
-
before it runs; over MCP only, ThumbGate answers `gate_check` and the agent decides
|
|
328
|
-
whether to obey.
|
|
126
|
+
## Install for your agent
|
|
329
127
|
|
|
330
128
|
| Agent | Command | Enforcement |
|
|
331
129
|
|-------|---------|-------------|
|
|
332
|
-
| **Claude Code** | `npx thumbgate init --agent claude-code` | Hard — PreToolUse
|
|
333
|
-
| **Codex** | `npx thumbgate init --agent codex` | Hard — `pre_tool_use`
|
|
334
|
-
| **Gemini CLI** | `npx thumbgate init --agent gemini` | Hard — PreToolUse
|
|
335
|
-
| **ForgeCode** | `npx thumbgate init --agent forge` | Hard — `pre_tool_use`
|
|
336
|
-
| **Cursor** | `npx thumbgate init --agent cursor` | Advisory — MCP `gate_check` |
|
|
337
|
-
| **Cline**
|
|
338
|
-
| **OpenCode** | `npx thumbgate init --agent opencode` | Advisory — MCP `gate_check` |
|
|
339
|
-
| **Any MCP agent** | `npx thumbgate serve` | Advisory — MCP `gate_check` |
|
|
340
|
-
| **Amp** | `npx thumbgate init --agent amp` | Feedback capture
|
|
341
|
-
| **
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
| **JetBrains** | [plugins/jetbrains-plugin/README.md](plugins/jetbrains-plugin/README.md) | See plugin README |
|
|
345
|
-
|
|
346
|
-
**Advisory means the agent can ignore it.** Harnesses without a pre-tool hook expose no
|
|
347
|
-
interception point, so ThumbGate cannot stop the call itself — it returns a verdict the
|
|
348
|
-
agent is instructed to honor. Treat advisory coverage as a strong default, not a
|
|
349
|
-
guarantee, and prefer a hard-enforcement harness for anything irreversible.
|
|
350
|
-
|
|
351
|
-
The gate is **model-agnostic**: verdicts come from deterministic policy evaluation over
|
|
352
|
-
the proposed tool call (`scripts/gates-engine.js`), never from an LLM. Swapping the model
|
|
353
|
-
behind any harness does not change what is allowed.
|
|
354
|
-
|
|
355
|
-
> **Enforcement posture:** ThumbGate ships **warn-by-default** — a matched gate is logged
|
|
356
|
-
> and surfaced, not blocked. Set `THUMBGATE_STRICT_ENFORCEMENT=1` to hard-block. The
|
|
357
|
-
> `gate_check` tool reports `warn` (never `allow`) when a gate matched but posture
|
|
358
|
-
> downgraded it, so an agent is never told a flagged action is fine.
|
|
130
|
+
| **Claude Code** | `npx thumbgate init --agent claude-code` | 🛡️ Hard — PreToolUse |
|
|
131
|
+
| **Codex** | `npx thumbgate init --agent codex` | 🛡️ Hard — `pre_tool_use` |
|
|
132
|
+
| **Gemini CLI** | `npx thumbgate init --agent gemini` | 🛡️ Hard — PreToolUse |
|
|
133
|
+
| **ForgeCode** | `npx thumbgate init --agent forge` | 🛡️ Hard — `pre_tool_use` |
|
|
134
|
+
| **Cursor** | `npx thumbgate init --agent cursor` | 💬 Advisory — MCP `gate_check` |
|
|
135
|
+
| **Cline** | `npx thumbgate init --agent cline` | 💬 Advisory — MCP + `.clinerules` |
|
|
136
|
+
| **OpenCode** | `npx thumbgate init --agent opencode` | 💬 Advisory — MCP `gate_check` |
|
|
137
|
+
| **Any MCP agent** | `npx thumbgate serve` | 💬 Advisory — MCP `gate_check` |
|
|
138
|
+
| **Amp** | `npx thumbgate init --agent amp` | 📝 Feedback capture |
|
|
139
|
+
| **GitHub Actions** | `uses: IgorGanapolsky/ThumbGate@v1` | 🩺 Marketplace Action — doctor / AI inventory in CI |
|
|
140
|
+
|
|
141
|
+
Per-agent guides: [Claude/Codex bridge](plugins/claude-codex-bridge/README.md) · [Codex profile](plugins/codex-profile/README.md) · [Cursor](docs/CURSOR_PLUGIN_OPERATIONS.md) · [MCP setup](docs/MCP_AUTONOMOUS_SETUP.md)
|
|
359
142
|
|
|
360
143
|
### Install scope: machine-wide vs per-project
|
|
361
144
|
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
|
365
|
-
|
|
366
|
-
| **Machine-wide** (default) | `npx thumbgate init` | `~/.claude/settings.json` | `~/.claude/memory/feedback/` | Solo operator — configured repos can use the same machine-local feedback store. Matching actions are evaluated according to the active policy; cross-repo blocking is not automatic without the relevant integration and rule. |
|
|
367
|
-
| **Per-project** | `npx thumbgate init --project` (in the repo root) | `<repo>/.claude/settings.json` | `<repo>/.claude/memory/feedback/` | Client work, compliance, or multi-tenant — **separate dashboard per repo**, lessons stay isolated, audit trail belongs to the repo. |
|
|
368
|
-
|
|
369
|
-
Both scopes write `mcpServers.thumbgate` + the PreToolUse / UserPromptSubmit / PostToolUse / SessionStart hooks; the only difference is *where*. Machine-wide is the right default for most developers. Switch to `--project` only when you have a reason to keep lessons from bleeding between repos.
|
|
370
|
-
|
|
371
|
-
> Per-project lesson DBs live under each repo's `.claude/memory/feedback/` and **must stay gitignored** — they're a runtime store, not source. ThumbGate's bundled `.gitignore` template handles this.
|
|
372
|
-
|
|
373
|
-
### Status bar proof
|
|
374
|
-
|
|
375
|
-

|
|
376
|
-
|
|
377
|
-

|
|
378
|
-
|
|
379
|
-
Claude renders the live ThumbGate footer today. `npx thumbgate init --agent codex` now installs the full Codex hook bundle and writes the ThumbGate `statusLine` target into `~/.codex/config.json` so you can test it on your local Codex build immediately.
|
|
380
|
-
|
|
381
|
-
### Install Codex Plugin
|
|
382
|
-
|
|
383
|
-
Open the Codex plugin install page or download the standalone bundle from GitHub Releases. The Codex launcher resolves `thumbgate@latest` when MCP and hooks start, so published npm fixes reach active Codex installs without hand-editing `~/.codex/config.toml`.
|
|
384
|
-
|
|
385
|
-
1. Install page: [thumbgate.ai/codex-plugin](https://thumbgate.ai/codex-plugin)
|
|
386
|
-
2. Direct zip: [thumbgate-codex-plugin.zip](https://github.com/IgorGanapolsky/ThumbGate/releases/latest/download/thumbgate-codex-plugin.zip)
|
|
387
|
-
3. Follow: [plugins/codex-profile/INSTALL.md](plugins/codex-profile/INSTALL.md)
|
|
145
|
+
| Scope | Command | Settings | Lessons | Best for |
|
|
146
|
+
|-------|---------|----------|---------|----------|
|
|
147
|
+
| **Machine-wide** (default) | `npx thumbgate init` | `~/.claude/settings.json` | `~/.claude/memory/feedback/` | Solo operators — **same machine-local feedback store** across repos |
|
|
148
|
+
| **Per-project** | `npx thumbgate init --project` | `<repo>/.claude/settings.json` | `<repo>/.claude/memory/feedback/` | Client / compliance — **separate dashboard** / isolated lessons per repo |
|
|
388
149
|
|
|
389
|
-
|
|
150
|
+
Both scopes write `mcpServers.thumbgate` plus PreToolUse / UserPromptSubmit / PostToolUse / SessionStart hooks. Machine-wide is the right default for most developers. Cross-repo blocking is not automatic: a lesson learned in one project only applies elsewhere when you share the store (machine-wide) or export/import lessons.
|
|
390
151
|
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
1. App page: [thumbgate.ai/chatgpt-app](https://thumbgate.ai/chatgpt-app)
|
|
394
|
-
2. Live GPT: [thumbgate.ai/go/gpt](https://thumbgate.ai/go/gpt?utm_source=github&utm_medium=readme&utm_campaign=chatgpt_app)
|
|
395
|
-
3. GPT Action schema: [thumbgate.ai/openapi.yaml](https://thumbgate.ai/openapi.yaml)
|
|
396
|
-
4. Follow: [adapters/chatgpt/INSTALL.md](adapters/chatgpt/INSTALL.md)
|
|
152
|
+
**MCP tools (surface):** `gate_check` (read/evaluate proposed tool call), feedback capture + session tools (write), dashboard/stats (read). Destructive agent actions stay blocked/warned by PreToolUse — ThumbGate does not execute user shell commands for you.
|
|
397
153
|
|
|
398
154
|
---
|
|
399
155
|
|
|
400
|
-
##
|
|
401
|
-
|
|
402
|
-
```
|
|
403
|
-
STEP 1 STEP 2 STEP 3
|
|
404
|
-
──────── ──────── ────────
|
|
156
|
+
## Discoverable slash-commands — the guardrail layer for spec-driven agents
|
|
405
157
|
|
|
406
|
-
|
|
158
|
+
Spec-driven agent frameworks like **GSD** (get-shit-done) and **GitHub Spec Kit** plan and generate work. ThumbGate is the **guardrail layer for spec-driven agents**: it sits *after* the plan, on the boundary between a generated tool call and its execution — **alongside GSD / Spec-Kit, not instead of them**.
|
|
407
159
|
|
|
408
|
-
|
|
409
|
-
agent action becomes a lesson can become a rule:
|
|
410
|
-
👍 on a good ──► Good pattern gets 🚦 flagged + logged
|
|
411
|
-
agent action reinforced (hard-blocked for
|
|
412
|
-
secret exfil / strict
|
|
413
|
-
mode, or ✅ allowed)
|
|
414
|
-
```
|
|
160
|
+
`npx thumbgate init` installs these into your agent palette:
|
|
415
161
|
|
|
416
|
-
|
|
162
|
+
| Command | What it does |
|
|
163
|
+
|---------|--------------|
|
|
164
|
+
| `/thumbgate-dashboard` | Open local project dashboard |
|
|
165
|
+
| `/thumbgate-guard` | Turn last mistake into a hard prevention rule |
|
|
166
|
+
| `/thumbgate-rules` | List active rules & lessons |
|
|
167
|
+
| `/thumbgate-blocked` | Gate stats + enforcement matrix |
|
|
168
|
+
| `/thumbgate-protect` | Branch governance + scoped approval |
|
|
169
|
+
| `/thumbgate-doctor` | Health-check hooks, MCP, readiness |
|
|
417
170
|
|
|
418
171
|
---
|
|
419
172
|
|
|
420
|
-
|
|
173
|
+
## Pricing & buyer paths
|
|
421
174
|
|
|
422
|
-
|
|
423
|
-
- **Catch repeated AI mistakes** — turn recurring failures into rules that warn and log by default, hard-block detected secret leaks and direct self-disable commands, and deny matched blocking rules under strict enforcement.
|
|
424
|
-
- **Turn AI into a reliable operator** — move from a smart assistant that apologizes after damage to a production-ready operator with checkpoints, proof, and enforcement.
|
|
425
|
-
- **Measure prompts instead of rewriting them blindly** — use `thumbgate eval --from-feedback`, proof lanes, ThumbGate Bench, and `self-heal:check` to evaluate whether prompts and workflows actually improved behavior.
|
|
175
|
+
Free tier: **2 feedback captures/day (10 total)** and **up to 3 active auto-promoted prevention rules**. Pro ($19/mo or $149/yr) is the individual tier for unlimited rules, history-aware lessons, linked feedback session flow, personal dashboard, and DPO export. **Enterprise is custom and scoped after intake**; hosted team lesson sync and a hosted org dashboard are not general availability.
|
|
426
176
|
|
|
427
|
-
|
|
177
|
+
| | Free | Pro ($19/mo or $149/yr) | Enterprise |
|
|
178
|
+
|---|---|---|---|
|
|
179
|
+
| Local CLI + PreToolUse | ✅ | ✅ | Scoped after intake |
|
|
180
|
+
| Feedback captures | 2 feedback captures/day (10 total) | Unlimited | Scoped after intake |
|
|
181
|
+
| Active auto-promoted rules | up to 3 active auto-promoted prevention rules | Unlimited | Scoped after intake |
|
|
182
|
+
| Personal dashboard + DPO export | — | ✅ | Reviewed during intake |
|
|
183
|
+
| Hosted team lesson sync | — | — | Not general availability |
|
|
184
|
+
| Hosted org dashboard | — | — | Not general availability |
|
|
428
185
|
|
|
429
|
-
|
|
186
|
+
**Enterprise intake path:** the **Workflow Hardening Sprint** scopes one repeated failure before any broader rollout commitment. **[Start intake →](https://thumbgate.ai/?utm_source=github&utm_medium=readme&utm_campaign=team_rollout#workflow-sprint-intake)**
|
|
430
187
|
|
|
431
|
-
|
|
432
|
-
- **Catch force-push to main** — Check flags `git push --force` on protected branches before it runs, and hard-blocks it under `THUMBGATE_STRICT_ENFORCEMENT=1`
|
|
433
|
-
- **Catch repeated migration failures** — accepted feedback becomes a searchable lesson; recurring patterns can become checks
|
|
434
|
-
- **Flag unauthorized file edits** — path-based rules warn by default and deny matching actions under strict enforcement
|
|
435
|
-
- **Local lessons across sessions** — configured integrations can load accepted feedback from the same local store
|
|
436
|
-
- **Portable lesson handoff** — Pro export/import moves reviewable lesson bundles between operator-managed instances
|
|
437
|
-
- **Outcome-derived proposals** — evaluation lanes can propose rules for operator review
|
|
188
|
+
**Local technical path:** install the CLI and use `init` plus the documented setup so Pre-Action Checks evaluate tool calls where the agent actually runs.
|
|
438
189
|
|
|
439
|
-
|
|
190
|
+
**First-dollar activation path:** open the [ThumbGate GPT](https://thumbgate.ai/go/gpt?utm_source=github&utm_medium=readme), paste the risky action, capture typed feedback (`thumbs down:` / `thumbs up:`). **Native ChatGPT rating buttons are not the ThumbGate capture path.** Ask: **what repeated AI mistake would be worth catching before the tool executes?**
|
|
440
191
|
|
|
441
|
-
|
|
192
|
+
**Paid path for individual operators:** [ThumbGate Pro](https://thumbgate.ai/checkout/pro?utm_source=github&utm_medium=readme&utm_campaign=pro_page) is the self-serve side lane for a personal dashboard and export-ready evidence.
|
|
442
193
|
|
|
443
|
-
|
|
444
|
-
- **Financial compliance** — gate templates for AI-generated trade recommendations, unauthorized disclosures, and approval chains before customer-facing outputs
|
|
445
|
-
- **Healthcare** — templates to keep AI agents from providing medical diagnoses, route data along HIPAA-compliant paths, and require clinician review before patient-facing content
|
|
446
|
-
- **Local decision records** — gate results preserve the decision and the rule, reason, timestamp, and context fields available to that evaluation
|
|
194
|
+
[**Start free**](https://thumbgate.ai/?utm_source=github&utm_medium=readme) · [**Pro $19/mo**](https://thumbgate.ai/checkout/pro?utm_source=github&utm_medium=readme) · [**Live Dashboard**](https://thumbgate.ai/dashboard?utm_source=github&utm_medium=readme) · [**Team Sprint intake**](https://thumbgate.ai/?utm_source=github&utm_medium=readme#workflow-sprint-intake) · [**Workflow Hardening Sprint**](https://thumbgate.ai/?utm_source=github&utm_medium=readme&utm_campaign=top_cta#workflow-sprint-intake) · [**First Dollar Playbook**](docs/FIRST_DOLLAR_PLAYBOOK.md)
|
|
447
195
|
|
|
448
|
-
[
|
|
196
|
+
**Popular buyer questions:** **[AI search topical presence](https://thumbgate.ai/guides/ai-search-topical-presence?utm_source=github&utm_medium=readme&utm_campaign=buyer_questions)** · **[Relational knowledge and AI recommendations](https://thumbgate.ai/guides/relational-knowledge-ai-recommendations?utm_source=github&utm_medium=readme&utm_campaign=buyer_questions)** · **[AI Mode ads for agent governance](https://thumbgate.ai/guides/ai-mode-ads-agent-governance?utm_source=github&utm_medium=readme&utm_campaign=buyer_questions)** · **[MCP tool governance](https://thumbgate.ai/guides/mcp-tool-governance?utm_source=github&utm_medium=readme&utm_campaign=buyer_questions)** · **[AI agent pre-action approval gates](https://thumbgate.ai/guides/ai-agent-pre-action-approval-gates?utm_source=github&utm_medium=readme&utm_campaign=buyer_questions)** · **[Background agent governance](https://thumbgate.ai/guides/background-agent-governance?utm_source=github&utm_medium=readme&utm_campaign=buyer_questions)** · **[GPT-5.5 model evaluation](https://thumbgate.ai/guides/gpt-5-5-model-evaluation?utm_source=github&utm_medium=readme&utm_campaign=buyer_questions)** · **[Stop repeated AI agent mistakes](https://thumbgate.ai/guides/stop-repeated-ai-agent-mistakes?utm_source=github&utm_medium=readme&utm_campaign=buyer_questions)** · **[Browser automation safety](https://thumbgate.ai/guides/browser-automation-safety?utm_source=github&utm_medium=readme&utm_campaign=buyer_questions)** · **[Native messaging host security](https://thumbgate.ai/guides/native-messaging-host-security?utm_source=github&utm_medium=readme&utm_campaign=buyer_questions)** · **[Autoresearch agent safety](https://thumbgate.ai/guides/autoresearch-agent-safety?utm_source=github&utm_medium=readme&utm_campaign=buyer_questions)** · **[Cursor guardrails](https://thumbgate.ai/guides/cursor-agent-guardrails?utm_source=github&utm_medium=readme&utm_campaign=buyer_questions)** · **[Codex CLI guardrails](https://thumbgate.ai/guides/codex-cli-guardrails?utm_source=github&utm_medium=readme&utm_campaign=buyer_questions)** · **[Gemini CLI memory + enforcement](https://thumbgate.ai/guides/gemini-cli-feedback-memory?utm_source=github&utm_medium=readme&utm_campaign=buyer_questions)** · **[Google Cloud MCP guardrails](https://thumbgate.ai/guides/gcp-mcp-guardrails?utm_source=github&utm_medium=readme&utm_campaign=buyer_questions)** · **[Roo Code alternative: migrate to Cline](https://thumbgate.ai/guides/roo-code-alternative-cline?utm_source=github&utm_medium=readme&utm_campaign=buyer_questions)**
|
|
449
197
|
|
|
450
198
|
---
|
|
451
199
|
|
|
452
|
-
##
|
|
200
|
+
## How it works (short)
|
|
453
201
|
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
⚠️ force-push → flags git push --force (hard-block under strict)
|
|
459
|
-
⚠️ protected-branch → flags direct push to main (hard-block under strict)
|
|
460
|
-
⚠️ unresolved-threads → flags push with open reviews (hard-block under strict)
|
|
461
|
-
⚠️ package-lock-reset → flags destructive lock edits (hard-block under strict)
|
|
462
|
-
|
|
463
|
-
Configured hooks record decisions for evaluated calls. Detected secret leaks and
|
|
464
|
-
the process-kill/environment-override self-protect gates deny by default. Direct
|
|
465
|
-
guardrail-file edits, rm -rf, force-push, and fetch-and-run warn and log by
|
|
466
|
-
default; matched blocking rules deny under THUMBGATE_STRICT_ENFORCEMENT=1.
|
|
467
|
-
|
|
468
|
-
+ custom prevention rules for project-specific failures
|
|
469
|
-
```
|
|
470
|
-
|
|
471
|
-
---
|
|
472
|
-
|
|
473
|
-
## CLI Reference
|
|
202
|
+
1. **Capture** 👍/👎 feedback (CLI, MCP, linked feedback session flow / `open_feedback_session`, or [ThumbGate GPT](https://thumbgate.ai/go/gpt?utm_source=github&utm_medium=readme))
|
|
203
|
+
2. **Promote** concrete lessons via history-aware lesson distillation into prevention rules
|
|
204
|
+
3. **Evaluate** the next proposed tool call against active rules (literal/AST + local vectors)
|
|
205
|
+
4. **Allow / warn / deny** before the tool runs
|
|
474
206
|
|
|
475
207
|
```bash
|
|
476
|
-
npx thumbgate
|
|
477
|
-
npx thumbgate doctor # health check
|
|
478
|
-
npx thumbgate capture up|down "<text>" # capture a signal as a stored lesson (positional format)
|
|
479
|
-
npx thumbgate lessons # see what's been learned
|
|
480
|
-
npx thumbgate brain --write # build .thumbgate/BRAIN.md — the agent-readable context brain
|
|
481
|
-
npx thumbgate explore # terminal explorer for lessons, checks, stats
|
|
482
|
-
npx thumbgate background-governance # review background-agent run risk
|
|
483
|
-
npx thumbgate model-candidates --workload=dashboard-analysis --provider=openai --json # evaluate GPT-5.5 routing
|
|
484
|
-
npx thumbgate native-messaging-audit # inspect local browser bridges and extension hosts
|
|
485
|
-
npx thumbgate dashboard --open # open local project-scoped dashboard in browser
|
|
486
|
-
thumbgate-dashboard # global bin after npm i -g thumbgate; agents: /thumbgate-dashboard (Claude/Cursor) or /project:thumbgate-dashboard (Grok)
|
|
487
|
-
npx thumbgate check-update # check if a new version is available on npm/GitHub
|
|
488
|
-
npx thumbgate self-update # update ThumbGate to the latest version globally
|
|
489
|
-
npx thumbgate serve # start MCP server on stdio
|
|
490
|
-
npx thumbgate bench # run reliability benchmark
|
|
491
|
-
npx thumbgate bench --programbench-smoke # include cleanroom whole-repo proof lane
|
|
492
|
-
npx thumbgate break-glass --reason="ThumbGate over-fired" # short TTL recovery for gate over-fire
|
|
208
|
+
npx thumbgate brain --write # → .thumbgate/BRAIN.md (lessons + gates in one artifact)
|
|
493
209
|
```
|
|
494
210
|
|
|
495
|
-
|
|
211
|
+
Pro operators can invoke `search_lessons` through MCP and use `npx thumbgate lessons` from the CLI. History-aware feedback sessions and lesson search are Pro capabilities; Free does not include recall or search.
|
|
212
|
+
|
|
213
|
+
<details>
|
|
214
|
+
<summary><b>Architecture diagram & stack</b></summary>
|
|
496
215
|
|
|
497
|
-
ThumbGate
|
|
216
|
+
[](https://thumbgate.ai/#how-it-works)
|
|
498
217
|
|
|
499
|
-
```
|
|
500
|
-
|
|
218
|
+
```mermaid
|
|
219
|
+
flowchart LR
|
|
220
|
+
A["Agent tool call"] --> B{"Rule match?"}
|
|
221
|
+
B -- exact --> D["On-device gate"]
|
|
222
|
+
B -- semantic --> C["Local LanceDB"]
|
|
223
|
+
C --> D
|
|
224
|
+
D -- secret/kill --> E["⛔ Hard-block"]
|
|
225
|
+
D -- known-bad --> G["👎 Warn + log"]
|
|
226
|
+
D -- safe --> F["👍 Allow"]
|
|
501
227
|
```
|
|
502
228
|
|
|
503
|
-
|
|
229
|
+
</details>
|
|
504
230
|
|
|
505
|
-
|
|
506
|
-
-
|
|
231
|
+
<details>
|
|
232
|
+
<summary><b>Built-in checks</b></summary>
|
|
507
233
|
|
|
508
|
-
|
|
234
|
+
```
|
|
235
|
+
⛔ secret-exfiltration → hard-block (default)
|
|
236
|
+
⛔ self-protect-kill → hard-block (default)
|
|
237
|
+
⛔ self-protect-env → hard-block (default)
|
|
238
|
+
⚠️ force-push → warn; hard-block under strict
|
|
239
|
+
⚠️ protected-branch → warn; hard-block under strict
|
|
240
|
+
⚠️ unresolved-threads → warn; hard-block under strict
|
|
241
|
+
⚠️ package-lock-reset → warn; hard-block under strict
|
|
242
|
+
```
|
|
509
243
|
|
|
510
|
-
|
|
511
|
-
- Arbitrary protected files such as `README.md`, `AGENTS.md`, policy bundles, or credentials.
|
|
244
|
+
</details>
|
|
512
245
|
|
|
513
|
-
|
|
246
|
+
<details>
|
|
247
|
+
<summary><b>CLI cheatsheet</b></summary>
|
|
514
248
|
|
|
515
249
|
```bash
|
|
516
|
-
npx thumbgate
|
|
250
|
+
npx thumbgate init
|
|
517
251
|
npx thumbgate doctor
|
|
252
|
+
npx thumbgate capture up|down "<text>"
|
|
253
|
+
npx thumbgate lessons
|
|
254
|
+
npx thumbgate brain --write
|
|
255
|
+
npx thumbgate dashboard --open
|
|
256
|
+
npx thumbgate break-glass --reason="ThumbGate over-fired" # 5-min recovery
|
|
518
257
|
```
|
|
519
258
|
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
---
|
|
259
|
+
</details>
|
|
523
260
|
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
| | Free | Pro ($19/mo) | Enterprise |
|
|
527
|
-
|---|---|---|---|
|
|
528
|
-
| Local CLI + PreToolUse checks | ✅ | ✅ | Existing public runtime |
|
|
529
|
-
| Feedback captures | 2/day (10 total) | Unlimited | Scoped after intake |
|
|
530
|
-
| Active auto-promoted prevention rules | 3 | Unlimited | Scoped after intake |
|
|
531
|
-
| Configured agent integrations | ✅ | ✅ | Scoped after intake |
|
|
532
|
-
| Personal dashboard | — | ✅ | Reviewed during intake |
|
|
533
|
-
| DPO export (model fine-tuning data) | — | ✅ | Reviewed during intake |
|
|
534
|
-
| Lesson export/import | — | ✅ | Operator-managed bundles |
|
|
535
|
-
| Hosted team lesson sync | — | — | Not general availability |
|
|
536
|
-
| Hosted org dashboard | — | — | Not general availability |
|
|
537
|
-
| Approval boundaries + rollout proof | — | — | Scoped after intake |
|
|
538
|
-
|
|
539
|
-
The free tier gives you 2 feedback captures/day (10 total) and up to 3 active auto-promoted prevention rules. Documented integration paths for Claude Code, Cursor, Codex, Gemini, Amp, Cline, and OpenCode ship free; each agent must be configured through its hook or MCP setup.
|
|
540
|
-
|
|
541
|
-
Pro ($19/mo or $149/yr) is the individual tier: it removes the rule cap and adds history-aware lesson recall, lesson search, DPO export, and a personal dashboard. Enterprise is custom and scoped after intake around one workflow, its approval boundaries, rollback plan, evidence requirements, and rollout support. Hosted team lesson sync, hosted org dashboards, SSO, SIEM, and compliance packaging are not general-availability features in the current public runtime.
|
|
542
|
-
|
|
543
|
-
**Enterprise intake path:** the **Workflow Hardening Sprint** scopes one repeated failure before any broader rollout commitment. **[Start intake →](https://thumbgate.ai/?utm_source=github&utm_medium=readme&utm_campaign=team_rollout#workflow-sprint-intake)**
|
|
544
|
-
|
|
545
|
-
**Local technical path:** install the CLI and use `init` plus the documented setup for the agent you already use.
|
|
546
|
-
|
|
547
|
-
**Paid path for individual operators:** [ThumbGate Pro](https://thumbgate.ai/checkout/pro?utm_source=github&utm_medium=readme&utm_campaign=pro_page) is the self-serve side lane for a personal dashboard and export-ready evidence.
|
|
548
|
-
|
|
549
|
-
**[Start free](https://thumbgate.ai/?utm_source=github&utm_medium=readme)** · **[See Pro](https://thumbgate.ai/checkout/pro?utm_source=github&utm_medium=readme)** · **[Team Sprint intake](https://thumbgate.ai/?utm_source=github&utm_medium=readme#workflow-sprint-intake)**
|
|
550
|
-
|
|
551
|
-
---
|
|
552
|
-
|
|
553
|
-
## Portable Lesson Export/Import (Pro)
|
|
554
|
-
|
|
555
|
-
ThumbGate Pro can export lessons as portable bundles and import them into another operator-managed ThumbGate instance. This is an explicit export/import workflow, not automatic hosted sync or org-wide enforcement.
|
|
556
|
-
|
|
557
|
-
**Export lessons from one project:**
|
|
261
|
+
<details>
|
|
262
|
+
<summary><b>Pro: lesson + DPO export</b></summary>
|
|
558
263
|
|
|
559
264
|
```bash
|
|
265
|
+
# Portable lessons
|
|
560
266
|
curl -X POST http://localhost:3456/v1/lessons/export \
|
|
561
267
|
-H "Authorization: Bearer $THUMBGATE_API_KEY" \
|
|
562
268
|
-H "Content-Type: application/json" \
|
|
563
269
|
-d '{"outputPath": "./lessons-export.json"}'
|
|
564
|
-
```
|
|
565
|
-
|
|
566
|
-
Filter by signal or tags:
|
|
567
|
-
|
|
568
|
-
```bash
|
|
569
|
-
curl -X POST http://localhost:3456/v1/lessons/export \
|
|
570
|
-
-H "Authorization: Bearer $THUMBGATE_API_KEY" \
|
|
571
|
-
-H "Content-Type: application/json" \
|
|
572
|
-
-d '{"signal": "down", "tags": ["push-notifications", "ci"]}'
|
|
573
|
-
```
|
|
574
|
-
|
|
575
|
-
**Import into another operator-managed ThumbGate instance:**
|
|
576
|
-
|
|
577
|
-
```bash
|
|
578
|
-
curl -X POST http://localhost:3456/v1/lessons/import \
|
|
579
|
-
-H "Authorization: Bearer $THUMBGATE_API_KEY" \
|
|
580
|
-
-H "Content-Type: application/json" \
|
|
581
|
-
-d @lessons-export.json
|
|
582
|
-
```
|
|
583
270
|
|
|
584
|
-
|
|
585
|
-
- **Deduplication** — lessons with the same ID or title+signal are skipped
|
|
586
|
-
- **Provenance tracking** — every imported lesson is tagged `team-import` with original source project, export timestamp, and original ID
|
|
587
|
-
- **No overwrite** — import is additive; existing lessons are never modified
|
|
588
|
-
|
|
589
|
-
The export bundle includes full lesson metadata: signal, title, context, tags, failure type, skill, structured rules, and diagnosis. It's the same data you see in the lesson detail dashboard — portable as JSON.
|
|
590
|
-
|
|
591
|
-
**Use cases:**
|
|
592
|
-
- Move reviewable lesson patterns across repos under operator control
|
|
593
|
-
- Onboard another project with an explicitly reviewed lesson bundle
|
|
594
|
-
- Export lessons before a project handoff so institutional knowledge transfers
|
|
595
|
-
- Feed lessons from multiple teams into a centralized DPO training pipeline
|
|
596
|
-
|
|
597
|
-
---
|
|
598
|
-
|
|
599
|
-
## DPO Export for Fine-Tuning (Pro)
|
|
600
|
-
|
|
601
|
-
Accepted thumbs-up and thumbs-down feedback can supply preference data. ThumbGate Pro exports eligible captured feedback as DPO (Direct Preference Optimization) pairs for a separate LoRA or other fine-tuning workflow. The export does not guarantee model behavior; training and evaluation remain operator responsibilities.
|
|
602
|
-
|
|
603
|
-
**Export DPO pairs:**
|
|
604
|
-
|
|
605
|
-
```bash
|
|
271
|
+
# DPO pairs for fine-tuning
|
|
606
272
|
curl -X POST http://localhost:3456/v1/dpo/export \
|
|
607
273
|
-H "Authorization: Bearer $THUMBGATE_API_KEY" \
|
|
608
274
|
-o dpo-pairs.jsonl
|
|
609
275
|
```
|
|
610
276
|
|
|
611
|
-
|
|
612
|
-
- `chosen` — the agent action you thumbed up
|
|
613
|
-
- `rejected` — the action you thumbed down for the same task context
|
|
614
|
-
- `prompt` — the originating user intent
|
|
615
|
-
|
|
616
|
-
**Use cases:**
|
|
617
|
-
- Fine-tune Llama 3 / Mistral / local models with a LoRA adapter trained on your real mistakes
|
|
618
|
-
- Feed into RLAIF or KTO pipelines (KTO export also available via `/v1/kto/export`)
|
|
619
|
-
- Build a model that natively avoids your team's known failure patterns — no check at inference time needed
|
|
620
|
-
|
|
621
|
-
**Why this matters:** Checks can deny matching actions under policy. Fine-tuning may reduce attempts, but only evaluation can establish whether behavior changed.
|
|
277
|
+
</details>
|
|
622
278
|
|
|
623
279
|
---
|
|
624
280
|
|
|
625
281
|
## Tech Stack
|
|
626
282
|
|
|
627
|
-
| Layer |
|
|
628
|
-
|
|
283
|
+
| Layer | Tech |
|
|
284
|
+
|-------|------|
|
|
285
|
+
| **Runtime** | Node.js ≥18 |
|
|
286
|
+
| **Interfaces** | MCP stdio, HTTP API, CLI |
|
|
629
287
|
| **Storage** | SQLite + FTS5, LanceDB vectors, JSONL logs |
|
|
630
|
-
| **
|
|
631
|
-
| **
|
|
632
|
-
| **Enforcement** | PreToolUse hook engine, Checks config |
|
|
633
|
-
| **Interfaces** | MCP stdio, HTTP API, CLI (Node.js >=18) |
|
|
634
|
-
| **Billing** | Stripe |
|
|
288
|
+
| **Intelligence** | MemAlign dual recall, Thompson Sampling, local embeddings |
|
|
289
|
+
| **Billing / host** | Stripe, Railway |
|
|
635
290
|
| **Execution** | Railway, Cloudflare Workers, Docker Sandboxes |
|
|
636
291
|
| **Governance** | Workflow Sentinel, control plane, Docker Sandboxes |
|
|
637
292
|
|
|
@@ -639,137 +294,45 @@ Every Changeset is tied to the exact `main` merge commit and generates Verificat
|
|
|
639
294
|
|
|
640
295
|
---
|
|
641
296
|
|
|
642
|
-
|
|
643
|
-
|
|
644
|
-
**Conversational ad / AI-search answer assets:** **[AI Mode ads for agent governance](https://thumbgate.ai/guides/ai-mode-ads-agent-governance?utm_source=github&utm_medium=readme&utm_campaign=buyer_questions)** · **[MCP tool governance](https://thumbgate.ai/guides/mcp-tool-governance?utm_source=github&utm_medium=readme&utm_campaign=buyer_questions)** · **[AI agent pre-action approval gates](https://thumbgate.ai/guides/ai-agent-pre-action-approval-gates?utm_source=github&utm_medium=readme&utm_campaign=buyer_questions)**
|
|
645
|
-
|
|
646
|
-
**[Workflow Hardening Sprint](https://thumbgate.ai/?utm_source=github&utm_medium=readme&utm_campaign=top_cta#workflow-sprint-intake)** · **[Live Dashboard](https://thumbgate.ai/dashboard?utm_source=github&utm_medium=readme&utm_campaign=top_cta)**
|
|
647
|
-
|
|
648
|
-
---
|
|
649
|
-
|
|
650
|
-
## Integrations
|
|
651
|
-
|
|
652
|
-
- **[ChatGPT App / GPT Action](https://thumbgate.ai/chatgpt-app)** — First-class ChatGPT distribution page with the live GPT, public OpenAPI Action schema, and local enforcement install path
|
|
653
|
-
- **[Open ThumbGate GPT](https://thumbgate.ai/go/gpt?utm_source=github&utm_medium=readme&utm_campaign=readme_gpt)** — ThumbGate GPT: start here. Paste agent actions, get advice + checkpointing. No, users do not have to keep chatting inside the ThumbGate GPT to use ThumbGate — the hard enforcement layer still runs where the work happens.
|
|
654
|
-
- **[Claude Desktop Extension](https://github.com/IgorGanapolsky/ThumbGate/releases/latest/download/thumbgate-claude-desktop.mcpb)** — One-click install for Claude Desktop
|
|
655
|
-
- **[Codex Plugin](https://thumbgate.ai/codex-plugin)** — Auto-updating standalone bundle and install page for Codex CLI
|
|
656
|
-
- **[VS Code / Open VSX Extension](plugins/vscode-extension/README.md)** — Marketplace-ready MCP provider and `.vscode/mcp.json` fallback for VS Code-compatible IDEs
|
|
657
|
-
- **[Antigravity-compatible VSIX](plugins/antigravity-extension/INSTALL.md)** — Open VSX/direct VSIX install path while Antigravity-specific marketplace support is still unproven
|
|
658
|
-
- **[JetBrains Plugin Scaffold](plugins/jetbrains-plugin/README.md)** — IntelliJ/PyCharm Marketplace path for the same `thumbgate@latest` runtime
|
|
659
|
-
- **[Perplexity Command Center](docs/PERPLEXITY_MAX_COMMAND_CENTER.md)** — AI-search visibility + lead discovery
|
|
660
|
-
- **[ThumbGate Bench](docs/THUMBGATE_BENCH.md)** — Reliability benchmark and ProgramBench-style cleanroom proof lane
|
|
661
|
-
- **[Manus AI Skill](skills/thumbgate/SKILL.md)** — ThumbGate integration for Manus AI agents
|
|
662
|
-
- **Grafana Cloud revenue evidence** — The npm package includes a PII-free aggregate exporter and importable Loki dashboard. Generate the dashboard locally with `thumbgate-revenue-evidence --dashboard --out thumbgate-revenue-evidence-dashboard.json`. Snapshot preparation is dry-run by default; network delivery requires both `--send` and `THUMBGATE_GRAFANA_ZERO_SPEND_CONFIRMED=1`. Dashboard observations never promote clicks, checkout starts, or intakes into payment or customer claims. Repository operators can use the full [Grafana integration guide](docs/integrations/grafana/README.md).
|
|
663
|
-
|
|
664
|
-
---
|
|
665
|
-
|
|
666
|
-
## Feedback Sessions
|
|
667
|
-
|
|
668
|
-
Give the agent more context when a thumbs-down isn't enough:
|
|
669
|
-
|
|
670
|
-
```
|
|
671
|
-
👎 thumbs down
|
|
672
|
-
└─► open_feedback_session
|
|
673
|
-
└─► "you lied about deployment" (append_feedback_context)
|
|
674
|
-
└─► "tests were actually failing" (append_feedback_context)
|
|
675
|
-
└─► finalize_feedback_session
|
|
676
|
-
└─► lesson inferred from full conversation
|
|
677
|
-
```
|
|
678
|
-
|
|
679
|
-
Pro operators can invoke `search_lessons` through MCP and use `npx thumbgate lessons` from the CLI. History-aware feedback sessions and lesson search are Pro capabilities; Free does not include recall or search.
|
|
680
|
-
|
|
681
|
-
---
|
|
682
|
-
|
|
683
|
-
## Enterprise Data Chat and Optional Google Adapters
|
|
297
|
+
## Integrations (compact)
|
|
684
298
|
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
|
|
688
|
-
|
|
689
|
-
|
|
690
|
-
|
|
691
|
-
|
|
692
|
-
|
|
693
|
-
|
|
694
|
-
|
|
695
|
-
* **Auto-Enablement:** Programmatically enables the Vertex AI API in your project.
|
|
696
|
-
* **Auto-Configuration:** Writes local Vertex routing settings to your `.env` file.
|
|
697
|
-
|
|
698
|
-
This command does **not** create or verify a live Dialogflow CX agent. Dialogflow is only relevant when a customer wants ThumbGate guard adapters in front of their own production DFCX agents. On current Google Cloud CLI installs, the old alpha gcloud CX command group is not available; verify Conversational Agents / Dialogflow CX with the Google Cloud console or the official Dialogflow CX REST API (`projects.locations.agents`) before claiming a live DFCX deployment.
|
|
699
|
-
|
|
700
|
-
### Cost Containment (roadmap / routed calls only)
|
|
701
|
-
Google Cloud budget alerts do not themselves stop API traffic. ThumbGate includes local budget-ledger and policy primitives, but a stop condition applies only to provider calls explicitly routed through the configured gate. It is not a cloud billing guarantee, and provider pricing or token usage must come from provider telemetry.
|
|
702
|
-
|
|
703
|
-
---
|
|
704
|
-
|
|
705
|
-
## FAQ
|
|
706
|
-
|
|
707
|
-
**Is ThumbGate a model fine-tuning tool?**
|
|
708
|
-
No. ThumbGate does not update model weights. It captures feedback, stores lessons, injects context at runtime, and evaluates proposed tool calls before execution. Detected secret leaks and direct process-kill/environment-override self-disable commands deny by default; strict mode denies every matched blocking rule.
|
|
709
|
-
|
|
710
|
-
**How is this different from CLAUDE.md or .cursorrules?**
|
|
711
|
-
Those are instructions in model context. A configured ThumbGate hook adds an external allow/warn/deny decision before tool execution. Detected secret leaks and direct process-kill/environment-override self-disable commands deny by default; other audited high-risk classes warn and log unless strict mode preserves the matched deny.
|
|
712
|
-
|
|
713
|
-
**Does it work with my agent?**
|
|
714
|
-
ThumbGate ships configuration paths for Claude Code, Claude Desktop, Cursor, Codex, Gemini CLI, Amp, Cline, and OpenCode. The relevant MCP or hook integration must be configured before it evaluates tool calls.
|
|
715
|
-
|
|
716
|
-
**Is it free?**
|
|
717
|
-
The free tier gives you 2 feedback captures/day, 10 total captures, and up to 3 active auto-promoted prevention rules — enough for a solo developer to verify a matching pre-action evaluation before upgrading. Supported MCP and hook integration files ship in the free package.
|
|
718
|
-
|
|
719
|
-
Pro ($19/mo or $149/yr) is for individual operators and adds history-aware lesson recall, lesson search, unlimited rules, exports, and a personal dashboard. Enterprise is custom and scoped after intake; hosted team sync and a hosted org dashboard are not general availability.
|
|
720
|
-
|
|
721
|
-
---
|
|
299
|
+
| Surface | Start here |
|
|
300
|
+
|---------|------------|
|
|
301
|
+
| **Open ThumbGate GPT** | [thumbgate.ai/go/gpt](https://thumbgate.ai/go/gpt?utm_source=github&utm_medium=readme&utm_campaign=readme_gpt) — **ThumbGate GPT: start here.** Paste agent actions, get advice + checkpointing. **No, users do not have to keep chatting inside the ThumbGate GPT to use ThumbGate** — the **hard enforcement layer still runs where the work happens**. |
|
|
302
|
+
| **Install Codex Plugin** | Open the Codex plugin install page: [thumbgate.ai/codex-plugin](https://thumbgate.ai/codex-plugin) · zip: [thumbgate-codex-plugin.zip](https://github.com/IgorGanapolsky/ThumbGate/releases/latest/download/thumbgate-codex-plugin.zip) · [plugins/codex-profile/INSTALL.md](plugins/codex-profile/INSTALL.md) |
|
|
303
|
+
| Claude Desktop `.mcpb` | [latest release](https://github.com/IgorGanapolsky/ThumbGate/releases/latest/download/thumbgate-claude-desktop.mcpb) |
|
|
304
|
+
| **VS Code / Open VSX** | [plugins/vscode-extension/README.md](plugins/vscode-extension/README.md) |
|
|
305
|
+
| **Antigravity-compatible** | [plugins/antigravity-extension/INSTALL.md](plugins/antigravity-extension/INSTALL.md) |
|
|
306
|
+
| **JetBrains** | [plugins/jetbrains-plugin/README.md](plugins/jetbrains-plugin/README.md) · JetBrains Marketplace path for the same runtime |
|
|
307
|
+
| ChatGPT App / GPT Action | [thumbgate.ai/chatgpt-app](https://thumbgate.ai/chatgpt-app) |
|
|
308
|
+
| ThumbGate-Core (staging) | [https://github.com/IgorGanapolsky/ThumbGate-Core](https://github.com/IgorGanapolsky/ThumbGate-Core) — pre-release staging + a few internal cache scripts; **not** the product moat |
|
|
722
309
|
|
|
723
310
|
## Docs
|
|
724
311
|
|
|
725
|
-
|
|
726
|
-
- [First Dollar Playbook](docs/FIRST_DOLLAR_PLAYBOOK.md) — turning one painful workflow into the next booked pilot
|
|
727
|
-
- [Commercial Truth](docs/COMMERCIAL_TRUTH.md) — pricing, claims, what we don't say
|
|
728
|
-
- [Sales Pipeline Evidence Contract](docs/SALES_PIPELINE_EVIDENCE.md) — stage-specific receipts, audits, and verified-revenue rules
|
|
729
|
-
- [Revenue Offer Ladder](docs/REVENUE_OFFER_LADDER.md) — productized diagnostic, sprint, recurring, and Enterprise economics without traction inflation
|
|
730
|
-
- [Goal Contracts](docs/GOAL_CONTRACTS.md) — evidence-before-done contracts for multi-agent handoffs
|
|
731
|
-
- [Changeset Strategy](docs/CHANGESET_STRATEGY.md) — release notes and version bump enforcement
|
|
732
|
-
- [Release Confidence](docs/RELEASE_CONFIDENCE.md) — changesets, version checks, proof lanes
|
|
733
|
-
- [Verification Evidence](docs/VERIFICATION_EVIDENCE.md) — proof artifacts
|
|
734
|
-
- [Claude Desktop Extension Guide](docs/CLAUDE_DESKTOP_EXTENSION.md)
|
|
735
|
-
- [Agent Workflow Contract](WORKFLOW.md) — the agent-run contract for all ThumbGate operations
|
|
736
|
-
- [Ready for Agent Intake](https://github.com/IgorGanapolsky/ThumbGate/issues/new?template=ready-for-agent.yml) — ready-for-agent intake template
|
|
737
|
-
- [SEO Guide: Claude Code Guardrails](docs/learn/claude-code-guardrails.md)
|
|
738
|
-
- [Unsupervised Learning Signals](docs/UL.md) — silent-failure clustering (**on by default** as of 2026-05-21; opt out via `THUMBGATE_SILENT_FAILURE_CLUSTERING=0`; only meaningfully active on workspaces with ≥ 50 tool calls/day)
|
|
739
|
-
- [ThumbGate-Core](https://github.com/IgorGanapolsky/ThumbGate-Core) — staging repo for pre-release features plus a handful of internal cache scripts that can't ship publicly. It is **not** the moat: intelligence, ranking, and synthesis land in this public repo by default (~212 of 216 Core scripts already ship publicly). The moat is hosted services + adapter compatibility + dashboard + support — see [MOAT.md](MOAT.md).
|
|
740
|
-
|
|
741
|
-
---
|
|
742
|
-
|
|
743
|
-
---
|
|
744
|
-
|
|
745
|
-
## ThumbGate Pro and Enterprise
|
|
312
|
+
Full index: **[docs/INDEX.md](docs/INDEX.md)**
|
|
746
313
|
|
|
747
|
-
|
|
314
|
+
| Need | Link |
|
|
315
|
+
|------|------|
|
|
316
|
+
| Agent workflow contract | [WORKFLOW.md](WORKFLOW.md) |
|
|
317
|
+
| Ready-for-agent intake | [.github/ISSUE_TEMPLATE/ready-for-agent.yml](.github/ISSUE_TEMPLATE/ready-for-agent.yml) |
|
|
318
|
+
| Verification Evidence | [docs/VERIFICATION_EVIDENCE.md](docs/VERIFICATION_EVIDENCE.md) |
|
|
319
|
+
| Release Confidence | [docs/RELEASE_CONFIDENCE.md](docs/RELEASE_CONFIDENCE.md) |
|
|
320
|
+
| Changeset strategy | [docs/CHANGESET_STRATEGY.md](docs/CHANGESET_STRATEGY.md) |
|
|
321
|
+
| First Dollar Playbook | [docs/FIRST_DOLLAR_PLAYBOOK.md](docs/FIRST_DOLLAR_PLAYBOOK.md) |
|
|
322
|
+
| Security policy | [SECURITY.md](SECURITY.md) |
|
|
323
|
+
| Threat model | [THREAT_MODEL.md](THREAT_MODEL.md) |
|
|
324
|
+
| Federal / regulated | [docs/FEDERAL.md](docs/FEDERAL.md) |
|
|
325
|
+
| Commercial Truth | [docs/COMMERCIAL_TRUTH.md](docs/COMMERCIAL_TRUTH.md) |
|
|
326
|
+
| Issues / PRs | [GitHub Issues](https://github.com/IgorGanapolsky/ThumbGate/issues) · [PR template](.github/pull_request_template.md) |
|
|
748
327
|
|
|
749
|
-
-
|
|
750
|
-
- **Enterprise (custom, intake-led)** — scope one workflow's approval boundaries, rollback plan, evidence requirements, and rollout support
|
|
751
|
-
- **Not general availability** — hosted team lesson sync, hosted org dashboards, SSO, SIEM, and compliance packaging
|
|
752
|
-
|
|
753
|
-
**[Start Pro →](https://thumbgate.ai/checkout/pro?utm_source=github&utm_medium=readme&utm_campaign=pro_page)** · **[Start Enterprise intake →](https://thumbgate.ai/#workflow-sprint-intake)**
|
|
328
|
+
**FAQ (one-liners):** Not a fine-tuner (runtime intercept only). Different from `CLAUDE.md` / `.cursorrules` (those are context; ThumbGate is an external allow/warn/deny before tools run).
|
|
754
329
|
|
|
755
330
|
---
|
|
756
331
|
|
|
757
|
-
## Who builds
|
|
758
|
-
|
|
759
|
-
I'm **Igor Ganapolsky** — I designed and maintain ThumbGate. If you're shipping **payments, AI agents, or Android features** and want them built by someone demonstrably careful with production and with money, I take a small number of **freelance / contract** engagements.
|
|
760
|
-
|
|
761
|
-
ThumbGate is the receipt, not the pitch: its default policy denies detected secret exfiltration and gate kill/bypass commands, strict mode also denies matching warning-mode checks, and the project publishes a [threat model](THREAT_MODEL.md) stating what the local evaluator does and cannot contain. Documenting where my own guardrails end is the standard I hold client work to.
|
|
762
|
-
|
|
763
|
-
- **Payments** — Stripe / Stripe Connect: destination charges, split payouts, escrow & milestone release, 3DS/SCA, idempotent webhooks, reconciliation.
|
|
764
|
-
- **Applied AI / agents** — tool-use guardrails, MCP servers, orchestration, and evaluation loops (the engineering behind this repo).
|
|
765
|
-
- **Android + backend** — native Android and the APIs behind it, shipped end-to-end.
|
|
332
|
+
## Who builds this
|
|
766
333
|
|
|
767
|
-
**$120–150/hr, 1099
|
|
768
|
-
|
|
769
|
-
> ThumbGate is free and MIT-licensed, and stays that way. If it saved you a costly mistake, the best thank-you is an intro to someone who needs an engineer who ships carefully.
|
|
770
|
-
|
|
771
|
-
---
|
|
334
|
+
**Igor Ganapolsky** — payments (Stripe/Connect), AI agent guardrails/MCP, Android + backends. Small number of contract slots: **$120–150/hr, 1099, remote US**. [LinkedIn](https://www.linkedin.com/in/igor-ganapolsky-859317343/) · [thumbgate.ai](https://thumbgate.ai)
|
|
772
335
|
|
|
773
336
|
## License
|
|
774
337
|
|
|
775
|
-
MIT
|
|
338
|
+
MIT — see [LICENSE](LICENSE). Project policy: [SECURITY.md](SECURITY.md) · [THREAT_MODEL.md](THREAT_MODEL.md).
|