using BotSharp.Abstraction.Loggers.Models; using BotSharp.Abstraction.Repositories.Filters; namespace BotSharp.Abstraction.Conversations; public interface IConversationService { IConversationStateService States { get; } string ConversationId { get; } Task NewConversation(Conversation conversation); void SetConversationId(string conversationId, List states); Task GetConversation(string id); Task> GetConversations(ConversationFilter filter); Task UpdateConversationTitle(string id, string title); Task> GetLastConversations(); Task> GetIdleConversations(int batchSize, int messageLimit); Task DeleteConversations(IEnumerable ids); Task TruncateConversation(string conversationId, string messageId); Task> GetConversationContentLogs(string conversationId); Task> GetConversationStateLogs(string conversationId); /// /// Send message to LLM /// /// /// /// Received the response from AI Agent /// This delegate is useful when you want to report progress on UI /// This delegate is useful when you want to report progress on UI /// Task SendMessage(string agentId, RoleDialogModel lastDalog, Func onResponseReceived, Func onFunctionExecuting, Func onFunctionExecuted); List GetDialogHistory(int lastCount = 50); Task CleanHistory(string agentId); }