Tongue
Identificazione della lingua sul dispositivo che, da poche parole, sceglie tra 84 lingue, in decine di microsecondi.

Demo
Riconosce la lingua da 3 parole.
«kann ich das haben» è tedesco. «안녕하세요» è coreano. Tre parole sono il caso difficile, e tre parole sono quelle che ti dà un campo di ricerca.
Da tre parole Tongue arriva a 0,933 dove un rilevatore da 293 MB si ferma a 0,887. Tongue pesa 2 MB e lavora in due fasi: alcune scritture appartengono a una lingua sola, l'hangul è coreano e il thai è thai, deciso senza modello. Il resto passa al modello.
Tongue non ha bisogno di tokenizer, file di vocabolario o runtime di inferenza, ed è così che l'intero pacchetto sta in 2 MB. Quando l'input è troppo breve per decidere, Tongue segnala un pareggio.
0,933 da un modello da 2 MB.
Con 2 MB Tongue segna 0,933 su input FLORES-200 di tre parole, contro 0,887 di un rilevatore da 293 MB.
Misurato sui pesi int8 rilasciati, su tre benchmark pubblici, con gli altri rilevatori eseguiti sulle stesse righe e sugli stessi sottoinsiemi di lingue. Tabelle complete e modalità di errore sulla scheda del modello.
Casi d'uso
Riconosce la lingua da 3 parole.
Instradare il testo per lingua
Scegliere il modello di traduzione, l'analizzatore o la coda di supporto giusti dalle prime parole digitate, interamente sul dispositivo.
Tastiere e input
Rilevare la lingua a metà frase per cambiare correzione automatica, suggerimenti o layout, al costo di decine di microsecondi per battuta.
Ricerca e pipeline di contenuti
Etichettare stringhe brevi con la lingua prima dell'indicizzazione o della moderazione, senza round-trip di rete né un servizio per richiesta.
Chiedi altro testo invece di indovinare
«la casa» è italiano e spagnolo allo stesso modo. Tongue segnala il pareggio invece di sceglierne una, così il prodotto può aspettare un'altra parola anziché cambiare tastiera per sbaglio.
Ispirazione
Idee da costruire con Tongue. Copia un prompt nel tuo coding agent e parti.
Route incoming messages to the right language agent.
Use Desert Ant's Tongue to identify the language of an incoming message from a few words, on-device, and route it to the right support queue, model, or translation path. Build it with the Desert Ant SDK. Tongue (Swift, Kotlin, JavaScript / TypeScript). Install and API: https://desertant.com/docs/tongue/. Install: SwiftPM desert-ant-core; Maven ai.desertant:tongue:3.1.0; npm i @desert-ant-labs/tongue. SDK source: https://github.com/Desert-Ant-Labs/desert-ant-core. Machine-readable catalog of every model and SDK: https://desertant.com/llms.txt.
Auto-switch the keyboard and spellcheck to the language being typed.
In a text field, run Desert Ant's Tongue on the first words to detect the language and switch keyboard, spellcheck, and autocorrect to match, in microseconds, on-device. Build it with the Desert Ant SDK. Tongue (Swift, Kotlin, JavaScript / TypeScript). Install and API: https://desertant.com/docs/tongue/. Install: SwiftPM desert-ant-core; Maven ai.desertant:tongue:3.1.0; npm i @desert-ant-labs/tongue. SDK source: https://github.com/Desert-Ant-Labs/desert-ant-core. Machine-readable catalog of every model and SDK: https://desertant.com/llms.txt.
Tag user posts by language for search and moderation.
Use Desert Ant's Tongue to label each user post with its language on-device, so search, ranking, and moderation can branch by language without a server call. Build it with the Desert Ant SDK. Tongue (Swift, Kotlin, JavaScript / TypeScript). Install and API: https://desertant.com/docs/tongue/. Install: SwiftPM desert-ant-core; Maven ai.desertant:tongue:3.1.0; npm i @desert-ant-labs/tongue. SDK source: https://github.com/Desert-Ant-Labs/desert-ant-core. Machine-readable catalog of every model and SDK: https://desertant.com/llms.txt.
Detect the language, then redact PII in that language.
Run Desert Ant's Tongue to detect a message's language, then Redact to strip PII with the right language coverage, both on-device. Build it with the Desert Ant SDK. Tongue (Swift, Kotlin, JavaScript / TypeScript). Install and API: https://desertant.com/docs/tongue/. Redact (Swift, Kotlin, JavaScript / TypeScript). Install and API: https://desertant.com/docs/redact/. SDK source: https://github.com/Desert-Ant-Labs/desert-ant-core. Machine-readable catalog of every model and SDK: https://desertant.com/llms.txt.
Detect the language of a search query and pick the right index.
Run Desert Ant's Tongue on a search query on-device to route it to the right language index or analyzer, in microseconds. Build it with the Desert Ant SDK. Tongue (Swift, Kotlin, JavaScript / TypeScript). Install and API: https://desertant.com/docs/tongue/. Install: SwiftPM desert-ant-core; Maven ai.desertant:tongue:3.1.0; npm i @desert-ant-labs/tongue. SDK source: https://github.com/Desert-Ant-Labs/desert-ant-core. Machine-readable catalog of every model and SDK: https://desertant.com/llms.txt.
Build an OpenClaw skill that tags and language-routes text.
Write an OpenClaw skill that runs Desert Ant's Tongue to detect a text's language and Gist to tag its topics, on-device, so an agent can route content without a server call. Build it with the Desert Ant SDK. Tongue (Swift, Kotlin, JavaScript / TypeScript). Install and API: https://desertant.com/docs/tongue/. Gist (Swift, Kotlin, JavaScript / TypeScript). Install and API: https://desertant.com/docs/gist/. SDK source: https://github.com/Desert-Ant-Labs/desert-ant-core. Machine-readable catalog of every model and SDK: https://desertant.com/llms.txt.
A chat bot that tags and language-routes messages, in Node.
Build a Slack or Discord bot that runs Desert Ant's Tongue and Gist in Node to detect each message's language and topic and route it, with no third-party classification service. Build it with the Desert Ant SDK. Tongue (Swift, Kotlin, JavaScript / TypeScript). Install and API: https://desertant.com/docs/tongue/. Gist (Swift, Kotlin, JavaScript / TypeScript). Install and API: https://desertant.com/docs/gist/. SDK source: https://github.com/Desert-Ant-Labs/desert-ant-core. Machine-readable catalog of every model and SDK: https://desertant.com/llms.txt.
Build an agent skill that tags and language-routes text for an agent.
Write a SKILL.md agent skill that runs Desert Ant's Tongue to detect a text's language and Gist to tag its topics, on-device, so the agent can route or filter content without a server call. Build it with the Desert Ant SDK. Tongue (Swift, Kotlin, JavaScript / TypeScript). Install and API: https://desertant.com/docs/tongue/. Gist (Swift, Kotlin, JavaScript / TypeScript). Install and API: https://desertant.com/docs/gist/. SDK source: https://github.com/Desert-Ant-Labs/desert-ant-core. Machine-readable catalog of every model and SDK: https://desertant.com/llms.txt.
Cosa fa il modello
- 84 lingue: 59 decodificate dal modello, 25 risolte dalla sola scrittura.
- Pesi int8 da 2 MB, inclusi nel pacchetto; non viene scaricato nulla.
- Decine di microsecondi per rilevamento, sul thread principale.
- Risposte identiche su Swift, Kotlin e JavaScript, vincolate a golden vectors condivisi.
- Restituisce un punteggio di affidabilità e segnala ogni pareggio.
Per iniziare
Aggiungi identificazione della lingua alla tua app iOS or macOS, Android or web in poche righe di codice. Documentazione di Tongue.
// Swift Package Manager
.package(url: "https://github.com/Desert-Ant-Labs/desert-ant-core", from: "3.1.0")
// target dependency
.product(name: "Tongue", package: "desert-ant-core")
import Tongue
let tongue = try Tongue()
tongue.detect("kann ich das haben").language
// "de"
Add Tongue from Desert Ant Labs to this Swift project (iOS, macOS). What it does: identificazione della lingua on-device. SDK: Swift (iOS, macOS) Repo: https://github.com/Desert-Ant-Labs/desert-ant-core#readme // Swift Package Manager .package(url: "https://github.com/Desert-Ant-Labs/desert-ant-core", from: "3.1.0") // target dependency .product(name: "Tongue", package: "desert-ant-core") Reference: - Model page: https://desertant.com/models/tongue/ - Full catalog and other models: https://desertant.com/llms.txt Add the SDK, then follow its README for the exact API and current version. Do not invent API names or method signatures; confirm them against the README.
// build.gradle.kts (Maven Central)
implementation("ai.desertant:tongue:3.1.0")
import ai.desertant.tongue.Tongue
val tongue = Tongue.bundled(context)
tongue.detect("kann ich das haben").language
// "de"
Add Tongue from Desert Ant Labs to this Kotlin project (Android).
What it does: identificazione della lingua on-device.
SDK:
Kotlin (Android)
Repo: https://github.com/Desert-Ant-Labs/desert-ant-core#readme
// build.gradle.kts (Maven Central)
implementation("ai.desertant:tongue:3.1.0")
Reference:
- Model page: https://desertant.com/models/tongue/
- Full catalog and other models: https://desertant.com/llms.txt
Add the SDK, then follow its README for the exact API and current version. Do not invent API names or method signatures; confirm them against the README.
npm i @desert-ant-labs/tongue
import { Tongue } from "@desert-ant-labs/tongue";
const tongue = await Tongue.load();
tongue.detect("kann ich das haben").language;
// "de"
Add Tongue from Desert Ant Labs to this JavaScript / TypeScript project (Web, Node.js). What it does: identificazione della lingua on-device. SDK: JavaScript / TypeScript (Web, Node.js) Repo: https://github.com/Desert-Ant-Labs/desert-ant-core#readme npm i @desert-ant-labs/tongue Reference: - Model page: https://desertant.com/models/tongue/ - Full catalog and other models: https://desertant.com/llms.txt Add the SDK, then follow its README for the exact API and current version. Do not invent API names or method signatures; confirm them against the README.
Specifiche
- Lingue
- 84, su 31 scritture
- Dimensione sul dispositivo
- Pesi int8 da 2 MB, dentro il pacchetto
- Velocità
- Decine di microsecondi per rilevamento
- Modello
- Router degli script più n-grammi di caratteri con hash verso una testa lineare int8
Con una o due parole spesso non si può davvero decidere, e nessuna dimensione del modello lo risolve. Tongue segnala un pareggio o una risposta provvisoria, quindi tratta un'affidabilità bassa come «sconosciuto», non come una risposta.
Malese e indonesiano condividono troppo lessico per essere distinti su un campione breve. Il mongolo è coperto solo nella scrittura tradizionale, quindi il mongolo in cirillico viene letto come russo.
Nomi di marca, numeri e codice non sono una lingua, e su questi Tongue tira comunque a indovinare.
FAQ
Cos'è Tongue?
Identificazione della lingua sul dispositivo che, da poche parole, sceglie tra 84 lingue, in decine di microsecondi.
Tongue funziona sul dispositivo?
Sì. Tongue funziona sul dispositivo, senza chiamate a un server, quindi i dati restano con l'utente.
Quali piattaforme supporta Tongue?
Tongue è distribuito come SDK nativo on-device per Swift, Kotlin, JavaScript / TypeScript.
Quanto costa Tongue?
Ogni modello è gratuito fino a 100k dispositivi attivi mensili per SDK. Inferenza illimitata per utente. Contattaci per licenze personalizzate.
Quanto è preciso o veloce Tongue?
Con 2 MB Tongue segna 0,933 su input FLORES-200 di tre parole, contro 0,887 di un rilevatore da 293 MB.