You've already forked DataMate
Add Label Studio adapter module and its build scipts.
This commit is contained in:
@@ -0,0 +1,41 @@
|
||||
"""Initiation
|
||||
|
||||
Revision ID: 755dc1afb8ad
|
||||
Revises:
|
||||
Create Date: 2025-10-20 19:34:20.258554
|
||||
|
||||
"""
|
||||
from typing import Sequence, Union
|
||||
|
||||
from alembic import op
|
||||
import sqlalchemy as sa
|
||||
|
||||
|
||||
# revision identifiers, used by Alembic.
|
||||
revision: str = '755dc1afb8ad'
|
||||
down_revision: Union[str, Sequence[str], None] = None
|
||||
branch_labels: Union[str, Sequence[str], None] = None
|
||||
depends_on: Union[str, Sequence[str], None] = None
|
||||
|
||||
|
||||
def upgrade() -> None:
|
||||
"""Upgrade schema."""
|
||||
# ### commands auto generated by Alembic - please adjust! ###
|
||||
op.create_table('mapping',
|
||||
sa.Column('mapping_id', sa.String(length=36), nullable=False),
|
||||
sa.Column('source_dataset_id', sa.String(length=36), nullable=False, comment='源数据集ID'),
|
||||
sa.Column('labelling_project_id', sa.String(length=36), nullable=False, comment='标注项目ID'),
|
||||
sa.Column('labelling_project_name', sa.String(length=255), nullable=True, comment='标注项目名称'),
|
||||
sa.Column('created_at', sa.DateTime(timezone=True), server_default=sa.text('now()'), nullable=True, comment='创建时间'),
|
||||
sa.Column('last_updated_at', sa.DateTime(timezone=True), server_default=sa.text('now()'), nullable=True, comment='最后更新时间'),
|
||||
sa.Column('deleted_at', sa.DateTime(timezone=True), nullable=True, comment='删除时间'),
|
||||
sa.PrimaryKeyConstraint('mapping_id')
|
||||
)
|
||||
# ### end Alembic commands ###
|
||||
|
||||
|
||||
def downgrade() -> None:
|
||||
"""Downgrade schema."""
|
||||
# ### commands auto generated by Alembic - please adjust! ###
|
||||
op.drop_table('mapping')
|
||||
# ### end Alembic commands ###
|
||||
Reference in New Issue
Block a user