"""add_new_shifu_models

Revision ID: d9605bb33e67
Revises: 15cc32aebd22
Create Date: 2025-07-18 08:49:03.300152

"""

from alembic import op
import sqlalchemy as sa
from sqlalchemy.dialects import mysql

# revision identifiers, used by Alembic.
revision = "d9605bb33e67"
down_revision = "15cc32aebd22"
branch_labels = None
depends_on = None


def upgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.create_table(
        "shifu_draft_blocks",
        sa.Column("id", mysql.BIGINT(), autoincrement=True, nullable=False),
        sa.Column(
            "block_bid",
            sa.String(length=32),
            nullable=False,
            comment="Block business identifier",
        ),
        sa.Column(
            "shifu_bid",
            sa.String(length=32),
            nullable=False,
            comment="Shifu business identifier",
        ),
        sa.Column(
            "outline_item_bid",
            sa.String(length=32),
            nullable=False,
            comment="Outline item business identifier",
        ),
        sa.Column("type", sa.SmallInteger(), nullable=False, comment="Block type"),
        sa.Column(
            "position",
            sa.SmallInteger(),
            nullable=False,
            comment="Block position within outline",
        ),
        sa.Column(
            "variable_bids",
            sa.String(length=500),
            nullable=False,
            comment="Variable business identifiers used in block",
        ),
        sa.Column(
            "resource_bids",
            sa.String(length=500),
            nullable=False,
            comment="Resource business identifiers used in block",
        ),
        sa.Column("content", sa.Text(), nullable=False, comment="Block content"),
        sa.Column(
            "deleted",
            sa.SmallInteger(),
            nullable=False,
            comment="Deletion flag: 0=active, 1=deleted",
        ),
        sa.Column(
            "created_at", sa.DateTime(), nullable=False, comment="Creation timestamp"
        ),
        sa.Column(
            "created_user_bid",
            sa.String(length=32),
            nullable=False,
            comment="Creator user business identifier",
        ),
        sa.Column(
            "updated_at", sa.DateTime(), nullable=False, comment="Last update timestamp"
        ),
        sa.Column(
            "updated_user_bid",
            sa.String(length=32),
            nullable=False,
            comment="Last updater user business identifier",
        ),
        sa.PrimaryKeyConstraint("id"),
    )
    with op.batch_alter_table("shifu_draft_blocks", schema=None) as batch_op:
        batch_op.create_index(
            batch_op.f("ix_shifu_draft_blocks_block_bid"), ["block_bid"], unique=False
        )
        batch_op.create_index(
            batch_op.f("ix_shifu_draft_blocks_outline_item_bid"),
            ["outline_item_bid"],
            unique=False,
        )
        batch_op.create_index(
            batch_op.f("ix_shifu_draft_blocks_position"), ["position"], unique=False
        )
        batch_op.create_index(
            batch_op.f("ix_shifu_draft_blocks_shifu_bid"), ["shifu_bid"], unique=False
        )

    op.create_table(
        "shifu_draft_outline_items",
        sa.Column("id", mysql.BIGINT(), autoincrement=True, nullable=False),
        sa.Column(
            "outline_item_bid",
            sa.String(length=32),
            nullable=False,
            comment="Outline item business identifier",
        ),
        sa.Column(
            "shifu_bid",
            sa.String(length=32),
            nullable=False,
            comment="Shifu business identifier",
        ),
        sa.Column(
            "title", sa.String(length=100), nullable=False, comment="Outline item title"
        ),
        sa.Column(
            "type",
            sa.SmallInteger(),
            nullable=False,
            comment="Outline item type: 401=trial, 402=normal",
        ),
        sa.Column(
            "hidden",
            sa.SmallInteger(),
            nullable=False,
            comment="Hidden flag: 0=visible, 1=hidden",
        ),
        sa.Column(
            "parent_bid",
            sa.String(length=32),
            nullable=False,
            comment="Parent outline item business identifier",
        ),
        sa.Column(
            "position",
            sa.String(length=10),
            nullable=False,
            comment="Position in outline",
        ),
        sa.Column(
            "prerequisite_item_bids",
            sa.String(length=500),
            nullable=False,
            comment="Prerequisite outline item business identifiers",
        ),
        sa.Column(
            "llm", sa.String(length=100), nullable=False, comment="LLM model name"
        ),
        sa.Column(
            "llm_temperature",
            sa.DECIMAL(precision=10, scale=2),
            nullable=False,
            comment="LLM temperature parameter",
        ),
        sa.Column(
            "llm_system_prompt", sa.Text(), nullable=False, comment="LLM system prompt"
        ),
        sa.Column(
            "ask_enabled_status",
            sa.SmallInteger(),
            nullable=False,
            comment="Ask agent status: 5101=default, 5102=disabled, 5103=enabled",
        ),
        sa.Column(
            "ask_llm",
            sa.String(length=100),
            nullable=False,
            comment="Ask agent LLM model",
        ),
        sa.Column(
            "ask_llm_temperature",
            sa.DECIMAL(precision=10, scale=2),
            nullable=False,
            comment="Ask mode LLM temperature",
        ),
        sa.Column(
            "ask_llm_system_prompt",
            sa.Text(),
            nullable=False,
            comment="Ask mode LLM system prompt",
        ),
        sa.Column(
            "deleted",
            sa.SmallInteger(),
            nullable=False,
            comment="Deletion flag: 0=active, 1=deleted",
        ),
        sa.Column(
            "created_at", sa.DateTime(), nullable=False, comment="Creation timestamp"
        ),
        sa.Column(
            "created_user_bid",
            sa.String(length=32),
            nullable=False,
            comment="Creator user business identifier",
        ),
        sa.Column(
            "updated_at", sa.DateTime(), nullable=False, comment="Last update timestamp"
        ),
        sa.Column(
            "updated_user_bid",
            sa.String(length=32),
            nullable=False,
            comment="Last updater user business identifier",
        ),
        sa.PrimaryKeyConstraint("id"),
    )
    with op.batch_alter_table("shifu_draft_outline_items", schema=None) as batch_op:
        batch_op.create_index(
            batch_op.f("ix_shifu_draft_outline_items_outline_item_bid"),
            ["outline_item_bid"],
            unique=False,
        )
        batch_op.create_index(
            batch_op.f("ix_shifu_draft_outline_items_parent_bid"),
            ["parent_bid"],
            unique=False,
        )
        batch_op.create_index(
            batch_op.f("ix_shifu_draft_outline_items_position"),
            ["position"],
            unique=False,
        )
        batch_op.create_index(
            batch_op.f("ix_shifu_draft_outline_items_shifu_bid"),
            ["shifu_bid"],
            unique=False,
        )

    op.create_table(
        "shifu_draft_shifus",
        sa.Column("id", mysql.BIGINT(), autoincrement=True, nullable=False),
        sa.Column(
            "shifu_bid",
            sa.String(length=32),
            nullable=False,
            comment="Shifu business identifier",
        ),
        sa.Column(
            "title", sa.String(length=100), nullable=False, comment="Shifu title"
        ),
        sa.Column(
            "keywords",
            sa.String(length=100),
            nullable=False,
            comment="Associated keywords",
        ),
        sa.Column(
            "description",
            sa.String(length=500),
            nullable=False,
            comment="Shifu description",
        ),
        sa.Column(
            "avatar_res_bid",
            sa.String(length=32),
            nullable=False,
            comment="Avatar resource business identifier",
        ),
        sa.Column(
            "llm", sa.String(length=100), nullable=False, comment="LLM model name"
        ),
        sa.Column(
            "llm_temperature",
            sa.DECIMAL(precision=10, scale=2),
            nullable=False,
            comment="LLM temperature parameter",
        ),
        sa.Column(
            "llm_system_prompt", sa.Text(), nullable=False, comment="LLM system prompt"
        ),
        sa.Column(
            "ask_enabled_status",
            sa.SmallInteger(),
            nullable=False,
            comment="Ask agent status: 5101=default, 5102=disabled, 5103=enabled",
        ),
        sa.Column(
            "ask_llm",
            sa.String(length=100),
            nullable=False,
            comment="Ask agent LLM model",
        ),
        sa.Column(
            "ask_llm_temperature",
            sa.DECIMAL(precision=10, scale=2),
            nullable=False,
            comment="Ask agent LLM temperature",
        ),
        sa.Column(
            "ask_llm_system_prompt",
            sa.Text(),
            nullable=False,
            comment="Ask agent LLM system prompt",
        ),
        sa.Column(
            "price",
            sa.DECIMAL(precision=10, scale=2),
            nullable=False,
            comment="Shifu price",
        ),
        sa.Column(
            "deleted",
            sa.SmallInteger(),
            nullable=False,
            comment="Deletion flag: 0=active, 1=deleted",
        ),
        sa.Column(
            "created_at", sa.DateTime(), nullable=False, comment="Creation timestamp"
        ),
        sa.Column(
            "created_user_bid",
            sa.String(length=32),
            nullable=False,
            comment="Creator user business identifier",
        ),
        sa.Column(
            "updated_at", sa.DateTime(), nullable=False, comment="Last update timestamp"
        ),
        sa.Column(
            "updated_user_bid",
            sa.String(length=32),
            nullable=False,
            comment="Last updater user business identifier",
        ),
        sa.PrimaryKeyConstraint("id"),
    )
    with op.batch_alter_table("shifu_draft_shifus", schema=None) as batch_op:
        batch_op.create_index(
            batch_op.f("ix_shifu_draft_shifus_created_user_bid"),
            ["created_user_bid"],
            unique=False,
        )
        batch_op.create_index(
            batch_op.f("ix_shifu_draft_shifus_shifu_bid"), ["shifu_bid"], unique=False
        )
        batch_op.create_index(
            batch_op.f("ix_shifu_draft_shifus_updated_user_bid"),
            ["updated_user_bid"],
            unique=False,
        )

    op.create_table(
        "shifu_log_draft_structs",
        sa.Column("id", mysql.BIGINT(), autoincrement=True, nullable=False),
        sa.Column(
            "struct_bid",
            sa.String(length=32),
            nullable=False,
            comment="Content business identifier",
        ),
        sa.Column(
            "shifu_bid",
            sa.String(length=32),
            nullable=False,
            comment="Shifu business identifier",
        ),
        sa.Column(
            "struct", sa.Text(), nullable=False, comment="JSON serialized shifu struct"
        ),
        sa.Column(
            "deleted",
            sa.SmallInteger(),
            nullable=False,
            comment="Deletion flag: 0=active, 1=deleted",
        ),
        sa.Column(
            "created_at", sa.DateTime(), nullable=False, comment="Creation timestamp"
        ),
        sa.Column(
            "created_user_bid",
            sa.String(length=32),
            nullable=False,
            comment="Creator user business identifier",
        ),
        sa.Column(
            "updated_at", sa.DateTime(), nullable=False, comment="Last update timestamp"
        ),
        sa.Column(
            "updated_user_bid",
            sa.String(length=32),
            nullable=False,
            comment="Last updater user business identifier",
        ),
        sa.PrimaryKeyConstraint("id"),
    )
    with op.batch_alter_table("shifu_log_draft_structs", schema=None) as batch_op:
        batch_op.create_index(
            batch_op.f("ix_shifu_log_draft_structs_shifu_bid"),
            ["shifu_bid"],
            unique=False,
        )
        batch_op.create_index(
            batch_op.f("ix_shifu_log_draft_structs_struct_bid"),
            ["struct_bid"],
            unique=True,
        )

    op.create_table(
        "shifu_log_published_structs",
        sa.Column("id", mysql.BIGINT(), autoincrement=True, nullable=False),
        sa.Column(
            "struct_bid",
            sa.String(length=32),
            nullable=False,
            comment="Content business identifier",
        ),
        sa.Column(
            "shifu_bid",
            sa.String(length=32),
            nullable=False,
            comment="Shifu business identifier",
        ),
        sa.Column(
            "struct",
            sa.Text(),
            nullable=False,
            comment="JSON serialized struct of published shifu",
        ),
        sa.Column(
            "deleted",
            sa.SmallInteger(),
            nullable=False,
            comment="Deletion flag: 0=active, 1=deleted",
        ),
        sa.Column(
            "created_at", sa.DateTime(), nullable=False, comment="Creation timestamp"
        ),
        sa.Column(
            "created_user_bid",
            sa.String(length=32),
            nullable=False,
            comment="Creator user business identifier",
        ),
        sa.Column(
            "updated_at", sa.DateTime(), nullable=False, comment="Last update timestamp"
        ),
        sa.Column(
            "updated_user_bid",
            sa.String(length=32),
            nullable=False,
            comment="Last updater user business identifier",
        ),
        sa.PrimaryKeyConstraint("id"),
    )
    with op.batch_alter_table("shifu_log_published_structs", schema=None) as batch_op:
        batch_op.create_index(
            batch_op.f("ix_shifu_log_published_structs_shifu_bid"),
            ["shifu_bid"],
            unique=False,
        )
        batch_op.create_index(
            batch_op.f("ix_shifu_log_published_structs_struct_bid"),
            ["struct_bid"],
            unique=True,
        )

    op.create_table(
        "shifu_published_blocks",
        sa.Column("id", mysql.BIGINT(), autoincrement=True, nullable=False),
        sa.Column(
            "block_bid",
            sa.String(length=32),
            nullable=False,
            comment="Block business identifier",
        ),
        sa.Column(
            "shifu_bid",
            sa.String(length=32),
            nullable=False,
            comment="Shifu business identifier",
        ),
        sa.Column(
            "outline_item_bid",
            sa.String(length=32),
            nullable=False,
            comment="Outline item business identifier",
        ),
        sa.Column("type", sa.SmallInteger(), nullable=False, comment="Block type"),
        sa.Column(
            "position",
            sa.SmallInteger(),
            nullable=False,
            comment="Block position within outline",
        ),
        sa.Column(
            "variable_bids",
            sa.String(length=500),
            nullable=False,
            comment="Variable business identifiers used in block",
        ),
        sa.Column(
            "resource_bids",
            sa.String(length=500),
            nullable=False,
            comment="Resource business identifiers used in block",
        ),
        sa.Column("content", sa.Text(), nullable=False, comment="Block content"),
        sa.Column(
            "deleted",
            sa.SmallInteger(),
            nullable=False,
            comment="Deletion flag: 0=active, 1=deleted",
        ),
        sa.Column(
            "created_at", sa.DateTime(), nullable=False, comment="Creation timestamp"
        ),
        sa.Column(
            "created_user_bid",
            sa.String(length=32),
            nullable=False,
            comment="Creator user business identifier",
        ),
        sa.Column(
            "updated_at", sa.DateTime(), nullable=False, comment="Last update timestamp"
        ),
        sa.Column(
            "updated_user_bid",
            sa.String(length=32),
            nullable=False,
            comment="Last updater user business identifier",
        ),
        sa.PrimaryKeyConstraint("id"),
    )
    with op.batch_alter_table("shifu_published_blocks", schema=None) as batch_op:
        batch_op.create_index(
            batch_op.f("ix_shifu_published_blocks_block_bid"),
            ["block_bid"],
            unique=False,
        )
        batch_op.create_index(
            batch_op.f("ix_shifu_published_blocks_outline_item_bid"),
            ["outline_item_bid"],
            unique=False,
        )
        batch_op.create_index(
            batch_op.f("ix_shifu_published_blocks_shifu_bid"),
            ["shifu_bid"],
            unique=False,
        )

    op.create_table(
        "shifu_published_outline_items",
        sa.Column("id", mysql.BIGINT(), autoincrement=True, nullable=False),
        sa.Column(
            "outline_item_bid",
            sa.String(length=32),
            nullable=False,
            comment="Outline item business identifier",
        ),
        sa.Column(
            "shifu_bid",
            sa.String(length=32),
            nullable=False,
            comment="Shifu business identifier",
        ),
        sa.Column(
            "title", sa.String(length=100), nullable=False, comment="Outline item title"
        ),
        sa.Column(
            "type",
            sa.SmallInteger(),
            nullable=False,
            comment="Outline item type: 401=trial, 402=normal",
        ),
        sa.Column(
            "hidden",
            sa.SmallInteger(),
            nullable=False,
            comment="Hidden flag: 0=visible, 1=hidden",
        ),
        sa.Column(
            "parent_bid",
            sa.String(length=32),
            nullable=False,
            comment="Parent outline item business identifier",
        ),
        sa.Column(
            "position", sa.String(length=10), nullable=False, comment="Outline position"
        ),
        sa.Column(
            "prerequisite_item_bids",
            sa.String(length=500),
            nullable=False,
            comment="Prerequisite outline item business identifiers",
        ),
        sa.Column(
            "llm", sa.String(length=100), nullable=False, comment="LLM model name"
        ),
        sa.Column(
            "llm_temperature",
            sa.DECIMAL(precision=10, scale=2),
            nullable=False,
            comment="LLM temperature parameter",
        ),
        sa.Column(
            "llm_system_prompt", sa.Text(), nullable=False, comment="LLM system prompt"
        ),
        sa.Column(
            "ask_enabled_status",
            sa.SmallInteger(),
            nullable=False,
            comment="Ask agent status: 5101=default, 5102=disabled, 5103=enabled",
        ),
        sa.Column(
            "ask_llm",
            sa.String(length=100),
            nullable=False,
            comment="Ask agent LLM model",
        ),
        sa.Column(
            "ask_llm_temperature",
            sa.DECIMAL(precision=10, scale=2),
            nullable=False,
            comment="Ask agent LLM temperature",
        ),
        sa.Column(
            "ask_llm_system_prompt",
            sa.Text(),
            nullable=False,
            comment="Ask agent LLM system prompt",
        ),
        sa.Column(
            "deleted",
            sa.SmallInteger(),
            nullable=False,
            comment="Deletion flag: 0=active, 1=deleted",
        ),
        sa.Column(
            "created_at", sa.DateTime(), nullable=False, comment="Creation timestamp"
        ),
        sa.Column(
            "created_user_bid",
            sa.String(length=32),
            nullable=False,
            comment="Creator user business identifier",
        ),
        sa.Column(
            "updated_at", sa.DateTime(), nullable=False, comment="Last update timestamp"
        ),
        sa.Column(
            "updated_user_bid",
            sa.String(length=32),
            nullable=False,
            comment="Last updater user business identifier",
        ),
        sa.PrimaryKeyConstraint("id"),
    )
    with op.batch_alter_table("shifu_published_outline_items", schema=None) as batch_op:
        batch_op.create_index(
            batch_op.f("ix_shifu_published_outline_items_created_user_bid"),
            ["created_user_bid"],
            unique=False,
        )
        batch_op.create_index(
            batch_op.f("ix_shifu_published_outline_items_outline_item_bid"),
            ["outline_item_bid"],
            unique=False,
        )
        batch_op.create_index(
            batch_op.f("ix_shifu_published_outline_items_shifu_bid"),
            ["shifu_bid"],
            unique=False,
        )

    op.create_table(
        "shifu_published_shifus",
        sa.Column("id", mysql.BIGINT(), autoincrement=True, nullable=False),
        sa.Column(
            "shifu_bid",
            sa.String(length=32),
            nullable=False,
            comment="Shifu business identifier",
        ),
        sa.Column(
            "title", sa.String(length=100), nullable=False, comment="Shifu title"
        ),
        sa.Column(
            "keywords",
            sa.String(length=100),
            nullable=False,
            comment="Associated keywords",
        ),
        sa.Column(
            "description",
            sa.String(length=500),
            nullable=False,
            comment="Shifu description",
        ),
        sa.Column(
            "avatar_res_bid",
            sa.String(length=32),
            nullable=False,
            comment="Avatar resource business identifier",
        ),
        sa.Column(
            "llm", sa.String(length=100), nullable=False, comment="LLM model name"
        ),
        sa.Column(
            "llm_temperature",
            sa.DECIMAL(precision=10, scale=2),
            nullable=False,
            comment="LLM temperature parameter",
        ),
        sa.Column(
            "llm_system_prompt", sa.Text(), nullable=False, comment="LLM system prompt"
        ),
        sa.Column(
            "ask_enabled_status",
            sa.SmallInteger(),
            nullable=False,
            comment="Ask agent status: 5101=default, 5102=disabled, 5103=enabled",
        ),
        sa.Column(
            "ask_llm",
            sa.String(length=100),
            nullable=False,
            comment="Ask agent LLM model",
        ),
        sa.Column(
            "ask_llm_temperature",
            sa.DECIMAL(precision=10, scale=2),
            nullable=False,
            comment="Ask agent LLM temperature",
        ),
        sa.Column(
            "ask_llm_system_prompt",
            sa.Text(),
            nullable=False,
            comment="Ask agent LLM system prompt",
        ),
        sa.Column(
            "price",
            sa.DECIMAL(precision=10, scale=2),
            nullable=False,
            comment="Shifu price",
        ),
        sa.Column(
            "deleted",
            sa.SmallInteger(),
            nullable=False,
            comment="Deletion flag: 0=active, 1=deleted",
        ),
        sa.Column(
            "created_at", sa.DateTime(), nullable=False, comment="Creation timestamp"
        ),
        sa.Column(
            "created_user_bid",
            sa.String(length=32),
            nullable=False,
            comment="Creator user business identifier",
        ),
        sa.Column(
            "updated_at", sa.DateTime(), nullable=False, comment="Last update timestamp"
        ),
        sa.Column(
            "updated_user_bid",
            sa.String(length=32),
            nullable=False,
            comment="Last updater user business identifier",
        ),
        sa.PrimaryKeyConstraint("id"),
    )
    with op.batch_alter_table("shifu_published_shifus", schema=None) as batch_op:
        batch_op.create_index(
            batch_op.f("ix_shifu_published_shifus_created_user_bid"),
            ["created_user_bid"],
            unique=False,
        )
        batch_op.create_index(
            batch_op.f("ix_shifu_published_shifus_shifu_bid"),
            ["shifu_bid"],
            unique=False,
        )


def downgrade():
    with op.batch_alter_table("shifu_published_shifus", schema=None) as batch_op:
        batch_op.drop_index(batch_op.f("ix_shifu_published_shifus_shifu_bid"))
        batch_op.drop_index(batch_op.f("ix_shifu_published_shifus_created_user_bid"))

    op.drop_table("shifu_published_shifus")
    with op.batch_alter_table("shifu_published_outline_items", schema=None) as batch_op:
        batch_op.drop_index(batch_op.f("ix_shifu_published_outline_items_shifu_bid"))
        batch_op.drop_index(
            batch_op.f("ix_shifu_published_outline_items_outline_item_bid")
        )
        batch_op.drop_index(
            batch_op.f("ix_shifu_published_outline_items_created_user_bid")
        )

    op.drop_table("shifu_published_outline_items")
    with op.batch_alter_table("shifu_published_blocks", schema=None) as batch_op:
        batch_op.drop_index(batch_op.f("ix_shifu_published_blocks_shifu_bid"))
        batch_op.drop_index(batch_op.f("ix_shifu_published_blocks_outline_item_bid"))
        batch_op.drop_index(batch_op.f("ix_shifu_published_blocks_block_bid"))

    op.drop_table("shifu_published_blocks")
    with op.batch_alter_table("shifu_log_published_structs", schema=None) as batch_op:
        batch_op.drop_index(batch_op.f("ix_shifu_log_published_structs_struct_bid"))
        batch_op.drop_index(batch_op.f("ix_shifu_log_published_structs_shifu_bid"))

    op.drop_table("shifu_log_published_structs")
    with op.batch_alter_table("shifu_log_draft_structs", schema=None) as batch_op:
        batch_op.drop_index(batch_op.f("ix_shifu_log_draft_structs_struct_bid"))
        batch_op.drop_index(batch_op.f("ix_shifu_log_draft_structs_shifu_bid"))

    op.drop_table("shifu_log_draft_structs")
    with op.batch_alter_table("shifu_draft_shifus", schema=None) as batch_op:
        batch_op.drop_index(batch_op.f("ix_shifu_draft_shifus_updated_user_bid"))
        batch_op.drop_index(batch_op.f("ix_shifu_draft_shifus_shifu_bid"))
        batch_op.drop_index(batch_op.f("ix_shifu_draft_shifus_created_user_bid"))

    op.drop_table("shifu_draft_shifus")
    with op.batch_alter_table("shifu_draft_outline_items", schema=None) as batch_op:
        batch_op.drop_index(batch_op.f("ix_shifu_draft_outline_items_shifu_bid"))
        batch_op.drop_index(batch_op.f("ix_shifu_draft_outline_items_position"))
        batch_op.drop_index(batch_op.f("ix_shifu_draft_outline_items_parent_bid"))
        batch_op.drop_index(batch_op.f("ix_shifu_draft_outline_items_outline_item_bid"))

    op.drop_table("shifu_draft_outline_items")
    with op.batch_alter_table("shifu_draft_blocks", schema=None) as batch_op:
        batch_op.drop_index(batch_op.f("ix_shifu_draft_blocks_shifu_bid"))
        batch_op.drop_index(batch_op.f("ix_shifu_draft_blocks_position"))
        batch_op.drop_index(batch_op.f("ix_shifu_draft_blocks_outline_item_bid"))
        batch_op.drop_index(batch_op.f("ix_shifu_draft_blocks_block_bid"))

    op.drop_table("shifu_draft_blocks")
    # ### end Alembic commands ###
