View Javadoc
1   package fr.tiogars.chat.domains.prompt.models;
2   
3   import io.swagger.v3.oas.annotations.media.Schema;
4   
5   /**
6    * Response model from the AI for a prompt.
7    */
8   @Schema(description = "AI response to a prompt")
9   public record PromptResponse(
10          @Schema(description = "The AI generated response")
11          String response,
12  
13          @Schema(description = "Model used for the response")
14          String model,
15  
16          @Schema(description = "Number of tokens in the response")
17          int tokenCount,
18  
19          @Schema(description = "Processing time in milliseconds")
20          long processingTimeMs,
21  
22          @Schema(description = "Finish reason (stop, length, error, etc.)")
23          String finishReason
24  ) {
25  }