Route messages to the right language experience.
Experiment with choosing a language-specific interface from a full sentence. Always let the user override the suggestion.
Build with LiltA small first step toward understanding. Identify eight languages, directly on the device.
Lilt looks for short character patterns associated with eight languages. Give it a sentence and it ranks the supported languages, without sending the sentence to a server. It identifies language; it does not translate or generate text.
Research v0.1.0 · A statistical classifier, not a generative foundation model.
Lowercase the sentence, normalize whitespace, and extract character pairs and triples.
Sum learned log-likelihoods for vocabulary features, using add-one smoothing and equal class priors.
Return the highest-scoring language and normalized scores. No known features produces Unknown.
Actual model inference, inside your browser.
No input is uploaded.
Scores are relative model outputs, not calibrated confidence.
Starting points for prototypes.
Validate the model for your use case.
Experiment with choosing a language-specific interface from a full sentence. Always let the user override the suggestion.
Build with LiltGroup a small personal notebook by language and inspect mistakes before applying tags.
Build with LiltExplore a cheap first-stage router before a larger model, with an explicit fallback for unsupported languages.
Build with Lilt80 sentences authored by the coding assistant inside the training script: ten in each of eight languages. These follow similar everyday themes and are not a collected multilingual corpus. No external dataset or pretrained weights were used.
The first eight sentences per language train the classifier; the last two are held out. This is a fixed split of closely related examples, with no independent author or domain separation.
No third-party model weights, external datasets, or user inputs were used to train this version. Training records are kept private. We publish weights, model cards, aggregate results, and the limitations of each release.
Multinomial naïve Bayes · character pairs and triples
Each release includes its model card, measured artifact size, and SHA-256 checksum. Training data and working checkpoints stay private.
Use the local workspace packages today. These packages have not been published to npm or Maven Central.
Run from the repository root, then import the model from a workspace example.
bun install
bun run sdk:buildWith JDK 17+ and Gradle 8.10+, publish the modules to your local Maven repository.
gradle test
gradle publishToMavenLocalrepositories {
mavenLocal()
mavenCentral()
}
dependencies {
implementation("dev.embermote:lilt:0.1.0")
}Kotlin/JVM tests pass. Android device validation, Swift, and native Core ML/LiteRT adapters are not available.
import { createModel } from '@embermote/lilt';
const model = createModel();
const input = "Les enfants jouent près de la maison.";
const result = model.predict(input);
console.log(result.label);
// Scores are not calibrated confidence.6ed25e6ad7de36bcdce12b99c2a11bffd43a58e891c7f6595e9eaf6cf1d770d4No. It ranks only the eight supported languages. Unknown means no vocabulary overlap; it is not a reliable detector for every unsupported language.
Inference runs locally. The website and artifact download make ordinary network requests, but the demos do not upload your input. Bundled SDK inference does not need an inference server.
Lilt stores a compact statistical representation for a narrow task. Its 146.5 KB artifact is not equivalent to a neural model of a different size, and the file size is not its total runtime memory.
This is a research baseline. Independent evaluation, task-specific acceptance criteria, real-device measurements, and release packaging remain necessary before production use.
Inspect the pieces behind this model.