mirror of
https://github.com/microsoft/agent-framework.git
synced 2026-06-16 21:04:09 +08:00
Python: Small fixes in examples (#540)
* Fixed Ruff formatting * Added more info to chat response cancellation example * Improved example * Small fix
This commit is contained in:
committed by
GitHub
Unverified
parent
6a00c9d026
commit
f5043e4fc1
+3
@@ -1,9 +1,11 @@
|
||||
# Copyright (c) Microsoft. All rights reserved.
|
||||
|
||||
import asyncio
|
||||
|
||||
from agent_framework import HostedWebSearchTool
|
||||
from agent_framework.openai import OpenAIChatClient
|
||||
|
||||
|
||||
async def main() -> None:
|
||||
client = OpenAIChatClient(ai_model_id="gpt-4o-search-preview")
|
||||
|
||||
@@ -35,5 +37,6 @@ async def main() -> None:
|
||||
)
|
||||
print(f"Assistant: {response}")
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
asyncio.run(main())
|
||||
|
||||
Reference in New Issue
Block a user