We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ac69a92 commit 22b96e4Copy full SHA for 22b96e4
examples/observers/openai_example.py
@@ -1,18 +1,14 @@
1
-import os
2
-
3
from openai import OpenAI
4
5
from observers import wrap_openai
6
7
8
-openai_client = OpenAI(
9
- base_url="https://api-inference.huggingface.co/v1/", api_key=os.getenv("HF_TOKEN")
10
-)
+openai_client = OpenAI()
11
12
client = wrap_openai(openai_client)
13
14
response = client.chat.completions.create(
15
- model="Qwen/Qwen2.5-72B-Instruct",
+ model="gpt-4o",
16
messages=[{"role": "user", "content": "Tell me a joke."}],
17
)
18
print(response)
0 commit comments