mirror of
https://github.com/kennethnym/freya
synced 2026-07-03 14:51:13 +01:00
feat: add agent response scheduler
This commit is contained in:
@@ -1,8 +1,3 @@
|
||||
export interface SendMessageResult {
|
||||
message: string
|
||||
conversationId: string
|
||||
}
|
||||
|
||||
export type AgentEvent =
|
||||
| { type: "conversation_started"; conversationId: string }
|
||||
| { type: "message_created"; text: string }
|
||||
@@ -11,8 +6,11 @@ export type AgentEvent =
|
||||
| { type: "message_finished" }
|
||||
| { type: "message_failed"; error: string }
|
||||
|
||||
export type UserEvent = { type: "typing" }
|
||||
|
||||
export interface AgentServerApi {
|
||||
sendMessage(message: string): Promise<SendMessageResult>
|
||||
sendMessage(message: string): Promise<boolean>
|
||||
notify(event: UserEvent): void
|
||||
ping(): "pong"
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user