- FastAPI backend with SQLModel, Alembic migrations, AgentScope agents - Next.js 15 frontend with React 19, Tailwind, Zustand, React Flow - Multi-provider AI system (DashScope, Kling, MiniMax, Volcengine, OpenAI, etc.) - All HTTP clients migrated from sync requests to async httpx - Admin-managed API keys via environment variables - SSRF vulnerability fixed in ensure_url()
37 lines
1.1 KiB
Python
37 lines
1.1 KiB
Python
"""add prompt fields to assets and storyboards
|
|
|
|
Revision ID: add_prompt_fields
|
|
Revises: add_task_mgmt_fields
|
|
Create Date: 2026-01-16
|
|
|
|
"""
|
|
from alembic import op
|
|
import sqlalchemy as sa
|
|
|
|
|
|
# revision identifiers, used by Alembic.
|
|
revision = 'add_prompt_fields'
|
|
down_revision = 'add_task_mgmt_fields'
|
|
branch_labels = None
|
|
depends_on = None
|
|
|
|
|
|
def upgrade() -> None:
|
|
# Add image_prompt to assets table
|
|
op.add_column('assets', sa.Column('image_prompt', sa.String(), nullable=True))
|
|
|
|
# Add prompt fields to storyboards table
|
|
op.add_column('storyboards', sa.Column('original_text', sa.String(), nullable=True))
|
|
op.add_column('storyboards', sa.Column('merge_image_prompt', sa.String(), nullable=True))
|
|
op.add_column('storyboards', sa.Column('video_prompt', sa.String(), nullable=True))
|
|
|
|
|
|
def downgrade() -> None:
|
|
# Remove fields from storyboards
|
|
op.drop_column('storyboards', 'video_prompt')
|
|
op.drop_column('storyboards', 'merge_image_prompt')
|
|
op.drop_column('storyboards', 'original_text')
|
|
|
|
# Remove field from assets
|
|
op.drop_column('assets', 'image_prompt')
|