lunary
docs
Documentation
Getting Started
Integrations
JavaScript
Python
LangChain
API
Others
Features
Observability
Prompts
Threads
Evaluations
Radars
Users
Feedback
Tags
More
Security
Concepts
Self-hosting
Our SDKs include automatic integration with OpenAI's modules.
1
Learn how to setup the JS SDk
2
With our SDKs, tracking OpenAI calls is super simple.
import OpenAI from "openai"import { monitorOpenAI } from "lunary/openai" // Simply call monitor() on the OpenAIApi class to automatically track requestsconst openai = new OpenAI()const openai = monitorOpenAI(new OpenAI())
3
You can now tag requests and identify users.
const result = await openai.chat.completions.create({ model: "gpt-4o", temperature: 0.9, tags: ["chat", "support"], // Optional: tags user: "user_123", // Optional: user ID userProps: { name: "John Doe" }, // Optional: user properties messages: [ { role: "system", content: "You are an helpful assistant" }, { role: "user", content: "Hello friend" }, ],})
Compare
Product
Company
Ecosystem
© 2024 Lunary LLC. All rights reserved.