"""Pydantic schemas for serve routes.

This module contains all request/response models used by the serve routes.
Organized by functional area for better maintainability.
"""
from __future__ import annotations

from .agent import (
    AgentRequest,
    AgentResponse,
    BatchAgentRequest,
    BatchAgentResponse,
    ContentPartPayload,
    ResumeRequest,
    StreamUIRequest,
    TaskRunLayout,
    TaskRunPayload,
    TaskRunRecord,
    TaskRunSection,
    ToolCallResponse,
    UIStreamRequest,
    UsageResponse,
)
from .chat import (
    ChatMessage,
    ChatSession,
    ChatSessionsResponse,
    CreateChatSessionRequest,
    TaskRunActionResponse,
    UpdateChatSessionRequest,
)
from .feedback import (
    FeedbackRequest,
    FeedbackResponse,
    OutcomeRequest,
    OutcomeResponse,
)
from .info import (
    AgentInfo,
    ToolInfo,
    ToolStatus,
    GraphDefinitionResponse,
    NodeUpdateRequest,
    CacheStatsResponse,
    SpendRecordResponse,
    BillingStatsResponse,
    IngestRequest,
    IngestResponse,
    ErrorResponse,
)
from .learning import (
    DatasetBuildRequest,
    DatasetBuildResponse,
    EvaluationChampionChallengerRequest,
    EvaluationChampionChallengerResponse,
    EvaluationContinuousIncidentActionRequest,
    EvaluationContinuousIncidentResponse,
    EvaluationContinuousIncidentSnapshotResponse,
    EvaluationContinuousIncidentsResponse,
    EvaluationContinuousJobCreateRequest,
    EvaluationContinuousJobResponse,
    EvaluationContinuousJobRunResponse,
    EvaluationContinuousJobsResponse,
    EvaluationContinuousTrendDeltaResponse,
    EvaluationJudgeDisagreementsRequest,
    EvaluationJudgeDisagreementsResponse,
    EvaluationRegressionDatasetResponse,
    EvaluationScorecardResponse,
    ImprovementPolicyResponse,
    ImprovementReflectionLessonsResponse,
    ImprovementRewardScoresResponse,
    ImprovementTrainingExportResponse,
    PromptCreateRequest,
    PromptExperimentCreateRequest,
    PromptExperimentResponse,
    PromptInfoResponse,
    PromptOptimizeRequest,
    PromptOptimizationResponse,
    PromptPromoteRequest,
    PromptRecommendationRequest,
    PromptRecommendationResponse,
    PromptRollbackRequest,
    PromptVersionCreateRequest,
)
from .retrieval import (
    RetrievalForceReindexRequest,
    RetrievalForceReindexResponse,
    RetrievalOpsSummaryResponse,
    RetrievalProfilesResponse,
    RetrievalReindexRequestResponse,
    RetrievalReindexRequestsResponse,
    RetrievalReindexTriggersResponse,
    RetrievalSourceDocumentsResponse,
    RetrievalSourceScoresResponse,
    RetrievalTriggerActionRequest,
    RetrievalTriggerActionResponse,
)
from .tool_workflow import (
    ToolWorkflowApprovalHotspotsResponse,
    ToolWorkflowBranchScoresResponse,
    ToolWorkflowFallbackRankingsResponse,
    ToolWorkflowLoopRecommendationsResponse,
    ToolWorkflowToolScoresResponse,
)
from .model_routing import (
    ModelRoutingBudgetStatusResponse,
    ModelRoutingCanariesResponse,
    ModelRoutingDecisionResponse,
    ModelRoutingLeaderboardResponse,
)

__all__ = [
    # Agent
    "AgentRequest",
    "AgentResponse",
    "BatchAgentRequest",
    "BatchAgentResponse",
    "ContentPartPayload",
    "ResumeRequest",
    "TaskRunLayout",
    "TaskRunPayload",
    "TaskRunRecord",
    "TaskRunSection",
    "ToolCallResponse",
    "UIStreamRequest",
    "UsageResponse",
    # Chat
    "ChatMessage",
    "ChatSession",
    "ChatSessionsResponse",
    "CreateChatSessionRequest",
    "TaskRunActionResponse",
    "UpdateChatSessionRequest",
    # Feedback
    "FeedbackRequest",
    "FeedbackResponse",
    "OutcomeRequest",
    "OutcomeResponse",
    # Info
    "AgentInfo",
    "ToolInfo",
    "ToolStatus",
    "GraphDefinitionResponse",
    "NodeUpdateRequest",
    "CacheStatsResponse",
    "SpendRecordResponse",
    "BillingStatsResponse",
    "IngestRequest",
    "IngestResponse",
    "ErrorResponse",
    # Learning - Dataset
    "DatasetBuildRequest",
    "DatasetBuildResponse",
    # Learning - Evaluation
    "EvaluationChampionChallengerRequest",
    "EvaluationChampionChallengerResponse",
    "EvaluationContinuousIncidentActionRequest",
    "EvaluationContinuousIncidentResponse",
    "EvaluationContinuousIncidentSnapshotResponse",
    "EvaluationContinuousIncidentsResponse",
    "EvaluationContinuousJobCreateRequest",
    "EvaluationContinuousJobResponse",
    "EvaluationContinuousJobRunResponse",
    "EvaluationContinuousJobsResponse",
    "EvaluationContinuousTrendDeltaResponse",
    "EvaluationJudgeDisagreementsRequest",
    "EvaluationJudgeDisagreementsResponse",
    "EvaluationRegressionDatasetResponse",
    "EvaluationScorecardResponse",
    # Learning - Improvement
    "ImprovementPolicyResponse",
    "ImprovementReflectionLessonsResponse",
    "ImprovementRewardScoresResponse",
    "ImprovementTrainingExportResponse",
    # Learning - Prompt
    "PromptCreateRequest",
    "PromptExperimentCreateRequest",
    "PromptExperimentResponse",
    "PromptInfoResponse",
    "PromptOptimizeRequest",
    "PromptOptimizationResponse",
    "PromptPromoteRequest",
    "PromptRecommendationRequest",
    "PromptRecommendationResponse",
    "PromptRollbackRequest",
    "PromptVersionCreateRequest",
    # Retrieval
    "RetrievalForceReindexRequest",
    "RetrievalForceReindexResponse",
    "RetrievalOpsSummaryResponse",
    "RetrievalProfilesResponse",
    "RetrievalReindexRequestResponse",
    "RetrievalReindexRequestsResponse",
    "RetrievalReindexTriggersResponse",
    "RetrievalSourceDocumentsResponse",
    "RetrievalSourceScoresResponse",
    "RetrievalTriggerActionRequest",
    "RetrievalTriggerActionResponse",
    # Tool Workflow
    "ToolWorkflowApprovalHotspotsResponse",
    "ToolWorkflowBranchScoresResponse",
    "ToolWorkflowFallbackRankingsResponse",
    "ToolWorkflowLoopRecommendationsResponse",
    "ToolWorkflowToolScoresResponse",
    # Model Routing
    "ModelRoutingBudgetStatusResponse",
    "ModelRoutingCanariesResponse",
    "ModelRoutingDecisionResponse",
    "ModelRoutingLeaderboardResponse",
]
