Downloads · 30 days
61
14% of all-time downloads
arabellako22/gifted_maths_unsloth_remerged_full_gemma_4
gifted_maths_unsloth_remerged_full_gemma_4 is a text generation model from arabellako22. Use it when you need the model to write or continue text. It is set up for transformers. The card lists the license as gemma.
Verified 16-bit full-weight merge of Gifted Maths LoRA, a Gemma 4 model fine-tuned as mathsengine for clear, step-by-step mathematics solutions in LaTeX.
Downloads · 30 days
61
14% of all-time downloads
All-time downloads
436
Public
Parameters
5.1B
10.3 GB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors10.2 GB · 100%
From the Hugging Face model README
Verified 16-bit full-weight merge of Gifted Maths LoRA, a Gemma 4 model fine-tuned as maths_engine for clear, step-by-step mathematics solutions in LaTeX.
This is the authoritative full model and the conversion source for the verified GGUF release.
The earlier GGUF export is retained as a legacy artifact and is not recommended for the current maths_engine release.
| Field | Value |
|---|---|
| Developer | arabellako22 |
| Original base | unsloth/gemma-4-E2B-it |
| LoRA adapter | arabellako22/gifted_maths_lora_model |
| Dataset | arabellako22/gifted_maths_training_dataset |
| Merge | Unsloth 16-bit merge |
| Format | Full-weight Safetensors, one file, approximately 10.2 GB |
| Architecture | Gemma4ForConditionalGeneration |
| Precision | BF16 |
| Task | Step-by-step mathematics reasoning |
| Language | English |
| License | Gemma license |
<start_of_turn>system
You are maths_engine, a local gifted mathematics reasoning model for students.
You solve maths problems step by step, clearly and calmly.
All variables, formulas, equations, transformations, and final answers must use LaTeX.
Use inline math with $...$ and display math with $$...$$.
Do not skip algebraic steps when the learner would benefit from seeing them.
End every solution with a clear line starting with: Final Answer:<end_of_turn>
<start_of_turn>user
{{ question }}<end_of_turn>
<start_of_turn>model
pip install -U unsloth transformers accelerate safetensors
import torch
from unsloth import FastModel
MODEL_ID = "arabellako22/gifted_maths_unsloth_remerged_full_gemma_4"
model, tokenizer = FastModel.from_pretrained(
model_name=MODEL_ID,
max_seq_length=1024,
dtype=None,
load_in_4bit=False,
)
FastModel.for_inference(model)
messages = [
{
"role": "system",
"content": """You are maths_engine, a local gifted mathematics reasoning model for students.
You solve maths problems step by step, clearly and calmly.
All variables, formulas, equations, transformations, and final answers must use LaTeX.
Use inline math with $...$ and display math with $$...$$.
Do not skip algebraic steps when the learner would benefit from seeing them.
End every solution with a clear line starting with: Final Answer:""",
},
{
"role": "user",
"content": "Find the coefficient of x^4 in (2x - 3)^6.",
},
]
prompt = tokenizer.apply_chat_template(
messages,
tokenize=False,
add_generation_prompt=True,
)
inputs = tokenizer(prompt, return_tensors="pt").to(model.device)
with torch.inference_mode():
outputs = model.generate(
**inputs,
max_new_tokens=900,
do_sample=False,
pad_token_id=tokenizer.eos_token_id,
)
new_tokens = outputs[0][inputs["input_ids"].shape[-1]:]
print(tokenizer.decode(new_tokens, skip_special_tokens=True))
| Stage | Recorded result |
|---|---|
| Base + adapter | Generated a worked algebra solution with a final answer |
| Unsloth 16-bit merge | Returned 2160 for the coefficient of $x^4$ in $(2x-3)^6$ |
| Downstream Q4_K_M | Returned $x=\frac{1}{2}$ or $x=-4$ for $2x^2+7x-4=0$, locally and after Hub re-download |
These are narrow artifact-integrity checks, not a standardized mathematics benchmark.
Do not treat outputs as guaranteed answers or use them for high-stakes grading, admissions, or placement without independent human verification.