PromptResponse.java

package fr.tiogars.chat.domains.prompt.models;

import io.swagger.v3.oas.annotations.media.Schema;

/**
 * Response model from the AI for a prompt.
 */
@Schema(description = "AI response to a prompt")
public record PromptResponse(
        @Schema(description = "The AI generated response")
        String response,

        @Schema(description = "Model used for the response")
        String model,

        @Schema(description = "Number of tokens in the response")
        int tokenCount,

        @Schema(description = "Processing time in milliseconds")
        long processingTimeMs,

        @Schema(description = "Finish reason (stop, length, error, etc.)")
        String finishReason
) {
}