phanpy-cz/assets/tinyld-light-PxOyhYWY.js

3 lines
67 KiB
JavaScript
Raw Permalink Normal View History

2024-06-23 10:39:24 +00:00
var b={TINYLD_CONFIG:"light"},f=/[,.。,、#%&/\\+*¡!¿?[\];:…„“«»”"“_—~]/gi,k=/[0-9]/g,y=/[\uFF10-\uFF19]/g,v=/\s\s+/g,z=//gi,E=/[\u0300-\u036f]/g;function p(e){return typeof e=="string"||e instanceof String}function S(e){return e.toLowerCase().replace(z,"'").replace(f," ").replace(y,a=>String.fromCharCode(a.charCodeAt(0)-65248)).replace(k,"").replace(v," ").trim()}function P(e){return e.normalize("NFD").replace(E,"")}var u={light:{TRAINING_UNIQUE_GRAMS:[1,2,3,4],TOP_LANGUAGE_UNIQUE_GRAMS:60,TOP_LANGUAGE_STATS_GRAMS:50},normal:{TRAINING_UNIQUE_GRAMS:[1,2,3,4,5],TOP_LANGUAGE_UNIQUE_GRAMS:100,TOP_LANGUAGE_STATS_GRAMS:180},heavy:{TRAINING_UNIQUE_GRAMS:[1,2,3,4,5],TOP_LANGUAGE_UNIQUE_GRAMS:320,TOP_LANGUAGE_STATS_GRAMS:1024}},G=b.TINYLD_CONFIG||"normal",H=u[G].TRAINING_UNIQUE_GRAMS,W=u[G].TOP_LANGUAGE_UNIQUE_GRAMS,Y=u[G].TOP_LANGUAGE_STATS_GRAMS,m=1e4;function g(e){return Math.round(e*m)/m}var N=e=>{let a={only:[],verbose:!1};return e?Object.assign(a,e):a},c={afr:{code:"af",region:"africa",name:"Afrikaans",skipLight:!0},amh:{code:"am",region:"africa",name:"Amharic",skipLight:!0,coefProb:0},ber:{code:"ber",region:"africa",name:"Berber",skipLight:!0,coefProb:.25},run:{code:"rn",region:"africa",name:"Kirundi",skipLight:!0},jpn:{code:"ja",region:"asia-east",name:"Japanese",alias:["jp"],coefProb:0},cmn:{code:"zh",region:"asia-east",name:"Chinese",alias:["cn"],coefProb:.25},kor:{code:"ko",region:"asia-east",name:"Korean",alias:["kr"],coefProb:0},mya:{code:"my",region:"asia",name:"Burmese",skipLight:!0,coefProb:0},tha:{code:"th",region:"asia",name:"Thai",coefProb:0},vie:{code:"vi",region:"asia",name:"Vietnamese",skipLight:!0,coefProb:0},ind:{code:"id",region:"asia",name:"Indonesian",skipLight:!0},khm:{code:"km",region:"asia",name:"Khmer",skipLight:!0,coefProb:0},tgl:{code:"tl",region:"asia",name:"Tagalog",skipLight:!0},ben:{code:"bn",region:"asia-south",name:"Bengali",coefProb:0},tam:{code:"ta",region:"asia-south",name:"Tamil",skipLight:!0,coefProb:0},hin:{code:"hi",region:"asia-south",name:"Hindi",coefProb:0},urd:{code:"ur",region:"asia-south",name:"Urdu",skipLight:!0,coefProb:0},guj:{code:"gu",region:"asia-south",name:"Gujarati",skipLight:!0,coefProb:0},kan:{code:"kn",region:"asia-south",name:"Kannada",skipLight:!0,coefProb:0},tel:{code:"te",region:"asia-south",name:"Telugu",skipLight:!0,coefProb:0},fra:{code:"fr",region:"europe-west",name:"French"},eng:{code:"en",region:"europe-west",name:"English",alias:["us","gb"]},deu:{code:"de",region:"europe-west",name:"German",coefProb:.5},spa:{code:"es",region:"europe-west",name:"Spanish"},por:{code:"pt",region:"europe-west",name:"Portuguese",alias:["po"]},ita:{code:"it",region:"europe-west",name:"Italian"},nld:{code:"nl",region:"europe-west",name:"Dutch"},gle:{code:"ga",region:"europe-west",name:"Irish",skipLight:!0},lat:{code:"la",region:"europe",name:"Latin",skipLight:!0},ces:{code:"cs",region:"europe",name:"Czech",skipLight:!0},srp:{code:"sr",region:"europe",name:"Serbian",skipLight:!0},ell:{code:"el",region:"europe",name:"Greek",alias:["gr"],coefProb:0},mkd:{code:"mk",region:"europe",name:"Macedonian",skipLight:!0,coefProb:1.5},slk:{code:"sk",region:"europe",name:"Slovak",skipLight:!0},dan:{code:"da",region:"europe-north",name:"Danish",skipLight:!0,coefProb:1.5},swe:{code:"sv",region:"europe-north",name:"Swedish"},fin:{code:"fi",region:"europe-north",name:"Finnish"},nob:{code:"no",region:"europe-north",name:"Norwegian",coefProb:1.5},isl:{code:"is",region:"europe-north",name:"Icelandic",skipLight:!0,coefProb:.5},hun:{code:"hu",region:"europe-east",name:"Hungarian"},ron:{code:"ro",region:"europe-east",name:"Romanian",coefProb:.5},bul:{code:"bg",region:"europe-east",name:"Bulgarian",skipLight:!0},bel:{code:"be",region:"europe-east",name:"Belarusian",skipLight:!0},rus:{code:"ru",region:"europe-east",name:"Russian"},ukr:{code:"uk",region:"europe-east",name:"Ukrainian",skipLight:!0},pol:{code:"pl",region:"europe-east",name:"Polish",coefProb:.5},lit:{code:"lt",region:"europe-east",name:"Lithuanian",skipLight:!0},est:{code:"et",region:"europe-east",name:"Estonia
//# sourceMappingURL=tinyld-light-PxOyhYWY.js.map