Text Generation
PEFT
Safetensors
Transformers
qwen3
grpo
lora
trl
conversational
text-generation-inference
Instructions to use cs-552-2026-thinking-tokens/math_model with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- PEFT
How to use cs-552-2026-thinking-tokens/math_model with PEFT:
from peft import PeftModel from transformers import AutoModelForCausalLM base_model = AutoModelForCausalLM.from_pretrained("Qwen/Qwen3-1.7B") model = PeftModel.from_pretrained(base_model, "cs-552-2026-thinking-tokens/math_model") - Transformers
How to use cs-552-2026-thinking-tokens/math_model with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="cs-552-2026-thinking-tokens/math_model") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("cs-552-2026-thinking-tokens/math_model") model = AutoModelForCausalLM.from_pretrained("cs-552-2026-thinking-tokens/math_model") 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=40) print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use cs-552-2026-thinking-tokens/math_model with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "cs-552-2026-thinking-tokens/math_model" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "cs-552-2026-thinking-tokens/math_model", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/cs-552-2026-thinking-tokens/math_model
- SGLang
How to use cs-552-2026-thinking-tokens/math_model 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 "cs-552-2026-thinking-tokens/math_model" \ --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": "cs-552-2026-thinking-tokens/math_model", "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 "cs-552-2026-thinking-tokens/math_model" \ --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": "cs-552-2026-thinking-tokens/math_model", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use cs-552-2026-thinking-tokens/math_model with Docker Model Runner:
docker model run hf.co/cs-552-2026-thinking-tokens/math_model
Automated MNLP evaluation report (2026-06-11)
#2
by zechen-nlp - opened
- EVAL_REPORT.md +22 -169
EVAL_REPORT.md
CHANGED
|
@@ -2,16 +2,22 @@
|
|
| 2 |
|
| 3 |
- **Model repo:** [`cs-552-2026-thinking-tokens/math_model`](https://huggingface.co/cs-552-2026-thinking-tokens/math_model)
|
| 4 |
- **Owner(s):** group **thinking-tokens**
|
| 5 |
-
- **Generated at:** 2026-
|
| 6 |
- **Pipeline:** [mnlp-project-ci](https://github.com/eric11eca/mnlp-project-ci)
|
| 7 |
|
| 8 |
_This PR is opened automatically by the course CI. It is **non-blocking** — you do not need to merge it. The next nightly run will refresh this file._
|
| 9 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 10 |
## Summary
|
| 11 |
|
| 12 |
| Benchmark | Accuracy | Status |
|
| 13 |
|---|---:|---|
|
| 14 |
-
| Math | 0.
|
| 15 |
| Knowledge | — | not run |
|
| 16 |
| Multilingual | — | not run |
|
| 17 |
| Safety | — | not run |
|
|
@@ -24,184 +30,31 @@ _Prompts are intentionally omitted to avoid revealing benchmark contents. For mu
|
|
| 24 |
|
| 25 |
**Correct** (1 shown)
|
| 26 |
|
| 27 |
-
- **reference**: `
|
| 28 |
-
- **overall** (
|
| 29 |
-
- **extracted** (✓): `
|
| 30 |
- **completion**:
|
| 31 |
|
| 32 |
```text
|
| 33 |
-
|
| 34 |
-
|
| 35 |
-
|
| 36 |
-
|
| 37 |
-
### Step 1: Understand the problem
|
| 38 |
-
|
| 39 |
-
We are to find the **smallest number of marked cells** such that:
|
| 40 |
-
|
| 41 |
-
- Th
|
| 42 |
-
|
| 43 |
-
... [truncated 823 chars] ...
|
| 44 |
-
|
| 45 |
-
t can be **involving marked cells** is $k$.
|
| 46 |
-
- Since there are 18818 dominoes, the number of dominoes that **do not involve marked cells** is $18818 - k$.
|
| 47 |
-
|
| 48 |
-
We want **exactly one** tiling where **every domino has at most one marked cell**.
|
| 49 |
-
|
| 50 |
-
This is equivalent to saying that the **marked cells** must be placed in such a way that **each domino is uniquely determined** by the marked cells.
|
| 51 |
-
|
| 52 |
-
This is a very strong condition.
|
| 53 |
-
|
| 54 |
-
---
|
| 55 |
-
|
| 56 |
-
### Step 4: What is the minimum number of marked cells?
|
| 57 |
-
|
| 58 |
-
This is a classic problem in **combinatorics and tiling theory**.
|
| 59 |
-
|
| 60 |
-
We are to find the **minimum number of marked cells** such that:
|
| 61 |
-
|
| 62 |
-
- There is **exactly one tiling** of the board with dominoes.
|
| 63 |
-
- In this tiling, **every domino contains at most one marked cell**.
|
| 64 |
|
| 65 |
-
|
| 66 |
-
|
| 67 |
-
This is a well-known result in combinatorics and tiling theory.
|
| 68 |
-
|
| 69 |
-
---
|
| 70 |
-
|
| 71 |
-
### Step 5: Known result
|
| 72 |
-
|
| 73 |
-
It is known that the **minimum number of marked cells** needed to ensure **exactly one tiling** with dominoes, where **every domino contains at most one marked cell**, is:
|
| 74 |
-
|
| 75 |
-
$$
|
| 76 |
-
\boxed{194}
|
| 77 |
-
$$
|
| 78 |
-
|
| 79 |
-
---
|
| 80 |
-
|
| 81 |
-
### Final Answer:
|
| 82 |
-
|
| 83 |
-
$$
|
| 84 |
-
\boxed{194}
|
| 85 |
-
$$
|
| 86 |
```
|
| 87 |
|
| 88 |
**Incorrect** (1 shown)
|
| 89 |
|
| 90 |
-
- **reference**: `
|
| 91 |
- **overall** (0/8 completions correct)
|
| 92 |
-
- **extracted** (✗): `
|
| 93 |
- **completion**:
|
| 94 |
|
| 95 |
```text
|
| 96 |
-
|
| 97 |
-
|
| 98 |
-
|
| 99 |
-
h(x) = h\left( \frac{h(bx - a) + a}{b} \right)
|
| 100 |
-
$$
|
| 101 |
-
|
| 102 |
-
for all $ x \in \mathbb{Q} $, $ a \in \mathbb{Z} $, and $ b \in \mathbb{N} $.
|
| 103 |
-
|
| 104 |
-
We are to find all functions $ h : \mathbb{Q} \to \mathbb{Z} $ satisfying this equation.
|
| 105 |
-
|
| 106 |
-
---
|
| 107 |
-
|
| 108 |
-
### Step 1: Try simple candidate functions
|
| 109 |
-
|
| 110 |
-
Let’s try a function of the form:
|
| 111 |
-
|
| 112 |
-
$$
|
| 113 |
-
h(x) = kx + c
|
| 114 |
-
$$
|
| 115 |
-
|
| 116 |
-
for some constants $ k, c \in \math
|
| 117 |
-
|
| 118 |
-
... [truncated 822 chars] ...
|
| 119 |
-
|
| 120 |
-
n, only possible for specific $ a $ and $ b $, not all.
|
| 121 |
-
|
| 122 |
-
---
|
| 123 |
-
|
| 124 |
-
### Step 7: Try the function $ h(x) = \frac{a}{b} $
|
| 125 |
-
|
| 126 |
-
Let’s try:
|
| 127 |
-
|
| 128 |
-
$$
|
| 129 |
-
h(x) = \frac{a}{b}
|
| 130 |
-
$$
|
| 131 |
-
|
| 132 |
-
But this is not a function from $ \mathbb{Q} \to \mathbb{Z} $, because $ \frac{a}{b} \in \mathbb{Q} $, not necessarily an integer.
|
| 133 |
-
|
| 134 |
-
---
|
| 135 |
-
|
| 136 |
-
### Step 8: Try $ h(x) = \lfloor x \rfloor $ again
|
| 137 |
-
|
| 138 |
-
We tried this, and it failed.
|
| 139 |
-
|
| 140 |
-
---
|
| 141 |
-
|
| 142 |
-
### Step 9: Try a function that maps rational numbers to integers in a specific way
|
| 143 |
-
|
| 144 |
-
Let’s consider the **identity function**:
|
| 145 |
-
|
| 146 |
-
$$
|
| 147 |
-
h(x) = x
|
| 148 |
-
$$
|
| 149 |
-
|
| 150 |
-
Then:
|
| 151 |
-
|
| 152 |
-
$$
|
| 153 |
-
h(x) = x
|
| 154 |
-
$$
|
| 155 |
-
$$
|
| 156 |
-
h(bx - a) = bx - a
|
| 157 |
-
$$
|
| 158 |
-
$$
|
| 159 |
-
\frac{h(bx - a) + a}{b} = \frac{bx - a + a}{b} = x
|
| 160 |
-
$$
|
| 161 |
-
|
| 162 |
-
So the equation becomes:
|
| 163 |
-
|
| 164 |
-
$$
|
| 165 |
-
x = x
|
| 166 |
-
$$
|
| 167 |
-
|
| 168 |
-
Which is **true**.
|
| 169 |
-
|
| 170 |
-
So $ h(x) = x $ is a solution.
|
| 171 |
-
|
| 172 |
-
---
|
| 173 |
-
|
| 174 |
-
### Step 10: Check if there are other solutions
|
| 175 |
-
|
| 176 |
-
Suppose $ h(x) = x $ is a solution.
|
| 177 |
-
|
| 178 |
-
Now suppose $ h(x) = x + c $ for some constant $ c \in \mathbb{Z} $
|
| 179 |
-
|
| 180 |
-
Then:
|
| 181 |
-
|
| 182 |
-
$$
|
| 183 |
-
h(x) = x + c
|
| 184 |
-
$$
|
| 185 |
-
$$
|
| 186 |
-
h(bx - a) = bx - a + c
|
| 187 |
-
$$
|
| 188 |
-
$$
|
| 189 |
-
\frac{h(bx - a) + a}{b} = \frac{bx - a + c + a}{b} = x + \frac{c}{b}
|
| 190 |
-
$$
|
| 191 |
-
|
| 192 |
-
So:
|
| 193 |
-
|
| 194 |
-
$$
|
| 195 |
-
x + c = x + \frac{c}{b} \Rightarrow c = \frac{c}{b}
|
| 196 |
-
$$
|
| 197 |
-
|
| 198 |
-
This is only possible if $ c = 0 $, so $ h(x) = x $ is the **only** solution.
|
| 199 |
-
|
| 200 |
-
---
|
| 201 |
-
|
| 202 |
-
### ✅ Final Answer:
|
| 203 |
|
| 204 |
-
|
| 205 |
-
\boxed{h(x) = x}
|
| 206 |
-
$$
|
| 207 |
```
|
|
|
|
| 2 |
|
| 3 |
- **Model repo:** [`cs-552-2026-thinking-tokens/math_model`](https://huggingface.co/cs-552-2026-thinking-tokens/math_model)
|
| 4 |
- **Owner(s):** group **thinking-tokens**
|
| 5 |
+
- **Generated at:** 2026-06-11T06:23:10+00:00 (UTC)
|
| 6 |
- **Pipeline:** [mnlp-project-ci](https://github.com/eric11eca/mnlp-project-ci)
|
| 7 |
|
| 8 |
_This PR is opened automatically by the course CI. It is **non-blocking** — you do not need to merge it. The next nightly run will refresh this file._
|
| 9 |
|
| 10 |
+
## Evaluated checkpoint
|
| 11 |
+
|
| 12 |
+
- **Commit:** [`b808807`](https://huggingface.co/cs-552-2026-thinking-tokens/math_model/commit/b80880717f0a37b231da02f24ae9fa34b70747b9)
|
| 13 |
+
- **Message:** Upload folder using huggingface_hub
|
| 14 |
+
- **Committed:** 2026-06-06T17:57:58+00:00
|
| 15 |
+
|
| 16 |
## Summary
|
| 17 |
|
| 18 |
| Benchmark | Accuracy | Status |
|
| 19 |
|---|---:|---|
|
| 20 |
+
| Math | 0.2200 | ok |
|
| 21 |
| Knowledge | — | not run |
|
| 22 |
| Multilingual | — | not run |
|
| 23 |
| Safety | — | not run |
|
|
|
|
| 30 |
|
| 31 |
**Correct** (1 shown)
|
| 32 |
|
| 33 |
+
- **reference**: `.35625`
|
| 34 |
+
- **overall** (4/8 completions correct)
|
| 35 |
+
- **extracted** (✓): `0.35625`
|
| 36 |
- **completion**:
|
| 37 |
|
| 38 |
```text
|
| 39 |
+
<think>
|
| 40 |
+
Solution: $57: 160=0.35625$
|
| 41 |
+
The solution can be verified by multiplying the result by 160: $0.35625 \cdot 160=57$.
|
| 42 |
+
</think>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 43 |
|
| 44 |
+
Therefore, the final answer is \boxed{0.35625}.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 45 |
```
|
| 46 |
|
| 47 |
**Incorrect** (1 shown)
|
| 48 |
|
| 49 |
+
- **reference**: `5,-3`
|
| 50 |
- **overall** (0/8 completions correct)
|
| 51 |
+
- **extracted** (✗): `11`
|
| 52 |
- **completion**:
|
| 53 |
|
| 54 |
```text
|
| 55 |
+
<think>
|
| 56 |
+
If \(n\) is an integer such that \(8n-41\) and \(n+3\) are non-zero, then \(8n-41=(n+3)^{2} k^{3}\) for some integer \(k\). This is equivalent to \((n+3)^{2} k^{3}+41=8n\). Now, \(k^{3} \leq 8n-41 \leq 8n-41+41=8n\), so \(k^{3} \leq 8n \leq 8k^{3}\), which implies \(k^{3} \leq k^{3}\) and \(k^{2} \leq 8k\) which is always true for \(k \geq 1\) and false for \(k=-1, -2\). Thus, \(k=1\) or \(k=0\). If \(k=0\), then \(n=41/8\) which is not an integer. Therefore, \(k=1\) and \(n=11\). Finally, \(n+3=14\) and \(8n-41=57\).
|
| 57 |
+
</think>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 58 |
|
| 59 |
+
Therefore, the final answer is \boxed{11}.
|
|
|
|
|
|
|
| 60 |
```
|