cterdam commited on
Commit
058be8e
·
1 Parent(s): 5f5e8fd

Use Language Rule lists from /home/llz/llz/doc/README.md

Browse files

Corrects SLAVIC_REGIONS and SINOPHONE_REGIONS to match the authoritative
Language Rule in doc/README.md. Key differences from the previous lists:
- Sinophone adds PH, ID (Philippines, Indonesia)
- Slavic adds AL, HU, RO (Albania, Hungary, Romania)

Files changed (1) hide show
  1. test/test_invariants.py +7 -5
test/test_invariants.py CHANGED
@@ -24,15 +24,17 @@ import pytest
24
  from collections import defaultdict
25
  from datasets import load_dataset
26
 
27
- # Copied from cterdam/iso_3166-1_alpha-2 test/test_invariants.py — the
28
- # authoritative definition of which regions use which primary language.
29
  SLAVIC_REGIONS = {
30
- 'RU', 'UA', 'BY', 'KZ', 'UZ', 'TJ', 'KG', 'TM', 'GE', 'AZ', 'AM', 'MD',
31
- 'LT', 'LV', 'EE', 'RS', 'ME', 'BA', 'HR', 'SI', 'SK', 'CZ', 'PL', 'BG', 'MK', 'FI'
 
32
  }
33
 
34
  SINOPHONE_REGIONS = {
35
- 'CN', 'TW', 'HK', 'MO', 'JP', 'KR', 'KP', 'MN', 'SG', 'VN', 'LA', 'TH', 'MM', 'KH', 'MY', 'BN'
 
36
  }
37
 
38
 
 
24
  from collections import defaultdict
25
  from datasets import load_dataset
26
 
27
+ # From /home/llz/llz/doc/README.md § Language — the authoritative
28
+ # "Language Rule" defining which regions use which primary language.
29
  SLAVIC_REGIONS = {
30
+ 'RU', 'UA', 'BY', 'LT', 'LV', 'EE', 'MD', 'GE', 'AM', 'AZ', 'KZ', 'KG',
31
+ 'TJ', 'TM', 'UZ', 'AL', 'BG', 'CZ', 'HU', 'PL', 'RO', 'SK', 'BA', 'HR',
32
+ 'ME', 'MK', 'RS', 'SI', 'FI',
33
  }
34
 
35
  SINOPHONE_REGIONS = {
36
+ 'CN', 'HK', 'MO', 'TW', 'KP', 'KR', 'MN', 'JP', 'VN', 'LA', 'MY', 'TH',
37
+ 'SG', 'PH', 'MM', 'ID', 'KH', 'BN',
38
  }
39
 
40