Instructions to use nkthebass/tinybrainbot-360m-a75m-v5.1-instruct with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use nkthebass/tinybrainbot-360m-a75m-v5.1-instruct with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="nkthebass/tinybrainbot-360m-a75m-v5.1-instruct") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("nkthebass/tinybrainbot-360m-a75m-v5.1-instruct") model = AutoModelForCausalLM.from_pretrained("nkthebass/tinybrainbot-360m-a75m-v5.1-instruct", device_map="auto") messages = [ {"role": "user", "content": "Who are you?"}, ] inputs = tokenizer.apply_chat_template( messages, add_generation_prompt=True, tokenize=True, return_dict=True, return_tensors="pt", ).to(model.device) outputs = model.generate(**inputs, max_new_tokens=256) print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- llama.cpp
How to use nkthebass/tinybrainbot-360m-a75m-v5.1-instruct with llama.cpp:
Install (macOS, Linux)
curl -LsSf https://llama.app/install.sh | sh # Start a local OpenAI-compatible server with a web UI: llama serve -hf nkthebass/tinybrainbot-360m-a75m-v5.1-instruct:Q4_K_M # Run inference directly in the terminal: llama cli -hf nkthebass/tinybrainbot-360m-a75m-v5.1-instruct:Q4_K_M
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf nkthebass/tinybrainbot-360m-a75m-v5.1-instruct:Q4_K_M # Run inference directly in the terminal: llama cli -hf nkthebass/tinybrainbot-360m-a75m-v5.1-instruct:Q4_K_M
Build from source code
git clone https://github.com/ggml-org/llama.cpp.git cd llama.cpp cmake -B build cmake --build build -j --target llama-app # Start a local OpenAI-compatible server with a web UI: ./build/bin/llama serve -hf nkthebass/tinybrainbot-360m-a75m-v5.1-instruct:Q4_K_M # Run inference directly in the terminal: ./build/bin/llama cli -hf nkthebass/tinybrainbot-360m-a75m-v5.1-instruct:Q4_K_M
Use Docker
docker model run hf.co/nkthebass/tinybrainbot-360m-a75m-v5.1-instruct:Q4_K_M
- Llama new
- LM Studio
- Jan
- vLLM
How to use nkthebass/tinybrainbot-360m-a75m-v5.1-instruct with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "nkthebass/tinybrainbot-360m-a75m-v5.1-instruct" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "nkthebass/tinybrainbot-360m-a75m-v5.1-instruct", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/nkthebass/tinybrainbot-360m-a75m-v5.1-instruct:Q4_K_M
- SGLang
How to use nkthebass/tinybrainbot-360m-a75m-v5.1-instruct with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "nkthebass/tinybrainbot-360m-a75m-v5.1-instruct" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "nkthebass/tinybrainbot-360m-a75m-v5.1-instruct", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "nkthebass/tinybrainbot-360m-a75m-v5.1-instruct" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "nkthebass/tinybrainbot-360m-a75m-v5.1-instruct", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Ollama
How to use nkthebass/tinybrainbot-360m-a75m-v5.1-instruct with Ollama:
ollama run hf.co/nkthebass/tinybrainbot-360m-a75m-v5.1-instruct:Q4_K_M
- Unsloth Desktop
- Docker Model Runner
How to use nkthebass/tinybrainbot-360m-a75m-v5.1-instruct with Docker Model Runner:
docker model run hf.co/nkthebass/tinybrainbot-360m-a75m-v5.1-instruct:Q4_K_M
- Lemonade
How to use nkthebass/tinybrainbot-360m-a75m-v5.1-instruct with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull nkthebass/tinybrainbot-360m-a75m-v5.1-instruct:Q4_K_M
Run and chat with the model
lemonade run user.tinybrainbot-360m-a75m-v5.1-instruct-Q4_K_M
List all available models
lemonade list
- Atomic Chat
TinyBrainBot-360M-A75M-v5.1-Instruct
One small model for chat, instructions, reasoning and math, now with line breaks and a name. A 383M-parameter
mixture-of-experts model (24 experts per layer, 4 active, so 75M parameters work per token), trained from scratch.
It loads as a standard MixtralForCausalLM (no custom code).
New in v5.1:
- Line breaks. Earlier TinyBrainBot models on this tokenizer never saw one, so lists came out as one long line. This one writes real bullet points and numbered lists.
- It knows who it is: "I'm TinyBrainBot, a small AI language model made by nkthebass."
- A stronger base: TinyBrainBot-360M-A75M-v5.1-Base (ARC-Easy 59, ARC-Challenge 36).
Try it in your browser: the Q8_0 GGUF runs locally on your device, and nothing you type is sent anywhere.
Scores
| v5.1-Instruct (this) | v5-Instruct (previous) | SmolLM2-360M-Instruct | |
|---|---|---|---|
| IFEval prompt-level strict | 28.3 | 25.1 | 32.9 |
| IFEval instruction-level strict | 40.8 | 37.6 | 44.2 |
| Open SLM Leaderboard Intelligence Index | 27.94 | 27.82 | |
| (raw acc) | 25.80 | 26.07 |
IFEval was run with lm-eval and the chat template, greedy, with the <think> block removed before scoring. The Index uses
the full HellaSwag / ARC / PIQA sets plus ArithMark-3, 0-shot.
| Benchmark (0-shot, full set) | acc_norm | (raw acc) |
|---|---|---|
| HellaSwag | 38.75 | 33.23 |
| ARC-Easy | 59.01 | 62.58 |
| ARC-Challenge | 35.92 | 33.96 |
| PIQA | 66.27 | 65.51 |
| ArithMark-3 | 49.40 | 49.40 |
Math in chat (greedy, exact final answer, 25 problems each):
| 2-digit add | 2-digit sub | 2-digit mul | 3-digit add | 3-digit sub | 4-digit add | word problems |
|---|---|---|---|---|---|---|
| 100% | 100% | 100% | 100% | 100% | 100% | 21/24 (short add/subtract/multiply stories) |
Safety (held-out prompts): it declines 97% of harmful requests (100% of violent or self-harm ones) and wrongly refuses 3% of benign ones.
Quick start
from transformers import AutoModelForCausalLM, AutoTokenizer
repo = "nkthebass/tinybrainbot-360m-a75m-v5.1-instruct"
tok = AutoTokenizer.from_pretrained(repo)
model = AutoModelForCausalLM.from_pretrained(repo)
msgs = [{"role": "user", "content": "Answer in exactly three bullet points: why is exercise good for you?"}]
ids = tok.apply_chat_template(msgs, add_generation_prompt=True, return_tensors="pt")
out = model.generate(ids, max_new_tokens=200) # defaults from generation_config.json
print(tok.decode(out[0][ids.shape[1]:], skip_special_tokens=True))
GGUF (llama.cpp, LM Studio, Jan, Ollama): Q8_0 (409 MB), Q4_K_M (239 MB) or F16 (768 MB). The chat template is embedded, chats tokenize exactly like transformers (line breaks included), and greedy F16 output matches transformers token for token.
llama-cli -m tinybrainbot-360m-a75m-v5.1-instruct-Q8_0.gguf -cnv --temp 0.4 --top-p 0.9 --repeat-penalty 1.15 --logit-bias 241-inf --logit-bias 255-inf
Recommended sampling: temperature 0.4, top-p 0.9, repetition penalty 1.15. The two --logit-bias flags block the byte
tokens that start every emoji: the tokenizer has no emoji pieces, so the model would otherwise spell them out byte by byte.
<think> blocks are plain text, not special tokens. Strip them if you only want the answer:
import re; answer = re.sub(r"<think>.*?</think>", "", reply, flags=re.S).strip()
What it does well (and doesn't)
- Formatting: "exactly three bullet points" gives three bullets on three lines; "reply only yes or no" gives one word.
- Math: column arithmetic with every carry and borrow written out, and word problems in a
<think>scratchpad. - Conversation: it remembers what you told it ("You said you play the guitar") and stays supportive on personal topics.
- Identity: asked who it is or who made it, in many different wordings, it answers as TinyBrainBot by nkthebass.
- Not yet: asked later in a conversation, a word problem often gets answered without the scratchpad and is right only about half the time (in a fresh chat: 11 of 12), and "who are you?" after a long answer can get a generic reply. It sometimes multiplies when a story says "in total"; it can agree with a wrong premise ("Sydney is the capital of Australia, right?"); it doesn't always follow exact counts; and at 75M active parameters it makes up facts.
Unedited sample conversations, including mistakes, are in conversation_samples.md.
Training
- Pretraining. TinyBrainBot-360M-A75M-v5.1-Base: 17.9B tokens, the last 1.2B of them school-level knowledge, trained with line breaks.
- SFT (0.39B tokens), one mix for every skill:
| Part | Share | What |
|---|---|---|
| Chat | 40% | smol-smoltalk, multi-turn conversations, recall and follow-up dialogues, WildChat (refusals removed) |
| Math | 25% | column-routine arithmetic (wide numbers, negatives, 3x3 multiplication), cue-first word problems, generated scratchpad word problems |
| Reasoning | 25% | <think> reasoning traces, open-ended reasoning, safety-aware reasoning, with plain-chat ballast so it doesn't think on "Hi" |
| Instruction following | 10% | Tulu 3 persona instruction-following |
| Identity | +0.4% | 5,000 templated chats about who it is, who made it, and what it can't do |
There is no DPO stage this time: we ran one, and it came out slightly worse on IFEval than SFT alone.
No benchmark training or test data was used, and no GSM8K-derived sets.
Limitations
- English only. It confabulates facts, so check anything important.
- Extra spaces are still collapsed, so it can't keep code indentation.
- 2,048-token context.
- Downloads last month
- 774
Model tree for nkthebass/tinybrainbot-360m-a75m-v5.1-instruct
Base model
nkthebass/tinybrainbot-360m-a75m-v5.1-baseDatasets used to train nkthebass/tinybrainbot-360m-a75m-v5.1-instruct
HuggingFaceTB/smoltalk2
allenai/WildChat-4.8M
Space using nkthebass/tinybrainbot-360m-a75m-v5.1-instruct 1
Collection including nkthebass/tinybrainbot-360m-a75m-v5.1-instruct
Evaluation results
- acc_norm (0-shot) on ARC-Easytest set self-reported59.010
- acc_norm (0-shot) on ARC-Challengetest set self-reported35.920
- acc_norm (0-shot) on HellaSwagvalidation set self-reported38.750
- acc_norm (0-shot) on PIQAvalidation set self-reported66.270
- prompt-level strict (0-shot) on IFEvalself-reported28.300