namespace AIStudio.Chat.Embedded;
///
/// Where the embedded chats of an assistant live, e.g., in a folder of the assistant below the data directory.
///
///
/// An embedded chat never lives in a workspace: it belongs to the assistant which shows it, and the assistant decides
/// how long it stays. The store finds a chat by its ID, ChatThread.ChatId.
///
public interface IEmbeddedChatStore
{
///
/// Loads a chat.
///
/// The ID of the chat.
/// The cancellation token.
/// The chat, or null when it has no stored thread yet.
/// This version cannot open the stored chat; the file stays as it is.
public Task LoadThreadAsync(Guid chatId, CancellationToken token = default);
///
/// Stores a chat, in place of what was stored of it before.
///
/// The chat, with its ID.
/// The cancellation token.
/// What the chat belonged to was deleted meanwhile; nothing is left to store.
public Task SaveThreadAsync(ChatThread thread, CancellationToken token = default);
}