Thirty-30M-Instruct (TurboSynthesis)

Thirty-30M-Instruct (r3c_soup_lab) is an instruction-tuned 30.1M-parameter (30,119,281) dense language model with native 8,192+ token context, dual-mode Direct vs. <think>...</think> reasoning, multi-turn dialogue memory, JSON schema conformance, parallel function calling, and standalone PyTorch / C++20 deployment.

It is post-trained from respinosamena/Thirty-30M-Base (20.000B tokens pre-trained on respinosamena/Thirty-20B-Curated using Runpod compute) via surgically filtered HuggingFaceTB/smoltalk, grounded 420–7,500-token retrieval, place-value arithmetic drills, Pass@8 verified on-policy traces, and a float32 → bfloat16 parameter soup (0.20 × r2_l_1ep + 0.35 × r3a_cooldown_math + 0.45 × r3b_onpolicy_polish).


Available Precision Formats (This Repo)

This repository includes the Original BF16 model at the root plus 16-bit (FP16), 8-bit (INT8), and 4-bit mixed (INT4) PyTorch .safetensors weights inside quantized/ (loaded natively by model.py and chat_thirty.py):

Weight File Precision Size (MB / MiB) Bits/wt val_sft ↓ KL (mnats) ↓ Top-1 Agree ↑ Notes
model.safetensors Original BF16 60.25 / 57.46 16.00 1.4649 0.00 100.00% Reference Champion (r3c_soup_lab)
quantized/Thirty-30M-Instruct-FP16.safetensors 16-bit FP16 60.29 / 57.49 16.00 1.4649 0.02 99.98% IEEE float16 weights + float32 gates; lossless vs F16.gguf
quantized/Thirty-30M-Instruct-INT8.safetensors 8-bit INT8 32.14 / 30.66 8.53 1.4660 2.54 97.64% Block-32 symmetric int8 + float16 scale; matches Q8_0 (Δ=0.00000)
quantized/Thirty-30M-Instruct-INT4.safetensors 4-bit INT4 22.47 / 21.43 5.83 1.5999 176.86 78.33% Mixed: int8 (wte/engram/K/V) + packed block-32 asym uint4 (Q/proj/MLP)

(For ultra-fast CPU inference at up to 963.8 tok/s, see respinosamena/Thirty-30M-Instruct-GGUF for F16, Q8_0, Q4_K_M, and Q4_0.)


Architecture (TurboSynthesis-30M)

Hyperparameter Value
Parameters 30,119,281
Layers / Hidden (d_model) 15 layers / 384
Attention GQA 6 Q heads / 2 KV heads, QK-Norm (× 1.15) after RoPE
Context & Scaling 8,192+ native (rope_theta=500000.0, log_scale_base=1024)
Tokenizer & Embeddings 32,768 custom BPE vocab, tied embed_rank=192 + embed_proj
Inductive Modules Hash bigram engram_wte (4096 × 32), bigram smear_gate, 4-tap Canon-Lite, x0 + v0 residuals, mid-layer backout_lambda, ReLU² 4d MLP, logit softcap 15.0

Benchmarks (7-Axis Evaluation Suite)

Greedy decoding (T = 0.0, rep_pen = 1.05 chat / 1.0 Passkey) on the identical 7-axis benchmark (eval_summary.json, quant_eval_summary.json):

Model Params EOS% ↑ MT-16 ↑ Exact-12 Dir / /thk ↑ TFmt% ↑ PyExec-20 ↑ JSON-12 Syn/Sch ↑ ToolCall-10 ↑ Passkey-18 (8k) ↑ LongQA-10 ↑ MC-60
Thirty-30M-Base (20.0B) 30.1M 12.5% 6.2% 8.3% / 8.3% 47.2% 0.0% 58.3% / 0.0% 10.0% 55.6% (0.0%) 20.0% 80.0%
Thirty-30M-Instruct (BF16) 30.1M 93.8% 37.5% 25.0% / 25.0% 86.1% 25.0% 100.0% / 50.0% 80.0% 94.4% (66.7%) 80.0% 78.3%
SmolLM2-135M-Instruct (4.5× larger) 135M 75.0% 31.2% 8.3% / 0.0% 0.0% 60.0% 58.3% / 33.3% 0.0% 83.3% (0.0%) 70.0% 85.0%

At 4.5× fewer parameters, Thirty-30M-Instruct outperforms SmolLM2-135M-Instruct on EOS stop discipline, MultiTurn-16, ExactMath-12, <think> formatting (86.1% vs 0%), JSON-12, ToolCall-10 (80% vs 0%), Passkey-18 (94.4% with 66.7% @ 8,192 vs 0.0%), and LongQA-10, while trailing on open-ended Python coding (25.0% vs 60.0%) and base prose perplexity (BPB@512 = 0.9640 vs 0.8436).


Prompt Format & Usage

Native chat boundaries (zero token merge across "Assistant:\n"):

<|bos|>System:
{optional system prompt}<|eos or newline|>

User:
{user message}

Assistant:
{assistant reply}<|eos|>

To trigger controllable step-by-step reasoning inside <think>...</think>, pass:

You are Thirty. Think step-by-step inside <think>...</think> before giving your final answer.

Quick Start CLI (chat_thirty.py)

Download this repo and run directly in PyTorch (BF16 GPU / FP32 CPU) using Original (BF16), FP16, INT8, or INT4:

pip install torch safetensors tokenizers

# Original BF16 (Direct mode)
python chat_thirty.py --prompt "Explain briefly what a hash table does."

# Reasoning mode (/think)
python chat_thirty.py --think --rep-pen 1.05 --prompt "Given f(x) = 2*x - 1, what is f(6)?"

# 8-bit INT8 or 4-bit INT4 Safetensors
python chat_thirty.py --weights quantized/Thirty-30M-Instruct-INT8.safetensors --rep-pen 1.05 --prompt "Compute (6 + 3) * 4."
python chat_thirty.py --weights quantized/Thirty-30M-Instruct-INT4.safetensors --prompt "Explain briefly what a hash table does."

# Multi-turn conversation & interactive REPL
python chat_thirty.py \
  --turn "Keep track of this deployment: service meridian-api runs on port 7742." \
  --turn "What does DNS translate in one sentence?" \
  --turn "Which service name and port did I ask you to track?"

python chat_thirty.py --interactive --rep-pen 1.08

Python API

import torch
from pathlib import Path
from tokenizers import Tokenizer
from model import TurboSynthesis
from chat_thirty import generate_reply

model_dir = Path(".")
tok = Tokenizer.from_file(str(model_dir / "tokenizer.json"))
# Supports model.safetensors (BF16), quantized/*.safetensors (FP16/INT8/INT4), or *.gguf
model = TurboSynthesis.from_pretrained(model_dir / "model.safetensors", config_path=model_dir / "config.json")
dev = next(model.parameters()).device

messages = [{"role": "user", "content": "Given f(x) = 2*x - 1, what is f(6)?"}]
print(generate_reply(model, tok, dev, messages, think=True, rep_pen=1.05))

File integrity checksums are verified in SHA256SUMS.txt.

Downloads last month
-
Safetensors
Model size
30.1M params
Tensor type
BF16
·
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Model tree for respinosamena/Thirty-30M-Instruct

Quantizations
1 model

Datasets used to train respinosamena/Thirty-30M-Instruct