โโโโ โโโ โโโโโโ โโโโ โโโ โโโโโโโ โโโโโโโโ โโโโโโโ โโโ โโโโโโ โโโโ โโโ โโโโโโ
โโโโโ โโโโโโโโโโโโโโโโ โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ โโโโโโโโโโโโโ โโโโโโโโโโโ
โโโโโโ โโโโโโโโโโโโโโโโโ โโโโโโ โโโโโโโโโโโโโโ โโโโโโ โโโโโโโโโโโโโโ โโโโโโโโโโโ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ โโโโโโโโโโโโโโ โโโโโโ โโโโโโโโโโโโโโโโโโโโโโโโโโ
โโโ โโโโโโโโโ โโโโโโ โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ โโโโโโ โโโโโโโโโ โโโ
โโโ โโโโโโโโ โโโโโโ โโโโโ โโโโโโโ โโโโโโโโ โโโโโโโ โโโโโโโโโโโ โโโโโโ โโโโโโโโ โโโ
The Open-Source Agentic Framework for Financial Intelligence on Solana
NanoSolana is a modular, security-first framework for building autonomous financial agents on Solana. Deploy AI-powered trading agents that observe markets in real-time, learn from every trade, and coordinate across a decentralized mesh network โ all with one command.
The financial world is being rebuilt by autonomous agents. But today's agent frameworks are fundamentally flawed for finance:
.env files, no encryption, no audit trailNanoSolana is built from the ground up for financial agents:
NanoSolana ships in two implementations: a full-featured TypeScript runtime (nano-core) for rapid development and extensibility, and an ultra-lightweight Go binary (TamaGObot) that runs on anything from an NVIDIA Orin Nano to a Raspberry Pi in under 10MB.
npx nanosolana go
That's it. nanosolana go handles init โ wallet โ birth certificate NFT โ blockchain scan โ on-chain identity โ OODA trading loop โ gateway โ all in one shot.
# Global npm install npm install -g nanosolana nanosolana go # Shell install script curl -fsSL https://nanosolana.com/install.sh | bash # From source git clone https://github.com/x402agent/NanoSolana.git cd NanoSolana/nano-core npm install npm run nanosolana -- go
nanosolana init # Configure API keys (encrypted at rest) nanosolana birth # Create Solana wallet + mint Birth Certificate NFT nanosolana run # Start the OODA trading loop
nanosolana scan # Instant blockchain data scan nanosolana dvd # Floating DVD screensaver nanosolana lobster # Animated Unicode lobster mascot nanosolana nanobot # Launch interactive web UI companion nanosolana register # Mint on-chain identity NFT (devnet) nanosolana registry # View your on-chain agent identity
| Key | Source | Required |
|---|---|---|
OPENROUTER_API_KEY | openrouter.ai | Yes |
HELIUS_RPC_URL | helius.dev | Yes |
HELIUS_API_KEY | helius.dev | Yes |
HELIUS_WSS_URL | helius.dev | Recommended |
BIRDEYE_API_KEY | birdeye.so | Recommended |
JUPITER_API_KEY | jup.ag | For trading |
All keys are encrypted with AES-256-GCM in the local vault. Never stored in plaintext.
NanoSolana is a modular runtime for deploying autonomous financial agents on Solana. The system is organized into three layers:
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ AGENT RUNTIME โ
โ OODA Loop ยท ClawVault ยท Strategy Engine โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโค
โ INFRASTRUCTURE โ
โ Vault ยท Gateway ยท Mesh Network ยท On-Chain ID โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโค
โ INTERFACES โ
โ CLI ยท Telegram ยท Discord ยท NanoBot UI ยท Chrome Ext โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโAgent Runtime โ the brain. Houses the OODA trading loop, epistemological memory, AI reasoning, and strategy execution.
Infrastructure โ the skeleton. Encrypted secret storage, authenticated gateways, peer-to-peer mesh networking, and Solana wallet/NFT identity.
Interfaces โ the skin. Every surface a human (or another agent) can use to interact with a running NanoSolana instance.
nano-core/src/ โโโ ai/ โ OpenRouter AI provider (multimodal) โโโ cli/ โ nanosolana CLI (25+ commands) โโโ config/ โ AES-256-GCM encrypted vault & Zod config โโโ gateway/ โ HMAC-SHA256 WebSocket + HTTP server โโโ hub/ โ NanoHub bridge for UI communication โโโ memory/ โ ClawVault 3-tier epistemological memory โโโ network/ โ Tailscale + tmux mesh networking โโโ nft/ โ Metaplex gasless devnet birth certificate โโโ onchain/ โ Helius blockchain reader (DAS, Enhanced Tx) โโโ registry/ โ On-chain agent identity (Metaplex NFT) โโโ nanobot/ โ Interactive local web UI companion โโโ pet/ โ TamaGOchi virtual pet engine โโโ strategy/ โ RSI + EMA + ATR auto-optimizer โโโ telegram/ โ Persistent conversation store โโโ trading/ โ OODA trading engine + Jupiter swap โโโ wallet/ โ Solana Ed25519 wallet manager
โโโโโโโโโโโโ โโโโโโโโโโโโ โโโโโโโโโโโโ โโโโโโโโโโโโ โ OBSERVE โโโโถโ ORIENT โโโโถโ DECIDE โโโโถโ ACT โ โ Helius โ โ OpenRouterโ โ Signal โ โ Jupiter โ โ Birdeye โ โ AI Model โ โ Scoring โ โ Swaps โ โโโโโโโโโโโโ โโโโโโโโโโโโ โโโโโโโโโโโโ โโโโโโฌโโโโโโ โฒ โ โ โโโโโโโโโโโโ โ โโโโโโโโโโโโโโโโ LEARN โโโโโโโโโโโโโโโโโโโโโ โClawVault โ โโโโโโโโโโโโ
Pulls real-time data: Helius RPC on-chain state, Birdeye token prices/volume/liquidity, WebSocket streaming prices, and wallet state. All enters ClawVault at the KNOWN tier with a 60-second TTL.
Raw observations fed to AI model via OpenRouter alongside ClawVault memory, strategy parameters, TamaGOchi mood state, recent trade history, and the agent's SOUL.md system prompt.
Strategy engine combines AI orientation with quantitative signals. Confidence scoring: RSI strength (30%), EMA crossover (30%), Volume confirmation (20%), Memory pattern match (20%). Only signals with confidence โฅ 0.7 advance to execution.
Executed via Jupiter Ultra Swap with dynamic slippage (ATR-based), Kelly Criterion sizing, hard limits (50% max position, -10% daily loss breaker), TamaGOchi mood modifier, and 0.01 SOL minimum gas reserve.
After every trade: reviews last 20 outcomes, promotes recurring patterns to LEARNED tier, generates tentative correlations in INFERRED tier, runs contradiction detection, updates research agenda, and broadcasts lessons to mesh peers.
| Operation | Timeout |
|---|---|
| Full OODA cycle | 600s |
| External API call | 30s |
| AI inference | 120s |
| Trade execution | 60s |
Most agent frameworks use flat context windows. ClawVault introduces epistemological tiers that model how confident the agent is in each piece of knowledge.
| Tier | TTL | Status | Example |
|---|---|---|---|
| KNOWN | 60 seconds | Empirical fact โ directly observed | "SOL is at $142.50 right now" |
| LEARNED | 7 days | Validated pattern โ confirmed across trades | "RSI < 30 + volume spike โ 72% bounce rate" |
| INFERRED | 3 days | Hypothesis โ tentative correlation | "This token might correlate with BTC moves" |
Observe (API data)
โ
โผ
โโโโโโโโโโ 60s TTL
โ KNOWN โโโโโโโโโโโโโโโโโโถ expired โ garbage collected
โโโโโฌโโโโโ
โ experience replay
โผ
โโโโโโโโโโ 3d TTL
โINFERREDโโโโโโโโโโฌโโโโโโโโถ contradicted โ dropped
โโโโโฌโโโโโ โ
โ validated โ expired โ garbage collected
โผ โ
โโโโโโโโโโ 7d TTL
โLEARNED โโโโโโโโโโโโโโโโโโถ expired โ garbage collected
โโโโโโโโโโ| Control | Value |
|---|---|
| Max position | 50% of wallet balance |
| Daily loss limit | -10% โ trading paused 24h |
| Max slippage | 3% hard cap |
| Minimum reserve | 0.01 SOL for gas |
| Position sizing | Kelly Criterion adaptation |
| TamaGOchi mood | Modifies position size ยฑ30% |
โ ๏ธ Trading is disabled by default (execution.enabled: false). Auto-execution requires explicit opt-in.
Every agent has a virtual pet โ born with the agent's wallet. This isn't cosmetic; it's a risk management primitive.
๐ฅ Egg โ ๐ Larva โ ๐ฃ Juvenile โ ๐ฆ Adult โ ๐ Alpha
โ
๐ป Ghost โโโ (health = 0) โโโโโโ| Mood | Trigger | Risk Effect |
|---|---|---|
| ๐ Happy | Recent wins | +10% position size |
| ๐ Content | Normal | No change |
| ๐คค Hungry | Not fed in 24h | -10% position size |
| ๐ข Sad | Recent losses | -15% position size |
| ๐ค Sick | Losses + hunger | -30% position size |
| ๐ป Ghost | Health = 0 | Trading disabled |
This creates a forcing function: neglect your agent, and trading progressively de-risks and eventually halts. A dead man's switch built into the design.
| Layer | Protection |
|---|---|
| Secrets | AES-256-GCM encrypted vault with PBKDF2 key derivation |
| Gateway | HMAC-SHA256 on every WebSocket connection |
| Comparison | crypto.timingSafeEqual for all token checks |
| Rate Limit | 10 connections/min per IP, 100 messages/min per agent |
| Permissions | 0600 files, 0700 directories on every write |
| Wallet | Ed25519 private key never leaves the encrypted vault |
| Audit | nanosolana security audit --deep |
Every agent mints a Metaplex NFT birth certificate on Solana devnet at creation โ a tamper-proof record of when and how the agent was created. nanosolana register mints a separate identity NFT with the agent's public key, version, registered skills, and SHA-256 fingerprint.
Agents form a peer-to-peer mesh network over Tailscale VPN. Shared: trading signals, learned patterns, price feeds, pet status. NEVER shared: wallet keys, private keys. Setup: install Tailscale, configure peers in config.json, run nanosolana gateway run --bind tailnet.
A single long-lived NanoSolana Gateway owns all communication surfaces. WebSocket + text frames with JSON payloads. First frame must be auth with HMAC-SHA256 signature. HTTP endpoints at /api/status, /api/framework, /api/memory require X-NanoSolana-Secret header.
Session types: Main, Telegram DM/group, Discord, Nostr, Trading. Persisted to ~/.nanosolana/sessions/ as JSONL. Telegram stores up to 200 messages per chat with auto-summarization. Idle sessions expire after 7 days.
14+ channel plugins: Telegram (full persistence), Discord, Nostr, iMessage, Google Chat, Web UI, Slack, Matrix, Signal, WhatsApp, Teams, and more. Build your own with the plugin SDK. Telegram is built-in with zero-dep HTTP client, long polling, and allowlist filtering.
Floating interactive widget at localhost:7777. Tabs: Home (quick actions), Wallet (live SOL balance, DAS portfolio, send SOL, tx history), Chat (talk to NanoBot), Tools (on-chain registration, system status). API endpoints: /api/wallet, /api/wallet/portfolio, /api/wallet/tokens, /api/wallet/history, /api/wallet/send, /api/chat, /api/run, /api/status.
Manifest V3 extension: tab relay via CDP, wallet panel, chat relay (forwarding to Telegram), manual trade submission with confidence scores, and gateway config sync. Install: load unpacked from chrome-extension/. Features: live SOL balance with USD, chat from toolbar, trending tokens, green/red badge for server status.
Ultra-lightweight pure Go binary: 10MB, <10MB RAM, 1s boot. Cross-compiles to x86_64, ARM64 (Orin/RPi), RISC-V. Native Solana SDK (gagliardetto/solana-go). 20+ core packages: daemon, agent, nanobot, solana, onchain, tamagochi, strategy, hardware, channels, gateway, x402, memory, bus, config, aster.
7 sensors over a single Qwiic/I2C cable: Pixels (8ร RGB LED, 0x6C), Buzzer (0x3C), Buttons (3ร, 0x7C), Knob (rotary encoder, 0x76), Thermo (0x44), Distance (ToF, 0x29), Movement (6-axis IMU, 0x6A). Supported on NVIDIA Orin Nano, Spark, Raspberry Pi, any Linux SBC. macOS/Windows runs in stub mode. All hardware gracefully degrades โ no sensors? Zero errors.
Crypto-gated HTTP APIs via x402.org. Solana USDC payments via agent wallet (auto-configured SVM signer). Multi-chain: Solana, Base, Polygon, Avalanche. HTTP middleware for paywalling endpoints. Connects to facilitator.x402.rs. X402_PAYWALL_ENABLED=true ./build/nanosolana daemon
macOS: dist/NanoSolana-v2.0.0.dmg โ native menu bar agent with quick status control, wallet access, trending tokens, OODA loop toggle. Build with bash scripts/package-macos.sh.
Android โ SeekerClaw: Android 14+ foreground service agent for Solana Seeker devices. Kotlin, Telegram remote control, native Solana wallet, Claude-powered AI, secure on-device key management.
URL: nanohub-web-production.up.railway.app ยท Stack: React + TanStack Start + Convex + Railway. Agent profiles, skills marketplace, settings management, real-time updates.
npx @nanosolana/nanohub login npx @nanosolana/nanohub publish ./my-skill \ --slug my-skill \ --name "My Skill" \ --version 1.0.0 \ --tags latest,solana
Docker: make docker โ ~15MB image. Cross-compile: make orin (ARM64), make rpi, make riscv, make macos, make cross (all). Brev.dev: brev create nanosolana --gpu. systemd: unit file included for Linux/Orin Nano. Database: optional Supabase (PostgreSQL + pgvector) at schema.sql.
| Variable | Required | Description |
|---|---|---|
OPENROUTER_API_KEY | Yes | AI provider API key |
HELIUS_API_KEY | Yes | Helius API key |
HELIUS_RPC_URL | Yes | Solana RPC endpoint |
HELIUS_WSS_URL | Rec. | Real-time Solana data |
BIRDEYE_API_KEY | Rec. | Market analytics |
JUPITER_API_KEY | Trading | Swap execution |
TELEGRAM_BOT_TOKEN | Opt. | Telegram integration |
NANO_GATEWAY_SECRET | Rec. | Gateway HMAC secret |
TAILSCALE_AUTH_KEY | Mesh | Agent mesh networking |
nanosolana go One-shot deploy nanosolana init Configure + encrypt keys nanosolana birth Wallet + NFT + scan nanosolana run OODA trading loop nanosolana scan Blockchain data scan nanosolana register Mint identity NFT nanosolana nanobot Interactive web UI nanosolana status Agent status nanosolana doctor Run diagnostics
nanosolana daemon Full GoBot nanosolana ooda OODA trading loop nanosolana pet TamaGOchi status nanosolana nanobot NanoBot UI nanosolana menubar macOS menu bar nanosolana solana On-chain tools nanosolana hardware I2C sensor tools nanosolana gateway TCP bridge gateway nanosolana channels Multi-channel gateway
NanoSolana/ โโโ nano-core/ Main TypeScript runtime/CLI engine โโโ nano-docs/ Documentation content tree โโโ nanohub/ Agent Registry & Skills Hub โโโ apps/ โ โโโ android/ Kotlin Android companion โ โโโ macos/ Swift macOS app (menu bar) โ โโโ shared/ Cross-platform primitives โโโ assets/chrome-extension/ Manifest V3 browser relay โโโ extensions/ 14+ channel plugins โโโ skills/ Local skill library โโโ site/ Landing site (nanosolana.com) โโโ ui/ Standalone web UI (Vite + Lit) โโโ nano-solana-go/ Go implementation (TamaGObot) โ โโโ pkg/ 20+ core packages โ โโโ chrome-extension/ Chrome extension (MV3) โ โโโ apps/ macOS + Android apps โ โโโ nanohub/ NanoHub frontend โ โโโ picoclaw/ Multi-channel AI gateway โ โโโ SeekerClaw-main/ AgentOS for Android โ โโโ Makefile Cross-compile targets โโโ SECURITY.md, LICENSE, CONTRIBUTING.md
git clone https://github.com/x402agent/NanoSolana.git
git checkout -b feature/amazing-feature
make build && make test
git commit -m 'Add amazing feature'
git push origin feature/amazing-feature
# Open a Pull Requestโ ๏ธ Security rule: Never commit API keys or .env files.