Grok Imagine
Grok Imagine is xAI's video generation model. It creates video clips from text prompts and images with motion, generated audio, and lip-sync, available through Vercel AI Gateway.
import { experimental_generateVideo as generateVideo } from 'ai';
const result = await generateVideo({ model: 'xai/grok-imagine-video', prompt: 'A serene mountain lake at sunrise.'});Frequently Asked Questions
What generation modes does Grok Imagine support?
Three modes: text-to-video (creating clips from descriptions), image-to-video (animating static images), and video editing (modifying existing videos through style changes, object replacement, and scene alterations).
Does Grok Imagine generate audio?
Yes. Grok Imagine generates audio in the clip with lip-sync, so you often don't need separate voice recording or dubbing.
How fast does Grok Imagine generate video?
Generation is fast enough for iteration in most setups; exact time depends on length, resolution, and load. Expect short clips, not long renders.
What plans support video generation?
Pro and Enterprise plan subscribers and paid AI Gateway users.
How do I authenticate with Grok Imagine through Vercel AI Gateway?
Use your Vercel AI Gateway API key with
xai/grok-imagine-videoas the model identifier. You can integrate through the AI SDK's generateVideo function, the AI Gateway playground at https://ai-sdk.dev/playground/xai:grok-imagine-video, or the v0 Grok Creative Studio.Can I refine generated videos with follow-up prompts?
Yes. Grok Imagine understands follow-up instructions to tweak scenes, adjust styles, and modify content. Use iterative prompting to refine output.
Does Vercel AI Gateway support Zero Data Retention for Grok Imagine?
Zero Data Retention is not currently available for this model. ZDR on AI Gateway applies to direct gateway requests; BYOK flows aren't covered. See https://vercel.com/docs/ai-gateway/capabilities/zdr for details.