thumbgate 1.27.7 → 1.27.9

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.
Files changed (106) hide show
  1. package/.well-known/llms.txt +1 -2
  2. package/README.md +0 -2
  3. package/bin/cli.js +259 -78
  4. package/package.json +12 -18
  5. package/public/blog.html +30 -0
  6. package/public/compare/adopt-ai.html +219 -0
  7. package/public/compare/agentix-labs.html +197 -0
  8. package/public/compare/ai-experience-orchestration.html +216 -0
  9. package/public/compare/anthropic-claude-for-legal.html +260 -0
  10. package/public/compare/anthropic-containment.html +280 -0
  11. package/public/compare/arcade.html +175 -0
  12. package/public/compare/arcjet.html +239 -0
  13. package/public/compare/bumblebee.html +307 -0
  14. package/public/compare/claude-code-hooks.html +294 -0
  15. package/public/compare/databricks-unity-ai-gateway.html +215 -0
  16. package/public/compare/fallow.html +351 -0
  17. package/public/compare/heidi.html +233 -0
  18. package/public/compare/mem0.html +342 -0
  19. package/public/compare/oak-and-sparrow-gatekeeper.html +289 -0
  20. package/public/compare/rein.html +236 -0
  21. package/public/compare/sigmashake.html +256 -0
  22. package/public/compare/speclock.html +342 -0
  23. package/public/compare.html +2 -0
  24. package/public/guides/agent-harness-optimization.html +342 -0
  25. package/public/guides/agentic-web-governance.html +406 -0
  26. package/public/guides/ai-agent-governance-sprint.html +415 -0
  27. package/public/guides/ai-agent-pre-action-approval-gates.html +401 -0
  28. package/public/guides/ai-agent-workflow-migration-checklist.html +392 -0
  29. package/public/guides/ai-deployment-readiness.html +415 -0
  30. package/public/guides/ai-mode-ads-agent-governance.html +401 -0
  31. package/public/guides/ai-search-topical-presence.html +342 -0
  32. package/public/guides/autoresearch-agent-safety.html +342 -0
  33. package/public/guides/background-agent-governance.html +358 -0
  34. package/public/guides/best-tools-stop-ai-agents-breaking-production.html +363 -0
  35. package/public/guides/browser-automation-safety.html +342 -0
  36. package/public/guides/chatgpt-ads-trust.html +353 -0
  37. package/public/guides/claude-code-feedback.html +339 -0
  38. package/public/guides/claude-code-prevent-repeated-mistakes.html +161 -0
  39. package/public/guides/claude-code-skills-guardrails.html +343 -0
  40. package/public/guides/claude-desktop.html +356 -0
  41. package/public/guides/code-knowledge-graph-guardrails.html +365 -0
  42. package/public/guides/codex-cli-guardrails.html +339 -0
  43. package/public/guides/cursor-agent-guardrails.html +339 -0
  44. package/public/guides/cursor-prevent-repeated-mistakes.html +161 -0
  45. package/public/guides/database-agent-safety.html +406 -0
  46. package/public/guides/deepseek-v4-runtime-guardrails.html +346 -0
  47. package/public/guides/developer-machine-supply-chain-guardrails.html +358 -0
  48. package/public/guides/gcp-mcp-guardrails.html +147 -0
  49. package/public/guides/gemini-cli-feedback-memory.html +339 -0
  50. package/public/guides/gpt-5-5-model-evaluation.html +358 -0
  51. package/public/guides/internal-ai-engineering-stack-guardrails.html +348 -0
  52. package/public/guides/long-running-agent-context-management.html +346 -0
  53. package/public/guides/mcp-tool-governance.html +401 -0
  54. package/public/guides/multica-thumbgate-setup.html +134 -0
  55. package/public/guides/native-messaging-host-security.html +342 -0
  56. package/public/guides/policy-engine-pre-action-gates.html +346 -0
  57. package/public/guides/pre-action-checks.html +342 -0
  58. package/public/guides/pretooluse-hooks-vs-advisory-prompt-rules.html +342 -0
  59. package/public/guides/prompt-tricks-to-workflow-rules.html +365 -0
  60. package/public/guides/proxy-pointer-rag-guardrails.html +352 -0
  61. package/public/guides/rag-precision-tuning-guardrails.html +352 -0
  62. package/public/guides/reasoning-compression-guardrails.html +346 -0
  63. package/public/guides/relational-knowledge-ai-recommendations.html +342 -0
  64. package/public/guides/roo-code-alternative-cline.html +339 -0
  65. package/public/guides/semantic-programmatic-seo-guardrails.html +352 -0
  66. package/public/guides/seo-agent-skills-guardrails.html +344 -0
  67. package/public/guides/stop-repeated-ai-agent-mistakes.html +342 -0
  68. package/public/index.html +10 -48
  69. package/public/learn/ac-dc-runtime-enforcement.html +277 -0
  70. package/public/learn/agent-harness-pattern.html +181 -0
  71. package/public/learn/agent-swarms-shared-gates.html +173 -0
  72. package/public/learn/agentic-enterprise-context-brain.html +117 -0
  73. package/public/learn/agentic-os-team-governance.html +146 -0
  74. package/public/learn/ai-agent-governance.html +158 -0
  75. package/public/learn/ai-agent-persistent-memory.html +211 -0
  76. package/public/learn/background-agent-control-layer.html +184 -0
  77. package/public/learn/claude-code-goal-with-rubrics.html +205 -0
  78. package/public/learn/codex-role-plugins-need-governance.html +125 -0
  79. package/public/learn/cost-aware-agent-gate-routing.html +173 -0
  80. package/public/learn/databricks-unity-ai-gateway-runtime-governance.html +157 -0
  81. package/public/learn/deterministic-agent-workflows.html +185 -0
  82. package/public/learn/feedback-loop-vs-decision-layer.html +283 -0
  83. package/public/learn/from-prototype-to-production.html +223 -0
  84. package/public/learn/learn.css +51 -0
  85. package/public/learn/mcp-pre-action-checks-explained.html +172 -0
  86. package/public/learn/pretix-stripe-connect-marketplaces.html +161 -0
  87. package/public/learn/regulated-agent-execution-boundary.html +196 -0
  88. package/public/learn/spec-driven-development.html +168 -0
  89. package/public/learn/stop-ai-agent-force-push.html +134 -0
  90. package/public/learn/vibe-coding-safety-net.html +142 -0
  91. package/public/learn.html +6 -50
  92. package/public/pro.html +6 -6
  93. package/scripts/cli-schema.js +10 -22
  94. package/scripts/dashboard-chat.js +1 -2
  95. package/scripts/document-intake.js +49 -1
  96. package/scripts/gemini-embedding-policy.js +1 -2
  97. package/scripts/hosted-config.js +12 -0
  98. package/scripts/plausible-domain-config.js +1 -3
  99. package/scripts/reddit-browser-notification-watch.js +230 -0
  100. package/scripts/seo-gsd.js +0 -239
  101. package/scripts/vector-store.js +0 -44
  102. package/scripts/workspace-evolver.js +2 -62
  103. package/src/api/server.js +124 -335
  104. package/adapters/policy-engine/ethicore-guardian-client.js +0 -68
  105. package/adapters/policy-engine/thumbgate-policy-engine-adapter.js +0 -260
  106. package/scripts/hook-stop-anti-claim.js +0 -227
@@ -64,11 +64,10 @@ npx thumbgate init --agent claude-code
64
64
  - Agent discovery: https://thumbgate.ai/.well-known/mcp.json
65
65
  - Progressive tool index: https://thumbgate.ai/.well-known/mcp/tools.json
66
66
  - Context footprint report: https://thumbgate.ai/.well-known/mcp/footprint.json
67
- - Headroom context compression guardrails: https://thumbgate.ai/guides/headroom-context-compression-guardrails
68
- - Sovereign coding model guardrails: https://thumbgate.ai/guides/sovereign-coding-model-guardrails
69
67
  - Agentic web governance: https://thumbgate.ai/guides/agentic-web-governance
70
68
  - AI Mode ads and agent governance: https://thumbgate.ai/guides/ai-mode-ads-agent-governance
71
69
  - MCP tool governance: https://thumbgate.ai/guides/mcp-tool-governance
70
+ - Policy engines need pre-action gates: https://thumbgate.ai/guides/policy-engine-pre-action-gates
72
71
  - AI agent pre-action approval gates: https://thumbgate.ai/guides/ai-agent-pre-action-approval-gates
73
72
  - Agent skills: https://thumbgate.ai/.well-known/mcp/skills.json
74
73
  - MCP applications: https://thumbgate.ai/.well-known/mcp/applications.json
package/README.md CHANGED
@@ -384,8 +384,6 @@ npx thumbgate model-candidates --workload=dashboard-analysis --provider=openai -
384
384
  npx thumbgate native-messaging-audit # inspect local browser bridges and extension hosts
385
385
  npx thumbgate dashboard --open # open local project-scoped dashboard in browser
386
386
  thumbgate-dashboard # standalone browser dashboard shortcut (run '/project:thumbgate-dashboard' in Claude/Grok)
387
- npx thumbgate check-update # check if a new version is available on npm/GitHub
388
- npx thumbgate self-update # update ThumbGate to the latest version globally
389
387
  npx thumbgate serve # start MCP server on stdio
390
388
  npx thumbgate bench # run reliability benchmark
391
389
  npx thumbgate bench --programbench-smoke # include cleanroom whole-repo proof lane
package/bin/cli.js CHANGED
@@ -2188,26 +2188,6 @@ function pulse() {
2188
2188
  });
2189
2189
  }
2190
2190
 
2191
- function checkUpdateCmd() {
2192
- const { checkUpdate } = require(path.join(PKG_ROOT, 'scripts', 'check-update'));
2193
- const args = parseArgs(process.argv.slice(3));
2194
- checkUpdate({ verbose: !args.json, force: args.force }).then((res) => {
2195
- if (args.json) {
2196
- console.log(JSON.stringify(res, null, 2));
2197
- }
2198
- process.exit(0);
2199
- }).catch((err) => {
2200
- console.error(err && err.message ? err.message : err);
2201
- process.exit(1);
2202
- });
2203
- }
2204
-
2205
- function selfUpdateCmd() {
2206
- const { selfUpdate } = require(path.join(PKG_ROOT, 'scripts', 'check-update'));
2207
- const success = selfUpdate();
2208
- process.exit(success ? 0 : 1);
2209
- }
2210
-
2211
2191
  function dispatchBrief() {
2212
2192
  const args = parseArgs(process.argv.slice(3));
2213
2193
  const {
@@ -3171,7 +3151,6 @@ const SUBCOMMAND_HELP = {
3171
3151
  lessons: 'Usage: npx thumbgate lessons [--query="..."] [--limit=N]\n\nSearch the lesson database (Pro feature).',
3172
3152
  search: 'Usage: npx thumbgate search <query>\n\nSearch ThumbGate knowledge base (Pro feature).',
3173
3153
  'gate-check': 'Usage: npx thumbgate gate-check\n\nPreToolUse hook interface: reads tool call JSON from stdin, outputs gate verdict.',
3174
- 'hermes-gate': 'Usage: npx thumbgate hermes-gate\n\nNous Research Hermes Agent pre_tool_call shell hook: reads Hermes tool-call JSON from stdin, runs the ThumbGate gate pipeline (strict by default), and outputs {"decision":"block","reason":...} to veto or {} to allow. Gates terminal/patch/skill_manage etc. See adapters/hermes/config.yaml.',
3175
3154
  'break-glass': 'Usage: npx thumbgate break-glass --reason="why" [--ttl=5m] [--json]\n\nShort-lived recovery path for over-firing gates. Allows hook settings edits and satisfies PR-create/thread-check gates without disabling core destructive-action protections.',
3176
3155
  serve: 'Usage: npx thumbgate serve\n\nStart the MCP stdio server. This is for agent runtimes, not the local HTTP dashboard.',
3177
3156
  mcp: 'Usage: npx thumbgate mcp\n\nAlias for `thumbgate serve`.',
@@ -3189,6 +3168,11 @@ const SUBCOMMAND_HELP = {
3189
3168
  'ai-inventory': 'Usage: npx thumbgate ai-inventory [--root <dir>] [--format=summary|json|cyclonedx] [--output <path>] [--max-files=N]\n\nScan source/manifests/model artifacts for AI, ML, agent-framework, vector DB, Vertex, Gemini, and Dialogflow CX components. Use --format=cyclonedx to produce exportable ML-BOM evidence for enterprise reviews.',
3190
3169
  brain: 'Usage: npx thumbgate brain [--write] [--json] [--limit=N]\n\nBuild the agent-readable "context brain" — a single artifact consolidating this\nrepo\'s lessons, prevention rules, active gates, and project context for a coding\nagent to read BEFORE acting. --write saves it to .thumbgate/BRAIN.md (versioned,\ndeterministic). --json emits the structured model. --limit caps lessons (default 15).',
3191
3170
  'team-sync': 'Usage: npx thumbgate team-sync\n\nSynchronize prevention rules and context brain with your team\'s git repository (git pull --rebase & git push), then auto-rebuild the local brain.',
3171
+ dream: 'Usage: npx thumbgate dream [--min=N] [--feedback-dir=DIR] [--json]\n\nConsolidate raw history and lessons ("Silicon Dreaming"), merge duplicates, promote recurring failures to gates, and rebuild prevention rules + BRAIN.md.',
3172
+ consolidate: 'Usage: npx thumbgate consolidate\n\nAlias for npx thumbgate dream.',
3173
+ triage: 'Usage: npx thumbgate triage [--schedule="daily 9:00"] [--json]\n\nRun git updates, test verification, and memory consolidation, or schedule it on a cron.',
3174
+ hygiene: 'Usage: npx thumbgate hygiene\n\nAlias for npx thumbgate triage.',
3175
+ community: 'Usage: npx thumbgate community query <error> | share <rule-id>\n\nQuery or share verified prevention rules with the community knowledge registry.',
3192
3176
  };
3193
3177
 
3194
3178
  if (_wantsHelp && COMMAND && SUBCOMMAND_HELP[COMMAND]) {
@@ -3291,6 +3275,31 @@ function renderBrainMarkdown(model) {
3291
3275
  return out.join('\n');
3292
3276
  }
3293
3277
 
3278
+ function autoWireInstructionFile(fileName) {
3279
+ const filePath = path.join(CWD, fileName);
3280
+ if (!fs.existsSync(filePath)) return;
3281
+ try {
3282
+ let content = fs.readFileSync(filePath, 'utf8');
3283
+ const blockStart = '<!-- ThumbGate -->';
3284
+ const blockEnd = '<!-- End ThumbGate -->';
3285
+ const block = `${blockStart}\nIMPORTANT: Read .thumbgate/BRAIN.md first for lessons, prevention rules, and active gates in this repo.\n${blockEnd}\n`;
3286
+
3287
+ if (content.includes(blockStart)) {
3288
+ const startIdx = content.indexOf(blockStart);
3289
+ const endIdx = content.indexOf(blockEnd);
3290
+ if (endIdx !== -1) {
3291
+ content = content.slice(0, startIdx) + block + content.slice(endIdx + blockEnd.length).replace(/^\n+/, '');
3292
+ }
3293
+ } else {
3294
+ content = block + '\n' + content;
3295
+ }
3296
+ fs.writeFileSync(filePath, content);
3297
+ console.error(` Auto-wired agent pointer into ${fileName}`);
3298
+ } catch (err) {
3299
+ console.warn(`⚠️ Failed to auto-wire agent pointer in ${fileName}: ${err.message}`);
3300
+ }
3301
+ }
3302
+
3294
3303
  function cmdBrain(args = {}) {
3295
3304
  const model = buildBrainModel({ limit: args.limit });
3296
3305
  if (args.json) { console.log(JSON.stringify(model, null, 2)); return 0; }
@@ -3310,14 +3319,120 @@ function cmdBrain(args = {}) {
3310
3319
  const lt = (model.lessons && model.lessons.total) || 0;
3311
3320
  const rt = (model.rules && model.rules.total) || 0;
3312
3321
  const gt = (model.gates && model.gates.total) || 0;
3313
- console.log(`\u{1f9e0} Wrote context brain to .thumbgate/BRAIN.md (${lt} lessons · ${rt} rules · ${gt} gates).`);
3314
- console.log(' Point your agent at it: add "Read .thumbgate/BRAIN.md first" to CLAUDE.md / AGENTS.md.');
3322
+ console.error(`\u{1f9e0} Wrote context brain to .thumbgate/BRAIN.md (${lt} lessons · ${rt} rules · ${gt} gates).`);
3323
+
3324
+ // Auto-inject pointer block into CLAUDE.md / AGENTS.md
3325
+ autoWireInstructionFile('CLAUDE.md');
3326
+ autoWireInstructionFile('AGENTS.md');
3327
+
3315
3328
  return 0;
3316
3329
  }
3317
3330
  process.stdout.write(md);
3318
3331
  return 0;
3319
3332
  }
3320
3333
 
3334
+ function brain() {
3335
+ const args = parseArgs(process.argv.slice(3));
3336
+ const subcommand = process.argv.slice(3).find((arg) => !arg.startsWith('--')) || 'status';
3337
+ const {
3338
+ buildContextPack,
3339
+ checkNeverDo,
3340
+ cleanupReport,
3341
+ ensureBrain,
3342
+ formatContextPack,
3343
+ recordMemory,
3344
+ refreshNeverDoGates,
3345
+ } = require(path.join(PKG_ROOT, 'scripts', 'brain'));
3346
+
3347
+ if (subcommand === 'init' || subcommand === 'status') {
3348
+ const result = ensureBrain(CWD);
3349
+ const gates = refreshNeverDoGates(CWD);
3350
+ const payload = { ...result, gateCount: gates.gateCount };
3351
+ if (args.json) {
3352
+ console.log(JSON.stringify(payload, null, 2));
3353
+ return;
3354
+ }
3355
+ console.log('ThumbGate brain');
3356
+ console.log('='.repeat(15));
3357
+ console.log(`Brain dir : ${path.relative(CWD, result.brainDir)}`);
3358
+ console.log(`Created : ${result.created.length}`);
3359
+ console.log(`Soul files: ${result.soulFiles.length}`);
3360
+ console.log(`Memory dirs: ${result.memoryDirs.length}`);
3361
+ console.log(`Never-do gates: ${gates.gateCount}`);
3362
+ return;
3363
+ }
3364
+
3365
+ if (subcommand === 'context') {
3366
+ const task = args.task || process.argv.slice(4).find((arg) => !arg.startsWith('--')) || '';
3367
+ const pack = buildContextPack(CWD, { task });
3368
+ if (args.json) {
3369
+ console.log(JSON.stringify(pack, null, 2));
3370
+ return;
3371
+ }
3372
+ process.stdout.write(formatContextPack(pack));
3373
+ return;
3374
+ }
3375
+
3376
+ if (subcommand === 'remember') {
3377
+ const title = args.title || process.argv.slice(4).find((arg) => !arg.startsWith('--')) || '';
3378
+ const result = recordMemory(CWD, {
3379
+ type: args.type,
3380
+ title,
3381
+ content: args.content || title,
3382
+ reason: args.reason,
3383
+ source: args.source,
3384
+ tags: args.tags,
3385
+ date: args.date,
3386
+ });
3387
+ if (args.json) {
3388
+ console.log(JSON.stringify(result, null, 2));
3389
+ return;
3390
+ }
3391
+ if (!result.ok) {
3392
+ console.error(result.error);
3393
+ process.exit(1);
3394
+ }
3395
+ console.log(`Stored brain memory: ${result.path}`);
3396
+ return;
3397
+ }
3398
+
3399
+ if (subcommand === 'check') {
3400
+ const text = args.text || args.action || readStdinText();
3401
+ const result = checkNeverDo(CWD, { text });
3402
+ if (args.json) {
3403
+ console.log(JSON.stringify(result, null, 2));
3404
+ if (!result.ok) process.exit(2);
3405
+ return;
3406
+ }
3407
+ console.log(`ThumbGate brain decision: ${result.decision.toUpperCase()}`);
3408
+ for (const rule of result.blocked) console.log(`- ${rule.text}`);
3409
+ if (!result.ok) process.exit(2);
3410
+ return;
3411
+ }
3412
+
3413
+ if (subcommand === 'cleanup') {
3414
+ const report = cleanupReport(CWD, args);
3415
+ if (args.json) {
3416
+ console.log(JSON.stringify(report, null, 2));
3417
+ return;
3418
+ }
3419
+ console.log('ThumbGate brain cleanup report');
3420
+ console.log('='.repeat(31));
3421
+ console.log(`Memory files: ${report.total}`);
3422
+ console.log(`Unsourced : ${report.unsourced.length}`);
3423
+ console.log(`Stale : ${report.stale.length}`);
3424
+ console.log(`Duplicates : ${report.duplicates.length}`);
3425
+ if (report.unsourced.length) {
3426
+ console.log('\nUnsourced files:');
3427
+ for (const filePath of report.unsourced) console.log(`- ${filePath}`);
3428
+ }
3429
+ return;
3430
+ }
3431
+
3432
+ console.error('Usage: npx thumbgate brain init|context|remember|check|cleanup [--json]');
3433
+ process.exit(1);
3434
+ }
3435
+
3321
3436
  async function teamSync() {
3322
3437
  const { execSync } = require('child_process');
3323
3438
 
@@ -3496,6 +3611,127 @@ switch (COMMAND) {
3496
3611
  }
3497
3612
  break;
3498
3613
  }
3614
+ case 'dream':
3615
+ case 'consolidate': {
3616
+ const args = parseArgs(process.argv.slice(3));
3617
+ const { dream } = require(path.join(PKG_ROOT, 'scripts', 'dream-consolidation'));
3618
+ dream({
3619
+ pkgRoot: PKG_ROOT,
3620
+ feedbackDir: args['feedback-dir'] || args.feedbackDir || CWD,
3621
+ rulesPath: args.output || path.join(CWD, '.thumbgate', 'prevention-rules.md'),
3622
+ minOccurrences: args.min || 2,
3623
+ }).then(async (result) => {
3624
+ try {
3625
+ await cmdBrain({ write: true });
3626
+ } catch (brainErr) {
3627
+ console.warn(`⚠️ Failed to rebuild context brain: ${brainErr.message}`);
3628
+ }
3629
+ if (args.json) {
3630
+ console.log(JSON.stringify(result, null, 2));
3631
+ } else {
3632
+ console.log(`✨ [Dreaming] Consolidation complete! Merged ${result.consolidated} duplicate(s) into ${result.lessonsCount} lessons.`);
3633
+ }
3634
+ process.exit(0);
3635
+ }).catch((err) => {
3636
+ console.error('❌ Error during memory consolidation:', err && err.message ? err.message : err);
3637
+ process.exit(1);
3638
+ });
3639
+ break;
3640
+ }
3641
+ case 'triage':
3642
+ case 'hygiene': {
3643
+ const args = parseArgs(process.argv.slice(3));
3644
+ const { runTriageLoop } = require(path.join(PKG_ROOT, 'scripts', 'triage-loop'));
3645
+
3646
+ if (args.schedule) {
3647
+ const { createSchedule } = require(path.join(PKG_ROOT, 'scripts', 'schedule-manager'));
3648
+ const scheduleResult = createSchedule({
3649
+ id: 'thumbgate-triage-hygiene',
3650
+ name: 'ThumbGate Triage & Hygiene Loop',
3651
+ description: 'Run autonomous git checks, test suite verification, and Silicon Dreaming memory consolidation.',
3652
+ schedule: args.schedule,
3653
+ command: `const { runTriageLoop } = require('${path.join(PKG_ROOT, 'scripts', 'triage-loop')}'); runTriageLoop({ cwd: '${CWD}', pkgRoot: '${PKG_ROOT}' }).catch(console.error);`,
3654
+ workingDirectory: CWD,
3655
+ });
3656
+ if (args.json) {
3657
+ console.log(JSON.stringify(scheduleResult, null, 2));
3658
+ } else {
3659
+ if (scheduleResult.success) {
3660
+ console.log(`✅ [Triage] Scheduled triage hygiene loop: ${scheduleResult.message}`);
3661
+ } else {
3662
+ console.error(`❌ [Triage] Failed to schedule: ${scheduleResult.error}`);
3663
+ process.exit(1);
3664
+ }
3665
+ }
3666
+ break;
3667
+ }
3668
+
3669
+ runTriageLoop({
3670
+ cwd: CWD,
3671
+ pkgRoot: PKG_ROOT,
3672
+ }).then(async (result) => {
3673
+ try {
3674
+ await cmdBrain({ write: true });
3675
+ } catch (brainErr) {
3676
+ console.warn(`⚠️ Failed to rebuild context brain: ${brainErr.message}`);
3677
+ }
3678
+ if (args.json) {
3679
+ console.log(JSON.stringify(result, null, 2));
3680
+ } else {
3681
+ console.log(result.log);
3682
+ }
3683
+ process.exit(0);
3684
+ }).catch((err) => {
3685
+ console.error('❌ Error during triage loop execution:', err && err.message ? err.message : err);
3686
+ process.exit(1);
3687
+ });
3688
+ break;
3689
+ }
3690
+ case 'community': {
3691
+ const args = parseArgs(process.argv.slice(3));
3692
+ const sub = process.argv.slice(3).find((arg) => !arg.startsWith('--'));
3693
+ const { queryCommunity, shareRule } = require(path.join(PKG_ROOT, 'scripts', 'community-knowledge'));
3694
+
3695
+ if (sub === 'query') {
3696
+ const queryIdx = process.argv.indexOf('query');
3697
+ const queryText = process.argv.slice(queryIdx + 1).filter(arg => !arg.startsWith('--')).join(' ');
3698
+ const result = queryCommunity(queryText, { remote: args.remote });
3699
+ if (args.json) {
3700
+ console.log(JSON.stringify(result, null, 2));
3701
+ } else {
3702
+ console.log(`🔍 Found ${result.resultsCount} community rule(s) matching "${result.query}":`);
3703
+ for (const r of result.results) {
3704
+ console.log(`\n- [${r.id}] ${r.rule}`);
3705
+ console.log(` Remedy: ${r.remedy}`);
3706
+ console.log(` Explanation: ${r.explanation}`);
3707
+ }
3708
+ }
3709
+ process.exit(0);
3710
+ } else if (sub === 'share') {
3711
+ const shareIdx = process.argv.indexOf('share');
3712
+ const ruleId = process.argv.slice(shareIdx + 1).find(arg => !arg.startsWith('--'));
3713
+ if (!ruleId) {
3714
+ console.error('❌ Error: rule ID is required for share subcommand.');
3715
+ process.exit(1);
3716
+ }
3717
+ const result = shareRule(ruleId, { feedbackDir: CWD });
3718
+ if (args.json) {
3719
+ console.log(JSON.stringify(result, null, 2));
3720
+ } else {
3721
+ if (result.ok) {
3722
+ console.log(`✨ Successfully shared rule "${ruleId}" to community registry.`);
3723
+ } else {
3724
+ console.error(`❌ Failed to share rule: ${result.error}`);
3725
+ process.exit(1);
3726
+ }
3727
+ }
3728
+ process.exit(0);
3729
+ } else {
3730
+ console.error('Usage: npx thumbgate community query <error> | share <rule-id> [--json]');
3731
+ process.exit(1);
3732
+ }
3733
+ break;
3734
+ }
3499
3735
  case 'billing:setup':
3500
3736
  require(path.join(PKG_ROOT, 'scripts', 'billing-setup'));
3501
3737
  break;
@@ -3863,14 +4099,6 @@ switch (COMMAND) {
3863
4099
  case 'pulse':
3864
4100
  pulse();
3865
4101
  break;
3866
- case 'check-update':
3867
- case 'upgrade-check':
3868
- checkUpdateCmd();
3869
- break;
3870
- case 'self-update':
3871
- case 'upgrade-cli':
3872
- selfUpdateCmd();
3873
- break;
3874
4102
  case 'dispatch':
3875
4103
  case 'dispatch-brief':
3876
4104
  dispatchBrief();
@@ -3896,53 +4124,6 @@ switch (COMMAND) {
3896
4124
  });
3897
4125
  break;
3898
4126
  }
3899
- case 'hermes-gate': {
3900
- // Nous Research Hermes Agent `pre_tool_call` shell hook.
3901
- // Hermes pipes each pending tool call as JSON to stdin and reads a decision from stdout;
3902
- // {"decision":"block","reason":...} vetoes the call. We reuse the SAME gate pipeline as
3903
- // `gate-check` (runAsync → secret guard, security scan, force-push / skill_manage / learned
3904
- // prevention rules) and translate the verdict into Hermes's format.
3905
- //
3906
- // Hermes `pre_tool_call` is binary (block or allow) with no warn channel, and the whole point
3907
- // of wiring it is to gate, so we run STRICT enforcement by default — otherwise ThumbGate's
3908
- // warn-by-default posture would pass every deny through and the hook would block nothing.
3909
- // Opt out with THUMBGATE_HERMES_WARN_ONLY=1; THUMBGATE_HOTFIX_BYPASS=1 still disables checks.
3910
- // Wire it in ~/.hermes/config.yaml — see adapters/hermes/config.yaml.
3911
- if (process.env.THUMBGATE_HERMES_WARN_ONLY !== '1' && process.env.THUMBGATE_HOTFIX_BYPASS !== '1') {
3912
- process.env.THUMBGATE_STRICT_ENFORCEMENT = '1';
3913
- }
3914
- const { runAsync: hermesGateRun } = require(path.join(PKG_ROOT, 'scripts', 'gates-engine'));
3915
- let hermesStdin = '';
3916
- process.stdin.setEncoding('utf8');
3917
- process.stdin.on('data', (chunk) => { hermesStdin += chunk; });
3918
- process.stdin.on('end', async () => {
3919
- try {
3920
- const payload = JSON.parse(hermesStdin);
3921
- // Hermes sends snake_case tool_name/tool_input — gates-engine reads these directly.
3922
- const verdict = await hermesGateRun({ tool_name: payload.tool_name, tool_input: payload.tool_input });
3923
- let parsed = {};
3924
- try { parsed = JSON.parse(verdict); } catch (_e) { parsed = {}; }
3925
- const hso = parsed.hookSpecificOutput || {};
3926
- if (hso.permissionDecision === 'deny') {
3927
- process.stdout.write(JSON.stringify({
3928
- decision: 'block',
3929
- reason: hso.permissionDecisionReason || 'Blocked by ThumbGate prevention rule.',
3930
- }) + '\n');
3931
- } else {
3932
- // warn / no match → allow. The gate engine already logged the decision.
3933
- process.stdout.write(JSON.stringify({}) + '\n');
3934
- }
3935
- process.exit(0);
3936
- } catch (err) {
3937
- // Hermes hooks fail OPEN on error/timeout — emit an explicit allow so a gate fault
3938
- // never wedges the agent (reliability ≈ enforcement; keep this fast).
3939
- process.stderr.write(`hermes-gate error: ${err.message}\n`);
3940
- process.stdout.write(JSON.stringify({}) + '\n');
3941
- process.exit(0);
3942
- }
3943
- });
3944
- break;
3945
- }
3946
4127
  case 'gate-stats':
3947
4128
  gateStats();
3948
4129
  break;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "thumbgate",
3
- "version": "1.27.7",
3
+ "version": "1.27.9",
4
4
  "description": "ThumbGate self-improving agent governance: thumbs-up/down turns every mistake into a prevention rule and blocks repeat patterns. 36 pre-action checks, budget enforcement, and self-protection for Claude Code, Cursor, Codex, Gemini CLI, and Amp.",
5
5
  "homepage": "https://thumbgate.ai",
6
6
  "repository": {
@@ -106,7 +106,6 @@
106
106
  "scripts/harness-selector.js",
107
107
  "scripts/hf-papers.js",
108
108
  "scripts/hook-runtime.js",
109
- "scripts/hook-stop-anti-claim.js",
110
109
  "scripts/hook-thumbgate-cache-updater.js",
111
110
  "scripts/hosted-config.js",
112
111
  "scripts/hybrid-feedback-context.js",
@@ -171,6 +170,7 @@
171
170
  "scripts/rag-precision-guardrails.js",
172
171
  "scripts/rate-limiter.js",
173
172
  "scripts/reasoning-efficiency-guardrails.js",
173
+ "scripts/reddit-browser-notification-watch.js",
174
174
  "scripts/repeat-metric.js",
175
175
  "scripts/reward-hacking-guardrails.js",
176
176
  "scripts/risk-scorer.js",
@@ -244,9 +244,6 @@
244
244
  "adapters/letta/README.md",
245
245
  "adapters/letta/thumbgate-letta-adapter.js",
246
246
  "adapters/gcp/dfcx-webhook-gate.js",
247
- "adapters/policy-engine/README.md",
248
- "adapters/policy-engine/ethicore-guardian-client.js",
249
- "adapters/policy-engine/thumbgate-policy-engine-adapter.js",
250
247
  "adapters/mcp/server-stdio.js",
251
248
  "adapters/opencode/opencode.json",
252
249
  "bench/programbench-smoke.json",
@@ -267,11 +264,14 @@
267
264
  "public/chatgpt-app.html",
268
265
  "public/codex-plugin.html",
269
266
  "public/compare.html",
267
+ "public/compare/",
270
268
  "public/dashboard.html",
271
269
  "public/federal.html",
272
270
  "public/guide.html",
271
+ "public/guides/",
273
272
  "public/index.html",
274
273
  "public/learn.html",
274
+ "public/learn/",
275
275
  "public/lessons.html",
276
276
  "public/numbers.html",
277
277
  "public/pricing.html",
@@ -366,6 +366,8 @@
366
366
  "trace:eval": "node scripts/decision-trace.js eval",
367
367
  "social:reply-monitor": "node scripts/social-reply-monitor.js",
368
368
  "social:reply-monitor:dry": "node scripts/social-reply-monitor.js --dry-run",
369
+ "social:reply-monitor:reddit-browser": "node scripts/reddit-browser-notification-watch.js",
370
+ "social:reply-monitor:reddit-browser:dry": "node scripts/reddit-browser-notification-watch.js --dry-run",
369
371
  "social:reply-monitor:install-reddit": "node scripts/reddit-monitor-launchd.js install",
370
372
  "social:reply-monitor:bluesky": "node scripts/social-reply-monitor-bluesky.js",
371
373
  "social:reply-monitor:bluesky:dry": "node scripts/social-reply-monitor-bluesky.js --dry-run",
@@ -374,10 +376,9 @@
374
376
  "social:prospect:bluesky": "node scripts/social-bluesky-prospecting.js",
375
377
  "social:prospect:bluesky:dry": "node scripts/social-bluesky-prospecting.js --dry-run",
376
378
  "social:reply-publish:bluesky:dry": "node scripts/social-reply-monitor-bluesky.js --publish-approved --dry-run",
377
- "test": "npm run test:python && npm run test:schema && npm run test:loop && npm run test:dpo && npm run test:kto && npm run test:api && npm run test:proof && npm run test:e2e && npm run test:rlaif && npm run test:attribution && npm run test:quality && npm run test:intelligence && npm run test:training-export && npm run test:deployment && npm run test:operational-integrity && npm run test:workflow && npm run test:billing && npm run test:cli && npm run test:watcher && npm run test:autoresearch && npm run test:ops && npm run test:session-analyzer && npm run test:tessl && npm run test:gates && npm run test:evoskill && npm run test:gates-hardening && npm run test:workers && npm run test:social-analytics && npm run test:memalign && npm run test:xmemory-lite && npm run test:filesystem-search && npm run test:zernio && npm run test:platform-limits && npm run test:post-video && npm run test:post-everywhere-instagram && npm run test:post-everywhere-channels && npm run test:post-everywhere-zernio-default && npm run test:zernio-canonical-pollers && npm run test:zernio-status && npm run test:obsidian-export && npm run test:lesson-db && npm run test:lesson-rotation && npm run test:memory-dedup && npm run test:feedback-quality && npm run test:sync-version && npm run test:check-congruence && npm run test:tool-registry && npm run test:repeat-metric && npm run test:noop-detect && npm run test:action-receipts && npm run test:feedback-to-rules && npm run test:memory-firewall && npm run test:memory-scope-readiness && npm run test:belief-update && npm run test:hosted-config && npm run test:operational-summary && npm run test:operational-dashboard && npm run test:operator-artifacts && npm run test:operator-key-auth && npm run test:cloudflare-sandbox && npm run test:mcp-config && npm run test:mcp-tool-annotations && npm run test:mcp-oauth && npm run test:mcp-oauth-flow && npm run test:plan-gate && npm run test:ai-component-inventory && npm run test:pulse && npm run test:semantic-layer && npm run test:data-pipeline && npm run test:optimize-context && npm run test:principle-extractor && npm run test:analytics-window && npm run test:funnel-analytics && npm run test:experiment-tracker && npm run test:build-metadata && npm run test:context-engine && npm run test:hf-papers && npm run test:marketing-experiment && npm run test:seo-gsd && npm run test:verify-run && npm run test:export-dpo-pairs && npm run test:export-hf-dataset && npm run test:license && npm run test:bot-detector && npm run test:audit-pr-bot-contamination && npm run test:stripe-bootstrap-saas-catalog && npm run test:postinstall && npm run test:funnel-invariants && npm run test:cli-telemetry && npm run test:pro-parity && npm run test:model-tier-router && npm run test:computer-use-firewall && npm run test:skill-exporter && npm run test:statusline && npm run test:statusline-cache-aggregate && npm run test:public-repo-hygiene && npm run test:no-internal-orchestration-leaks && npm run test:evolution && npm run test:org-dashboard && npm run test:multi-hop-recall && npm run test:synthetic-dpo && npm run test:thumbgate-skill && npm run test:learn-hub && npm run test:feedback-fallback && npm run test:metaclaw && npm run test:server-lock && npm run test:control-tower && npm run test:pii-scanner && npm run test:data-governance && npm run test:lesson-inference && npm run test:semantic-dedup && npm run test:fs-utils && npm run test:cli-schema && npm run test:explore && npm run test:lesson-reranker && npm run test:lesson-retrieval && npm run test:lesson-semantic-retrieval && npm run test:cross-encoder && npm run test:reflector-agent && npm run test:feedback-session && npm run test:feedback-history-distiller && npm run test:hallucination-detector && npm run test:history-distiller && npm run test:predictive-insights && npm run test:predictive-credible-range && npm run test:prove-predictive-insights && npm run test:statusbar-cli && npm run test:generate-instagram-card && npm run test:instagram-thumbgate-post && npm run test:publish-instagram-thumbgate && npm run test:lesson-synthesis && npm run test:lesson-canonical && npm run test:background-governance && npm run test:memory-migration && npm run test:prompt-dlp && npm run test:ephemeral-store && npm run test:agent-security && npm run test:skill-progressive && npm run test:per-step-scoring && npm run test:weekly-auto-post && npm run test:social-post-hourly && npm run test:social-quality-gate && npm run test:a2ui-engine && npm run test:gate-satisfy && npm run test:money-watcher && npm run test:budget && npm run test:quick-start && npm run test:utm && npm run test:product-feedback && npm run test:feedback-root-consolidator && npm run test:engagement-audit && npm run test:install-growth-automation && npm run test:publish-thumbgate-launch && npm run test:reconcile-thumbgate-campaign && npm run test:reddit-publisher && npm run test:schedule-thumbgate-campaign && npm run test:social-reply-monitor && npm run test:social-dedupe-cleanup && npm run test:sync-launch-assets && npm run test:ai-search-visibility && npm run test:perplexity && npm run test:security-scanner && npm run test:llm-client && npm run test:managed-lesson-agent && npm run test:self-distill && npm run test:meta-agent && npm run test:harness-selector && npm run test:thumbgate-bench && npm run test:seo-guides && npm run test:enforcement-loop && npm run test:cli-agent-experience && npm run test:bot-detection && npm run test:checkout-archived-product-guard && npm run test:postgres-guard && npm run test:checkout-bot-guard && npm run test:checkout-pro-confirmation-gate && npm run test:pricing-page-telemetry && npm run test:session-health && npm run test:session-episodes && npm run test:spec-gate && npm run test:decision-trace && npm run test:dashboard-insights && npm run test:telemetry-tracked-link-slug && npm run test:prompt-eval && npm run test:gate-coherence && npm run test:gate-eval && npm run test:high-roi && npm run test:public-static-assets && npm run test:token-savings && npm run test:numbers-page && npm run test:workflow-gate-checkpoint && npm run test:lesson-export-import && npm run test:landing-page-claims && npm run test:competitive-positioning-marketing && npm run test:medium-weekly && npm run test:dashboard-deeplink-e2e && npm run test:public-package-parity && npm run test:token-savings-dashboard && npm run test:cursor-wiring && npm run test:pretooluse-injection && npm run test:recent-corrective-context && npm run test:durability-step && npm run test:mailer && npm run test:brand-assets && npm run test:enforcement-teeth && npm run test:bayes-optimal-gate && npm run test:swarm-coordinator && npm run test:session-report && npm run test:agent-reasoning-traces && npm run test:judge-reward && npm run test:llm-behavior-monitor && npm run test:prompting-os && npm run test:single-use-credential-gate && npm run test:structured-prompt-driven && npm run test:require-evidence-gate && npm run test:rule-validator && npm run test:bluesky-atproto && npm run test:social-reply-monitor-bluesky && npm run test:bluesky-delete-replies && npm run test:architect-kit-memory-bridge && npm run test:sonar-review-hotspots && npm run test:actionable-remediations && npm run test:gemini-embedding-policy && npm run test:agent-design-governance && npm run test:public-core-boundary && npm run test:hook-stop-verify-deploy && npm run test:hook-stop-anti-claim && npm run test:plausible-server-events && npm run test:activation-tracker && npm run test:activation-onboarding && npm run test:unified-revenue-rollup && npm run test:conversion-rate-stats && npm run test:external-customer-audit && npm run test:telemetry-export && npm run test:stripe-checkout-diagnostic && npm run test:stripe-business-identity-probe && npm run test:revenue-observability-doctor && npm run test:public-bundle-ratchet && npm run test:stripe-payment-link-update && npm run test:ci-cd-hygiene-audit && npm run test:verify-marketing-pages-deployed && npm run test:install-email-capture && npm run test:install-shim && npm run test:hook-runtime-subcommands && npm run test:implementation-notes && npm run test:daily-block-cap && npm run test:free-to-paid-conversion-units && npm run test:metrics-real-endpoint && npm run test:cli-trial-and-help && npm run test:cost-cli && npm run test:silent-failure-cluster && npm run test:proof:truth && node --test tests/adaptive-reliability.test.js && npm run test:mcp-oauth-reviewer && npm run test:dfcx-gate && npm run test:dfcx-gate-server && npm run test:vertex-scorer && npm run test:dashboard-chat && npm run test:gitar-integration && npm run test:secret-redaction && npm run test:discoverable-skills && npm run test:discoverable-skill-skills && npm run test:sync-telemetry && npm run test:leak-scanner && npm run test:team-sync && npm run test:eval-rag && npm run test:async-eval-observability && npm run test:letta-adapter && npm run test:tool-contract-validator && npm run test:check-update",
379
+ "test": "npm run test:brain && npm run test:python && npm run test:schema && npm run test:loop && npm run test:dpo && npm run test:kto && npm run test:api && npm run test:proof && npm run test:e2e && npm run test:rlaif && npm run test:attribution && npm run test:quality && npm run test:intelligence && npm run test:training-export && npm run test:deployment && npm run test:operational-integrity && npm run test:workflow && npm run test:billing && npm run test:cli && npm run test:watcher && npm run test:autoresearch && npm run test:ops && npm run test:session-analyzer && npm run test:tessl && npm run test:gates && npm run test:evoskill && npm run test:gates-hardening && npm run test:workers && npm run test:social-analytics && npm run test:memalign && npm run test:xmemory-lite && npm run test:filesystem-search && npm run test:zernio && npm run test:platform-limits && npm run test:post-video && npm run test:post-everywhere-instagram && npm run test:post-everywhere-channels && npm run test:post-everywhere-zernio-default && npm run test:zernio-canonical-pollers && npm run test:zernio-status && npm run test:obsidian-export && npm run test:lesson-db && npm run test:lesson-rotation && npm run test:memory-dedup && npm run test:feedback-quality && npm run test:sync-version && npm run test:check-congruence && npm run test:tool-registry && npm run test:repeat-metric && npm run test:noop-detect && npm run test:action-receipts && npm run test:feedback-to-rules && npm run test:memory-firewall && npm run test:memory-scope-readiness && npm run test:belief-update && npm run test:hosted-config && npm run test:operational-summary && npm run test:operational-dashboard && npm run test:operator-artifacts && npm run test:operator-key-auth && npm run test:cloudflare-sandbox && npm run test:mcp-config && npm run test:mcp-tool-annotations && npm run test:mcp-oauth && npm run test:mcp-oauth-flow && npm run test:plan-gate && npm run test:ai-component-inventory && npm run test:pulse && npm run test:semantic-layer && npm run test:data-pipeline && npm run test:optimize-context && npm run test:principle-extractor && npm run test:analytics-window && npm run test:funnel-analytics && npm run test:experiment-tracker && npm run test:build-metadata && npm run test:context-engine && npm run test:hf-papers && npm run test:marketing-experiment && npm run test:seo-gsd && npm run test:verify-run && npm run test:export-dpo-pairs && npm run test:export-hf-dataset && npm run test:license && npm run test:bot-detector && npm run test:audit-pr-bot-contamination && npm run test:stripe-bootstrap-saas-catalog && npm run test:postinstall && npm run test:funnel-invariants && npm run test:cli-telemetry && npm run test:pro-parity && npm run test:model-tier-router && npm run test:computer-use-firewall && npm run test:skill-exporter && npm run test:statusline && npm run test:statusline-cache-aggregate && npm run test:public-repo-hygiene && npm run test:no-internal-orchestration-leaks && npm run test:evolution && npm run test:org-dashboard && npm run test:multi-hop-recall && npm run test:synthetic-dpo && npm run test:thumbgate-skill && npm run test:learn-hub && npm run test:feedback-fallback && npm run test:metaclaw && npm run test:server-lock && npm run test:control-tower && npm run test:pii-scanner && npm run test:data-governance && npm run test:lesson-inference && npm run test:semantic-dedup && npm run test:fs-utils && npm run test:cli-schema && npm run test:explore && npm run test:lesson-reranker && npm run test:lesson-retrieval && npm run test:lesson-semantic-retrieval && npm run test:cross-encoder && npm run test:reflector-agent && npm run test:feedback-session && npm run test:feedback-history-distiller && npm run test:hallucination-detector && npm run test:history-distiller && npm run test:predictive-insights && npm run test:predictive-credible-range && npm run test:prove-predictive-insights && npm run test:statusbar-cli && npm run test:generate-instagram-card && npm run test:instagram-thumbgate-post && npm run test:publish-instagram-thumbgate && npm run test:lesson-synthesis && npm run test:lesson-canonical && npm run test:background-governance && npm run test:memory-migration && npm run test:prompt-dlp && npm run test:ephemeral-store && npm run test:agent-security && npm run test:skill-progressive && npm run test:per-step-scoring && npm run test:weekly-auto-post && npm run test:social-post-hourly && npm run test:social-quality-gate && npm run test:a2ui-engine && npm run test:gate-satisfy && npm run test:money-watcher && npm run test:budget && npm run test:quick-start && npm run test:utm && npm run test:product-feedback && npm run test:feedback-root-consolidator && npm run test:engagement-audit && npm run test:install-growth-automation && npm run test:publish-thumbgate-launch && npm run test:reconcile-thumbgate-campaign && npm run test:reddit-publisher && npm run test:schedule-thumbgate-campaign && npm run test:social-reply-monitor && npm run test:social-dedupe-cleanup && npm run test:sync-launch-assets && npm run test:ai-search-visibility && npm run test:perplexity && npm run test:security-scanner && npm run test:llm-client && npm run test:managed-lesson-agent && npm run test:self-distill && npm run test:meta-agent && npm run test:harness-selector && npm run test:thumbgate-bench && npm run test:seo-guides && npm run test:enforcement-loop && npm run test:cli-agent-experience && npm run test:bot-detection && npm run test:checkout-archived-product-guard && npm run test:postgres-guard && npm run test:checkout-bot-guard && npm run test:checkout-pro-confirmation-gate && npm run test:pricing-page-telemetry && npm run test:session-health && npm run test:session-episodes && npm run test:spec-gate && npm run test:decision-trace && npm run test:dashboard-insights && npm run test:telemetry-tracked-link-slug && npm run test:prompt-eval && npm run test:gate-coherence && npm run test:gate-eval && npm run test:high-roi && npm run test:public-static-assets && npm run test:token-savings && npm run test:numbers-page && npm run test:workflow-gate-checkpoint && npm run test:lesson-export-import && npm run test:landing-page-claims && npm run test:competitive-positioning-marketing && npm run test:medium-weekly && npm run test:dashboard-deeplink-e2e && npm run test:public-package-parity && npm run test:token-savings-dashboard && npm run test:cursor-wiring && npm run test:pretooluse-injection && npm run test:recent-corrective-context && npm run test:durability-step && npm run test:mailer && npm run test:brand-assets && npm run test:enforcement-teeth && npm run test:bayes-optimal-gate && npm run test:swarm-coordinator && npm run test:session-report && npm run test:agent-reasoning-traces && npm run test:judge-reward && npm run test:llm-behavior-monitor && npm run test:prompting-os && npm run test:single-use-credential-gate && npm run test:structured-prompt-driven && npm run test:require-evidence-gate && npm run test:rule-validator && npm run test:bluesky-atproto && npm run test:social-reply-monitor-bluesky && npm run test:bluesky-delete-replies && npm run test:architect-kit-memory-bridge && npm run test:sonar-review-hotspots && npm run test:actionable-remediations && npm run test:gemini-embedding-policy && npm run test:agent-design-governance && npm run test:public-core-boundary && npm run test:hook-stop-verify-deploy && npm run test:hook-stop-anti-claim && npm run test:plausible-server-events && npm run test:activation-tracker && npm run test:activation-onboarding && npm run test:unified-revenue-rollup && npm run test:conversion-rate-stats && npm run test:external-customer-audit && npm run test:telemetry-export && npm run test:stripe-checkout-diagnostic && npm run test:stripe-business-identity-probe && npm run test:revenue-observability-doctor && npm run test:public-bundle-ratchet && npm run test:stripe-payment-link-update && npm run test:ci-cd-hygiene-audit && npm run test:verify-marketing-pages-deployed && npm run test:install-email-capture && npm run test:install-shim && npm run test:hook-runtime-subcommands && npm run test:implementation-notes && npm run test:daily-block-cap && npm run test:free-to-paid-conversion-units && npm run test:metrics-real-endpoint && npm run test:cli-trial-and-help && npm run test:cost-cli && npm run test:silent-failure-cluster && npm run test:proof:truth && node --test tests/adaptive-reliability.test.js && npm run test:mcp-oauth-reviewer && npm run test:dfcx-gate && npm run test:dfcx-gate-server && npm run test:vertex-scorer && npm run test:dashboard-chat && npm run test:gitar-integration && npm run test:secret-redaction && npm run test:discoverable-skills && npm run test:discoverable-skill-skills && npm run test:sync-telemetry && npm run test:leak-scanner && npm run test:team-sync && npm run test:eval-rag && npm run test:async-eval-observability && npm run test:letta-adapter && npm run test:tool-contract-validator && npm run test:policy-engine-adapter",
380
+ "test:brain": "node --test tests/brain.test.js",
378
381
  "test:python": "python3 -m pytest tests/*.py",
379
- "test:check-update": "node --test tests/check-update.test.js",
380
- "test": "npm run test:python && npm run test:schema && npm run test:loop && npm run test:dpo && npm run test:kto && npm run test:api && npm run test:proof && npm run test:e2e && npm run test:rlaif && npm run test:attribution && npm run test:quality && npm run test:intelligence && npm run test:training-export && npm run test:deployment && npm run test:operational-integrity && npm run test:workflow && npm run test:billing && npm run test:cli && npm run test:watcher && npm run test:autoresearch && npm run test:ops && npm run test:session-analyzer && npm run test:tessl && npm run test:gates && npm run test:evoskill && npm run test:gates-hardening && npm run test:workers && npm run test:social-analytics && npm run test:memalign && npm run test:xmemory-lite && npm run test:filesystem-search && npm run test:zernio && npm run test:platform-limits && npm run test:post-video && npm run test:post-everywhere-instagram && npm run test:post-everywhere-channels && npm run test:post-everywhere-zernio-default && npm run test:zernio-canonical-pollers && npm run test:zernio-status && npm run test:obsidian-export && npm run test:lesson-db && npm run test:lesson-rotation && npm run test:memory-dedup && npm run test:feedback-quality && npm run test:sync-version && npm run test:check-congruence && npm run test:tool-registry && npm run test:repeat-metric && npm run test:noop-detect && npm run test:action-receipts && npm run test:feedback-to-rules && npm run test:memory-firewall && npm run test:memory-scope-readiness && npm run test:belief-update && npm run test:hosted-config && npm run test:operational-summary && npm run test:operational-dashboard && npm run test:operator-artifacts && npm run test:operator-key-auth && npm run test:cloudflare-sandbox && npm run test:mcp-config && npm run test:mcp-tool-annotations && npm run test:mcp-oauth && npm run test:mcp-oauth-flow && npm run test:plan-gate && npm run test:ai-component-inventory && npm run test:pulse && npm run test:semantic-layer && npm run test:data-pipeline && npm run test:optimize-context && npm run test:principle-extractor && npm run test:analytics-window && npm run test:funnel-analytics && npm run test:experiment-tracker && npm run test:build-metadata && npm run test:context-engine && npm run test:hf-papers && npm run test:marketing-experiment && npm run test:seo-gsd && npm run test:verify-run && npm run test:export-dpo-pairs && npm run test:export-hf-dataset && npm run test:license && npm run test:bot-detector && npm run test:audit-pr-bot-contamination && npm run test:stripe-bootstrap-saas-catalog && npm run test:postinstall && npm run test:funnel-invariants && npm run test:cli-telemetry && npm run test:pro-parity && npm run test:model-tier-router && npm run test:computer-use-firewall && npm run test:skill-exporter && npm run test:statusline && npm run test:statusline-cache-aggregate && npm run test:public-repo-hygiene && npm run test:no-internal-orchestration-leaks && npm run test:evolution && npm run test:org-dashboard && npm run test:multi-hop-recall && npm run test:synthetic-dpo && npm run test:thumbgate-skill && npm run test:learn-hub && npm run test:feedback-fallback && npm run test:metaclaw && npm run test:server-lock && npm run test:control-tower && npm run test:pii-scanner && npm run test:data-governance && npm run test:lesson-inference && npm run test:semantic-dedup && npm run test:fs-utils && npm run test:cli-schema && npm run test:explore && npm run test:lesson-reranker && npm run test:lesson-retrieval && npm run test:lesson-semantic-retrieval && npm run test:cross-encoder && npm run test:reflector-agent && npm run test:feedback-session && npm run test:feedback-history-distiller && npm run test:hallucination-detector && npm run test:history-distiller && npm run test:predictive-insights && npm run test:predictive-credible-range && npm run test:prove-predictive-insights && npm run test:statusbar-cli && npm run test:generate-instagram-card && npm run test:instagram-thumbgate-post && npm run test:publish-instagram-thumbgate && npm run test:lesson-synthesis && npm run test:lesson-canonical && npm run test:background-governance && npm run test:memory-migration && npm run test:prompt-dlp && npm run test:ephemeral-store && npm run test:agent-security && npm run test:skill-progressive && npm run test:per-step-scoring && npm run test:weekly-auto-post && npm run test:social-post-hourly && npm run test:social-quality-gate && npm run test:a2ui-engine && npm run test:gate-satisfy && npm run test:money-watcher && npm run test:budget && npm run test:quick-start && npm run test:utm && npm run test:product-feedback && npm run test:feedback-root-consolidator && npm run test:engagement-audit && npm run test:install-growth-automation && npm run test:publish-thumbgate-launch && npm run test:reconcile-thumbgate-campaign && npm run test:reddit-publisher && npm run test:schedule-thumbgate-campaign && npm run test:social-reply-monitor && npm run test:social-dedupe-cleanup && npm run test:sync-launch-assets && npm run test:ai-search-visibility && npm run test:perplexity && npm run test:security-scanner && npm run test:llm-client && npm run test:managed-lesson-agent && npm run test:self-distill && npm run test:meta-agent && npm run test:harness-selector && npm run test:thumbgate-bench && npm run test:seo-guides && npm run test:enforcement-loop && npm run test:cli-agent-experience && npm run test:bot-detection && npm run test:checkout-archived-product-guard && npm run test:postgres-guard && npm run test:checkout-bot-guard && npm run test:checkout-pro-confirmation-gate && npm run test:pricing-page-telemetry && npm run test:session-health && npm run test:session-episodes && npm run test:spec-gate && npm run test:decision-trace && npm run test:dashboard-insights && npm run test:telemetry-tracked-link-slug && npm run test:prompt-eval && npm run test:gate-coherence && npm run test:gate-eval && npm run test:high-roi && npm run test:public-static-assets && npm run test:token-savings && npm run test:numbers-page && npm run test:workflow-gate-checkpoint && npm run test:lesson-export-import && npm run test:landing-page-claims && npm run test:competitive-positioning-marketing && npm run test:medium-weekly && npm run test:dashboard-deeplink-e2e && npm run test:public-package-parity && npm run test:token-savings-dashboard && npm run test:cursor-wiring && npm run test:pretooluse-injection && npm run test:recent-corrective-context && npm run test:durability-step && npm run test:mailer && npm run test:brand-assets && npm run test:enforcement-teeth && npm run test:bayes-optimal-gate && npm run test:swarm-coordinator && npm run test:session-report && npm run test:agent-reasoning-traces && npm run test:judge-reward && npm run test:llm-behavior-monitor && npm run test:prompting-os && npm run test:single-use-credential-gate && npm run test:structured-prompt-driven && npm run test:require-evidence-gate && npm run test:rule-validator && npm run test:bluesky-atproto && npm run test:social-reply-monitor-bluesky && npm run test:bluesky-delete-replies && npm run test:architect-kit-memory-bridge && npm run test:sonar-review-hotspots && npm run test:actionable-remediations && npm run test:gemini-embedding-policy && npm run test:agent-design-governance && npm run test:public-core-boundary && npm run test:hook-stop-verify-deploy && npm run test:hook-stop-anti-claim && npm run test:plausible-server-events && npm run test:activation-tracker && npm run test:activation-onboarding && npm run test:unified-revenue-rollup && npm run test:conversion-rate-stats && npm run test:external-customer-audit && npm run test:telemetry-export && npm run test:stripe-checkout-diagnostic && npm run test:stripe-business-identity-probe && npm run test:revenue-observability-doctor && npm run test:public-bundle-ratchet && npm run test:stripe-payment-link-update && npm run test:ci-cd-hygiene-audit && npm run test:verify-marketing-pages-deployed && npm run test:install-email-capture && npm run test:install-shim && npm run test:hook-runtime-subcommands && npm run test:implementation-notes && npm run test:daily-block-cap && npm run test:free-to-paid-conversion-units && npm run test:metrics-real-endpoint && npm run test:cli-trial-and-help && npm run test:cost-cli && npm run test:silent-failure-cluster && npm run test:proof:truth && node --test tests/adaptive-reliability.test.js && npm run test:mcp-oauth-reviewer && npm run test:dfcx-gate && npm run test:dfcx-gate-server && npm run test:vertex-scorer && npm run test:dashboard-chat && npm run test:gitar-integration && npm run test:secret-redaction && npm run test:discoverable-skills && npm run test:discoverable-skill-skills && npm run test:sync-telemetry && npm run test:leak-scanner && npm run test:team-sync && npm run test:eval-rag && npm run test:async-eval-observability && npm run test:letta-adapter && npm run test:tool-contract-validator && npm run test:check-update && npm run test:hermes-gate",
381
382
  "test:hook-stop-verify-deploy": "node --test tests/hook-stop-verify-deploy.test.js",
382
383
  "test:hook-stop-anti-claim": "node --test tests/hook-stop-anti-claim.test.js",
383
384
  "test:plausible-server-events": "node --test tests/plausible-server-events.test.js tests/plausible-poller.test.js tests/plausible-domain-config.test.js",
@@ -453,6 +454,7 @@
453
454
  "test:memory-scope-readiness": "node --test tests/memory-scope-readiness.test.js",
454
455
  "test:belief-update": "node --test tests/belief-update.test.js",
455
456
  "test:hosted-config": "node --test tests/hosted-config.test.js",
457
+ "test:policy-engine-adapter": "node --test tests/policy-engine-adapter.test.js",
456
458
  "test:operational-summary": "node --test tests/operational-summary.test.js",
457
459
  "test:operational-dashboard": "node --test tests/operational-dashboard.test.js",
458
460
  "test:operator-artifacts": "node --test tests/operator-artifacts.test.js tests/revenue-pack-utils.test.js",
@@ -476,7 +478,6 @@
476
478
  "test:hf-papers": "node --test tests/hf-papers.test.js",
477
479
  "test:marketing-experiment": "node --test tests/marketing-experiment.test.js",
478
480
  "test:seo-gsd": "node --test tests/seo-gsd.test.js",
479
- "test:hermes-gate": "node --test tests/hermes-gate.test.js",
480
481
  "test:verify-run": "node --test tests/verify-run.test.js",
481
482
  "test:export-dpo-pairs": "node --test tests/export-dpo-pairs.test.js",
482
483
  "test:secret-redaction": "node --test tests/secret-redaction.test.js",
@@ -503,7 +504,7 @@
503
504
  "test:operational-integrity": "node --test tests/operational-integrity.test.js tests/sync-branch-protection.test.js",
504
505
  "test:workflow": "node --test tests/parallel-workflow.test.js tests/workflow-contract.test.js tests/positioning-contract.test.js tests/docs-claim-hygiene.test.js tests/thumbgate-scope.test.js tests/workflow-runs.test.js tests/workflow-sprint-intake.test.js tests/revenue-pack-utils.test.js tests/sales-pipeline.test.js tests/github-outreach.test.js tests/enterprise-story.test.js tests/guide-conversion-path.test.js tests/buyer-intent-revenue-assist.test.js",
505
506
  "test:sales-pipeline": "node --test tests/sales-pipeline.test.js",
506
- "test:billing": "node --test tests/billing.test.js tests/stripe-sync-product-images.test.js",
507
+ "test:billing": "node --test tests/billing.test.js tests/stripe-sync-product-images.test.js tests/payment-rails.test.js",
507
508
  "test:cli": "node --test tests/analytics-report.test.js tests/agent-design-governance.test.js tests/codex-self-heal.test.js tests/creator-campaigns.test.js tests/cli.test.js tests/codex-bridge-script.test.js tests/dependabot-changeset.test.js tests/dispatch-brief.test.js tests/feedback-normalize.test.js tests/install-mcp.test.js tests/install-scope-docs.test.js tests/pr-manager.test.js tests/pro-local-dashboard.test.js tests/published-cli.test.js tests/revenue-status.test.js tests/stripe-live-status.test.js tests/creator-dev-and-prune.test.js",
508
509
  "test:evolution": "node --test tests/workspace-evolver.test.js",
509
510
  "test:watcher": "node --test tests/jsonl-watcher.test.js",
@@ -822,16 +823,9 @@
822
823
  "stripe": "^22.2.0"
823
824
  },
824
825
  "overrides": {
825
- "@google/genai": {
826
- "protobufjs": "7.6.4"
827
- },
828
- "onnxruntime-web": {
829
- "protobufjs": "7.6.4"
830
- },
831
826
  "express@4.22.1": {
832
827
  "path-to-regexp": "0.1.13"
833
- },
834
- "js-yaml": "4.2.0"
828
+ }
835
829
  },
836
830
  "mcpName": "io.github.IgorGanapolsky/thumbgate",
837
831
  "devDependencies": {
package/public/blog.html CHANGED
@@ -34,6 +34,12 @@
34
34
  "url": "https://thumbgate.ai/blog",
35
35
  "publisher": { "@type": "Organization", "name": "ThumbGate" },
36
36
  "blogPost": [
37
+ {
38
+ "@type": "BlogPosting",
39
+ "headline": "Databricks validates runtime AI governance. The next layer is pre-action enforcement.",
40
+ "datePublished": "2026-06-20",
41
+ "keywords": "Databricks Unity AI Gateway, runtime AI governance, MCP governance, pre-action enforcement, ThumbGate"
42
+ },
37
43
  {
38
44
  "@type": "BlogPosting",
39
45
  "headline": "Your AI agent is a supply chain attack surface. Here's how to gate it.",
@@ -172,6 +178,30 @@
172
178
  </header>
173
179
 
174
180
  <div class="container">
181
+ <article class="post">
182
+ <div class="post-date">June 20, 2026</div>
183
+ <h2>Databricks validates runtime AI governance. The next layer is pre-action enforcement.</h2>
184
+
185
+ <p>
186
+ Databricks Unity AI Gateway is a strong market signal: enterprise AI
187
+ governance is moving from static policy into runtime interactions
188
+ across models, agents, MCP services, tools, guardrails, observability,
189
+ and cost controls.
190
+ </p>
191
+ <p>
192
+ That is exactly where ThumbGate should live in the buyer conversation:
193
+ not as a Databricks replacement, but as the local pre-action gate that
194
+ stops the developer agent before it calls shell, browser, file, API,
195
+ MCP, or deploy tools.
196
+ </p>
197
+ <p>
198
+ Dashboards and budgets warn you. Gates stop the action.
199
+ </p>
200
+ <p>
201
+ <a href="/learn/databricks-unity-ai-gateway-runtime-governance" class="cta">Read the runtime governance breakdown</a>
202
+ </p>
203
+ </article>
204
+
175
205
  <article class="post">
176
206
  <div class="post-date">April 10, 2026</div>
177
207
  <h2>Your AI agent is a supply chain attack surface. Here's how to gate it.</h2>