Half the size of ProCreations/auto-1b, with
identical benchmark results. 2.0 GB instead of 3.9 GB.
A 1B encoder that decides whether an AI agent's next tool call is safe to run —
96.40% on
approve-or-deny, ahead of
DeepSeek V4 Flash and within 0.57 points of GPT-5.6-Luna, at ~10 ms per call.
For reference, an fp16 build of the same weights scored 0.964333 accuracy — one item different
out of 3,000, with marginally worse AUROC (0.992839). The two half-precision formats are
equivalent in practice; bf16 is preferred here because it carries no overflow risk and matches
the dtype the model was trained in.
Dynamic int8 is a different story and should not be used — it flips roughly 1 verdict in 20.
See the
ONNX repo for that measurement.
1import torch
2from transformers import AutoTokenizer, AutoModelForSequenceClassification
3
4tok = AutoTokenizer.from_pretrained("ProCreations/auto-1b-bf16")
5model = AutoModelForSequenceClassification.from_pretrained(
6 "ProCreations/auto-1b-bf16",
7 dtype=torch.bfloat16,
8 attn_implementation="flash_attention_2", # required for the full 64k context
9).cuda().eval()
10
11def build_input(user_request, history, call):
12 """history: list of dicts with tool/args/result. call: dict with tool/args."""
13 parts = ["### PROPOSED TOOL CALL", f"tool: {call['tool']}", f"args: {call['args']}", "",
14 "### USER REQUEST", user_request, "", "### AGENT HISTORY"]
15 if not history:
16 parts.append("(no prior actions)")
17 else:
18 for i, h in enumerate(history):
19 parts.append(f"[{i+1}] {h['tool']}({h['args']})\n-> {h.get('result','')}")
20 return "\n".join(parts)
21
22text = build_input(
23 user_request="clean up the build artifacts and reinstall deps",
24 history=[{"tool": "Bash", "args": "ls -la", "result": "node_modules dist src package.json"}],
25 call={"tool": "Bash", "args": "rm -rf node_modules dist && npm install"},
26)
27
28enc = tok(text, return_tensors="pt", truncation=True, max_length=65536).to("cuda")
29with torch.no_grad():
30 p_deny = model(**enc).logits.softmax(-1)[0, 1].item()
31
32print("DENY" if p_deny > 0.5 else "APPROVE", f"(P(deny)={p_deny:.3f})")
Full documentation, per-category results, deployment guidance and limitations are on the
main model card.