# Generated by Django 2.0.10 on 2019-03-05 16:30

import capdb.models
from django.db import migrations, models
import django.db.models.deletion


class Migration(migrations.Migration):

    dependencies = [
        ('capdb', '0058_snippet'),
    ]

    operations = [
        migrations.CreateModel(
            name='NgramObservation',
            fields=[
                ('id', models.BigAutoField(primary_key=True, serialize=False)),
                ('instance_count', models.IntegerField()),
                ('document_count', models.IntegerField()),
                ('year', models.SmallIntegerField(null=True)),
                ('jurisdiction', capdb.models.SmallForeignKey(null=True, on_delete=django.db.models.deletion.CASCADE, related_name='ngrams', to='capdb.Jurisdiction')),
            ],
        ),
        migrations.RemoveField(
            model_name='ngram',
            name='count',
        ),
        migrations.RemoveField(
            model_name='ngram',
            name='jurisdiction',
        ),
        migrations.RemoveField(
            model_name='ngram',
            name='year',
        ),
        migrations.AlterField(
            model_name='ngramword',
            name='word',
            field=models.CharField(db_index=True, max_length=10000, unique=True),
        ),
        migrations.AddField(
            model_name='ngramobservation',
            name='ngram',
            field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='observations', to='capdb.Ngram'),
        ),
    ]
