Supra2-Medium Instruct

Ultra-efficient chat instruction model • 25M Parameters • 1K Context

supra2-medium

Supra2-Medium Instruct is a 25M-parameter decoder-only language model pretrained from scratch by SupraLabs on 20B tokens of English web text. It uses the Qwen3 architecture with a custom 16,384-token tokenizer. This is the instruct version of Supra2-Medium-Base.


Some samples...

Prompt: "How does ChatGPT work?" Answer:

ChatGT is a chatbot-based AI that uses text-based language to generate and share information, such as responses, responses, and other forms of communication. It works by using natural language processing (NLP) to generate text, which is then converted into actionable responses. The AI then uses this NLP to generate the text, making it available for downloading, sharing, and retrieving.

The AI then generates the text based on the input, allowing users to respond quickly and efficiently. This process is called "collaboration" or "memory" of the input text, where users can share their thoughts, feelings, and experiences with others. The chatbot then uses the text to generate responses, which are then sent to the AI to be used by the user.
Overall, Chat GPT is a powerful tool for creating and sharing content, and it has become an integral part of many modern daily life, enabling people to interact with and understand the world around them.

Prompt: "What is AI?" Answer:

AI is a technology that enables machines to learn, adapt, and improve their behavior. It's a way for humans to learn and adapt to new situations, from simple tasks like reading to more complex ones like writing. AI is used in various fields, including education, healthcare, and social sciences, as well as in the field of psychology, where it helps people understand and respond to emotions, behaviors, and experiences.

In essence, AI is designed to help individuals learn, adjust, and thrive in a world where they can learn and grow, while also being able to adapt and learn from their environment. This means that AI can be used to make decisions, solve problems, and even learn from others, making it a valuable tool for individuals who want to learn more about themselves and their surroundings.

Prompt: "What is 2+2 ?" Answer:

The result is **4**.

Finetuning Data

Source Approx. share
smol-smoltalk 77.5%
Synthethic Basic Arithmetic 9.3%
qwedsacf/grade-school-math-instructions 4.5%
no_robots 3.4%
Style Rewrite of smol-smoltalk 2.5%
Style Rewrite of no_robots 1.5%
Templated b-mc2/wikihow_lists 1.2%

Usage

import torch
from tokenizers import pre_tokenizers
from transformers import AutoModelForCausalLM, AutoTokenizer

REPO_ID = "SupraLabs/Supra2-Medium-Instruct"
device = "cuda" if torch.cuda.is_available() else "cpu"

print(f"[*] Loading model and tokenizer from Hub: {REPO_ID}...")

# 1. Load Tokenizer & configure ByteLevel pre-tokenizer
tokenizer = AutoTokenizer.from_pretrained(REPO_ID, trust_remote_code=True)
tokenizer._tokenizer.pre_tokenizer = pre_tokenizers.ByteLevel(add_prefix_space=False)

# 2. Load Model
model = AutoModelForCausalLM.from_pretrained(
    REPO_ID,
    torch_dtype=torch.bfloat16 if torch.cuda.is_available() else torch.float32,
    device_map="auto" if torch.cuda.is_available() else None,
    trust_remote_code=True
)
model.eval()

# 3. Prepare Chat Prompt
messages = [
    {"role": "user", "content": "What is AI?"}
]

prompt_text = tokenizer.apply_chat_template(
    messages, 
    tokenize=False, 
    add_generation_prompt=True
)

inputs = tokenizer(prompt_text, return_tensors="pt").to(device)

print("[*] Generating response...\n")

# 4. Generate
im_end_id = tokenizer.convert_tokens_to_ids("<|im_end|>")
eos_ids = [im_end_id, tokenizer.eos_token_id] if im_end_id is not None else tokenizer.eos_token_id

with torch.no_grad():
    output_ids = model.generate(
        **inputs,
        max_new_tokens=256,
        do_sample=True,
        temperature=0.2,
        top_p=0.85,
        top_k=25,
        no_repeat_ngram_size=3,
        pad_token_id=tokenizer.pad_token_id,
        eos_token_id=eos_ids
    )

# 5. Extract & Decode Response
generated_tokens = output_ids[0][inputs["input_ids"].shape[-1]:]
response = tokenizer.decode(generated_tokens, skip_special_tokens=True)

print("--- Output ---")
print(response.strip())

© SupraLabs 2026

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

Model tree for SupraLabs/Supra2-Medium-Instruct

Finetuned
(1)
this model

Dataset used to train SupraLabs/Supra2-Medium-Instruct

Collection including SupraLabs/Supra2-Medium-Instruct