https://github.com/langfuse/langfuse-vercel-ai-nextjs-example
https://github.com/langfuse/langfuse-vercel-ai-nextjs-example
Last synced: about 1 year ago
JSON representation
- Host: GitHub
- URL: https://github.com/langfuse/langfuse-vercel-ai-nextjs-example
- Owner: langfuse
- Created: 2024-08-02T10:09:05.000Z (almost 2 years ago)
- Default Branch: main
- Last Pushed: 2025-03-04T10:24:39.000Z (over 1 year ago)
- Last Synced: 2025-03-29T12:15:17.757Z (over 1 year ago)
- Language: TypeScript
- Homepage: https://langfuse-vercel-ai-nextjs-example.vercel.app
- Size: 154 KB
- Stars: 4
- Watchers: 2
- Forks: 4
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# NextJs, Vercel AI SDK, and Langfuse Example
This example repo demostrates how to use Langfuse to instrument a NextJs app with the Vercel AI SDK. This repo is based on the [next-openai](https://github.com/vercel/ai/tree/main/examples/next-openai) example.
Relevant Files:
- `instrumentation.ts` - Register the `LangfuseExporter`
- `app/routes/api/*` - Enable `experimental_telemetry` in AI SDK routes
See the integration docs for more information and a step-by-step guide: https://langfuse.com/docs/integrations/vercel-ai-sdk