backend: implement agents and connect them with chats

This commit is contained in:
Shivering Ocelot committed 2025-05-12 12:55:50 -05:00
1 parent e57e5ba16a
commit 49df72f2a1
9 files changed
+313 -40

No files matched your search

+2 -3
View File
@@ -57,8 +57,7 @@ class Chat(Base):
ordering: Mapped[Optional[int]]
# For indexing purposes, some information is taken from the last chat message.
# Preview is the (possibly cropped) content,
# time is the timestamp of the last event.
# Preview is the (possibly cropped) content, time is the timestamp of the message.
last_message_preview: Mapped[Optional[str]]
last_message_time: Mapped[Optional[int]]
@@ -81,7 +80,7 @@ class Message(Base):
# Timestamp of this message
time: Mapped[int]
# Identifier of the sender: user / system / agent-$ID
# Identifier of the sender: user / system / $AGENT_ID
sender: Mapped[str]
# Predefined set of message types, interpreted as 'text' when empty.