feat: add generation trace and partial-ready workflow status

This commit is contained in:
2026-04-18 21:53:55 +08:00
parent 96dfc677e2
commit e99a7fbe14
36 changed files with 2597 additions and 144 deletions

View File

@@ -66,7 +66,8 @@ async def test_story(db_session: AsyncSession, test_user: User) -> Story:
story_text="从前有一只小兔子。",
cover_prompt="A cute rabbit in a forest",
mode="generated",
generation_status="narrative_ready",
generation_status="partial_ready",
text_status="ready",
image_status="not_requested",
audio_status="not_requested",
)
@@ -102,6 +103,7 @@ async def storybook_story(db_session: AsyncSession, test_user: User) -> Story:
image_url="https://example.com/storybook-cover.png",
mode="storybook",
generation_status="degraded_completed",
text_status="ready",
image_status="failed",
audio_status="not_requested",
last_error="第 2 页插图生成失败",
@@ -123,6 +125,7 @@ async def degraded_story_with_text(db_session: AsyncSession, test_user: User) ->
cover_prompt="A rabbit under the moon",
mode="generated",
generation_status="degraded_completed",
text_status="ready",
image_status="failed",
audio_status="not_requested",
last_error="封面生成失败",