From d6ac3c09ea47ccae8298cfc2dded62d135e56e47 Mon Sep 17 00:00:00 2001 From: Haiping Chen Date: Mon, 27 May 2024 21:06:05 -0500 Subject: [PATCH] Fix current agent id for routing rule. --- src/Infrastructure/BotSharp.Core/Routing/RoutingContext.cs | 1 + 1 file changed, 1 insertion(+) diff --git a/src/Infrastructure/BotSharp.Core/Routing/RoutingContext.cs b/src/Infrastructure/BotSharp.Core/Routing/RoutingContext.cs index 6b126a37..31caa932 100644 --- a/src/Infrastructure/BotSharp.Core/Routing/RoutingContext.cs +++ b/src/Infrastructure/BotSharp.Core/Routing/RoutingContext.cs @@ -118,6 +118,7 @@ public class RoutingContext : IRoutingContext var message = new RoleDialogModel(AgentRole.User, $"Try to route to agent {agent.Name}") { + CurrentAgentId = currentAgentId, FunctionName = "route_to_agent", FunctionArgs = JsonSerializer.Serialize(new FunctionCallFromLlm {