1. Live 66-Class Form Field Classifier
Pick a form field signature, edit any HTML attribute below, or drop an .html / .txt input snippet:
–
Top-k Softmax Probabilities & Raw Logits
66-class softmax · BertForSequenceClassificationDownload or initialise the local model above, then classify a form field signature.
rolf-mozilla/tinybert-address-autofill
2. See Inside — 66-Class Raw Logit Telemetry & WordPiece Tokens
Inspect the exact [1, 66] raw classifier logits produced before softmax alongside the uncased
WordPiece tokens fed into ONNX Runtime. Notice that config.json maps Mozilla's 1-indexed labels
1 (other) through 65 (reference-point), while index
0 stays an unassigned negative-logit padding slot.
All 66 Raw Classifier Logits
min / max / slot-0WordPiece Tokenization
BertTokenizer · 30,522 vocabClassify a field above to inspect uncased WordPiece tokens.
3. Why On-Device Autofill Classification Matters
- Private by design: Form DOM inspection happens 100% locally in a Web Worker — zero page markup, customer labels, or input structures ever leave the device.
-
Beyond brittle regexes: Replaces hard-coded multilingual regular expressions with a 15.32 MB
TinyBERT classifier that generalizes across camelCase names, German/Spanish/French labels, and missing
autocompleteattributes (0.8897 strict / 0.9133 close offline accuracy on Firefox's benchmark). -
Conservative false-fill posture: When inputs lack clear semantic cues (such as hashed React IDs
or promo-code boxes), the model abstains to
otherrather than leaking personal data into the wrong field.
Use-Case Ladder
4. How the API Works & Code Inspection
import { AutoModelForSequenceClassification, AutoTokenizer } from "@huggingface/transformers";
const tokenizer = await AutoTokenizer.from_pretrained("rolf-mozilla/tinybert-address-autofill");
const classifier = await AutoModelForSequenceClassification.from_pretrained(
"rolf-mozilla/tinybert-address-autofill",
{ device: "wasm", dtype: "q8" },
);
// Normalized Firefox v0.2.2 field signature (no ** type marker; camelCase split & lowercased)
const encoded = await tokenizer("shipping zip postal code 02138 zip postal code", {
padding: false,
truncation: true,
max_length: 512,
});
const { logits } = await classifier(encoded); // Float32Array(66) -> softmax + id2label[String(idx)]