Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/.sync-sha
Original file line number Diff line number Diff line change
@@ -1 +1 @@
154cef9a84b8bdd6966acebaced70f9a5a0b3d46
c47f5c67c4e6e732996a4a0d200e2b6026c9cd15
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@
api_key = os.environ["AZURE_OPENAI_API_KEY"]
deployment = os.environ["MODEL_DEPLOYMENT_NAME"]

# <chat_completion>
client = AzureOpenAI(
azure_endpoint=endpoint,
api_key=api_key,
Expand All @@ -45,6 +46,7 @@
},
],
)
# </chat_completion>

print("--- Chat Completions Response ---")
print(f"Routed to model: {response.model}")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@
project_endpoint = os.environ["AZURE_AI_PROJECT_ENDPOINT"]
deployment = os.environ["MODEL_DEPLOYMENT_NAME"]

# <foundry_responses>
with (
DefaultAzureCredential() as credential,
AIProjectClient(endpoint=project_endpoint, credential=credential) as project_client,
Expand All @@ -42,6 +43,7 @@
model=deployment,
input="In one sentence, name the most popular tourist destination in Seattle.",
)
# </foundry_responses>

print("--- Foundry Responses SDK Output ---")
print(f"Routed to model: {response.model}")
Expand Down
Loading