feat(audiobook): implement chapter management with CRUD operations and enhance project detail responses

This commit is contained in:
2026-03-10 16:42:32 +08:00
parent 01b6f4633e
commit 3c30afc476
8 changed files with 393 additions and 156 deletions

View File

@@ -34,9 +34,20 @@ class AudiobookCharacterResponse(BaseModel):
model_config = ConfigDict(from_attributes=True)
class AudiobookChapterResponse(BaseModel):
id: int
project_id: int
chapter_index: int
title: Optional[str] = None
status: str
error_message: Optional[str] = None
model_config = ConfigDict(from_attributes=True)
class AudiobookProjectDetail(AudiobookProjectResponse):
characters: List[AudiobookCharacterResponse] = []
chapter_count: int = 0
chapters: List[AudiobookChapterResponse] = []
class AudiobookGenerateRequest(BaseModel):