CoolFace
Datasetpublic

NagaYu/tessera-mixed-pages

Tessera mixed-page corpus Synthetic multilingual web pages with exact span boundaries and multi-label language annotations, for training and evaluating span-level language identification. Why this is synthetic, stated up front No public corpus annotates span boundaries and languages inside real multilingual web pages at scale. Annotating one by hand across 479 languages, most of them low-resource, is not feasible and would itself be error-prone in exactly the… See the full description on the dataset page: https://huggingface.co/datasets/NagaYu/tessera-mixed-pages.

sourceHugging Facecc-by-sa-4.0updated 19d agoView on Hugging Face
0likes46downloads
Dataset Card

Tessera mixed-page corpus

Synthetic multilingual web pages with exact span boundaries and multi-label language annotations, for training and evaluating span-level language identification.

Why this is synthetic, stated up front

No public corpus annotates span boundaries and languages inside real multilingual web pages at scale. Annotating one by hand across 479 languages, most of them low-resource, is not feasible and would itself be error-prone in exactly the places that matter most.

So the gold labels here are constructive: each document is assembled from source sentences of known language, and each span's offsets and language are recorded as it is placed. The boundaries are exact by definition.

The cost is real and is not hidden: the difficulty of this corpus was chosen by its authors. Results measured on it are labelled synthetic wherever they appear, and the accompanying repository reports real-data checks separately.

Contents

splitdocumentsspanslanguagesspans <= 20 charsmulti-label spans
train30,000561,36857852.89%16.47%
validation3,00056,11753455.08%18.25%
test4,00074,20054955.08%18.31%
test_adversarial2,50047,08657655.62%25.49%
test_romanized2,50047,16211448.58%8.66%

test_adversarial applies every degradation layer aggressively. test_romanized contains only non-Latin-script body languages, romanised with probability 1.0.

How a document is built

Pages imitate real furniture, because that furniture is why document-level LID discards low-resource text: navigation, footers, advertising and copyright lines are very often English even on a page whose body is not.

Archetypes:

  • —buried_body -- body in a mid/tail language, chrome in English. Document-level LID labels the page English, and the body is lost.
  • —buried_minority -- body in English with a quote or comment block in another language. The document survives filtering as English, and the minority text is silently absorbed into an English corpus.
  • —codeswitch_heavy, short_span_heavy, monolingual (control).

Degradation layers

shorten (5-20 chars), informalize (repetition, emoji, case, punctuation, abbreviation, typos -- all script-generic, no English-specific slang), romanize, codeswitch, mojibake (encoding round-trip damage), html_residue. Each span records which layers were applied, so results can be stratified by condition.

Multi-label definition

Two kinds of multi-label, scored differently, and which labels are correct is measured rather than asserted:

  • —`any` (alternatives). A string attested in several languages' source corpora gets all of them. The token Massa is attested in dozens of Latin-script languages; any one is correct, and predicting all of them earns no extra credit.
  • —`all` (code-switching). The span really contains every listed language, so each is separately required.
  • —`script_only`. Digits, punctuation and symbols get und and are scored on whether a system declines to name a language.

primary always records the language the text was actually sampled from, so recall-per-language can never be inflated by permissive alternates.

Sources and licensing

sourcelicenceredistributableshare-alike
UDHR-LID (cis-lmu/udhr-lid)CC0-1.0TrueFalse
FLORES-200CC-BY-SA-4.0TrueTrue

Effective licence: CC-BY-SA-4.0. FLORES-200 is CC-BY-SA-4.0 and its share-alike term propagates to any corpus containing its sentences.

No scraped web text is redistributed. Only material whose licence permits redistribution is published.

Resource tiers

Defined operationally, not editorially: head = in fastText lid.176's label space, mid = absent from that but present in GlotLID or OpenLID, tail = covered by no evaluated document-level LID. Counts: {'tail': 50, 'mid': 282, 'head': 147}.

Known weaknesses

Please read these before using this corpus for anything consequential.

  1. 1.Register. UDHR is formal legal prose and FLORES is encyclopaedic. Neither is conversational. The informalize layer approximates informality; it does not sample it from real usage.
  2. 2.Romanisation is systematic transliteration, not attested user romanisation. Real users writing Hindi or Tigrinya in Latin script do not follow a transliteration standard. Anything trained or evaluated on this layer is measuring an approximation, and Han, Kana and Hangul are excluded entirely because character-reading transliteration produces text no human would write.
  3. 3.Page structure is templated. Five archetypes cannot cover the real diversity of the web.
  4. 4.Sentence counts are very uneven. Some languages have 40 UDHR sentences and others have 997 FLORES sentences; the per-language table below gives the exact figure, and any per-language claim should be read against it.
  5. 5.Language identity is contested for some codes. Where a macrolanguage and its varieties both appear, the labels follow the source corpus's choices, which are not neutral and may not match a speaker community's own view.
  6. 6.Tail languages are only 50 of the 479 here. GlotLID covers 2,102 labels, so the population most at risk in this corpus is mid: languages that existing LID knows but that document-level application discards anyway.

Language coverage

codescriptsource sentencessources
aar_LatnLatn57udhr
abk_CyrlCyrl57udhr
ace_ArabArab997flores
ace_LatnLatn1058flores, udhr
acm_ArabArab997flores
acq_ArabArab997flores
acu_LatnLatn180udhr
ada_LatnLatn59udhr
ady_CyrlCyrl56udhr
aeb_ArabArab997flores
afr_LatnLatn1057flores, udhr
agr_LatnLatn57udhr
aii_SyrcSyrc57udhr
ajg_LatnLatn59udhr
ajp_ArabArab997flores
aka_LatnLatn997flores
als_LatnLatn1056flores, udhr
alt_CyrlCyrl51udhr
amc_LatnLatn56udhr
ame_LatnLatn59udhr
amh_EthiEthi1048flores, udhr
ami_LatnLatn58udhr
amr_LatnLatn61udhr
apc_ArabArab997flores
arb_ArabArab1055flores, udhr
arb_LatnLatn997flores
arl_LatnLatn60udhr
arn_LatnLatn58udhr
ars_ArabArab997flores
ary_ArabArab997flores
arz_ArabArab997flores
asm_BengBeng997flores
ast_LatnLatn1055flores, udhr
auc_LatnLatn154udhr
awa_DevaDeva997flores
ayr_LatnLatn1056flores, udhr
azb_ArabArab997flores
azj_CyrlCyrl56udhr
azj_LatnLatn1055flores, udhr
bak_CyrlCyrl997flores
bam_LatnLatn1054flores, udhr
ban_LatnLatn1057flores, udhr
bax_LatnLatn58udhr
bba_LatnLatn58udhr
bci_LatnLatn58udhr
bcl_LatnLatn59udhr
bel_CyrlCyrl1055flores, udhr
bem_LatnLatn1054flores, udhr
ben_BengBeng1055flores, udhr
bfa_LatnLatn42udhr
bho_DevaDeva1053flores, udhr
bin_LatnLatn47udhr
bis_LatnLatn59udhr
bjn_ArabArab997flores
bjn_LatnLatn997flores
blt_TavtTavt55udhr
boa_LatnLatn61udhr
bod_TibtTibt1057flores, udhr
bos_CyrlCyrl59udhr
bos_LatnLatn1056flores, udhr
bre_LatnLatn59udhr
buc_LatnLatn57udhr
bug_LatnLatn1057flores, udhr
bul_CyrlCyrl1055flores, udhr
bum_LatnLatn58udhr
cab_LatnLatn60udhr
cak_LatnLatn57udhr
cat_LatnLatn1055flores, udhr
cbi_LatnLatn62udhr
cbr_LatnLatn60udhr
cbs_LatnLatn43udhr
cbt_LatnLatn57udhr
cbu_LatnLatn57udhr
ccp_CakmCakm62udhr
ceb_LatnLatn1056flores, udhr
ces_LatnLatn1055flores, udhr
cfm_LatnLatn57udhr
cha_LatnLatn57udhr
chj_LatnLatn59udhr
chk_LatnLatn58udhr
chr_CherCher115udhr
chv_CyrlCyrl25udhr
cic_LatnLatn60udhr
cjk_LatnLatn1111flores, udhr
cjs_CyrlCyrl59udhr
cjy_HaniHani58udhr
ckb_ArabArab997flores
cmn_HaniHani363udhr
cnh_LatnLatn58udhr
cni_LatnLatn52udhr
cnr_LatnLatn59udhr
cof_LatnLatn59udhr
cos_LatnLatn59udhr
cot_LatnLatn60udhr
cpu_LatnLatn60udhr
crh_LatnLatn1056flores, udhr
cri_LatnLatn58udhr
crs_LatnLatn58udhr
csa_LatnLatn57udhr
csw_CansCans43udhr
ctd_LatnLatn60udhr
cym_LatnLatn1057flores, udhr
dag_LatnLatn57udhr
dan_LatnLatn1058flores, udhr
ddn_LatnLatn58udhr
deu_LatnLatn1064flores, udhr
dga_LatnLatn59udhr
dik_LatnLatn997flores
dip_LatnLatn57udhr
div_ThaaThaa57udhr
dje_LatnLatn54udhr
duu_LatnLatn57udhr
dyo_LatnLatn55udhr
dyu_LatnLatn1055flores, udhr
dzo_TibtTibt1056flores, udhr
ekk_LatnLatn60udhr
ell_GrekGrek1113flores, udhr
emk_LatnLatn58udhr
eng_LatnLatn1055flores, udhr
epo_LatnLatn1055flores, udhr
ese_LatnLatn35udhr
est_LatnLatn997flores
eus_LatnLatn1056flores, udhr
eve_CyrlCyrl49udhr
evn_CyrlCyrl57udhr
ewe_LatnLatn1056flores, udhr
fao_LatnLatn1054flores, udhr
fat_LatnLatn57udhr
fij_LatnLatn1056flores, udhr
fin_LatnLatn1058flores, udhr
fkv_LatnLatn58udhr
fon_LatnLatn1055flores, udhr
fra_LatnLatn1055flores, udhr
fry_LatnLatn58udhr
fuf_AdlmAdlm58udhr
fuf_LatnLatn58udhr
fur_LatnLatn1056flores, udhr
fuv_LatnLatn1105flores, udhr
fvr_LatnLatn57udhr
gaa_LatnLatn59udhr
gag_LatnLatn59udhr
gan_HaniHani58udhr
gaz_LatnLatn1057flores, udhr
gej_LatnLatn58udhr
gjn_LatnLatn60udhr
gkp_LatnLatn56udhr
gla_LatnLatn1059flores, udhr
gld_CyrlCyrl59udhr
gle_LatnLatn1053flores, udhr
glg_LatnLatn1055flores, udhr
glv_LatnLatn58udhr
grn_LatnLatn997flores
gsw_LatnLatn59udhr
guc_LatnLatn58udhr
gug_LatnLatn49udhr
guj_GujrGujr1055flores, udhr
guk_LatnLatn55udhr
guu_LatnLatn58udhr
gyr_LatnLatn49udhr
hak_HaniHani57udhr
hat_LatnLatn1114flores, udhr
hau_LatnLatn1152flores, udhr
haw_LatnLatn58udhr
hea_LatnLatn58udhr
heb_HebrHebr1055flores, udhr
hil_LatnLatn58udhr
hin_DevaDeva1057flores, udhr
hlt_LatnLatn55udhr
hms_LatnLatn59udhr
hne_DevaDeva997flores
hni_LatnLatn57udhr
hnj_LatnLatn58udhr
hns_LatnLatn59udhr
hrv_LatnLatn1055flores, udhr
hsb_LatnLatn59udhr
hsn_HaniHani58udhr
hun_LatnLatn1056flores, udhr
hus_LatnLatn175udhr
huu_LatnLatn58udhr
hye_ArmnArmn1068flores, udhr
ibb_LatnLatn67udhr
ibo_LatnLatn1055flores, udhr
ido_LatnLatn55udhr
idu_LatnLatn51udhr
iii_YiiiYiii57udhr
ijs_LatnLatn50udhr
ike_CansCans44udhr
ilo_LatnLatn1055flores, udhr
ina_LatnLatn58udhr
ind_LatnLatn1057flores, udhr
isl_LatnLatn1055flores, udhr
ita_LatnLatn1055flores, udhr
jav_JavaJava62udhr
jav_LatnLatn1057flores, udhr
jiv_LatnLatn60udhr
jpn_JpanJpan1140flores, udhr
kaa_CyrlCyrl58udhr
kab_LatnLatn1055flores, udhr
kac_LatnLatn997flores
kal_LatnLatn58udhr
kam_LatnLatn997flores
kan_KndaKnda1055flores, udhr
kas_ArabArab997flores
kas_DevaDeva997flores
kat_GeorGeor1055flores, udhr
kaz_CyrlCyrl1055flores, udhr
kbd_CyrlCyrl55udhr
kbp_LatnLatn1056flores, udhr
kbr_LatnLatn59udhr
kde_LatnLatn51udhr
kdh_LatnLatn59udhr
kea_LatnLatn1055flores, udhr
kek_LatnLatn57udhr
kha_LatnLatn58udhr
khk_CyrlCyrl1054flores, udhr
khm_KhmrKhmr1056flores, udhr
kik_LatnLatn997flores
kin_LatnLatn1056flores, udhr
kir_CyrlCyrl1055flores, udhr
kjh_CyrlCyrl57udhr
kkh_LanaLana51udhr
kmb_LatnLatn1113flores, udhr
kmr_LatnLatn1055flores, udhr
knc_ArabArab997flores
knc_LatnLatn1061flores, udhr
kng_LatnLatn115udhr
koi_CyrlCyrl57udhr
kon_LatnLatn997flores
koo_LatnLatn54udhr
kor_HangHang1055flores, udhr
kqn_LatnLatn59udhr
kqs_LatnLatn58udhr
kri_LatnLatn58udhr
krl_LatnLatn183udhr
ktu_LatnLatn118udhr
kwi_LatnLatn145udhr
lad_LatnLatn58udhr
lao_LaooLaoo1054flores, udhr
lat_LatnLatn118udhr
lia_LatnLatn45udhr
lij_LatnLatn1055flores, udhr
lim_LatnLatn997flores
lin_LatnLatn1107flores, udhr
lit_LatnLatn1055flores, udhr
lld_LatnLatn59udhr
lmo_LatnLatn997flores
lns_LatnLatn57udhr
lob_LatnLatn58udhr
lot_LatnLatn140udhr
loz_LatnLatn58udhr
ltg_LatnLatn997flores
ltz_LatnLatn1056flores, udhr
lua_LatnLatn1055flores, udhr
lue_LatnLatn58udhr
lug_LatnLatn1046flores, udhr
lun_LatnLatn56udhr
luo_LatnLatn997flores
lus_LatnLatn1055flores, udhr
lvs_LatnLatn1112flores, udhr
mad_LatnLatn60udhr
mag_DevaDeva1050flores, udhr
mah_LatnLatn58udhr
mai_DevaDeva1055flores, udhr
mal_MlymMlym1097flores, udhr
mam_LatnLatn58udhr
mar_DevaDeva1056flores, udhr
maz_LatnLatn59udhr
mcd_LatnLatn60udhr
mcf_LatnLatn62udhr
men_LatnLatn59udhr
mfq_LatnLatn58udhr
mic_LatnLatn59udhr
min_ArabArab997flores
min_LatnLatn1056flores, udhr
miq_LatnLatn51udhr
mkd_CyrlCyrl1055flores, udhr
mlt_LatnLatn1056flores, udhr
mni_BengBeng997flores
mnw_MymrMymr56udhr
mor_LatnLatn59udhr
mos_LatnLatn1053flores, udhr
mri_LatnLatn1054flores, udhr
mto_LatnLatn51udhr
mxi_LatnLatn58udhr
mxv_LatnLatn58udhr
mya_MymrMymr1053flores, udhr
mzi_LatnLatn58udhr
nan_HaniHani58udhr
nav_LatnLatn59udhr
nba_LatnLatn59udhr
nbl_LatnLatn58udhr
ndo_LatnLatn58udhr
nds_LatnLatn58udhr
nhn_LatnLatn58udhr
nio_CyrlCyrl51udhr
niu_LatnLatn58udhr
niv_CyrlCyrl56udhr
njo_LatnLatn64udhr
nku_LatnLatn52udhr
nld_LatnLatn1055flores, udhr
nno_LatnLatn1055flores, udhr
nob_LatnLatn1059flores, udhr
not_LatnLatn59udhr
npi_DevaDeva1052flores, udhr
nso_LatnLatn1055flores, udhr
nus_LatnLatn997flores
nya_LatnLatn1113flores, udhr
nym_LatnLatn49udhr
nyn_LatnLatn50udhr
nzi_LatnLatn59udhr
oaa_CyrlCyrl58udhr
oci_LatnLatn1395flores, udhr
ojb_CansCans44udhr
oki_LatnLatn59udhr
orh_LatnLatn59udhr
ory_OryaOrya997flores
oss_CyrlCyrl44udhr
ote_LatnLatn59udhr
pag_LatnLatn997flores
pam_LatnLatn66udhr
pan_GuruGuru1055flores, udhr
pap_LatnLatn1055flores, udhr
pau_LatnLatn57udhr
pbb_LatnLatn56udhr
pbt_ArabArab997flores
pbu_ArabArab59udhr
pcd_LatnLatn58udhr
pcm_LatnLatn56udhr
pes_ArabArab1055flores, udhr
pis_LatnLatn57udhr
piu_LatnLatn57udhr
plt_LatnLatn1050flores, udhr
pnb_ArabArab61udhr
pol_LatnLatn1056flores, udhr
pon_LatnLatn57udhr
por_LatnLatn1112flores, udhr
pov_LatnLatn115udhr
ppl_LatnLatn59udhr
prs_ArabArab1053flores, udhr
quc_LatnLatn58udhr
que_LatnLatn58udhr
qug_LatnLatn182udhr
quh_LatnLatn57udhr
quy_LatnLatn1057flores, udhr
quz_LatnLatn57udhr
qva_LatnLatn59udhr
qvc_LatnLatn58udhr
qvh_LatnLatn58udhr
qvm_LatnLatn60udhr
qvn_LatnLatn57udhr
qwh_LatnLatn59udhr
qxn_LatnLatn57udhr
qxu_LatnLatn54udhr
rar_LatnLatn59udhr
rgn_LatnLatn58udhr
rmn_LatnLatn116udhr
roh_LatnLatn399udhr
ron_LatnLatn1094flores, udhr
run_LatnLatn1055flores, udhr
rup_LatnLatn57udhr
rus_CyrlCyrl1055flores, udhr
sag_LatnLatn1056flores, udhr
sah_CyrlCyrl57udhr
san_DevaDeva1052flores, udhr
san_GranGran51udhr
sat_OlckOlck997flores
scn_LatnLatn997flores
sco_LatnLatn58udhr
sey_LatnLatn61udhr
shk_LatnLatn55udhr
shn_MymrMymr1053flores, udhr
shp_LatnLatn62udhr
sid_LatnLatn57udhr
sin_SinhSinh1056flores, udhr
skr_ArabArab63udhr
slk_LatnLatn1053flores, udhr
slr_LatnLatn58udhr
slv_LatnLatn1056flores, udhr
sme_LatnLatn58udhr
smo_LatnLatn1060flores, udhr
sna_LatnLatn1057flores, udhr
snd_ArabArab997flores
snk_LatnLatn58udhr
snn_LatnLatn136udhr
som_LatnLatn1054flores, udhr
sot_LatnLatn1054flores, udhr
spa_LatnLatn1075flores, udhr
src_LatnLatn59udhr
srd_LatnLatn997flores
srp_CyrlCyrl1056flores, udhr
srp_LatnLatn59udhr
srr_LatnLatn58udhr
ssw_LatnLatn1057flores, udhr
suk_LatnLatn58udhr
sun_LatnLatn1063flores, udhr
sus_LatnLatn58udhr
swb_LatnLatn58udhr
swe_LatnLatn1058flores, udhr
swh_LatnLatn1055flores, udhr
szl_LatnLatn997flores
tah_LatnLatn57udhr
tam_TamlTaml1066flores, udhr
taq_LatnLatn997flores
taq_TfngTfng997flores
tat_CyrlCyrl1054flores, udhr
tbz_LatnLatn60udhr
tca_LatnLatn60udhr
tdt_LatnLatn57udhr
tel_TeluTelu1055flores, udhr
tem_LatnLatn55udhr
tet_LatnLatn58udhr
tgk_CyrlCyrl1054flores, udhr
tgl_LatnLatn1057flores, udhr
tha_ThaiThai1111flores, udhr
tir_EthiEthi1055flores, udhr
tiv_LatnLatn67udhr
tly_LatnLatn59udhr
tob_LatnLatn59udhr
toi_LatnLatn57udhr
toj_LatnLatn57udhr
ton_LatnLatn60udhr
top_LatnLatn59udhr
tpi_LatnLatn1055flores, udhr
tsn_LatnLatn1055flores, udhr
tso_LatnLatn1111flores, udhr
tsz_LatnLatn59udhr
tuk_CyrlCyrl57udhr
tuk_LatnLatn1056flores, udhr
tum_LatnLatn997flores
tur_LatnLatn1056flores, udhr
twi_LatnLatn1113flores, udhr
tyv_CyrlCyrl58udhr
tzh_LatnLatn25udhr
tzm_TfngTfng998flores, udhr
tzo_LatnLatn58udhr
udu_LatnLatn60udhr
uig_ArabArab1055flores, udhr
uig_LatnLatn59udhr
ukr_CyrlCyrl1055flores, udhr
umb_LatnLatn1104flores, udhr
ura_LatnLatn56udhr
urd_ArabArab1105flores, udhr
uzn_CyrlCyrl58udhr
uzn_LatnLatn1055flores, udhr
vai_VaiiVaii61udhr
vec_LatnLatn1055flores, udhr
ven_LatnLatn89udhr
vep_LatnLatn58udhr
vie_LatnLatn1057flores, udhr
vmw_LatnLatn58udhr
war_LatnLatn1057flores, udhr
wln_LatnLatn59udhr
wol_LatnLatn1057flores, udhr
wuu_HaniHani58udhr
wwa_LatnLatn39udhr
xho_LatnLatn1055flores, udhr
xsm_LatnLatn59udhr
yad_LatnLatn55udhr
yao_LatnLatn52udhr
yap_LatnLatn58udhr
ydd_HebrHebr1056flores, udhr
ykg_CyrlCyrl51udhr
yor_LatnLatn1054flores, udhr
yrk_CyrlCyrl55udhr
yua_LatnLatn59udhr
yue_HaniHani59udhr
yue_HantHant997flores
zam_LatnLatn60udhr
zdj_LatnLatn50udhr
zgh_TfngTfng61udhr
zho_HansHans997flores
zho_HantHant997flores
zlm_ArabArab24udhr
zlm_LatnLatn58udhr
zro_LatnLatn56udhr
zsm_LatnLatn997flores
ztu_LatnLatn58udhr
zul_LatnLatn1055flores, udhr
zyb_LatnLatn57udhr

Links

  • —Code: <https://github.com/NagaYu/tessera>
  • —Model: <https://huggingface.co/NagaYu/tessera-span-lid>
  • —Demo (runs in your browser): <https://huggingface.co/spaces/NagaYu/tessera>

Citation

Built with Tessera -- span-level multi-label language identification. Repository: NagaYu/tessera-mixed-pages.