You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: public-endpoints/ai-sdk.mdx
+107-2Lines changed: 107 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -5,13 +5,13 @@ description: "Use the @runpod/ai-sdk-provider package to integrate Public Endpoi
5
5
tag: "NEW"
6
6
---
7
7
8
-
The `@runpod/ai-sdk-provider` package integrates Runpod Public Endpoints with the [Vercel AI SDK](https://ai-sdk.dev/docs/introduction). This gives you a streamlined, type-safe interface for text generation, streaming, and image generation in JavaScript and TypeScript projects.
8
+
The `@runpod/ai-sdk-provider` package integrates Runpod Public Endpoints with the [Vercel AI SDK](https://ai-sdk.dev/docs/introduction). This gives you a streamlined, type-safe interface for text generation, streaming, image generation, and video generation in JavaScript and TypeScript projects.
9
9
10
10
The Vercel AI SDK is a popular open-source library for building AI applications. By using the Runpod provider, you can access Runpod's Public Endpoints using the same patterns and APIs you'd use with other AI providers like OpenAI or Anthropic.
11
11
12
12
## Why use the Vercel AI SDK?
13
13
14
-
-**Unified interface**: Use the same `generateText`, `streamText`, and `generateImage` functions regardless of which AI provider you're using.
14
+
-**Unified interface**: Use the same `generateText`, `streamText`, `generateImage`, and `generateVideo` functions regardless of which AI provider you're using.
15
15
-**Type safety**: Full TypeScript support with typed responses and parameters.
16
16
-**Streaming built-in**: First-class support for streaming text responses.
17
17
-**Framework integrations**: Works seamlessly with Next.js, React, Svelte, and other frameworks.
|`maxPollAttempts`| Max polling attempts for async generation |
262
262
|`pollIntervalMillis`| Milliseconds between status polls |
263
263
264
+
## Video generation
265
+
266
+
Use `experimental_generateVideo` to generate videos from text prompts or images. The Runpod provider supports 15 video models, including Sora, Wan, Seedance, and Kling.
267
+
268
+
Video generation is asynchronous—the SDK submits a job, polls for completion, and returns the video URL when ready.
0 commit comments