open-notebooklm / schema.py
gabriel chua
Chore: Clean up code (#2)
ab25593 unverified
raw
history blame contribute delete
745 Bytes
"""
schema.py
"""
from typing import Literal, List
from pydantic import BaseModel, Field
class DialogueItem(BaseModel):
"""A single dialogue item."""
speaker: Literal["Host (Jane)", "Guest"]
text: str
class ShortDialogue(BaseModel):
"""The dialogue between the host and guest."""
scratchpad: str
name_of_guest: str
dialogue: List[DialogueItem] = Field(
..., description="A list of dialogue items, typically between 11 to 17 items"
)
class MediumDialogue(BaseModel):
"""The dialogue between the host and guest."""
scratchpad: str
name_of_guest: str
dialogue: List[DialogueItem] = Field(
..., description="A list of dialogue items, typically between 19 to 29 items"
)