Open
Description
There are a few problems with the vercelAiIntegration
on Next.js. We made some improvements already (and/or they are pending):
- feat(node): Automatically enable
vercelAiIntegration
whenai
module is detected #16565 - feat(node): Ensure
modulesIntegration
works in more environments #16566 - feat(node): Allow to force activate
vercelAiIntegration
#16551 - feat(nextjs): Ensure all packages we auto-instrument are externalized #16552
Once all of this landed, we've done everything we can do in the SDK itself. That leaves the problem that we cannot monkey-patch ai
on Next.js, for whatever reason. This PR may fix this: vercel/ai#6716 in the ai package, but this is still WIP and unclear when/how this lands.
For the time being, once all the linked PRs in the SDK are merged & released, stuff should work, if users manually enable telemetry in every call:
await generateText({
experimental_telemetry: { isEnabled: true },
// ...
});
We should probably inform users in the AI insights module that are using Next.js about this, somehow.
Metadata
Metadata
Assignees
Labels
No labels