8000 chore: upgrade sample prompt for better consistency · cnblogs/dashscope-sdk@ce3c707 · GitHub
[go: up one dir, main page]

Skip to content

Commit ce3c707

Browse files
committed
chore: upgrade sample prompt for better consistency
1 parent 38c6598 commit ce3c707

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

sample/Cnblogs.DashScope.Sample/Cnblogs.DashScope.Sample.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
</ItemGroup>
2121

2222
<ItemGroup>
23-
<PackageReference Include="Microsoft.Extensions.AI" Version="9.0.1-preview.1.24570.5" />
23+
<PackageReference Include="Microsoft.Extensions.AI" Version="9.3.0-preview.1.25114.11" />
2424
</ItemGroup>
2525

2626
</Project>

sample/Cnblogs.DashScope.Sample/ToolCallWithExtensions.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,12 @@ public static class ToolCallWithExtensions
1010
public static async Task ToolCallWithExtensionAsync(this IDashScopeClient dashScopeClient)
1111
{
1212
[Description("Gets the weather")]
13-
string GetWeather() => Random.Shared.NextDouble() > 0.5 ? "It's sunny" : "It's raining";
13+
string GetWeather(string location) => Random.Shared.NextDouble() > 0.5 ? "It's sunny" : "It's raining";
1414

1515
var chatOptions = new ChatOptions { Tools = [AIFunctionFactory.Create(GetWeather)] };
1616

1717
var client = dashScopeClient.AsChatClient("qwen-max").AsBuilder().UseFunctionInvocation().Build();
18-
await foreach (var message in client.GetStreamingResponseAsync("What is weather today?", chatOptions))
18+
await foreach (var message in client.GetStreamingResponseAsync("What is weather of LA today?", chatOptions))
1919
{
2020
Console.WriteLine(JsonSerializer.Serialize(message));
2121
}

src/Cnblogs.DashScope.Core/Cnblogs.DashScope.Core.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
</PropertyGroup>
99

1010
<ItemGroup>
11-
<PackageReference Include="Microsoft.ML.Tokenizers" Version="1.0.1"/>
11+
<PackageReference Include="Microsoft.ML.Tokenizers" Version="1.0.2" />
1212
</ItemGroup>
1313

1414
<ItemGroup>

0 commit comments

Comments
 (0)
0