Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
git clone --depth 1 https://github.com/brendadeeznuts1111/betting-brain-v3Wrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/rules/brendadeeznuts1111/betting-brain-v3/bun-runtime)<a href="https://agentmods.dev/rules/brendadeeznuts1111/betting-brain-v3/bun-runtime"><img src="https://agentmods.dev/badge/rules/brendadeeznuts1111/betting-brain-v3/bun-runtime/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/rules/brendadeeznuts1111/betting-brain-v3/bun-runtime"><img src="https://agentmods.dev/badge/rules/brendadeeznuts1111/betting-brain-v3/bun-runtime.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.01622 | $0.01622 |
| Opus 5 | $0.00811 | $0.00811 |
| Sonnet 5 | $0.00324 | $0.00324 |
| Haiku 4.5 | $0.00162 | $0.00162 |
Grade A, and why
bun-runtime scanned grade A with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 9d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Runs shell commandslowCapability
Expected in a hook, worth knowing in a rule or an instructions file.
ast-grep --pattern 'import { spawn } from "child_process"' src/ How it starts
The opening of the file, as written. The whole thing — 241 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Bun Runtime Rules
🔍 Code Searchability Patterns
Find Bun Runtime Issues with ast-grep
# Find incorrect process spawning (should use processManager)
ast-grep --pattern 'Bun.spawn($$$)' src/
ast-grep --pattern 'import { spawn } from "bun"' src/
ast-grep --pattern 'import { spawn } from "child_process"' src/
sg -p 'Bun.spawn' src/
sg -p 'from "child_process"' src/
# Find Node.js fs usage (should use Bun file APIs)
ast-grep --pattern 'import fs from "fs"' src/
ast-grep --pattern 'import { readFile } from "fs/promises"' src/
sg -p 'from "fs"' src/
sg -p 'from "fs/promises"' src/
# Find incorrect test imports (should use bun:test)
ast-grep --pattern 'import { describe, test, expect } from "vitest"' tests/
ast-grep --pattern 'import { describe, test, expect } from "@jest/globals"' tests/
sg -p 'from "vitest"' tests/
sg -p 'from "@jest/globals"' tests/
# Find npm/yarn usage (should use bun)
ast-grep --pattern 'npm install' scripts/
ast-grep --pattern 'yarn install' scripts/
sg -p 'npm install' scripts/
sg -p 'yarn install' scripts/
Bun Runtime Discovery Commands
# Find all Bun-specific patterns
sg search 'Bun.' src/
sg search 'bun:' src/
sg search 'processManager' src/
# Find Node.js anti-patterns
sg search 'from "fs"' src/
sg search 'from "child_process"' src/
sg search 'npm ' scripts/
sg search 'yarn ' scripts/
# Find Bun native APIs
sg search 'Bun.file' src/
sg search 'Bun.write' src/
sg search 'Bun.password' src/
Process Spawning (CRITICAL)
Always Use Process Manager
// ❌ WRONG - Creates zombie processes
import { spawn } from 'bun';
const proc = Bun.spawn(['command']);
// ❌ WRONG - Old Node.js pattern
import { spawn } from 'child_process';
// ✅ CORRECT - Tracked and cleaned up
import processManager from './tests/utils/process-cleanup';
const proc = processManager.spawn(['command'], options);
See Process Management Rules for details.
File Operations
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 9d ago First seen · 241 lines · 1,622 tokens per session scan A 31633f571231
bun-runtime is a cursor rule published in the GitHub repository brendadeeznuts1111/betting-brain-v3 (8 stars, last pushed 11mo ago), licensed MIT. It adds 1,622 tokens to every session, about $0.0081 per session on Opus 5. A static security scan graded it A with 1 finding (runs shell commands). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other cursor rules, from other repositories
typescript-imports
Golden rule: import each symbol from the module that defines it. A package index.ts may barrel only its own ./ modules — never another package.
code-style
A set of coding rules for TypeScript and Vue files, including file extensions, imports, naming, comments, and syntax that Node cannot automatically transform.
typescript-config
Shared TSConfig presets - inheritance, the strict flags that change how you write code, deliberate omissions, editing rules, in-app #/ imports.
type-inference
Derive TypeScript types from Zod schemas - no hand-written interfaces for wire shapes.
naming
Naming - kebab-case files, front PascalCase components, DTO Schema suffix.
code-style.toolchain
🔒 LOCKED — managed by clade Source: rules/core/code-style.toolchain.md Edit at: $CLADEHOME Local edits will be reverted by the next sync. -->.