study-buddy / app /schemas /project.py
GitHub Actions
deploy d092bea3608b7a29952f16357fda39b7a29e399b
2e818da
Raw
History Blame Contribute Delete
608 Bytes
from pydantic import BaseModel, Field
from app.schemas.session import Intention
class ProjectFile(BaseModel):
filename: str
file_id: str # full sha256 hex of the file bytes
class Project(BaseModel):
project_id: str
name: str
created_at: float
updated_at: float
files: list[ProjectFile] = Field(default_factory=list)
intention: Intention = Intention.LEARN
title: str = ""
class ProjectDetail(Project):
document_id: str = ""
class ProjectUpdateRequest(BaseModel):
name: str | None = None
intention: Intention | None = None
title: str | None = None