← back
Give Your Agent a Computer — Nico Albanese, Vercel
Takeaway
Production agents need their own sandboxed computer — Vercel Sandbox + AI Gateway makes that an OIDC-authenticated primitive.
Summary
- Vercel demo wiring up an agent with the Vercel AI Gateway for model access plus Vercel Sandbox (vsel) for sandboxed code execution — using OIDC tokens for auth.
- Live walkthrough: clone repo → vercel link → pull env vars → agent gets a real computer (filesystem + shell) to operate.
- Demonstrates the pattern of giving an agent its own ephemeral compute environment so it can run code, not just call tools.
- Targets developers building production agent apps on Vercel's edge platform.
agentsvercelsandbox
Original description
The key insight from Vercel's internal agent work: giving an agent a file system didn't just add storage, it changed how the agent behaved. It started following through on long tasks, staying on track, and building on its own prior work. That's what this workshop builds toward. @nicoalbanese10 walks through AI SDK v6 from scratch: a tool loop agent, provider-executed web search, end-to-end type safety, and Vercel's new persistent named sandboxes. The agent gets a bash tool, a memories.md file it reads and writes, and instructions that make it generate Python scripts for repeatable tasks and store them for later. By the end, it's an agent that accumulates tools and context across sessions without any manual memory management. Speaker info: - https://x.com/nicoalbanese10 - https://www.linkedin.com/in/nicoalbanese/ - https://github.com/nicoalbanese Timestamps: 0:00 Setup and project initialization 7:31 Installing dependencies 9:02 Introduction to AI SDK v6 and tool loop agents 11:05 Defining the agent in agent.ts 13:40 Building the route handler for the chat API 15:26 Creating the frontend UI with useChat 16:53 Modifying agent instructions 18:40 Adding web search tool (provider-executed tools) 23:55 Adding UI components for tool usage 27:43 The importance of persistent sandboxes (file systems for agents) 33:45 Managing context and message history across steps 45:11 Initializing persistent sandboxes 47:20 Defining custom call options and context 51:10 Creating the bash execution tool 55:05 Integrating the bash tool into the agent 57:15 Adding persistent memory (memories.md) 1:03:44 Making agents learn by generating Python scripts 1:05:58 Reviewing the full agent system and sub-agents