Platform

AI

Amplitude AI
Analytics that never stops working
AI Agents
Sense, decide, and act faster than ever before
AI Visibility
See how your brand shows up in AI search
AI Feedback
Distill what your customers say they want
Amplitude MCP
Insights from the comfort of your favorite AI tool
AI Assistant
Support powered by product data

Insights

Product Analytics
Understand the full user journey
Marketing Analytics
Get the metrics you need with one line of code
Session Replay
Visualize sessions based on events in your product
Heatmaps
Visualize clicks, scrolls, and engagement

Action

Guides and Surveys
Guide your users and collect feedback
Feature Experimentation
Innovate with personalized product experiences
Web Experimentation
Drive conversion with A/B testing powered by data
Feature Management
Build fast, target easily, and learn as you ship
Activation
Unite data across teams

Data

Data Governance
Complete data you can trust
Integrations
Connect Amplitude to hundreds of partners
Security & Privacy
Keep your data secure and compliant
Solutions
Solutions that drive business results
Deliver customer value and drive business outcomes
Amplitude Solutions →

Industry

Financial Services
Personalize the banking experience
B2B
Maximize product adoption
Media
Identify impactful content
Healthcare
Simplify the digital healthcare experience
Ecommerce
Optimize for transactions

Use Case

Acquisition
Get users hooked from day one
Retention
Understand your customers like no one else
Monetization
Turn behavior into business

Team

Product
Fuel faster growth
Data
Make trusted data accessible
Engineering
Ship faster, learn more
Marketing
Build customers for life
Executive
Power decisions, shape the future

Size

Startups
Free analytics tools for startups
Enterprise
Advanced analytics for scaling businesses
Resources

Learn

Blog
Thought leadership from industry experts
Resource Library
Expertise to guide your growth
Compare
See how we stack up against the competition
Glossary
Learn about analytics, product, and technical terms
Explore Hub
Detailed guides on product and web analytics

Connect

Community
Connect with peers in product analytics
Events
Register for live or virtual events
Customers
Discover why customers love Amplitude
Partners
Accelerate business value through our ecosystem

Support & Services

Customer Help Center
All support resources in one place: policies, customer portal, and request forms
Developer Hub
Integrate and instrument Amplitude
Academy & Training
Become an Amplitude pro
Customer Success
Drive business success with expert guidance and support
Product Updates
See what's new from Amplitude

Tools

Benchmarks
Understand how your product compares
Prompt Library
Prompts for Agents to get started
Templates
Kickstart your analysis with custom dashboard templates
Tracking Guides
Learn how to track events and metrics with Amplitude
Maturity Model
Learn more about our digital experience maturity model
Pricing
LoginContact salesGet started

AI

Amplitude AIAI AgentsAI VisibilityAI FeedbackAmplitude MCPAI Assistant

Insights

Product AnalyticsMarketing AnalyticsSession ReplayHeatmaps

Action

Guides and SurveysFeature ExperimentationWeb ExperimentationFeature ManagementActivation

Data

Data GovernanceIntegrationsSecurity & Privacy
Amplitude Solutions →

Industry

Financial ServicesB2BMediaHealthcareEcommerce

Use Case

AcquisitionRetentionMonetization

Team

ProductDataEngineeringMarketingExecutive

Size

StartupsEnterprise

Learn

BlogResource LibraryCompareGlossaryExplore Hub

Connect

CommunityEventsCustomersPartners

Support & Services

Customer Help CenterDeveloper HubAcademy & TrainingCustomer SuccessProduct Updates

Tools

BenchmarksPrompt LibraryTemplatesTracking GuidesMaturity Model
LoginSign Up

Building CLI Agents: It’s What You Don’t Give Them That Counts

In the last month of developing Amplitude Wizard CLI, we cut more than we added. Here’s why.
Insights

May 27, 2026

6 min read

Kelson Warner

Kelson Warner

Engineering Manager, Amplitude

Building a good CLI agent

A version of this post originally appeared on Kelson's Twitter.

My team shipped @amplitude/wizard on April 30. One simple command, run from your terminal, and you get a fully instrumented Amplitude project: framework detection, SDK install, custom event tracking written into your code, ingestion verified before the agent says done.

Because the drive was for simplicity, my engineering team actually spent most of our time removing things from the Wizard CLI. Tools the agent shouldn’t have. Context that made it worse. A mega-prompt that felt comprehensive and performed terribly.

At the end of it, the Wizard we shipped is actually fourteen subagents pretending to be one tool. The architecture makes it feel like one tool instead of fourteen. We only got there by rigorously setting constraints.

Here are some of the things we thought about as we worked to make our CLI agent simpler in case you’re building one of your own.

npx @amplitude/wizard

A tracking plan as simple as an SDK install

Our launch post does a good job explaining the problem we were trying to solve with the Wizard CLI and what we built. But to summarize.

Getting started with analytics is hard. The problem isn’t the install; SDKs have been a one-line install for years. It’s everything after that, where you figure out which events and properties you actually need to track. We’ve watched thousands of teams get stuck here.

But if you take a step back, what’s hard about a tracking plan? The whole point of analytics is to answer questions about your product. The question of what to track is a question about your product. Your code is your product, written down. It describes exactly what’s worth tracking, in language more accurate than any docs page or onboarding wizard.

So we built something that reads your code.

npx @amplitude/wizard runs an agent in your terminal that walks your repo, proposes events that match how your product actually works, shows you the plan, and writes the calls inline once you approve. Not generic page_viewed. Actual events, named in your product’s vocabulary, in the files where they belong.

End-to-end, it does auth, framework detection, SDK install, tracking plan, Session Replay + Experiment + Guides and Surveys, API key, verification, and the MCP server. Nothing lands in your tracked code until you approve it, though. Every change is shown as a diff. Revert anytime.

Big things that didn’t make the cut

Letting the agent pick its own tools. It picked Bash for everything. Always. Including things that obviously needed a structured file edit. We narrowed each subagent’s tool set explicitly. Hallucinated git calls dropped to zero.

We started with one model doing it all. That didn’t work. The latest Sonnet models ended up being the right supervisor. Narrow subagents handle classification, file walks, and plan generation. Each one runs hot, dies fast, and returns a structured result. The supervisor never sees the subagent’s reasoning trace, just the validated output.

The Wizard installs an MCP server so users can ask their editor to do tasks with Amplitude, like “Add tracking to the new checkout flow,” or “What events fired on the sign-up page yesterday?” MCP is the only connector standard we tried that didn’t fall apart in testing. We’re going forward with it.

The detail that took weeks: Polling

Oh, the polling loop. This took four rewrites.

When the agent finishes writing track() calls, we don’t trust that the install worked. We hit the Amplitude ingestion API and wait until the first event lands. If it doesn’t, we surface what’s wrong instead of saying “Done” and leaving you to discover at 11 p.m. three days later that nothing was flowing.

The current version is uglier than we’d like. It works.

It’s the kind of thing nobody notices when it works and would be furious about if it didn’t. Most setup tools skip it. We didn’t.

Three things the Wizard taught us

Building good agents is mostly about deciding what NOT to give them. Tools, files, instructions, history. Less is the entire trick.

For instructions, context is a budget, not a buffer. Every token you put into a prompt is a token of attention you’re spending. We removed more instructions than we added in the last month of development.

Controlling context also means constraining scope. Parallelism is great, but subagents really need isolation to be effective. One job, one context, one thing to be good at. When something fails, the supervisor’s context is still clean. Blast radius matters more than throughput.

Finally, don’t give agents too many choices with how to do their job. A little flexibility is fine to reduce instruction, but if you’re too open-ended, they’ll flounder. Give guidance on tools.

Standing on spiky shoulders

Hat tip to PostHog. Their engineering blog showed that writing honestly about what you built, what broke, and what you’d do differently is a better growth channel than any landing page. We took notes. Their open-source CLI was an early inspiration for the Wizard, too. If you’re building agents, their work is worth reading alongside ours.

Where this is heading (headless-ing?)

Today’s Wizard is iteration 1. The obvious flows are great, but the hard taxonomy work isn’t done yet. We shipped because it’s already better than what was there, and real feedback beats waiting for more polish.

The Wizard is one command. What’s next depends on an API-first mindset across the whole product. The CLI is the surface. Everything underneath has to be reachable, scriptable, and agent-driveable.

That’s where my team is going.

Try the Amplitude Wizard CLI: npx @amplitude/wizard. Read more at amplitude.com/builders. File issues on GitHub. Use /feedback inside the wizard. Or email wizard@amplitude.com. That goes to the team, and we read everything. Tell us what could be better, and we’ll keep working to fix it.

About the author
Kelson Warner

Kelson Warner

Engineering Manager, Amplitude

More from Kelson

Kelson Warner is an Engineering Manager at Amplitude, where he heads up the Growth Engineering team. He focuses on making the product easier to get started with and faster to deliver value, helping users quickly connect with Amplitude’s insights. Outside of work, Kelson enjoys spending time with his family and his cats, and loves outdoor activities like camping, hiking, and exploring nature.

More from Kelson
Topics

AI

Amplitude AI

Engineering

Getting Started

Recommended Reading

article card image
Read 
Product
How We Built a Product That Tells Us What To Build Next: Inside Amplitude Wave

Jun 10, 2026

26 min read

article card image
Read 
Customers
Looking Beyond Campaign Metrics: 7 Marketing Success Stories

Jun 9, 2026

6 min read

article card image
Read 
Insights
AI Evals for Product Managers: A Beginner’s Guide to Getting Started

Jun 5, 2026

16 min read

article card image
Read 
Insights
The Builder Skills Library

Jun 5, 2026

7 min read

Platform
  • AI Agents
  • AI Visibility
  • AI Feedback
  • Amplitude MCP
  • AI Assistant
  • Product Analytics
  • Web Analytics
  • Feature Experimentation
  • Feature Management
  • Web Experimentation
  • Session Replay
  • Guides and Surveys
  • Activation
Compare us
  • Adobe
  • Google Analytics
  • Contentsquare
  • Fullstory
  • Heap
  • LaunchDarkly
  • Mixpanel
  • Optimizely
  • Pendo
  • PostHog
Resources
  • Resource Library
  • Blog
  • Agent Prompt Library
  • Product Updates
  • Amp Champs
  • Amplitude Academy
  • Events
  • Glossary
Partners & Support
  • Status
  • Contact Us
  • Customer Help Center
  • Community
  • Developer Docs
  • Partner Program
  • Partner Directory
  • Become an affiliate
Company
  • About Us
  • Careers
  • Press & News
  • Investor Relations
  • Diversity, Equity & Inclusion
View markdown
Terms of ServicePrivacy NoticeAcceptable Use PolicyLegal
EnglishJapanese (日本語)Korean (한국어)Español (LATAM)Español (Spain)Português (Brasil)Português (Portugal)FrançaisDeutsch
© 2026 Amplitude, Inc. All rights reserved. Amplitude is a registered trademark of Amplitude, Inc.
Blog
InsightsProductCompanyCustomers
Topics

101

AI

APJ

Acquisition

Adobe Analytics

Agents

Amplify

Amplitude AI

Amplitude Academy

Amplitude Activation

Amplitude Agent Analytics

Amplitude Analytics

Amplitude Audiences

Amplitude Community

Amplitude Feature Experimentation

Amplitude Full Platform

Amplitude Guides and Surveys

Amplitude Heatmaps

Amplitude Made Easy

Amplitude Session Replay

Amplitude Web Experimentation

Amplitude on Amplitude

Analytics

B2B SaaS

Behavioral Analytics

Benchmarks

Churn Analysis

Cohort Analysis

Collaboration

Consolidation

Conversion

Customer Experience

Customer Lifetime Value

Customer Support

DEI

Data

Data Governance

Data Management

Data Tables

Digital Experience Maturity

Digital Native

Digital Transformer

EMEA

Ecommerce

Employee Resource Group

Engagement

Engineering

Event Tracking

Experimentation

Feature Adoption

Financial Services

Funnel Analysis

Getting Started

Google Analytics

Growth

Healthcare

How I Amplitude

Implementation

Integration

LATAM

LLM

Life at Amplitude

MCP

Machine Learning

Marketing Analytics

Media and Entertainment

Metrics

Modern Data Series

Monetization

Next Gen Builders

North Star Metric

Partnerships

Personalization

Pioneer Awards

Privacy

Product 50

Product Analytics

Product Design

Product Management

Product Releases

Product Strategy

Product-Led Growth

Recap

Retention

Revenue

Startup

Tech Stack

The Ampys

Warehouse-native Amplitude