yes / no / unknown classifier for short user replies, distilled from Claude Sonnet 4.6 into a multilingual MiniLM-L12. 2 ms on CPU, 24-113 MB, no API call needed.1from forsurellm import classify
2
3classify("carrément") # ("yes", 0.97)
4classify("laisse tomber") # ("no", 0.98)
5classify("je sais pas trop") # ("unknown", 0.96)
6classify("oui mais non") # ("unknown", 0.92)
7classify("yeah right") # ("no", 0.87) # sarcasm detected
8classify("+1") # ("yes", 1.00) # symbolic preprocessor
9classify("👍") # ("yes", 1.00)| Metric | Value |
|---|---|
| Adversarial accuracy (124 trap phrases, 22 categories) | 95.2 % |
| Surface-variant robustness (1227 variants) | 95.8 % |
| Test set accuracy (1178 phrases) | 91.7 % |
| Calibration ECE | 0.012 |
| CPU latency p50 | 1.8 ms |
| ONNX int8 size | 113 MB (multilingual) · 24 MB (FR+EN pruned variant) |
| Classifier | Accuracy | p50 latency | API cost |
|---|---|---|---|
| ForSureLLM | 95.2 % | 1.8 ms | 0 |
| Haiku 4.5 zero-shot | 75.0 % | 602 ms | $$ |
| Cosine MiniLM-L12 (no fine-tune) | 67.7 % | 8 ms | 0 |
modern_slang (Gen-Z): no cap, bet, say less, deadass — 100 % vs 43 %negated_verb: I wouldn't say no, ce n'est pas un non — 83 % vs 17 %sarcasm: oui bien sûr..., yeah right — 100 % vs 40 %symbolic: +1, 100%, 👍, 10/10 — 100 % vs 40 % (deterministic preprocessor)slang_abbrev: np, tkt, kk, nope — 100 % vs 50 %forsurellm-int8.onnx — full multilingual model, 113 MB (50+ languages supported via shared subwords, FR+EN tuned)forsurellm-int8_fr-en.onnx — vocab-pruned FR+EN variant, 24 MB. Same predictions as the full model on FR+EN inputs, 5× lighter on disk and in RAM (+85 MB process memory vs +418 MB), latency unchanged. Tokens outside FR+EN become <unk>.1import onnxruntime as ort
2from huggingface_hub import hf_hub_download
3from tokenizers import Tokenizer
4import numpy as np
5
6onnx_path = hf_hub_download("jcfossati/ForSureLLM", "forsurellm-int8.onnx")
7session = ort.InferenceSession(onnx_path, providers=["CPUExecutionProvider"])
8# tokenizer.json must be downloaded from the GitHub repo (space/tokenizer.json)
9# or installed via the forsurellm package once published.forsurellm Python package — see the GitHub repo for installation.sentence-transformers/paraphrase-multilingual-MiniLM-L12-v2 (12 layers, 384 hidden)yeah right defaults to "no" because it's overwhelmingly sarcastic in modern English usage — a sincere user without punctuation might get the wrong call. Use threshold=0.85 for action-confirmation contexts to fall back to unknown on borderline cases.