Shipping an On-Chain AI Agent on a One-Week Cadence (While Migrating Chains)
Building an AI agent in production is hard. Building one that touches real money, on real chains, with weekly releases driven by market momentum — and migrating the entire on-chain layer mid-flight — is a different kind of problem.
This is what that looked like, from the inside.
The product
An AI agent built around two integrated surfaces: X (Twitter) for narrative and momentum analysis, and on-chain actions for executing on those signals. The first release shipped as an agent that surfaced trends and chart-grade insights. It later grew into an integrated trading workflow. A coordinated token launch was timed with the public release, and premium features were gated to holders.
The operating tempo was roughly one production release per week, driven by community attention and the competitive pressure of the crypto-agent space. That cadence is the load-bearing variable in everything that follows.
Stack at a glance
- Backend. NestJS with modular domains (agent/chat, auth, wallet/trading, portfolio, notifications), MongoDB for state, scheduled jobs for polling and maintenance.
- Model layer. LLM with tool calling — X search, chart generation, token/wallet/portfolio lookups — so answers came from retrieved data rather than pure completion.
- On-chain. Solana Web3.js, Raydium (v2 SDK) for routing and swaps, SPL token handling, session-oriented wallets for trading flows.
- Frontend. Next.js with Solana wallet adapters. EVM tooling remained in the stack during the migration window for Base-aligned flows and gating checks.
- Identity. SIWE-style sessions, server-side entitlement gating for sensitive flows.
- Media. Server-side chart rendering for agent-delivered visuals, object storage for shareable artifacts.
Three engineering bets that mattered
1. Tool-calling, not free-form completion
Every agent answer was grounded in retrieved data — X searches, on-chain queries, real price feeds. The model never produced numbers it didn't see. In a domain where a hallucinated chart or a wrong balance moves money, this isn't an aesthetic choice. It's the difference between a product and a liability.
2. A compressed cross-chain migration
The product began EVM-aligned on Base. Mid-lifecycle, the team migrated the on-chain layer to Solana under deadline pressure. That's not a swap of dependencies. Wallet flows, transaction and confirmation patterns, DEX integration shapes, reliability characteristics, and test coverage all diverged materially from the EVM baseline. For a window, two integration surfaces ran in parallel; then aggressive deprecation and cleanup. The migration shipped in weeks, not quarters.
3. X data as a moving target
The X ingestion path moved between official API usage and alternate acquisition (scraping / unofficial clients) over the lifecycle, driven by changing access economics. Rate limits, freshness SLAs, and cost control became first-class engineering concerns. Caching, deduplication, backoff-with-jitter, and burst-aware fetching weren't nice-to-haves — they were prerequisites for the agent's signal quality.
Multi-surface correctness
Trading workflows meant the tool outputs, on-chain state, and UI had to stay aligned under partial-failure modes — block confirmations lagging, RPC errors, stale quotes, transient slippage. We made partial-failure handling explicit, with user-visible error states rather than silent retries that pretended everything was fine.
Wrong information at the wrong moment, in this product, is worse than no answer. That's an invariant you build the system around.
Launch
The initial public release was timed with the token launch for coordinated marketing. Deadlines were tight. Day-one traffic produced the predictable class of incidents: capacity limits, connection pool exhaustion, cold-start latency. The team mitigated quickly; the launch window stabilized within hours, and the post-launch baseline held.
What this looks like for your team
If your roadmap involves:
- An aggressive release cadence in a domain where momentum is the moat
- A migration coming between fundamental platform choices — one chain to another, one ML stack to another, one cloud to another
- AI features that touch real-world state (money, infrastructure, user data) where wrong answers cost more than no answers
— you need senior engineers who can hold the entire surface in their head: AI infrastructure, domain semantics (in this case on-chain), partial-failure UX, and the calendar. Specialists wired together by a project manager produce a project plan. They don't ship through a chain migration on a one-week cadence.
We did this as a small, embedded team. The architecture choices were negotiable. So were most of the deadlines. What wasn't negotiable was the agent telling the truth, under load.