AI CLI (Vercel)

CLI tool from Vercel that provides terminal access to every AI model via Vercel AI Gateway - images, video, text. npm i -g ai-cli.

What It Does

Render images, video, audio, and text directly from the terminal. The README describes it as an agent-native CLI with stdin support and predictable artifact outputs, backed by the Vercel AI SDK and AI Gateway for unified model access. Announced by Guillermo Rauch (@rauchg). Source: X/@rauchg, 2026-05-14; Source: GitHub vercel-labs/ai-cli, checked 2026-07-03

npx ai-cli image 'a vercel ai sdk diagram'

The reviewed local artifact shows the image-generation path in the product's intended form: a terminal command generates an OpenAI image, saves it to disk, and renders the output inline in the terminal. The generated example is a dark Vercel AI SDK architecture diagram, so the bookmark is also evidence for terminal-native visual artifacts in agent workflows. Source: local image review, 2026-07-03

Version Snapshot

Current npm snapshot as of 2026-07-06: ai-cli@0.4.2, latest dist-tag 0.4.2, beta dist-tag 0.0.2-beta.0, last modified 2026-07-02. The npm metadata points to vercel-labs/ai-cli, and the repo HEAD checked at 2a72d32793e21839439e96adc8429453f17500f1. It describes the package as a small CLI for generating images, video, audio, and text with predictable artifact outputs. Requires rechecking before pinning because the package is still moving quickly. Source: npm registry packument and git ls-remote, 2026-07-06

Model Catalog and Voice

The new ai models bookmark turns AI CLI from "generate media from terminal" into a model-catalog inspection tool. The local artifact shows ai models --creator anthropic returning model metadata such as context window, pricing, provider, latency, throughput, and uptime; use ai models [model] or JSON output when an agent needs to choose a model based on current Gateway metadata instead of stale docs. Source: X/@rauchg, 2026-07-02

The paired audio rows extend the same agent-native surface: ai audio speak for speech generation and ai audio transcribe for transcription, both routed through AI Gateway. Keep them as CLI convenience tools until a project needs a durable audio pipeline; production voice agents still route through Vercel AI SDK / AI Gateway code paths with observability, spend controls, and browser-token boundaries. Source: X/@rauchg, 2026-06-30; Source: X/@rauchg, 2026-06-30

Vercel CLI Firewall Command

The new vercel firewall command brings firewall configuration to the terminal. Agents and developers can manage custom rules, IP blocks, system mitigations, Attack Mode, and more from CLI. Source: Vercel, 2026-05-19

AI Gateway Sorting

Sort providers by metric on AI Gateway:

Flag Metric Strategy
sort: 'cost' Cheapest first Budget optimization
sort: 'ttft' Lowest latency first User-facing, real-time
sort: 'tps' Highest throughput first Batch processing

Source: Vercel, 2026-05-19

Relevance

Terminal-first AI access complements the agent workflow - agents can invoke image generation, model inference, and multimodal tasks without leaving the shell. The firewall CLI and gateway sorting extend the pattern: agents can manage infrastructure and optimize model routing from the same shell. Source: compiled from X bookmark analysis + Vercel updates, 2026-05-19


Timeline