by BlockRunAI
Franklin — The AI agent with a wallet. The first AI agent that can actually spend USDC to get real work done. Pay per action, no subscriptions.
# Add to your Claude Code skills
git clone https://github.com/BlockRunAI/FranklinEvery AI coding tool today writes text. franklin spends money — your USDC, from your wallet, on your behalf, under a hard budget cap — to actually get work done. One agent. 55+ models. Every paid API routed through the x402 micropayment protocol. No subscriptions. No API keys. No account. The wallet is your identity.
Built by the BlockRun team. Apache‑2.0. TypeScript. Ships as one npm package.
# 1. Install
npm install -g @blockrun/franklin
# 2. Run (free — uses NVIDIA Nemotron & Qwen3 Coder out of the box)
franklin
# 3. (optional) Fund a wallet to unlock Claude, GPT, Gemini, Grok, + paid APIs
franklin setup base # or: franklin setup solana
franklin balance # show address + USDC balance
That's it. Zero signup, zero credit card, zero phone verification. Send $5 of USDC to the wallet and you've unlocked every frontier model and every paid tool in the BlockRun gateway.
███████╗██████╗ █████╗ ███╗ ██╗██╗ ██╗██╗ ██╗███╗ ██╗
██╔════╝██╔══██╗██╔══██╗████╗ ██║██║ ██╔╝██║ ██║████╗ ██║
█████╗ ██████╔╝███████║██╔██╗ ██║█████╔╝ ██║ ██║██╔██╗ ██║
██╔══╝ ██╔══██╗██╔══██║██║╚██╗██║██╔═██╗ ██║ ██║██║╚██╗██║
██║ ██║ ██║██║ ██║██║ ╚████║██║ ██╗███████╗██║██║ ╚████║
╚═╝ ╚═╝ ╚═╝╚═╝ ╚═╝╚═╝ ╚═══╝╚═╝ ╚═╝╚══════╝╚═╝╚═╝ ╚═══╝
Franklin · The AI agent with a wallet · v3.1.0
Model : anthropic/claude-sonnet-4.6
Wallet: 0x7a9…4e2 · 12.47 USDC
> refactor src/auth.ts to use the new jwt helper, then run the tests
✓ Read src/auth.ts $0.0024
✓ Read src/lib/jwt.ts $0.0011
✓ Edit src/auth.ts (-24 +31 lines) $0.0082
✓ Bash npm test $0.0000
› 142 passing · 0 failing · 2.4s
Done in 18s · 4 tool calls · 12.8k in / 2.1k out · $0.0117
No comments yet. Be the first to share your thoughts!
Every tool call is itemised. Every token is priced. The wallet is the source of truth — when it hits zero, Franklin stops. No overdraft, no surprise bill, no rate-limit wall at 3am.
No subscriptions. No "Pro" tier. You fund a wallet once and Franklin spends atomically per API call via HTTP 402. Cheap models cost fractions of a cent. Frontier models cost what they cost. When the wallet is empty, Franklin stops.
No email. No phone. No KYC. Your Base or Solana address is your account. Portable across machines — franklin setup imports an existing wallet in one command. Your sessions, your config, your money.
Claude Sonnet/Opus 4.6, GPT‑5.4, Gemini 2.5 Pro, Grok 4, DeepSeek V3, GLM‑5.1, Kimi, Minimax, plus NVIDIA's free tier (Nemotron, Qwen3 Coder). Switch mid‑session with /model. Automatic fallback if one provider is down.
| | Claude Code | Aider | Cursor | Franklin | | --------------------------------- | -------------- | ------------- | -------------- | --------------------- | | Writes and edits code | ✅ | ✅ | ✅ | ✅ | | Multi‑model support | ❌ Claude only | ✅ BYOK | ⚠️ limited | ✅ 55+ via 1 wallet | | Pricing model | Subscription | BYOK | Subscription | Pay per action | | Identity | Account | API keys | Account | Wallet | | Spend budget cap enforced on‑chain | ❌ | ❌ | ❌ | ✅ | | Pay any API (images, search…) | ❌ | ❌ | ❌ | ✅ via x402 | | Plugin SDK for custom workflows | ❌ | ⚠️ | ❌ | ✅ | | Persistent sessions + search | ⚠️ | ⚠️ | ⚠️ | ✅ | | Start free, no signup | ❌ | ⚠️ BYOK | ❌ | ✅ |
Franklin is the first agent in the Autonomous Economic Agent category — an agent that takes a goal, decides what to spend on, and executes within a hard budget cap enforced by the wallet.
🧠 55+ models via one wallet Anthropic, OpenAI, Google, xAI, DeepSeek, GLM, Kimi, Minimax, NVIDIA free tier. One URL, one wallet, automatic fallback.
💳 x402 micropayments HTTP 402 native. Every tool call is a tiny signed transaction against your USDC balance. No escrow, no refund API, no subscription.
🚦 Smart tier routing
Mark steps as free / cheap / premium — Franklin picks the best model per tier, per task. Configurable defaults in franklin config.
🔌 Plugin SDK Core is workflow‑agnostic. Ship a new vertical (marketing, trading, research) without touching the agent loop. See docs/plugin-sdk.md.
💾 Persistent sessions Every turn is streamed to disk with full metadata. Resume any session by ID. Survives crashes, reboots, context compaction.
🔍 Full‑text session search
franklin search "payment loop" — tokenised search across every past session. No SQLite, no indexing daemon, just fast.
📊 Cost insights
franklin insights — daily spend sparklines, per‑model breakdown, projections. Never wonder where the USDC went.
⚡ Anthropic prompt caching
Multi‑turn Sonnet/Opus sessions use ephemeral cache breakpoints (system_and_3 strategy). Large input savings on long conversations.
🛠 12 built‑in tools Read · Write · Edit · Bash · Glob · Grep · WebFetch · WebSearch · Task · ImageGen · AskUser · SubAgent.
🔗 MCP auto‑discovery
Drop‑in Model Context Protocol servers from ~/.blockrun/mcp.json. Ships with awareness of blockrun-mcp (markets, X, prediction markets) and unbrowse (any site → API).
🧭 Plan / Execute modes
/plan to design read‑only, /execute to commit. No accidental writes while exploring.
🪄 Slash ergonomics
/commit, /push, /pr, /review, /ultrathink, /compact, /model, /cost, /wallet, and 20+ more.
Franklin is plugin‑first. The core agent doesn't know what a "marketing campaign" or "trading signal" is — it just runs workflows. Adding a new vertical is a single TypeScript file.
import type { Plugin, Workflow } from '@blockrun/franklin/plugin-sdk';
const researchWorkflow: Workflow = {
id: 'research',
name: 'Competitor Research',
description: 'Find and summarise 10 competitors in a given space',
steps: [
{
name: 'search',
modelTier: 'none', // pure API call, no LLM
execute: async (ctx) => {
const results = await ctx.exa.search(ctx.input.topic, { limit: 10 });
return { output: `Found ${results.length}`, data: { results } };
},
},
{
name: 'summarise',
modelTier: 'cheap', // bulk work — use GLM or DeepSeek
execute: async (ctx) => {
const summaries = await ctx.llm.map(ctx.data.results, (r) =>
`Summarise in 3 bullets: ${r.text}`);
return { output: 'Summaries written', data: { summaries } };
},
},
{
name: 'synthesise',
modelTier: 'premium', // final output — use Claude Opus
execute: async (ctx) => {
const report = await ctx.llm.complete({
system: 'You are a strategy analyst.',
user: `Synthesise these into a 1‑page report: ${JSON.stringify(ctx.data