Add workspaces & persistent chats (#23)

This commit is contained in:
Thorsten Sommer authored and GitHub committed 2024-07-13 10:37:57 +02:00
1 parent 29263660fc
commit 59d0321625
43 files changed
+1392 -66

No files matched your search

+4 -7
View File
@@ -3,25 +3,22 @@ namespace AIStudio.Chat;
/// <summary>
/// A block of content in a chat thread. Might be any type of content, e.g., text, image, voice, etc.
/// </summary>
/// <param name="time">Time when the content block was created.</param>
/// <param name="type">Type of the content block, e.g., text, image, voice, etc.</param>
/// <param name="content">The content of the block.</param>
public class ContentBlock(DateTimeOffset time, ContentType type, IContent content)
public class ContentBlock
{
/// <summary>
/// Time when the content block was created.
/// </summary>
public DateTimeOffset Time => time;
public DateTimeOffset Time { get; init; }
/// <summary>
/// Type of the content block, e.g., text, image, voice, etc.
/// </summary>
public ContentType ContentType => type;
public ContentType ContentType { get; init; } = ContentType.NONE;
/// <summary>
/// The content of the block.
/// </summary>
public IContent Content => content;
public IContent? Content { get; init; } = null;
/// <summary>
/// The role of the content block in the chat thread, e.g., user, AI, etc.