Non-autoregressive System 1 decision engine. Typed choice, score and yes/no decisions over any text in a single forward pass, in 100+ languages, with a router that picks the right checkpoint per request.
Python calibrationclassificationdecision-modelhuggingfacejevmodernbertmultilingualnlppythonpytorchroutingtyped-decisionszero-shot
Merge main into this branch and resolve conflicts
Nandakishor01340931dfe9
diff --cc laya-ts/tests/lang.test.tsindex 5a1f8653,731b6985..342eabab--- a/laya-ts/tests/lang.test.ts+++ b/laya-ts/tests/lang.test.ts@@@ -69,15 -85,17 +85,29 @@@ describe("lang", () =>expect(analyse("que hora es en australia").language).toBe("es");expect(analyse("baisse le volume du haut-parleur").language).toBe("fr");});+ it.each<[string, string | null, boolean]>([+ ["Preciso do contrato confidencial assinado até sexta.", "pt", false],+ ["Gătește-mi o rețetă de sarmale de post pentru mâine.", "ro", false],+ ["Müşteriden iki kez ücret alındı ve para iadesi istiyor", null, false],+ ["Khách hàng đã bị thu phí hai lần và muốn được hoàn tiền ngay", null, false],+ ])("counts accented words whole, like Python: %s", (text, language, english) => {+ const a = analyse(text);+ expect(a.language).toBe(language);+ expect(a.isEnglish).toBe(english);+ expect(a.languageUndecided).toBe(language === null);+ });+++ it("does not let English sibling fields hide a German value", () => {+ const sentence = "Mein Konto wurde zweimal belastet";+ const asString = analyse(sentence);+ expect(asString.language).toBe("de");+ expect(asString.isEnglish).toBe(false);+ expect(analyse({ message: sentence }).language).toBe(asString.language);+ const buried = analyse({+ agent_notes: "Please check the shipping status and refund the customer if the charge was duplicated. The order was late and we have not heard back.",+ message: sentence,+ });+ expect(buried.isEnglish).toBe(false);+ expect(buried.language).toBe("de");+ });});