Skip to content

Commit 309b4a7

Browse files
howieleungscbedd
andauthored
Sample updates (#43767)
* Samples update * Resolved comments * Resolved comments * rename files * resolved comment * Remove TODO comment regarding 'input' parameter in response creation * update * resolved build * fix install * Resolve misconfigured `dpkg` (#43777) * image has a new issue from update. some player is leaving apt-get unconfigured, so we need to add a dpkg configure before apt-get installing anything * Remove aiofiles dependency and update installation instructions in sample agent code --------- Co-authored-by: Scott Beddall <[email protected]>
1 parent dbbac66 commit 309b4a7

24 files changed

+467
-423
lines changed

sdk/ai/azure-ai-projects/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ print(f"Created conversation with initial user message (id: {conversation.id})")
152152
response = openai_client.responses.create(
153153
conversation=conversation.id,
154154
extra_body={"agent": {"name": agent.name, "type": "agent_reference"}},
155-
input="", # TODO: Remove 'input' once service is fixed
155+
input="",
156156
)
157157
print(f"Response output: {response.output_text}")
158158

@@ -165,7 +165,7 @@ print(f"Added a second user message to the conversation")
165165
response = openai_client.responses.create(
166166
conversation=conversation.id,
167167
extra_body={"agent": {"name": agent.name, "type": "agent_reference"}},
168-
input="", # TODO: Remove 'input' once service is fixed
168+
input="",
169169
)
170170
print(f"Response output: {response.output_text}")
171171

sdk/ai/azure-ai-projects/samples/agents/sample_agent_basic.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@
6161
response = openai_client.responses.create(
6262
conversation=conversation.id,
6363
extra_body={"agent": {"name": agent.name, "type": "agent_reference"}},
64-
input="", # TODO: Remove 'input' once service is fixed
64+
input="",
6565
)
6666
print(f"Response output: {response.output_text}")
6767

@@ -74,7 +74,7 @@
7474
response = openai_client.responses.create(
7575
conversation=conversation.id,
7676
extra_body={"agent": {"name": agent.name, "type": "agent_reference"}},
77-
input="", # TODO: Remove 'input' once service is fixed
77+
input="",
7878
)
7979
print(f"Response output: {response.output_text}")
8080

sdk/ai/azure-ai-projects/samples/agents/sample_agent_basic_async.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
1818
Before running the sample:
1919
20-
pip install "azure-ai-projects>=2.0.0b1" azure-identity aiohttp load_dotenv
20+
pip install "azure-ai-projects>=2.0.0b1" azure-identity aiohttp python-dotenv
2121
2222
Set these environment variables with your own values:
2323
1) AZURE_AI_PROJECT_ENDPOINT - The Azure AI Project endpoint, as found in the Overview
@@ -65,7 +65,7 @@ async def main() -> None:
6565
response = await openai_client.responses.create(
6666
conversation=conversation.id,
6767
extra_body={"agent": {"name": agent.name, "type": "agent_reference"}},
68-
input="", # TODO: Remove 'input' once service is fixed
68+
input="",
6969
)
7070
print(f"Response output: {response.output_text}")
7171

@@ -78,7 +78,7 @@ async def main() -> None:
7878
response = await openai_client.responses.create(
7979
conversation=conversation.id,
8080
extra_body={"agent": {"name": agent.name, "type": "agent_reference"}},
81-
input="", # TODO: Remove 'input' once service is fixed
81+
input="",
8282
)
8383
print(f"Response output: {response.output_text}")
8484

sdk/ai/azure-ai-projects/samples/agents/sample_agent_crud.py

Lines changed: 0 additions & 87 deletions
This file was deleted.

sdk/ai/azure-ai-projects/samples/agents/sample_agent_crud_async.py

Lines changed: 0 additions & 98 deletions
This file was deleted.

sdk/ai/azure-ai-projects/samples/agents/sample_agent_file_search_in_stream_async.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
1616
Before running the sample:
1717
18-
pip install "azure-ai-projects>=2.0.0b1" azure-identity aiohttp load_dotenv
18+
pip install "azure-ai-projects>=2.0.0b1" azure-identity aiohttp python-dotenv
1919
2020
Set these environment variables with your own values:
2121
1) AZURE_AI_PROJECT_ENDPOINT - The Azure AI Project endpoint, as found in the Overview

sdk/ai/azure-ai-projects/samples/agents/sample_agent_responses_code_interpreter.py

Lines changed: 0 additions & 47 deletions
This file was deleted.

sdk/ai/azure-ai-projects/samples/agents/sample_agent_retrieve_basic.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
1919
Before running the sample:
2020
21-
pip install "azure-ai-projects>=2.0.0b1" azure-identity load_dotenv
21+
pip install "azure-ai-projects>=2.0.0b1" azure-identity python-dotenv
2222
2323
Set these environment variables with your own values:
2424
1) AZURE_AI_PROJECT_ENDPOINT - The Azure AI Project endpoint, as found in the Overview
@@ -62,6 +62,6 @@
6262
print(f"Added a user message to the conversation")
6363

6464
response = openai_client.responses.create(
65-
conversation=conversation.id, extra_body={"agent": {"name": agent.name, "type": "agent_reference"}}
65+
conversation=conversation.id, extra_body={"agent": {"name": agent.name, "type": "agent_reference"}}, input=""
6666
)
6767
print(f"Response output: {response.output_text}")

0 commit comments

Comments
 (0)