This repository contains GGUF quantized versions of the palmyra-mini-thinking-b model, based on the Qwen2 architecture. This model represents an advanced iteration of the thinking model series with improved reasoning capabilities and ChatML format support. GGUF quantizations are optimized for efficient inference across various hardware platforms using llama.cpp and compatible frameworks.
Available Quantizations
BF16 (Brain Float 16)
File: palmyra-mini-thinking-b-BF16.gguf
Size: 3.3GB
Precision: 16-bit brain float
Use Case: Highest quality reasoning, requires more memory
Q8_0 (8-bit Quantization)
File: palmyra-mini-thinking-b-Q8_0.gguf
Size: 1.8GB
Precision: 8-bit integer
Use Case: Good balance of reasoning quality and efficiency
Quick Start
Installation
bash
1# Install llama.cpp2git clone https://github.com/ggerganov/llama.cpp
3cd llama.cpp
4make56# Or use a pre-built binary
Usage
bash
1# Run with ChatML format2./main -m /path/to/palmyra-mini-thinking-b-BF16.gguf \3 -p "<|im_start|>user\nSolve this step by step: What is 30% of 250?<|im_end|>\n<|im_start|>assistant\n"\4 -n 51256# Interactive mode7./main -m /path/to/palmyra-mini-thinking-b-Q8_0.gguf -i
LM Studio Use
Steps to download a model through the Discover tab can be found here
1./main -m palmyra-mini-thinking-b-Q8_0.gguf \2 -p "<|im_start|>user\nA rectangle has a length of 15 cm and width of 10 cm. What is its area and perimeter?<|im_end|>\n<|im_start|>assistant\n"\3 -n 300\4 --temp 0.7
Problem Solving with System Message
bash
1./main -m palmyra-mini-thinking-b-BF16.gguf \2 -p "<|im_start|>system\nYou are a helpful assistant that explains concepts clearly and step by step.<|im_end|>\n<|im_start|>user\nExplain how photosynthesis works.<|im_end|>\n<|im_start|>assistant\n"\3 -n 400\4 --temp 0.8
Known Limitations
Context Length: Default context is 4,096 tokens, though the model supports up to 131,072
Format Dependency: Optimized for ChatML format; other formats may not work as well
Quantization Trade-offs: Lower bit quantizations may affect reasoning quality
Platform Optimization: Performance varies across different hardware configurations
Compatibility
llama.cpp: Compatible with recent versions
Frameworks: Ollama, LM Studio, GPT4All, and other GGUF-compatible tools
Platforms: Windows, macOS, Linux (x86_64, ARM64)
Chat Format: ChatML format support required for optimal performance
License
Apache 2.0
Original model card below:
Palmyra-mini-thinking-b
Model Description
Language(s) (NLP): English
License: Apache-2.0
Finetuned from model: Qwen/Qwen2.5-1.5B
Context window: 131,072 tokens
Parameters: 1.7 billion
Introduction
Palmyra-mini-thinking-b represents a significant step forward in generative AI, demonstrating exceptional capabilities in complex reasoning and problem-solving domains. This model excels in mathematical and programming challenges, showcasing a robust understanding of abstract concepts and logical structures. Its performance is not just a measure of its power but a testament to its specialized training, which has honed its ability to tackle tasks that demand deep, multi-step thinking.
Mathematical Prowess
The model's mathematical abilities are particularly noteworthy. It achieves an impressive score of 0.925 on the AMC23 benchmark, indicating a strong grasp of advanced high school mathematics. This is further complemented by its performance on MATH500, where it scores 0.882, proving its proficiency across a wide range of mathematical problems. The model also shows its strength in competitive mathematics, scoring 0.6 on AIME24(pass@1)(avg-of-1) and 0.5733 on Olympiadbench (extractive_match). These scores highlight the model's capacity for sophisticated mathematical reasoning, making it a powerful tool for both educational and research applications.
Excellence in Competitive Programming
Beyond mathematics, Palmyra-mini-thinking-b demonstrates strong performance in the competitive programming arena. Its score of 0.6343 on the Codeforces (pass_rate) benchmark underscores its ability to understand complex algorithmic problems and generate correct, efficient code. This capability suggests the model is well-suited for tasks involving code generation, debugging, and algorithmic design, making it a valuable asset for software developers and computer science researchers.
You can run conversational inference using the Transformers Auto classes with the generate() function. Here's an example:
py
1import torch
2from transformers import AutoTokenizer, AutoModelForCausalLM
34model_id ="Writer/palmyra-mini-thinking-b"56tokenizer = AutoTokenizer.from_pretrained(model_id)78model = AutoModelForCausalLM.from_pretrained(9 model_id,10 torch_dtype=torch.float16,11 device_map="auto",12 attn_implementation="flash_attention_2",13)1415messages =[16{17"role":"user",18"content":"You have a 3-liter jug and a 5-liter jug. How can you measure exactly 4 liters of water?"19}20],2122input_ids = tokenizer.apply_chat_template(23 messages, tokenize=True, add_generation_prompt=True, return_tensors="pt"24)2526gen_conf ={27"max_new_tokens":256,28"eos_token_id": tokenizer.eos_token_id,29"temperature":0.3,30"top_p":0.9,31}3233with torch.inference_mode():34 output_id = model.generate(input_ids,**gen_conf)3536output_text = tokenizer.decode(output_id[0][input_ids.shape[1]:])3738print(output_text)
Running with vLLM
vllm serve Writer/palmyra-mini-thinking-b
py
1curl -X POST http://localhost:8000/v1/chat/completions \
2-H "Content-Type: application/json" \
3-d '{4"model":"Writer/palmyra-mini-thinking-b",5"messages":[6{7"role":"user",8"content":"You have a 3-liter jug and a 5-liter jug. How can you measure exactly 4 liters of water?"9}10],11"max_tokens":8000,12"temperature":0.213}'
Ethical Considerations
As with any language model, there is a potential for generating biased or inaccurate information. Users should be aware of these limitations and use the model responsibly.
Footnotes
Base model: This model builds on NVIDIA's OpenReasoning-Nemotron-1.5B (https://huggingface.co/nvidia/OpenReasoning-Nemotron-1.5B).
Evaluation methodology:
Pass@1 (avg-of-1): computed using lm_eval and lighteval.
Pass@1 (avg-of-64) and Majority@64: computed using nemoskills.
Citation and Related Information
To cite this model:
@misc{Palmyra-mini-thinking-b,
author = {Writer Engineering team},
title = {{Palmyra-mini: A powerful LLM designed for math and coding}},
howpublished = {\url{https://dev.writer.com}},
year = 2025,
month = Sep
}