from typing import List, Dict, Any, Optional from pydantic import BaseModel class RAGDocument(BaseModel): text: str metadata: Dict[str, Any] = {} similarity: Optional[float] = None class RAGSearchResult(BaseModel): id: str text: str similarity: float metadata: Dict[str, Any] class ChatMessage(BaseModel): role: str content: str class TTSRequest(BaseModel): text: str language: str = 'vi' provider: str = 'auto'