ettin-subjects-68m
Built for Orb, and not very useful outside it. The categories, the input shaping and the decision thresholds were all chosen for one job inside one app: catching a roleplay writer model that re-describes the same thing every reply. It is not a general-purpose text classifier, attribute extractor or content tagger. Its labels come from an LLM, not from people, and it has only been measured on roleplay narration.
Reads which subjects the narration of one roleplay reply dwells on, and how. Orb tags each reply, counts descriptions across the last few replies, and has its editor cut a subject the writer keeps re-describing (her violet eyes, her halo, the crackling fire) when the draft does it again.
Each of 20 categories gets one of three levels:
absent: not mentionedaction: mentioned for what it does (her eyes widen, he grips the hilt)description: described for how it looks, sounds or feels (her violet eyes glint, calloused hands)
The split between action and description is the point: Orb counts description only, so her eyes widen every
reply is not a streak.
Categories, in head order: eyes, hair, face, mouth, voice, breath, scent, hands, skin, chest,
lower_body, neck, build, clothing, accessory, object, nonhuman (halo, horns, wings, tail), light,
sound, weather.
| Base | jhu-clsp/ettin-encoder-68m (ModernBERT) |
| Parameters | 68,438,076 |
| Head | 60 logits: 20 categories × 3 levels, row-major, one 3-way softmax per category |
| Input | narration only (dialogue removed), up to 1,024 tokens |
| Files | safetensors (fp32, 274 MB) · gguf/subjects-68m-q8_0.gguf (74.6 MB) |
| Speed | 5 ms for a 28-token reply, 44 ms for 210 tokens (q8_0, llama.cpp, 4 CPU threads) |
Use
Remove dialogue first. The model never saw quoted speech in training, so feed it narration only. Orb uses its own
markup parser for this (narration_only in backend/analysis/text/markup.py); dropping the quoted spans gets close.
import torch
from transformers import AutoTokenizer, AutoModelForSequenceClassification
REPO = "chartreuse-verte/ettin-subjects-68m"
tok = AutoTokenizer.from_pretrained(REPO)
model = AutoModelForSequenceClassification.from_pretrained(REPO).eval()
CATEGORIES = [model.config.id2label[i].split("|")[0] for i in range(0, 60, 3)]
LEVELS = ["absent", "action", "description"]
def read(narration):
ids = torch.tensor([tok(narration)["input_ids"][:1024]]) # the first 1,024 ids, as in training
with torch.no_grad():
logits = model(input_ids=ids, attention_mask=torch.ones_like(ids)).logits[0]
probs = logits.view(20, 3).softmax(-1) # softmax per category, not over all 60
return {c: (LEVELS[int(p.argmax())], round(float(p[2]), 2)) for c, p in zip(CATEGORIES, probs)}
for text in ["*Her violet eyes glint in the lamplight, silver hair spilling over one shoulder.*",
"*Her eyes widen. She grabs the lantern and runs for the door.*"]:
print({c: v for c, v in read(text).items() if v[0] != "absent"})
# {'eyes': ('description', 0.99), 'hair': ('description', 0.97), 'neck': ('description', 0.52),
# 'nonhuman': ('description', 0.77), 'light': ('description', 0.86)}
# {'eyes': ('action', 0.03), 'face': ('action', 0.08), 'hands': ('action', 0.0), 'object': ('action', 0.0)}
The second number is P(description). Note the first example: "silver hair spilling over one shoulder" also reads
as neck and nonhuman. Single replies are noisy. Orb only acts when the draft and at least three of the four
replies before it describe the same category.
The GGUF is the same model for llama.cpp:
from llama_cpp import Llama, LLAMA_POOLING_TYPE_RANK
llm = Llama("gguf/subjects-68m-q8_0.gguf", embedding=True, pooling_type=LLAMA_POOLING_TYPE_RANK,
n_ctx=1024, n_batch=1024, n_ubatch=1024, verbose=False)
logits = llm.embed(narration)[:60] # the same 60 cells; softmax each group of 3
embed returns a hidden-size vector; only its first 60 values are the cells. Set n_batch and n_ubatch to
n_ctx: the encoder needs the whole sequence in one batch.
How well it works
Held out by conversation: 1,494 replies, scored against the labeler's argmax. dAUC is description-vs-rest AUC,
the read Orb uses.
| category | acc | dAUC | category | acc | dAUC | |
|---|---|---|---|---|---|---|
| eyes | 92.2% | 0.986 | lower_body | 93.1% | 0.981 | |
| hair | 97.5% | 0.996 | neck | 94.5% | 0.975 | |
| face | 78.3% | 0.924 | build | 91.8% | 0.986 | |
| mouth | 86.3% | 0.960 | clothing | 92.5% | 0.988 | |
| voice | 81.1% | 0.963 | accessory | 93.2% | 0.973 | |
| breath | 92.2% | 0.966 | object | 86.8% | 0.960 | |
| scent | 97.7% | 0.995 | nonhuman | 94.4% | 0.956 | |
| hands | 90.4% | 0.981 | light | 94.2% | 0.985 | |
| skin | 87.2% | 0.980 | sound | 91.2% | 0.966 | |
| chest | 96.1% | 0.992 | weather | 92.6% | 0.971 | |
| mean | 91.2% | 0.974 |
The q8_0 GGUF scores the same on this split (91.2% / 0.974). Per-source and per-category numbers are in
test_report.json.
Limits
- Made for one app's streak rule, not for reading a single reply. See the warning at the top.
- English roleplay narration only. Not tested on other fiction, other languages, or text with dialogue left in.
- All synth data, no human labels.
- Fixed categories.
Training
11,795 replies (1,172 for validation, 1,494 for test, split by conversation) from three sources: various imported RP excerpts,
LLM-to-LLM synthetic roleplay, and
Gryphe/Sonnet3.5-Charcard-Roleplay (its
license is listed as unknown). Soft cross-entropy per 3-way group, 6 epochs, lr 5e-5, batch 32, cosine schedule with
6% warmup, best checkpoint by validation macro-F1. The data includes real conversation text, so it isn't published.
License
MIT, same as the base model.