BotSharp/src/Infrastructure/BotSharp.Abstraction/Routing/IRoutingHook.cs

31 lines
946 B
C#
Raw Normal View History

2024-02-28 16:21:14 +00:00
using BotSharp.Abstraction.Functions.Models;
namespace BotSharp.Abstraction.Routing;
public interface IRoutingHook
{
/// <summary>
/// Conversation is redirected to another agent
/// </summary>
/// <param name="toAgentId"></param>
/// <param name="message"></param>
/// <returns></returns>
Task OnConversationRedirected(string toAgentId, RoleDialogModel message);
/// <summary>
/// Routing instruction is received from Router
/// </summary>
/// <param name="instruct">routing instruction</param>
/// <param name="message">message</param>
/// <returns></returns>
Task OnConversationRouting(FunctionCallFromLlm instruct, RoleDialogModel message);
Task OnAgentEnqueued(string agentId, string preAgentId);
Task OnAgentDequeued(string agentId, string currentAgentId);
Task OnAgentReplaced(string fromAgentId, string toAgentId);
Task OnAgentQueueEmptied(string agentId);
}