Research talk:Revision scoring as a service/Work log/2015-11-12
Add topicAppearance
Latest comment: 9 years ago by Halfak (WMF) in topic Thursday, November 12, 2015
Thursday, November 12, 2015
[edit]Today, I'm loading Russian and Ukranian edit quality campaigns into Wiki labels.
u_wikilabels=> SELECT id, name, wiki FROM campaign WHERE wiki IN ('ruwiki', 'ukwiki'); id | name | wiki ----+------------------------------------------------------+-------- 10 | Редактировать качество (20k случайная выборка, 2015) | ruwiki 11 | Редагувати якість (20k випадкова вибірка, 2015) | ukwiki
OK. Campaign records created. I'm using the result of running the prelabeling script on these wikis to load them up.
First, let's look at some sample output:
$ cat datasets/ruwiki.prelabeled_revisions.20k_2015.tsv | grep -P "rev_id|[0-9]+\tTrue" | head | /srv/wikilabels/venv/bin/wikilabels task_inserts 5 INSERT INTO task (campaign_id, data) VALUES (5, '{"reason": "NULL", "needs_review": "True", "rev_id": 66696639}'), (5, '{"reason": "reverted edit", "needs_review": "True", "rev_id": 66852339}'), (5, '{"reason": "NULL", "needs_review": "True", "rev_id": 71887614}'), (5, '{"reason": "NULL", "needs_review": "True", "rev_id": 70870700}'), (5, '{"reason": "NULL", "needs_review": "True", "rev_id": 71123011}'), (5, '{"reason": "reverted edit", "needs_review": "True", "rev_id": 69314507}'), (5, '{"reason": "NULL", "needs_review": "True", "rev_id": 72741611}'), (5, '{"reason": "NULL", "needs_review": "True", "rev_id": 73622657}'), (5, '{"reason": "NULL", "needs_review": "True", "rev_id": 73276754}');
Now to run the real thing.
halfak@wikilabels-01:~$ cat datasets/ruwiki.prelabeled_revisions.20k_2015.tsv | grep -P "rev_id|[0-9]+\tTrue" | /srv/wikilabels/venv/bin/wikilabels task_inserts 10 | psql -h wikilabels-database --user u_wikilabels u_wikilabels -W Password for user u_wikilabels: INSERT 0 5193 halfak@wikilabels-01:~$ cat datasets/ukwiki.prelabeled_revisions.20k_2015.tsv | grep -P "rev_id|[0-9]+\tTrue" | /srv/wikilabels/venv/bin/wikilabels task_inserts 11 | psql -h wikilabels-database --user u_wikilabels u_wikilabels -W Password for user u_wikilabels: INSERT 0 3318
OK. Now to test on those wikis! ... Looks like uk:Вікіпедія:Оцінки and ru:Википедия:Оценка are working. :) --Halfak (WMF) (talk) 18:11, 12 November 2015 (UTC)
Looks like I'm doing idwiki, nlwiki and eswiki too.
u_wikilabels=> SELECT id, name, wiki, active FROM campaign WHERE wiki IN ('nlwiki', 'idwiki', 'eswiki'); id | name | wiki | active ----+----------------------------------------------+--------+-------- 12 | Editar calidad (20k muestra aleatoria, 2015) | eswiki | t 13 | Mengedit kualitas (20k sampel acak, 2015) | idwiki | t 14 | Kwaliteit bewerken (20k steekproef, 2015) | nlwiki | t (3 rows)
halfak@wikilabels-01:~$ cat datasets/eswiki.prelabeled_revisions.20k_2015.tsv | grep -P "rev_id|[0-9]+\tTrue" | /srv/wikilabels/venv/bin/wikilabels task_inserts 12 | psql -h wikilabels-database --user u_wikilabels u_wikilabels -W Password for user u_wikilabels: INSERT 0 8434 halfak@wikilabels-01:~$ cat datasets/idwiki.prelabeled_revisions.20k_2015.tsv | grep -P "rev_id|[0-9]+\tTrue" | /srv/wikilabels/venv/bin/wikilabels task_inserts 13 | psql -h wikilabels-database --user u_wikilabels u_wikilabels -W Password for user u_wikilabels: INSERT 0 2200 halfak@wikilabels-01:~$ cat datasets/dewiki.prelabeled_revisions.20k_2015.tsv | grep -P "rev_id|[0-9]+\tTrue" | /srv/wikilabels/venv/bin/wikilabels task_inserts 14 | psql -h wikilabels-database --user u_wikilabels u_wikilabels -W Password for user u_wikilabels: INSERT 0 4177