File size: 714 Bytes
a1c5622
 
3ba9c0c
a1c5622
 
 
bc1cf4e
7286745
bc1cf4e
 
7286745
bc1cf4e
a1c5622
cef4233
 
 
d0a1b70
6b8f69a
 
 
 
 
bfbf1a7
1c2515f
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
import { Chat, Message } from '@prisma/client';
import { type Message as MessageAI } from 'ai';

export type ChatWithMessages = Chat & { messages: Message[] };

export type MessageUserInput = Pick<Message, 'prompt' | 'mediaUrl'>;
export type MessageAssistantResponse = {
  result?: PrismaJson.FinalResultBody;
  response: string;
  responseBody: PrismaJson.AgentResponseBodies;
  streamDuration: number;
};

export type MessageUI = Pick<MessageAI, 'role' | 'content' | 'id'> & {
  media?: string[];
};

export interface SignedPayload {
  id: string;
  publicUrl: string;
  signedUrl: string;
  fields: Record<string, string>;
}

export interface MessageFilterParams {
  date: string;
  includeExamples: boolean;
}