Refactor AI chat: streaming, tool calls, UI polish
All checks were successful
CI / check (pull_request) Successful in 3m25s
All checks were successful
CI / check (pull_request) Successful in 3m25s
This commit is contained in:
@@ -1,18 +1,41 @@
|
||||
import { Type } from 'class-transformer';
|
||||
import { IsInt, IsNotEmpty, IsOptional, IsString, Max, MaxLength, Min } from 'class-validator';
|
||||
import {
|
||||
ArrayMaxSize,
|
||||
IsArray,
|
||||
IsIn,
|
||||
IsInt,
|
||||
IsNotEmpty,
|
||||
IsOptional,
|
||||
IsString,
|
||||
IsUUID,
|
||||
Max,
|
||||
MaxLength,
|
||||
Min,
|
||||
} from 'class-validator';
|
||||
|
||||
export class CreateConversationDto {
|
||||
@IsOptional()
|
||||
@IsString()
|
||||
@MaxLength(100)
|
||||
title?: string;
|
||||
|
||||
@IsOptional()
|
||||
@IsString()
|
||||
@MaxLength(50)
|
||||
lockedSkillKey?: string | null;
|
||||
}
|
||||
|
||||
export class RenameConversationDto {
|
||||
export class UpdateConversationDto {
|
||||
@IsOptional()
|
||||
@IsString()
|
||||
@IsNotEmpty()
|
||||
@MaxLength(100)
|
||||
title: string;
|
||||
title?: string;
|
||||
|
||||
@IsOptional()
|
||||
@IsString()
|
||||
@MaxLength(50)
|
||||
lockedSkillKey?: string | null;
|
||||
}
|
||||
|
||||
export class SendMessageDto {
|
||||
@@ -20,6 +43,36 @@ export class SendMessageDto {
|
||||
@IsNotEmpty()
|
||||
@MaxLength(16000)
|
||||
message: string;
|
||||
|
||||
@IsOptional()
|
||||
@IsArray()
|
||||
@ArrayMaxSize(5)
|
||||
@IsInt({ each: true })
|
||||
@Min(1, { each: true })
|
||||
attachmentIds?: number[];
|
||||
|
||||
@IsOptional()
|
||||
@IsString()
|
||||
@MaxLength(50)
|
||||
skillKey?: string | null;
|
||||
|
||||
@IsUUID()
|
||||
clientRequestId: string;
|
||||
}
|
||||
|
||||
export class RegenerateMessageDto {
|
||||
@IsUUID()
|
||||
clientRequestId: string;
|
||||
}
|
||||
|
||||
export class MessageFeedbackDto {
|
||||
@IsIn(['like', 'dislike', null])
|
||||
feedback: 'like' | 'dislike' | null;
|
||||
|
||||
@IsOptional()
|
||||
@IsString()
|
||||
@MaxLength(500)
|
||||
reason?: string;
|
||||
}
|
||||
|
||||
export class MessagePageQueryDto {
|
||||
|
||||
Reference in New Issue
Block a user