feat: complete T-533 incremental generation
This commit is contained in:
+10
-1
@@ -1225,4 +1225,13 @@
|
||||
|
||||
- 文档:`docs/06-tasks.md`、`docs/api.md`、`docs/routes.md`、`docs/cmhub-integration-design.md`、`docs/current-state.md` 已记录当前 `/api/v1/balance` 返回结构 `{user, points_balance, account:{username, display_name}}`。
|
||||
- 代码:`SettingsTab` 账号显示名提取优先读取 `account.display_name`,再兜底 `account.username`、`user`、name/account_name/email/id 等字段;邮箱仍脱敏展示。
|
||||
- 测试:补充 GUI worker 与设置页成功提示单测,确认当前结构显示 `主账号` 而不是 `cmhub_user`;未改 cmhub HTTP 协议、配置 schema、AI 生成或 Shopee/CDP 流程。
|
||||
- 测试:补充 GUI worker 与设置页成功提示单测,确认当前结构显示 `主账号` 而不是 `cmhub_user`;未改 cmhub HTTP 协议、配置 schema、AI 生成或 Shopee/CDP 流程。
|
||||
|
||||
## 【2026-07-06】T-533 完成 · ②增量生成按缺失组件补齐
|
||||
|
||||
- 状态:DONE
|
||||
- 代码:`app/ai.py` 新增 `generation_needs()` / `generation_component_totals()`,`is_generatable_task()` 改为按当前封面开关判断标题/封面缺口;`generate_batch()` 对已有 `new_title` 的任务跳过生文,只在缺 `new_cover_path` 且开启封面时补封面,避免覆盖 T-509 手动标题和重复扣标题点。
|
||||
- GUI:②开始生成、待生成筛选、`GenerateWorker` 和底部进度改用组件口径;本轮日志会显示已有标题跳过生文,标题/图片进度分别按 `title_total` / `cover_total` 统计;无缺口时提示先完成①采集或勾选封面补封面。
|
||||
- 边界:未改 cmhub HTTP 协议、配置 schema、DB schema、Excel、Shopee/CDP 流程;全组件齐备任务不纳入本轮生成。
|
||||
- 测试:新增/调整 AI 与 GUI 单测覆盖只补封面、混合标题/封面缺口、封面关闭时标题态任务不纳入、全组件齐备不重复生成、②入口可启动补封面。
|
||||
- 验证:`python -m py_compile app\ai.py app\gui\workers.py app\gui\tabs\generate.py tests\test_ai.py tests\test_gui.py` 通过;`python -m unittest discover -s tests -p test_ai.py` 通过(23 tests);相关 GUI 用例通过;`python -m compileall app main.py` 通过;`python -m unittest discover -s tests` 通过(207 tests);`git diff --check` 通过,仅有本机 LF/CRLF 提示。
|
||||
|
||||
Reference in New Issue
Block a user