diff --git a/packages/core/src/chat/chat.ts b/packages/core/src/chat/chat.ts index 405fc0d1..8d2db667 100644 --- a/packages/core/src/chat/chat.ts +++ b/packages/core/src/chat/chat.ts @@ -5,6 +5,8 @@ import { paginateQuery, type PaginatedData } from '@shumai/core/src/pagination' import type { ChatRequest, ChatSessionInfo, ChatMessage } from '@shumai/dtos' import { ulid } from 'ulid' +type User = Prisma.UserGetPayload> + export function mapEntryToMessage( entryRecord: Prisma.AgentSessionEntryGetPayload>, ): ChatMessage { @@ -77,9 +79,8 @@ export class ChatService { return parts.join('/') } - // eslint-disable-next-line @typescript-eslint/no-explicit-any async startOrContinueChat( - user: any, + user: User, req: ChatRequest, ): Promise<{ sessionId: string; taskId: string }> { const {