Skip to main content
The Vercel AI SDK is a powerful Typescript library designed to help developers build AI-powered applications. Using Neosantara AI and the Vercel AI SDK, you can easily integrate AI into your TypeScript, React, or Next.js project. In this tutorial, we’ll look into how easy it is to use Neosantara AI’s models and the Vercel AI SDK.

QuickStart: 15 lines of code

  1. Install both the Vercel AI SDK and OpenAI’s Vercel package.
  1. Instantiate the Neosantara client and call the generateText function with nusantara-base to generate some text.
TypeScript

Output

Streaming with the Vercel AI SDK

To stream from Neosantara AI models using the Vercel AI SDK, simply use streamText as seen below.
TypeScript

Output


Last modified on November 11, 2025