The local-first safety and cost layer for your autonomous agents Aisona Lab released Tucana Code v0.1.0, an MIT-licensed, zero-telemetry safety and budget gate that runs inside Claude Code's PreToolUse hook and wraps other CLI agents such as Codex, OpenCode and Gemini CLI. Tucana Code blocks destructive or exfiltration commands and allows safe read-only checks in under 1 ms at $0 cost and 100% offline, versus the 150–600 ms network roundtrip the project attributes to cloud AI gateways, and enforces real-time spend caps in USD plus 6 Latin American currencies (MXN, COP, ARS, BRL, CLP, PEN). The published CLI requires Node.js >=22.16.0, ships with zero runtime dependencies at 27.5 kB packed and roughly 56 ms cold start, and routes gray-zone commands to an ESCALATE prompt while logging overrides for human review in the separate tucana-lab repository. The local-first safety & cost layer for Claude Code, Codex, and OpenCode. Same agents. Hard spend caps. Sub-millisecond guardrails. Zero telemetry. Quickstart 30-second-quickstart • Why Tucana why-tucana-code • Safety Cockpit local-safety-cockpit-web-ui • Architecture system-0--system-1-architecture • Kill-Switch local-currency-kill-switch • Closed-Loop Calibration closed-loop-calibration-with-tucana-lab Coding agents run real shell commands on your machine and burn real API dollars while you look away. One hallucinated rm -rf , one leaked .env piped to curl , or one runaway reasoning loop on pay-as-you-go tokens can wipe your morning in seconds. Tucana Code puts a <1 ms, $0, 100% offline safety & budget gate directly inside Claude Code's PreToolUse hook and any CLI agent wrapper — without shipping your prompts, code, or traces to anyone's cloud. | Capability | Unprotected Agent | Cloud AI Gateways | Tucana Code v0.1.0 | |---|---|---|---| | Safe read-only checks git status , tests | Manual click or YOLO | +150–600 ms network roundtrip | <1 ms System 0, $0 , 100% offline | | Destructive / exfil protection | Hope the LLM behaves | Cloud policy / SaaS lock-in | Instant deterministic block + fail-safe | | API spend ceiling & Kill-Switch | Surprise invoice tomorrow | USD-only / proxy account | Real-time USD + 6 LATAM currencies | | Telemetry & cloud accounts | Vendor telemetry | Cloud dashboard + auth | Zero accounts · Zero network · MIT | | Learn from your overrides | Re-prompt forever | Vendor fine-tuning | Human review in tucana-lab https://github.com/aisona-lab/tucana-lab → <1 ms rules | Requires Node.js =22.16.0 . Zero runtime dependencies in the published CLI 27.5 kB packed, ~56 ms cold start . npm install -g tucana-code tucana-code --help Want to try a one-off command first? Run npx tucana-code --help . init --dry-run backs up ~/.claude/settings.json with a timestamp, registers PreToolUse idempotently using your resolved binary path never slow npx in the hot path , and runs in observation mode while writing real traces: tucana-code init --dry-run --currency MXN tucana-code doctor Test all three decision paths immediately: php tucana-code guard check -- git status System 0 - ALLOW <1 ms, $0 tucana-code guard check -- "rm -rf /" System 0 - BLOCK <1 ms, $0 tucana-code guard check -- "npm run deploy:staging" Gray zone - ESCALATE ask Ready to enforce live blocking? Re-run without --dry-run : tucana-code init --currency MXN Using Codex , OpenCode , Gemini CLI , or local scripts? Wrap any command in one line: tucana-code guard check --