Veyra-100M: Fast Encoder-Based Topic Classification
Veyra-100M is a compact, encoder-only text classification model built by Dl26. It is designed for fast English topic classification using a BERT-style bidirectional Transformer encoder. Instead of generating answers autoregressively, it reads the input text in a single encoder pass and returns a class score over a fixed topic taxonomy.
The released checkpoint, Dl26/Veyra-100M, is a 100M-parameter-class classifier trained from random initialization. It uses the standard Transformers bert model type, so it loads with AutoModelForSequenceClassification and does not require trust_remote_code=True.
Veyra-100M is intended for practical classification workflows such as document routing, topic labeling, metadata enrichment, dataset filtering, and lightweight encoder research.
Why this model
Compact BERT-style encoder for fast text classification
Standard Hugging Face Transformers compatibility
No custom architecture files or remote code requirement
14-way topic taxonomy based on DBpedia-style categories
Useful for document routing, triage, and automatic labeling
Trained from scratch with AdamW rather than adapted from a pretrained encoder
Designed to run efficiently on CPU, GPU, and batch inference pipelines
Model details
Property
Value
Model name
Veyra-100M
Developer
Dl26
Model type
Encoder-only sequence classifier
Transformers model type
bert
Architecture
BertForSequenceClassification
Parameters
101,515,758
Hidden size
736
Layers
12
Attention heads
16
Intermediate size
2,944
Max positions
512
Vocabulary size
30,522
Number of labels
14
Training objective
Supervised single-label classification
License
Apache 2.0
Supported labels
Veyra-100M predicts one label from the following fixed topic set:
Villages, towns, municipalities, local settlements
Animal
Animal species and animal-related entries
Plant
Plant species and plant-related entries
Album
Music albums and recorded releases
Film
Films, movies, cinematic works
WrittenWork
Books, written publications, literary works
Installation
pip install -U transformers torch accelerate
For CPU-only inference, accelerate is optional:
pip install -U transformers torch
Quick start
python
1from transformers import AutoTokenizer, AutoModelForSequenceClassification
2import torch
34model_id ="Dl26/Veyra-100M"56tokenizer = AutoTokenizer.from_pretrained(model_id)7model = AutoModelForSequenceClassification.from_pretrained(model_id)8model.eval()910text ="Apple announced a new processor for its laptop computers."1112inputs = tokenizer(13 text,14 return_tensors="pt",15 truncation=True,16 max_length=128,17)1819with torch.no_grad():20 logits = model(**inputs).logits
2122predicted_id =int(logits.argmax(dim=-1))23label = model.config.id2label[predicted_id]24print(label)
GPU inference
python
1from transformers import AutoTokenizer, AutoModelForSequenceClassification
2import torch
34model_id ="Dl26/Veyra-100M"56tokenizer = AutoTokenizer.from_pretrained(model_id)7model = AutoModelForSequenceClassification.from_pretrained(8 model_id,9 torch_dtype=torch.bfloat16,10 device_map="auto",11)1213texts =[14"The athlete scored two goals in the final match.",15"The album includes twelve songs recorded in London.",16"The village is located near a river and surrounded by hills.",17]1819inputs = tokenizer(20 texts,21 return_tensors="pt",22 truncation=True,23 padding=True,24 max_length=128,25).to(model.device)2627with torch.no_grad():28 logits = model(**inputs).logits
2930predictions = logits.argmax(dim=-1).tolist()31for text, label_id inzip(texts, predictions):32print(model.config.id2label[label_id],"-", text)
Batch inference
For high-throughput classification, batch inputs together and keep a consistent max_length.
Veyra-100M is a single-label classifier. For each input text, the model returns logits over the 14 supported labels. The highest-scoring label is usually treated as the predicted class.
Use confidence scores as a routing signal, not as a perfect measure of correctness. Low-confidence predictions are good candidates for fallback handling, manual review, or a broader classification model.
Recommended practices:
Use title plus body text when available.
Keep inputs descriptive rather than extremely short.
Use max_length=128 for fast classification.
Increase to max_length=256 or 512 when documents need more context.
Calibrate confidence thresholds on your own validation set.
Evaluation highlights
The downloaded checkpoint was tested after training on DBpedia-style topic classification.
Evaluation
Result
Held-out 5K evaluation sample
98.4% accuracy
Separate 2K test script sample
96.2% accuracy
Model load path
AutoModelForSequenceClassification
Remote code required
No
These numbers are useful as sanity checks for the released checkpoint, but users should evaluate the model on their own data before deployment.
Input formatting
The model works best with natural, descriptive English text.
Good examples:
text
1Apple announced a new processor for its laptop computers.
2The athlete scored two goals in the final match.
3The album includes twelve songs recorded in London.
For records with separate title and body fields, combine them:
text = f"{title}. {description}"
Very short or generic inputs may be ambiguous. For example, a sentence such as “The film won several awards” may not contain enough detail for stable classification.
Intended use
Veyra-100M is intended for:
topic classification
document routing
metadata enrichment
dataset filtering
search indexing labels
moderation queue triage by broad topic
lightweight encoder benchmarking
educational experiments with from-scratch classifiers
Out-of-scope use
Veyra-100M is not intended for:
open-ended text generation
semantic embedding search
safety moderation as a policy model
legal, medical, financial, or identity-sensitive decision making
reliable classification outside the supported label taxonomy without additional validation
Limitations
The model supports a fixed 14-label taxonomy.
It is trained for English text and may be unreliable on other languages.
It can misclassify short, vague, adversarial, or out-of-domain inputs.
It is not a general-purpose reasoning model.
It is not a replacement for human review in high-impact workflows.
Confidence scores may require calibration for production systems.
Citation
bibtex
1@misc{dl26_2026_veyra_100m,
2 title = {Veyra-100M: Fast Encoder-Based Topic Classification},
3 author = {Dl26},
4 year = {2026},
5 url = {https://huggingface.co/Dl26/Veyra-100M}
6}