from typing import List from pydantic.v1 import BaseModel, Field class Topic(BaseModel): name: str = Field(..., title="Topic") confidence: float = Field( ..., description="Confidence value between 0-1 of the correctness of the topic.", ) confidence_explanation: str = Field( ..., description="Explanation for the confidence score" ) class Questions(BaseModel): question: str = Field(..., title="Question") answer: str = Field(..., title="Answer") class CustomerDetail(BaseModel): detail: str = Field(..., title="Custom Detail", description="Detail provided by the customer on the call.") class TranscriptPeople(BaseModel): name: str = Field(..., title="Person Name") class Transcript(BaseModel): response: str = Field(..., title="Response", description="The answer to the question.") id: str = Field(..., title="Transcript ID") description: str = Field(..., title="Transcript Description") duration: int = Field(..., title="Duration of the transcript in seconds") number_of_questions: int = Field(..., title="Number of questions", description="Number of questions asked in the transcript") topics: List[Topic] = Field(..., title="Topics List", description="List of topics discussed in the transcript") questions: List[Questions] = Field(..., title="Questions List", description="List of questions asked and answers in the transcript") people: List[TranscriptPeople] = Field(..., title="People List", description="List of people in the transcript") customer_details: List[CustomerDetail] = Field(..., title="Customer Details", description="List of customer details in the transcript")