Skip to content

Commit

Permalink
merge periodical/newspaper categories
Browse files Browse the repository at this point in the history
  • Loading branch information
lukavdplas committed Sep 21, 2023
1 parent f498883 commit 886ea6e
Show file tree
Hide file tree
Showing 5 changed files with 22 additions and 5 deletions.
3 changes: 1 addition & 2 deletions backend/addcorpus/constants.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
CATEGORIES = [
('newspaper', 'Newspapers'),
('parliament', 'Parliamentary debates'),
('periodical', 'Periodicals'),
('periodical', 'Newspapers and other periodicals'),
('finance', 'Financial reports'),
('ruling', 'Court rulings'),
('review', 'Online reviews'),
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Generated by Django 4.1.9 on 2023-09-21 14:16

from django.db import migrations, models


class Migration(migrations.Migration):

dependencies = [
('addcorpus', '0003_add_corpusconfiguration'),
]

operations = [
migrations.AlterField(
model_name='corpusconfiguration',
name='category',
field=models.CharField(choices=[('parliament', 'Parliamentary debates'), ('periodical', 'Newspapers and other periodicals'), ('finance', 'Financial reports'), ('ruling', 'Court rulings'), ('review', 'Online reviews'), ('inscription', 'Funerary inscriptions'), ('oration', 'Orations'), ('book', 'Books')], help_text='category/medium of documents in this dataset', max_length=64),
),
]
2 changes: 1 addition & 1 deletion backend/corpora/dutchnewspapers/dutchnewspapers_public.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ class DutchNewspapersPublic(XMLCorpusDefinition):
es_index = getattr(settings, 'DUTCHNEWSPAPERS_ES_INDEX', 'dutchnewspapers-public')
image = 'dutchnewspapers.jpg'
languages = ['nl']
category = 'newspaper'
category = 'periodical'

@property
def es_settings(self):
Expand Down
2 changes: 1 addition & 1 deletion backend/corpora/guardianobserver/guardianobserver.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ class GuardianObserver(XMLCorpusDefinition):
image = 'guardianobserver.jpg'
scan_image_type = getattr(settings, 'GO_SCAN_IMAGE_TYPE', 'application/pdf')
languages = ['en']
category = 'newspaper'
category = 'periodcal'

@property
def es_settings(self):
Expand Down
2 changes: 1 addition & 1 deletion backend/corpora/times/times.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ class Times(XMLCorpusDefinition):
scan_image_type = getattr(settings, 'TIMES_SCAN_IMAGE_TYPE', 'image/png')
description_page = 'times.md'
languages = ['en']
category = 'newspaper'
category = 'periodical'

@property
def es_settings(self):
Expand Down

0 comments on commit 886ea6e

Please sign in to comment.