Handles multiple tool calls, parallel execution, and result filtering in a single piece of code, reducing the data passed to the model.
- Pause and resume: Pauses when authentication or human approval is required, then resumes. Already-completed tool calls are not repeated.
- Execution limits: Supports time and memory limits. Tasks that need OS-level access or package installation use a separate Vercel Sandbox.
Code Mode
Let models orchestrate AI SDK tools with sandboxed JavaScript and TypeScript.
https://ai-sdk.dev/docs/ai-sdk-core/code-mode
Run SDK
The internal engine that actually executes the code generated in Code Mode is the Run SDK, built with QuickJS. Code runs inside it without direct access to the system or network, and can only call functions the developer has allowed.
Introducing Run SDK: secure eval for your agents
Execute untrusted JavaScript and TypeScript without giving it access to your application, and pause mid-run for human approval.
https://vercel.com/blog/introducing-run


Seonglae Cho