src/ai/dto/query.dto.ts
Properties |
| question |
Type : string
|
Decorators :
@ApiProperty({description: 'Natural-language question about the fleet (max 2000 chars).', example: 'How many trips delivered late this week?'})
|
|
Defined in src/ai/dto/query.dto.ts:15
|
import { ApiProperty } from '@nestjs/swagger';
import { IsString, IsNotEmpty, MaxLength } from 'class-validator';
export class QueryDto {
@ApiProperty({
description: 'Natural-language question about the fleet (max 2000 chars).',
example: 'How many trips delivered late this week?',
})
@IsString()
@IsNotEmpty()
@MaxLength(2000, {
message:
'Question must be 2000 characters or fewer. Long prompts are blocked to control cost.',
})
question!: string;
}