- 015-017迁移:image_candidate 文案复审/AI视觉分/重生标记 - constants C7素人感约束(反电商摆拍对齐真实笔记)+C3叠字口子 - celery visibility_timeout=2h 防长任务被误判重投重复烧钱(task75教训) - image_scorer 评图分(只筛选+展示,真实信号才进飞轮权重) - storyboard/image_gen/pipeline_io 生图存量 - task_actions/tasks/task_service/flywheel 审核回路+飞轮存量 Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
34 lines
926 B
Python
34 lines
926 B
Python
"""015 image_candidates 表加 text_review 字段(标题文字校验闸门)
|
|
|
|
Revision ID: 015
|
|
Revises: 014
|
|
Create Date: 2026-06-16
|
|
|
|
gpt-image-2 渲染中文偶发错别字。生图后对 hook/特写图做 OCR 校验,错别字自动
|
|
重生(上限2次);仍不过则放行该图并写 text_review 标记,前端提示运营人工筛。
|
|
NULL=未校验或一次通过;有值=曾不过或重生过的记录(倩倩姐2026-06-16拍板)。
|
|
"""
|
|
from alembic import op
|
|
import sqlalchemy as sa
|
|
|
|
revision = "015"
|
|
down_revision = "014"
|
|
branch_labels = None
|
|
depends_on = None
|
|
|
|
|
|
def upgrade():
|
|
op.add_column(
|
|
"image_candidates",
|
|
sa.Column(
|
|
"text_review",
|
|
sa.String(512),
|
|
nullable=True,
|
|
comment="标题文字校验结果JSON(NULL=通过;有值=曾不过/重生,needs_text_review)",
|
|
),
|
|
)
|
|
|
|
|
|
def downgrade():
|
|
op.drop_column("image_candidates", "text_review")
|