mom-multilingual-class
Collection
long context models for MoM multilingual classifier (domain, jailbreak, pii, factual, feedback)
•
10 items
•
Updated
Full merged model for intent classification based on mmBERT-32K-YaRN (32K context, multilingual). This is the LoRA adapter merged with the base model for direct inference without PEFT.
biology, business, chemistry, computer science, economics, engineering, health, history, law, math, other, philosophy, physics, psychology
| Metric | Score |
|---|---|
| Test Accuracy | 80.0% |
from transformers import AutoTokenizer, AutoModelForSequenceClassification
import torch
model = AutoModelForSequenceClassification.from_pretrained("llm-semantic-router/mmbert32k-intent-classifier-merged")
tokenizer = AutoTokenizer.from_pretrained("llm-semantic-router/mmbert32k-intent-classifier-merged")
# Inference
inputs = tokenizer("How do neural networks learn?", return_tensors="pt")
with torch.no_grad():
outputs = model(**inputs)
probs = torch.softmax(outputs.logits, dim=1)
predicted_class = probs.argmax().item()
confidence = probs[0][predicted_class].item()
# Get label
print(f"Category: {model.config.id2label[str(predicted_class)]}, Confidence: {confidence:.2%}")
This merged model is compatible with the candle-binding Rust library for high-performance inference in production systems.
Base model
jhu-clsp/mmBERT-base