fix typing

This commit is contained in:
Shroominic
2025-12-24 12:12:32 +01:00
parent 2c404c66d6
commit 41fd2e2dfc
2 changed files with 1 additions and 22 deletions
+1 -1
View File
@@ -7,7 +7,7 @@ client = OpenAI(
base_url=os.environ.get("API_URL", "https://api.routstr.com/v1"),
)
conversation = []
conversation = [] # type: ignore
# First turn
response1 = client.responses.create( # type: ignore
-21
View File
@@ -1,21 +0,0 @@
import os
from openai import OpenAI
client = OpenAI(
api_key=os.environ.get("TOKEN"),
base_url=os.environ.get("API_URL", "https://api.routstr.com/v1"),
)
stream = client.responses.create(
model="gpt-5-nano",
input="Write a short poem about rust.",
stream=True,
)
for event in stream:
# Note: Depending on the SDK version and response structure,
# you might access event.output_delta or similar fields
print(event, end="", flush=True)
print()