ppt / presentation.py
sarim's picture
response type
3745704
raw
history blame
2.12 kB
from pydantic import BaseModel, Field
from dataclasses import dataclass, field
from typing import List, Dict,Optional
@dataclass
class Presentation(BaseModel):
title: str = Field(
description="The main title of the slide. Should be concise and descriptive, summarizing the core idea of the slide. Avoid lengthy titles and focus on clarity."
)
# subTitle: Optional[str] = Field(
# description="An optional subtitle for the slide, typically used on the first slide to provide context or additional information. It should complement the title and give more detail about the presentation topic."
# )
# author: Optional[str] = Field(
# description="The name of the author or presenter, typically included on the first slide. Useful for attributing the presentation to a specific individual or organization."
# )
text: str = Field(
description="The detailed description or narrative content of the slide. This should include key information, explanations, or supporting arguments. Keep it concise yet informative to avoid overwhelming the audience."
)
bulletPoints: Optional[List[str]] = Field(
description="A list of bullet points summarizing key information on the slide. Each bullet point should be detail, long, and highlight a specific aspect of the slide's topic. ideally, limit to 3-5 points."
)
imageSuggestion: Optional[str] = Field(
description="A prompt for generating an image to complement the slide content. Describe the desired visual in detail, including elements, style, and relevance to the topic. Ensure the prompt is actionable for AI tools."
)
@dataclass
class PPT(BaseModel):
per:list[Presentation] = Field(description="A list of `Presentation` objects, where each object represents a single slide in the PowerPoint presentation. Ensure that the list is ordered logically to maintain the flow of the presentation. Each `Presentation` object should provide the necessary details, including title, content, bullet points, and optional image suggestions, to create an engaging and informative slide deck.")