Views
No views yet

SpiceeChat/Genre-Classifier dataset1from transformers import AutoModel, AutoTokenizer
2
3model = AutoModel.from_pretrained(
4 "SpiceeChat/FirstName-Genre-Classifier-30M-SFT",
5 trust_remote_code=True # custom architecture, audited and safe
6)
7tokenizer = AutoTokenizer.from_pretrained(
8 "SpiceeChat/FirstName-Genre-Classifier-30M-SFT",
9 trust_remote_code=True
10)
11
12name = "Arjun"
13inputs = tokenizer(name, return_tensors="pt")
14pred, probs = model.predict_gender(inputs.input_ids)
15gender = "M" if pred.item() == 1 else "F"
16print(f"{name} → {gender} (confidence: {probs.max().item():.2f})")Arjun → M (confidence: 0.98)| Metric | Value |
|---|---|
| Validation Accuracy | 84.74% |
| Macro F1 | 81.06% |
| Parameters | ~20M |
| Model Size | 129 MB |
| Detail | Value |
|---|---|
| Base model | SpiceeChat/Genre-Classifier-1-20M-BASE-BF16 |
| Training data | 150,000 + 922 custom examples |
| Optimizer | AdamW (LR = 2e-5) |
| Batch size | 64 (train) / 256 (eval) |
| Hardware | Tesla T4 (FP16) |
head.weight and tok_emb.weight. A harmless head.weight | MISSING warning may appear on load — this is expected behavior.trust_remote_code=True is required because the architecture is custom. The modeling code is included in this repository and fully auditable.1python -c "
2from transformers import AutoModel, AutoTokenizer
3model = AutoModel.from_pretrained('SpiceeChat/FirstName-Genre-Classifier-30M-SFT', trust_remote_code=True)
4tokenizer = AutoTokenizer.from_pretrained('SpiceeChat/FirstName-Genre-Classifier-30M-SFT', trust_remote_code=True)
5name = input('Enter a first name: ')
6inputs = tokenizer(name, return_tensors='pt')
7pred, _ = model.predict_gender(inputs.input_ids)
8print('M' if pred.item() == 1 else 'F')
9"Built by PhysiQuanty(Did the most work) and QuantaSparkLabs.