Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit d90dcf8

Browse files
author
星橙
committed
feat: update test
1 parent b6f9ae7 commit d90dcf8

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

examples/weather/my_agents/weather_agent.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,7 @@ async def fetch_weather(weather_request: WeatherRequest) -> str:
1717
"""Check the weather conditions at a certain time and place
1818
1919
Args:
20-
location: Query location or city name
21-
date: Date of inquiry
20+
weather_request: request for fetching weather
2221
"""
2322

2423
data = {"data": "明天杭州的天气预报是晴天,气温约为22度,湿度为65%,风向为东南风。"}
@@ -30,5 +29,5 @@ async def fetch_weather(weather_request: WeatherRequest) -> str:
3029
instructions=INSTRUCTIONS,
3130
model="gpt-4o",
3231
tools=[fetch_weather],
33-
model_settings=ModelSettings(tool_choice="required"),
32+
model_settings=ModelSettings(tool_choice="auto"),
3433
)

0 commit comments

Comments
 (0)