# Generated by Django 2.2.24 on 2021-10-07 08:33

from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
import multiselectfield.db.fields


class Migration(migrations.Migration):

    initial = True

    dependencies = [
        migrations.swappable_dependency(settings.AUTH_USER_MODEL),
        ('core', '0018_delete_phrase'),
        ('elastic', '0015_breakup_characters'),
        ('embedding', '0016_auto_20211006_0348'),
    ]

    operations = [
        migrations.CreateModel(
            name='CRFExtractor',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('description', models.CharField(max_length=1000)),
                ('query', models.TextField(default='{"query": {"match_all": {}}}')),
                ('labels', models.TextField(default='["GPE", "ORG", "PER", "LOC"]')),
                ('num_iter', models.IntegerField(default=100)),
                ('test_size', models.FloatField(default=0.3)),
                ('c1', models.FloatField(default=1.0)),
                ('c2', models.FloatField(default=1.0)),
                ('bias', models.BooleanField(default=True)),
                ('window_size', models.IntegerField(default=2)),
                ('suffix_len', models.TextField(default='[2, 2]')),
                ('mlp_field', models.CharField(default='text', max_length=1000)),
                ('feature_fields', multiselectfield.db.fields.MultiSelectField(choices=[('text', 'text'), ('lemmas', 'lemmas'), ('pos_tags', 'pos_tags')], max_length=20)),
                ('context_feature_fields', multiselectfield.db.fields.MultiSelectField(choices=[('text', 'text'), ('lemmas', 'lemmas'), ('pos_tags', 'pos_tags')], max_length=20)),
                ('feature_extractors', multiselectfield.db.fields.MultiSelectField(choices=[('isupper', 'isupper'), ('istitle', 'istitle'), ('hasdigit', 'hasdigit')], max_length=24)),
                ('context_feature_extractors', multiselectfield.db.fields.MultiSelectField(choices=[('isupper', 'isupper'), ('istitle', 'istitle'), ('hasdigit', 'hasdigit')], max_length=24)),
                ('model', models.FileField(default=None, max_length=1000, null=True, upload_to='', verbose_name='')),
                ('model_size', models.FloatField(default=None, null=True)),
                ('plot', models.FileField(null=True, upload_to='data/media', verbose_name='')),
                ('author', models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, to=settings.AUTH_USER_MODEL)),
                ('embedding', models.ForeignKey(default=None, null=True, on_delete=django.db.models.deletion.CASCADE, to='embedding.Embedding')),
                ('indices', models.ManyToManyField(default=None, to='elastic.Index')),
                ('project', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='core.Project')),
                ('task', models.OneToOneField(null=True, on_delete=django.db.models.deletion.SET_NULL, to='core.Task')),
            ],
        ),
    ]
