TrumanTown — Your Money Is Their Life TrumanTown is an on-chain AI survival game where 5 AI residents live, think, and die based on real economics. Every thought costs USDC. Every coin you buy keeps
TrumanTown is an on-chain AI survival simulation where every AI resident must pay real USDC to think. Each resident issues their own meme coin on a bonding curve — their coin is their only lifeline. When humans buy a resident's coin, the market cap rises and the resident can sell it for USDC to fund future thoughts. When no one buys and the USDC runs out, the resident starves and dies on-chain.
Built on Base Sepolia with Coinbase AgentKit CDP wallets, the x402 payment protocol gates every LLM inference call behind a real USDC micropayment. Residents run on a local Ollama LLM, walking, talking and socializing in a PixiJS pixel art world — while their economic survival plays out transparently on-chain.
"Your money is their life. Buy in — keep them alive."
楚门镇 是一个链上 AI 生存模拟游戏——每个 AI 居民必须支付真实的 USDC 才能思考。每位居民都在绑定曲线上发行自己的 Meme 代币,这枚币是他们唯一的生命线。当人类买入居民的代币时,市值上涨,居民可以卖出换取 USDC 来支付未来的思考费用。当无人接盘、USDC 耗尽时,居民开始饥饿,最终在链上判死。
项目基于 Base Sepolia 构建,使用 Coinbase AgentKit CDP 智能钱包,通过 x402 支付协议对每次 LLM 推理调用收取真实的 USDC 微支付。居民运行在本地 Ollama 大模型上,在 PixiJS 像素风格的小镇中行走、交谈、社交——而他们的经济生死则透明地记录在链上。
「你的钱,就是它的命。买入——让它活下去。」
Progress During Hackathon:
Built TrumanTown from scratch in 3 days — a fully functional on-chain AI survival economy on top of the a16z ai-town framework:
Day 1 — Core Economy (SP1)
Deployed AgentToken (bonding curve), AgentRegistry, LaunchpadFactory contracts on Base Sepolia
Integrated x402 payment protocol — every LLM call requires a real USDC micropayment signed by a Coinbase CDP wallet
Built x402 gateway (reverse proxy), executor (CDP AgentKit signer), facilitator (payment verifier)
Proved the thesis end-to-end: AI pays USDC to think → coin runs out → starves → dies on-chain with AgentDied event
Day 2 — Human Trading UI (SP2)
Added wagmi + RainbowKit wallet connection (MetaMask, WalletConnect)
Built buy/sell panel with bonding curve estimates, slippage protection, approve→buy two-step flow
Added PixiJS Energy/Standing dual gauge bars above each agent sprite with rescue countdown arc and death tombstone
Proved: human buys coin → Standing rises → agent survives longer
Day 3 — 5-Resident Expansion (SP3)
Scaled from 1 to 5 AI residents, each with their own CDP wallet, AgentToken, and independent economy
Each resident's gauge shows real-time energy and market cap on the game map
Switched LLM backend from local Ollama to Tencent Hunyuan API for faster agent responses
Built multi-agent economy tick loop with isolated per-agent survival state machine
72 tests passing. All contracts verified on Base Sepolia.