thumbgate 1.28.0 โ 1.28.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/.claude-plugin/plugin.json +2 -1
- package/.well-known/mcp/server-card.json +1 -1
- package/README.md +96 -122
- package/adapters/claude/.mcp.json +2 -2
- package/adapters/mcp/server-stdio.js +18 -33
- package/adapters/opencode/opencode.json +1 -1
- package/bin/cli.js +70 -70
- package/config/gates/default.json +2 -2
- package/config/github-about.json +2 -5
- package/config/post-deploy-marketing-pages.json +1 -1
- package/hooks/hooks.json +38 -0
- package/package.json +18 -8
- package/public/chatgpt-app.html +2 -2
- package/public/codex-enterprise.html +1 -1
- package/public/codex-plugin.html +1 -1
- package/public/diagnostic.html +23 -1
- package/public/guide.html +1 -1
- package/public/index.html +172 -201
- package/public/numbers.html +2 -2
- package/public/partner-intake.html +198 -0
- package/public/pricing.html +51 -14
- package/scripts/billing.js +815 -137
- package/scripts/checkout-attribution-reference.js +85 -0
- package/scripts/claude-feedback-sync.js +23 -6
- package/scripts/cli-feedback.js +19 -10
- package/scripts/feedback-loop.js +290 -1
- package/scripts/feedback-quality.js +25 -26
- package/scripts/feedback-sanitizer.js +151 -3
- package/scripts/gates-engine.js +128 -49
- package/scripts/hosted-config.js +9 -2
- package/scripts/mailer/resend-mailer.js +11 -5
- package/scripts/secret-scanner.js +363 -68
- package/scripts/self-protection.js +21 -36
- package/src/api/server.js +121 -12
- package/public/assets/brand/github-social-preview.png +0 -0
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "thumbgate",
|
|
3
3
|
"description": "One ๐ becomes a hard rule the agent cannot bypass. Captures thumbs-down feedback, distills it into PreToolUse Pre-Action Checks, enforced across every future Claude Code session.",
|
|
4
|
-
"version": "1.28.
|
|
4
|
+
"version": "1.28.1",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "Igor Ganapolsky",
|
|
7
7
|
"email": "ig5973700@gmail.com",
|
|
@@ -29,6 +29,7 @@
|
|
|
29
29
|
],
|
|
30
30
|
"skills": "./skills/",
|
|
31
31
|
"commands": "./.claude/commands/",
|
|
32
|
+
"hooks": "./hooks/hooks.json",
|
|
32
33
|
"mcpServers": {
|
|
33
34
|
"thumbgate": {
|
|
34
35
|
"command": "npx",
|
package/README.md
CHANGED
|
@@ -8,27 +8,27 @@
|
|
|
8
8
|
|
|
9
9
|
**AI coding agents repeat mistakes โ and one wrong tool call can wipe a directory, leak a key, or push broken code.**
|
|
10
10
|
|
|
11
|
-
ThumbGate is the local-first Pre-Action Checks engine for AI coding agents. It runs in the PreToolUse hook on your machine: it
|
|
11
|
+
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.)
|
|
12
12
|
|
|
13
|
-
|
|
13
|
+
Accepted feedback is stored as local lessons. Repeated concrete failures can become prevention rules that flag or block matching tool calls according to policy.
|
|
14
14
|
|
|
15
15
|
<p align="center">
|
|
16
|
-
<img src="docs/media/thumbgate-demo.gif" alt="ThumbGate gating an AI agent's dangerous commands (rm -rf, force-push, chmod 777) in real time โ hard-blocking
|
|
16
|
+
<img src="docs/media/thumbgate-demo.gif" alt="ThumbGate gating an AI agent's dangerous commands (rm -rf, force-push, chmod 777) in real time โ flagging them by default and hard-blocking under strict mode, while letting safe commands through" width="820" />
|
|
17
17
|
</p>
|
|
18
18
|
|
|
19
19
|
```
|
|
20
20
|
Agent tries: rm -rf tests/
|
|
21
|
-
ThumbGate:
|
|
21
|
+
ThumbGate: โ ๏ธ WARN + LOG โ "Never delete test directories"
|
|
22
22
|
Pattern matched: rm.*-rf.*tests
|
|
23
23
|
Source: your thumbs-down from last Tuesday
|
|
24
|
-
|
|
24
|
+
Strict mode: DENY before tool execution
|
|
25
25
|
```
|
|
26
26
|
|
|
27
27
|
```bash
|
|
28
|
-
npx thumbgate init # auto-detects
|
|
28
|
+
npx thumbgate init # auto-detects the supported agent and wires its integration
|
|
29
29
|
```
|
|
30
30
|
|
|
31
|
-
Works with **Claude Code, Cursor, Codex, Gemini CLI, Amp, Cline, OpenCode** and
|
|
31
|
+
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.
|
|
32
32
|
|
|
33
33
|
[](https://github.com/IgorGanapolsky/ThumbGate/actions/workflows/ci.yml)
|
|
34
34
|
[](https://www.npmjs.com/package/thumbgate)
|
|
@@ -40,18 +40,18 @@ Works with **Claude Code, Cursor, Codex, Gemini CLI, Amp, Cline, OpenCode** and
|
|
|
40
40
|
>
|
|
41
41
|
> โ **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).
|
|
42
42
|
>
|
|
43
|
-
> ThumbGate is
|
|
43
|
+
> 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.
|
|
44
44
|
|
|
45
45
|
---
|
|
46
46
|
|
|
47
47
|
## Agentic development cycle fit
|
|
48
48
|
|
|
49
|
-
Agentic development is becoming a loop: **Guide โ Generate โ Verify โ Solve**. ThumbGate
|
|
49
|
+
Agentic development is becoming a loop: **Guide โ Generate โ Verify โ Solve**. ThumbGate adds a pre-action decision point before tool execution.
|
|
50
50
|
|
|
51
51
|
- **Guide:** standards, prior thumbs-downs, and approval policies become concrete context.
|
|
52
52
|
- **Generate:** Claude Code, Cursor, Codex, Gemini, Amp, Cline, OpenCode, and MCP agents keep producing plans and tool calls.
|
|
53
53
|
- **Verify:** risky actions need evidence before execution, not just after PR review.
|
|
54
|
-
- **Solve:**
|
|
54
|
+
- **Solve:** flagged or denied failures can become reusable lessons, prevention rules, DPO exports, and audit events.
|
|
55
55
|
|
|
56
56
|
In that stack, ThumbGate is the pre-action gate between generated intent and executed action.
|
|
57
57
|
|
|
@@ -59,7 +59,7 @@ In that stack, ThumbGate is the pre-action gate between generated intent and exe
|
|
|
59
59
|
|
|
60
60
|
## Discoverable slash-commands โ the guardrail layer for spec-driven agents
|
|
61
61
|
|
|
62
|
-
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; ThumbGate
|
|
62
|
+
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.
|
|
63
63
|
|
|
64
64
|
`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:
|
|
65
65
|
|
|
@@ -77,7 +77,7 @@ Each is a thin wrapper over an existing MCP tool or CLI command โ **no new enf
|
|
|
77
77
|
|
|
78
78
|
## ๐ฌ 90-second demo
|
|
79
79
|
|
|
80
|
-
Watch the force-push scenario: agent
|
|
80
|
+
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`.
|
|
81
81
|
|
|
82
82
|
[**โถ 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)
|
|
83
83
|
|
|
@@ -92,9 +92,9 @@ If someone is not already bought into ThumbGate, do not lead with architecture.
|
|
|
92
92
|
1. **Show the pain:** open the **[ThumbGate GPT](https://thumbgate.ai/go/gpt?utm_source=github&utm_medium=readme&utm_campaign=first_dollar_activation&cta_id=readme_first_dollar_open_gpt&cta_placement=readme_first_dollar)** and paste the bad answer, risky command, deploy, PR action, or agent plan before it runs again.
|
|
93
93
|
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.
|
|
94
94
|
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.
|
|
95
|
-
4. **Upgrade only after proof:** Solo Pro is for the dashboard, DPO export,
|
|
95
|
+
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.
|
|
96
96
|
|
|
97
|
-
The buying question is simple: **what repeated AI mistake would be worth
|
|
97
|
+
The buying question is simple: **what repeated AI mistake would be worth catching before the tool executes?**
|
|
98
98
|
|
|
99
99
|
---
|
|
100
100
|
|
|
@@ -108,42 +108,21 @@ For partners building detection or coordination layers, ThumbGate is the downstr
|
|
|
108
108
|
|
|
109
109
|
---
|
|
110
110
|
|
|
111
|
-
## The Problem โ
|
|
111
|
+
## The Problem โ repeated failures consume model, tool, and review time
|
|
112
112
|
|
|
113
|
-
|
|
113
|
+
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.
|
|
114
114
|
|
|
115
|
-
|
|
116
|
-
- retries the same failing tool call until it gives up,
|
|
117
|
-
- regenerates a 4,000-token plan you already approved last session,
|
|
118
|
-
- repeats a destructive command you blocked manually yesterday,
|
|
115
|
+
## The Solution โ evaluate the proposed tool call before execution
|
|
119
116
|
|
|
120
|
-
|
|
117
|
+
`PreToolUse` runs **after the model has proposed a tool call and before the tool executes**. ThumbGate therefore does not claim that a gate decision makes the model generation free. A denial can avoid downstream execution and remediation, while a warning gives the agent another chance to choose a safer plan.
|
|
121
118
|
|
|
122
|
-
|
|
123
|
-
Session 1: Agent force-pushes to main. You fix it. +4,200 tokens
|
|
124
|
-
Session 2: Agent force-pushes again. You fix it. +4,200 tokens
|
|
125
|
-
Session 3: Same mistake. Again. You lose 45m. +5,800 tokens
|
|
126
|
-
```
|
|
127
|
-
|
|
128
|
-
That's ~$0.21 in tokens just to fix the same mistake three times โ multiplied by every developer, every repeated-mistake class, every week. The math gets ugly fast.
|
|
129
|
-
|
|
130
|
-
## The Solution โ fix it once, the bill never sees it again
|
|
131
|
-
|
|
132
|
-
```
|
|
133
|
-
Session 1: Agent force-pushes to main. You ๐ it. +4,200 tokens
|
|
134
|
-
Session 2: โ ๏ธ Gate flags the force-push. Zero round-trip. +0 tokens
|
|
135
|
-
Session 3+: Warned every time (hard-blocked under strict). +0 tokens
|
|
136
|
-
```
|
|
137
|
-
|
|
138
|
-
One thumbs-down. The PreToolUse hook catches the call **before** it reaches the model โ no input tokens, no output tokens, no retry loop. Catastrophic classes (secret exfiltration, `rm -rf`, supply-chain) hard-block by default; the rest warn-and-log by default and hard-block under `THUMBGATE_STRICT_ENFORCEMENT=1`. The dashboard tracks **tokens saved this week** as a live counter so you can see exactly what your prevention rules are worth. Mark a review checkpoint once, and the dashboard narrows the next pass to only the feedback, lessons, and check blocks that landed since your last review.
|
|
139
|
-
|
|
140
|
-
ThumbGate doesn't make your agent smarter. It makes your agent *cheaper to be wrong with.*
|
|
119
|
+
The dashboard's token and dollar savings values are **estimates**, derived from recorded block counts and documented token/price assumptions. They are not measured provider usage or a guarantee of savings. Mark a review checkpoint once, and the dashboard narrows the next pass to the feedback, lessons, and check decisions added since the last review.
|
|
141
120
|
|
|
142
121
|
---
|
|
143
122
|
|
|
144
123
|
## ๐ง The Context Brain
|
|
145
124
|
|
|
146
|
-
|
|
125
|
+
Coding-agent sessions do not automatically inherit ThumbGate's prior local lessons, rejected fixes, or repo rules. Without configured context and hooks, a later session can repeat a previously corrected failure.
|
|
147
126
|
|
|
148
127
|
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.
|
|
149
128
|
|
|
@@ -151,7 +130,7 @@ ThumbGate gives your repo a **context brain**: a single, versioned, agent-readab
|
|
|
151
130
|
npx thumbgate brain --write # โ .thumbgate/BRAIN.md
|
|
152
131
|
```
|
|
153
132
|
|
|
154
|
-
Then point
|
|
133
|
+
Then point each agent at it โ add `Read .thumbgate/BRAIN.md first` to the relevant `CLAUDE.md` / `AGENTS.md` integration. Sessions that honor that instruction can load the repo's institutional memory. The generated output is deterministic for the same inputs, so `BRAIN.md` can be reviewed like any other file.
|
|
155
134
|
|
|
156
135
|
```
|
|
157
136
|
# ThumbGate Context Brain
|
|
@@ -170,11 +149,11 @@ Same idea the SEO world is now calling a *"client brain"* โ persistent context
|
|
|
170
149
|
## Quick Start
|
|
171
150
|
|
|
172
151
|
```bash
|
|
173
|
-
npx thumbgate init #
|
|
152
|
+
npx thumbgate init # initializes local state; use --agent for an explicit integration
|
|
174
153
|
npx thumbgate capture down "Never run DROP on production tables"
|
|
175
154
|
```
|
|
176
155
|
|
|
177
|
-
That
|
|
156
|
+
That command stores a concrete negative lesson and applies promotion rules. If the pattern becomes an active prevention rule, configured agents in the same install scope can evaluate a later `DROP` attempt:
|
|
178
157
|
|
|
179
158
|
```
|
|
180
159
|
โ ๏ธ Check fired: "Never run DROP on production tables"
|
|
@@ -191,31 +170,31 @@ ThumbGate operates as a 4-layer enforcement stack between your AI agent and your
|
|
|
191
170
|

|
|
192
171
|
|
|
193
172
|
### Layer 1: Feedback Capture
|
|
194
|
-
|
|
173
|
+
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.
|
|
195
174
|
|
|
196
175
|
### Layer 2: Check Engine
|
|
197
|
-
The check engine
|
|
176
|
+
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.
|
|
198
177
|
|
|
199
|
-
Where retrieval is needed (an agent is about to run a destructive command not on the literal block list, but semantically similar to
|
|
178
|
+
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.
|
|
200
179
|
|
|
201
|
-
**Thompson Sampling tunes per-rule confidence weights** for soft-gating rules so high-noise rules quiet down and high-signal rules sharpen. It
|
|
180
|
+
**Thompson Sampling tunes per-rule confidence weights** for soft-gating rules so high-noise rules quiet down and high-signal rules sharpen. It does not decide whether a hard pattern matches. A force-push pattern match is deterministic, while the public runtime warns by default and denies the matching action under strict enforcement.
|
|
202
181
|
|
|
203
182
|
Rules stay in local ThumbGate runtime state.
|
|
204
183
|
|
|
205
184
|
### Layer 3: Pre-Action Interception
|
|
206
|
-
|
|
185
|
+
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.
|
|
207
186
|
|
|
208
187
|
### Layer 4: Multi-Agent Distribution (why not a hand-rolled hook?)
|
|
209
188
|
Claude Code already ships `permissions.deny` and `PreToolUse` hooks. Cursor and Codex have their own. So why ThumbGate over a hand-written hook?
|
|
210
189
|
|
|
211
190
|
Two things hand-written hooks structurally cannot do:
|
|
212
191
|
|
|
213
|
-
1. **Cross-agent
|
|
214
|
-
2. **Learning loop.** A hand-written hook covers exactly the patterns you wrote. ThumbGate
|
|
192
|
+
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.
|
|
193
|
+
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.
|
|
215
194
|
|
|
216
|
-
Hand-rolled hooks are the right tool for a small, static denylist you maintain by hand. ThumbGate is
|
|
195
|
+
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.
|
|
217
196
|
|
|
218
|
-
Prompt engineering still matters, but it is only the starting point. ThumbGate adds prompt evaluation on top: proof lanes, benchmarks, and self-heal checks
|
|
197
|
+
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.
|
|
219
198
|
|
|
220
199
|
### Retrieval & latency: local-first, zero network hops
|
|
221
200
|
|
|
@@ -227,16 +206,16 @@ flowchart LR
|
|
|
227
206
|
B -- "exact match" --> D["Deterministic gate decision<br/>(no model, on-device)"]
|
|
228
207
|
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)"]
|
|
229
208
|
C --> D
|
|
230
|
-
D -- "
|
|
209
|
+
D -- "secret exfil / self-protect" --> E["โ Hard-block before execution"]
|
|
231
210
|
D -- "other known-bad" --> G["โ ๏ธ Warn + log<br/>(hard-block under strict)"]
|
|
232
211
|
D -- "safe" --> F["โ Allow"]
|
|
233
212
|
```
|
|
234
213
|
|
|
235
|
-
- **Deterministic first.** Most decisions are a literal or AST pattern match against
|
|
214
|
+
- **Deterministic first.** Most decisions are a local literal or AST pattern match against active rules and do not require embeddings.
|
|
236
215
|
- **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.
|
|
237
|
-
- **No LLM on the enforcement path.** The gate never calls a model to decide
|
|
216
|
+
- **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).
|
|
238
217
|
|
|
239
|
-
The
|
|
218
|
+
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.
|
|
240
219
|
|
|
241
220
|
### Managed model benchmark lane
|
|
242
221
|
|
|
@@ -286,7 +265,7 @@ ThumbGate supports two install scopes. Pick once when you install โ you can sw
|
|
|
286
265
|
|
|
287
266
|
| Scope | Command | Settings file | Lesson DB + dashboard live in | When to use |
|
|
288
267
|
|-------|---------|---------------|--------------------------------|-------------|
|
|
289
|
-
| **Machine-wide** (default) | `npx thumbgate init` | `~/.claude/settings.json` | `~/.claude/memory/feedback/` | Solo
|
|
268
|
+
| **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. |
|
|
290
269
|
| **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. |
|
|
291
270
|
|
|
292
271
|
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.
|
|
@@ -328,23 +307,22 @@ ChatGPT is the advice, checkpointing, and typed-feedback surface; ThumbGate's ha
|
|
|
328
307
|
|
|
329
308
|
You react ThumbGate learns The check holds
|
|
330
309
|
|
|
331
|
-
๐ on a bad โโโบ
|
|
332
|
-
agent action a
|
|
333
|
-
and a block rule same thing:
|
|
310
|
+
๐ on a bad โโโบ Accepted feedback โโโบ A recurring failure
|
|
311
|
+
agent action becomes a lesson can become a rule:
|
|
334
312
|
๐ on a good โโโบ Good pattern gets ๐ฆ flagged + logged
|
|
335
313
|
agent action reinforced (hard-blocked for
|
|
336
|
-
|
|
337
|
-
|
|
314
|
+
secret exfil / strict
|
|
315
|
+
mode, or โ
allowed)
|
|
338
316
|
```
|
|
339
317
|
|
|
340
|
-
|
|
318
|
+
Concrete feedback can reduce manual rule-writing while keeping the resulting lessons and rules inspectable.
|
|
341
319
|
|
|
342
320
|
---
|
|
343
321
|
|
|
344
322
|
ThumbGate sells three concrete outcomes:
|
|
345
323
|
|
|
346
324
|
- **Prevent expensive AI mistakes** โ catch bad commands, destructive database actions, unsafe publishes, and risky API calls before they run.
|
|
347
|
-
- **
|
|
325
|
+
- **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.
|
|
348
326
|
- **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.
|
|
349
327
|
- **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.
|
|
350
328
|
|
|
@@ -354,20 +332,20 @@ ThumbGate sells three concrete outcomes:
|
|
|
354
332
|
|
|
355
333
|
### Developer Workflows
|
|
356
334
|
- **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`
|
|
357
|
-
- **
|
|
358
|
-
- **
|
|
359
|
-
- **
|
|
360
|
-
- **
|
|
361
|
-
- **
|
|
335
|
+
- **Catch repeated migration failures** โ accepted feedback becomes a searchable lesson; recurring patterns can become checks
|
|
336
|
+
- **Flag unauthorized file edits** โ path-based rules warn by default and deny matching actions under strict enforcement
|
|
337
|
+
- **Local lessons across sessions** โ configured integrations can load accepted feedback from the same local store
|
|
338
|
+
- **Portable lesson handoff** โ Pro export/import moves reviewable lesson bundles between operator-managed instances
|
|
339
|
+
- **Outcome-derived proposals** โ evaluation lanes can propose rules for operator review
|
|
362
340
|
|
|
363
341
|
### Enterprise & Regulated Industries (roadmap / templates)
|
|
364
342
|
|
|
365
|
-
These are policy-template directions on the roadmap,
|
|
343
|
+
These are policy-template directions on the roadmap, not customer-proven compliance capabilities. They build on the same gate engine:
|
|
366
344
|
|
|
367
345
|
- **Legal AI intake governance** โ templates targeting unauthorized practice of law (ABA Rule 5.5), conflict-of-interest clearance before fact collection (Rules 1.7/1.9/1.10), and keeping privileged content inside firm boundaries (Rule 1.6)
|
|
368
346
|
- **Financial compliance** โ gate templates for AI-generated trade recommendations, unauthorized disclosures, and approval chains before customer-facing outputs
|
|
369
347
|
- **Healthcare** โ templates to keep AI agents from providing medical diagnoses, route data along HIPAA-compliant paths, and require clinician review before patient-facing content
|
|
370
|
-
- **
|
|
348
|
+
- **Local decision records** โ gate results preserve the decision and the rule, reason, timestamp, and context fields available to that evaluation
|
|
371
349
|
|
|
372
350
|
[Talk to us about regulated templates โ](https://thumbgate.ai/dashboard)
|
|
373
351
|
|
|
@@ -376,15 +354,18 @@ These are policy-template directions on the roadmap, available on request โ no
|
|
|
376
354
|
## Built-in Checks
|
|
377
355
|
|
|
378
356
|
```
|
|
379
|
-
โ
|
|
357
|
+
โ secret-exfiltration โ hard-blocks detected secret exposure (default)
|
|
358
|
+
โ self-protect-kill โ blocks direct process termination (default)
|
|
359
|
+
โ self-protect-env โ blocks direct ThumbGate env override (default)
|
|
380
360
|
โ ๏ธ force-push โ flags git push --force (hard-block under strict)
|
|
381
361
|
โ ๏ธ protected-branch โ flags direct push to main (hard-block under strict)
|
|
382
362
|
โ ๏ธ unresolved-threads โ flags push with open reviews (hard-block under strict)
|
|
383
363
|
โ ๏ธ package-lock-reset โ flags destructive lock edits (hard-block under strict)
|
|
384
364
|
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
365
|
+
Configured hooks record decisions for evaluated calls. Detected secret leaks and
|
|
366
|
+
the process-kill/environment-override self-protect gates deny by default. Direct
|
|
367
|
+
guardrail-file edits, rm -rf, force-push, and fetch-and-run warn and log by
|
|
368
|
+
default; matched blocking rules deny under THUMBGATE_STRICT_ENFORCEMENT=1.
|
|
388
369
|
|
|
389
370
|
+ custom prevention rules for project-specific failures
|
|
390
371
|
```
|
|
@@ -446,28 +427,24 @@ If you change MCP or hook settings, restart the affected agent session so Claude
|
|
|
446
427
|
|
|
447
428
|
| | Free | Pro ($19/mo) | Enterprise |
|
|
448
429
|
|---|---|---|---|
|
|
449
|
-
| Local CLI +
|
|
450
|
-
| Feedback captures | 2/day (10 total) | Unlimited |
|
|
451
|
-
| Active auto-promoted prevention rules | 3 | Unlimited |
|
|
452
|
-
|
|
|
453
|
-
| Personal dashboard | โ | โ
|
|
|
454
|
-
| DPO export (model fine-tuning) | โ | โ
|
|
|
455
|
-
| Lesson export/import | โ | โ
|
|
|
456
|
-
|
|
|
457
|
-
|
|
|
458
|
-
| Approval +
|
|
459
|
-
| Regulatory gate templates (roadmap / on request) | โ | โ | ๐ฃ๏ธ |
|
|
460
|
-
| Custom policy layers (firm/practice-area, roadmap) | โ | โ | ๐ฃ๏ธ |
|
|
461
|
-
| Compliance audit export (roadmap) | โ | โ | ๐ฃ๏ธ |
|
|
462
|
-
| Dedicated onboarding + SLA | โ | โ | โ
|
|
|
430
|
+
| Local CLI + PreToolUse checks | โ
| โ
| Existing public runtime |
|
|
431
|
+
| Feedback captures | 2/day (10 total) | Unlimited | Scoped after intake |
|
|
432
|
+
| Active auto-promoted prevention rules | 3 | Unlimited | Scoped after intake |
|
|
433
|
+
| Configured agent integrations | โ
| โ
| Scoped after intake |
|
|
434
|
+
| Personal dashboard | โ | โ
| Reviewed during intake |
|
|
435
|
+
| DPO export (model fine-tuning data) | โ | โ
| Reviewed during intake |
|
|
436
|
+
| Lesson export/import | โ | โ
| Operator-managed bundles |
|
|
437
|
+
| Hosted team lesson sync | โ | โ | Not general availability |
|
|
438
|
+
| Hosted org dashboard | โ | โ | Not general availability |
|
|
439
|
+
| Approval boundaries + rollout proof | โ | โ | Scoped after intake |
|
|
463
440
|
|
|
464
|
-
The free tier gives you 2 feedback captures/day (10 total) and up to 3 active auto-promoted prevention rules
|
|
441
|
+
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.
|
|
465
442
|
|
|
466
|
-
Pro ($19/mo or $149/yr) removes the rule cap and adds history-aware lesson recall, lesson search, DPO export, and a personal dashboard. Enterprise
|
|
443
|
+
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.
|
|
467
444
|
|
|
468
|
-
**
|
|
445
|
+
**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)**
|
|
469
446
|
|
|
470
|
-
**
|
|
447
|
+
**Local technical path:** install the CLI and use `init` plus the documented setup for the agent you already use.
|
|
471
448
|
|
|
472
449
|
**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.
|
|
473
450
|
|
|
@@ -475,9 +452,9 @@ Pro ($19/mo or $149/yr) removes the rule cap and adds history-aware lesson recal
|
|
|
475
452
|
|
|
476
453
|
---
|
|
477
454
|
|
|
478
|
-
##
|
|
455
|
+
## Portable Lesson Export/Import (Pro)
|
|
479
456
|
|
|
480
|
-
|
|
457
|
+
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.
|
|
481
458
|
|
|
482
459
|
**Export lessons from one project:**
|
|
483
460
|
|
|
@@ -497,7 +474,7 @@ curl -X POST http://localhost:3456/v1/lessons/export \
|
|
|
497
474
|
-d '{"signal": "down", "tags": ["push-notifications", "ci"]}'
|
|
498
475
|
```
|
|
499
476
|
|
|
500
|
-
**Import into another
|
|
477
|
+
**Import into another operator-managed ThumbGate instance:**
|
|
501
478
|
|
|
502
479
|
```bash
|
|
503
480
|
curl -X POST http://localhost:3456/v1/lessons/import \
|
|
@@ -514,16 +491,16 @@ What happens on import:
|
|
|
514
491
|
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.
|
|
515
492
|
|
|
516
493
|
**Use cases:**
|
|
517
|
-
-
|
|
518
|
-
- Onboard
|
|
494
|
+
- Move reviewable lesson patterns across repos under operator control
|
|
495
|
+
- Onboard another project with an explicitly reviewed lesson bundle
|
|
519
496
|
- Export lessons before a project handoff so institutional knowledge transfers
|
|
520
497
|
- Feed lessons from multiple teams into a centralized DPO training pipeline
|
|
521
498
|
|
|
522
499
|
---
|
|
523
500
|
|
|
524
|
-
## DPO Export for Fine-Tuning (Pro
|
|
501
|
+
## DPO Export for Fine-Tuning (Pro)
|
|
525
502
|
|
|
526
|
-
|
|
503
|
+
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.
|
|
527
504
|
|
|
528
505
|
**Export DPO pairs:**
|
|
529
506
|
|
|
@@ -543,7 +520,7 @@ curl -X POST http://localhost:3456/v1/dpo/export \
|
|
|
543
520
|
- Feed into RLAIF or KTO pipelines (KTO export also available via `/v1/kto/export`)
|
|
544
521
|
- Build a model that natively avoids your team's known failure patterns โ no check at inference time needed
|
|
545
522
|
|
|
546
|
-
**Why this matters:** Checks
|
|
523
|
+
**Why this matters:** Checks can deny matching actions under policy. Fine-tuning may reduce attempts, but only evaluation can establish whether behavior changed.
|
|
547
524
|
|
|
548
525
|
---
|
|
549
526
|
|
|
@@ -600,15 +577,15 @@ Give the agent more context when a thumbs-down isn't enough:
|
|
|
600
577
|
โโโบ lesson inferred from full conversation
|
|
601
578
|
```
|
|
602
579
|
|
|
603
|
-
|
|
580
|
+
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.
|
|
604
581
|
|
|
605
582
|
---
|
|
606
583
|
|
|
607
584
|
## Enterprise Data Chat and Optional Google Adapters
|
|
608
585
|
|
|
609
|
-
The
|
|
586
|
+
The package includes a local data-chat path over ThumbGate data using lesson retrieval, LanceDB-backed vectors, and an operator-configured LLM. Set `THUMBGATE_LOCAL_LLM_ENDPOINT` to an OpenAI-compatible local endpoint (Ollama, llama.cpp, vLLM, LM Studio, etc.) when you want generated answers without sending dashboard data to Google. This is a local package capability, not a hosted org-dashboard claim.
|
|
610
587
|
|
|
611
|
-
Google Cloud is an optional
|
|
588
|
+
Google Cloud is an optional adapter, not a dashboard requirement. The package provides setup and guard-adapter code for operators who already use Vertex AI or Dialogflow CX; each deployment and data boundary must be configured and verified in that tenancy.
|
|
612
589
|
|
|
613
590
|
### Optional Vertex Setup
|
|
614
591
|
To wire local ThumbGate scoring to Vertex AI, run:
|
|
@@ -621,28 +598,26 @@ npx thumbgate setup-vertex
|
|
|
621
598
|
|
|
622
599
|
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.
|
|
623
600
|
|
|
624
|
-
### Cost Containment (
|
|
625
|
-
Google Cloud budget alerts
|
|
626
|
-
* **Local token ledger:** ThumbGate maintains a lightweight, local token ledger intended to halt outgoing API traffic as monthly token spend approaches a configurable cap (e.g. **$10**, ~500k tokens of Gemini 1.5 Flash).
|
|
627
|
-
* **No extra shutdown plumbing:** the local ThumbGate-side stop condition needs no Pub/Sub or Cloud Functions. You still need normal Google Cloud billing/API setup and live-agent verification for DFCX pilots.
|
|
601
|
+
### Cost Containment (roadmap / routed calls only)
|
|
602
|
+
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.
|
|
628
603
|
|
|
629
604
|
---
|
|
630
605
|
|
|
631
606
|
## FAQ
|
|
632
607
|
|
|
633
608
|
**Is ThumbGate a model fine-tuning tool?**
|
|
634
|
-
No. ThumbGate does not update model weights. It captures feedback, stores lessons, injects context at runtime, and
|
|
609
|
+
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.
|
|
635
610
|
|
|
636
611
|
**How is this different from CLAUDE.md or .cursorrules?**
|
|
637
|
-
Those are
|
|
612
|
+
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.
|
|
638
613
|
|
|
639
614
|
**Does it work with my agent?**
|
|
640
|
-
|
|
615
|
+
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.
|
|
641
616
|
|
|
642
617
|
**Is it free?**
|
|
643
|
-
The free tier gives you 2 feedback captures/day, 10 total captures, and up to 3 active auto-promoted prevention rules โ enough for solo
|
|
618
|
+
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.
|
|
644
619
|
|
|
645
|
-
Pro ($19/mo or $149/yr)
|
|
620
|
+
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.
|
|
646
621
|
|
|
647
622
|
---
|
|
648
623
|
|
|
@@ -666,16 +641,15 @@ Pro ($19/mo or $149/yr) removes the rule cap and adds history-aware lesson recal
|
|
|
666
641
|
|
|
667
642
|
---
|
|
668
643
|
|
|
669
|
-
## ThumbGate Pro
|
|
644
|
+
## ThumbGate Pro and Enterprise
|
|
670
645
|
|
|
671
|
-
ThumbGate is free and MIT-licensed
|
|
646
|
+
ThumbGate is free and MIT-licensed. The paid paths are intentionally separate:
|
|
672
647
|
|
|
673
|
-
- **
|
|
674
|
-
- **
|
|
675
|
-
- **
|
|
676
|
-
- **Priority support** โ direct access, SLA, onboarding help
|
|
648
|
+
- **Pro ($19/mo or $149/yr)** โ individual recall/search, unlimited rules and captures, personal dashboard, and exports
|
|
649
|
+
- **Enterprise (custom, intake-led)** โ scope one workflow's approval boundaries, rollback plan, evidence requirements, and rollout support
|
|
650
|
+
- **Not general availability** โ hosted team lesson sync, hosted org dashboards, SSO, SIEM, and compliance packaging
|
|
677
651
|
|
|
678
|
-
|
|
652
|
+
**[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)**
|
|
679
653
|
|
|
680
654
|
---
|
|
681
655
|
|
|
@@ -683,7 +657,7 @@ ThumbGate is free and MIT-licensed forever. For teams that need more:
|
|
|
683
657
|
|
|
684
658
|
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.
|
|
685
659
|
|
|
686
|
-
ThumbGate is the receipt, not the pitch:
|
|
660
|
+
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.
|
|
687
661
|
|
|
688
662
|
- **Payments** โ Stripe / Stripe Connect: destination charges, split payouts, escrow & milestone release, 3DS/SCA, idempotent webhooks, reconciliation.
|
|
689
663
|
- **Applied AI / agents** โ tool-use guardrails, MCP servers, orchestration, and evaluation loops (the engineering behind this repo).
|
|
@@ -2,13 +2,13 @@
|
|
|
2
2
|
"mcpServers": {
|
|
3
3
|
"thumbgate": {
|
|
4
4
|
"command": "npx",
|
|
5
|
-
"args": ["--yes", "--package", "thumbgate@1.28.
|
|
5
|
+
"args": ["--yes", "--package", "thumbgate@1.28.1", "thumbgate", "serve"]
|
|
6
6
|
}
|
|
7
7
|
},
|
|
8
8
|
"hooks": {
|
|
9
9
|
"preToolUse": {
|
|
10
10
|
"command": "npx",
|
|
11
|
-
"args": ["--yes", "--package", "thumbgate@1.28.
|
|
11
|
+
"args": ["--yes", "--package", "thumbgate@1.28.1", "thumbgate", "gate-check"]
|
|
12
12
|
}
|
|
13
13
|
}
|
|
14
14
|
}
|