Text Generation
Transformers
Safetensors
English
slm
arithmetic
math
causal-lm
custom_code
Eval Results (legacy)
Instructions to use WhirlwindAI/Arithmetic-SLM with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use WhirlwindAI/Arithmetic-SLM with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="WhirlwindAI/Arithmetic-SLM", trust_remote_code=True)# Load model directly from transformers import AutoModelForCausalLM model = AutoModelForCausalLM.from_pretrained("WhirlwindAI/Arithmetic-SLM", trust_remote_code=True, dtype="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use WhirlwindAI/Arithmetic-SLM with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "WhirlwindAI/Arithmetic-SLM" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "WhirlwindAI/Arithmetic-SLM", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/WhirlwindAI/Arithmetic-SLM
- SGLang
How to use WhirlwindAI/Arithmetic-SLM 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 "WhirlwindAI/Arithmetic-SLM" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "WhirlwindAI/Arithmetic-SLM", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'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 "WhirlwindAI/Arithmetic-SLM" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "WhirlwindAI/Arithmetic-SLM", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use WhirlwindAI/Arithmetic-SLM with Docker Model Runner:
docker model run hf.co/WhirlwindAI/Arithmetic-SLM
Update README.md
Browse files
README.md
CHANGED
|
@@ -1,32 +1,34 @@
|
|
| 1 |
---
|
| 2 |
license: apache-2.0
|
| 3 |
language:
|
| 4 |
-
|
| 5 |
tags:
|
| 6 |
-
|
| 7 |
-
|
| 8 |
-
|
| 9 |
-
|
| 10 |
-
|
| 11 |
-
|
| 12 |
-
|
| 13 |
library_name: transformers
|
| 14 |
pipeline_tag: text-generation
|
| 15 |
metrics:
|
| 16 |
-
|
| 17 |
model-index:
|
| 18 |
-
|
| 19 |
-
|
| 20 |
-
|
| 21 |
-
|
| 22 |
-
|
| 23 |
-
|
| 24 |
-
|
| 25 |
-
|
| 26 |
-
|
| 27 |
-
|
| 28 |
-
|
| 29 |
-
|
|
|
|
|
|
|
| 30 |
---
|
| 31 |
|
| 32 |
|
|
@@ -282,4 +284,4 @@ This project does not claim to be a revolution.
|
|
| 282 |
|
| 283 |
It is an experiment in making small models learn precise arithmetic, numerical structure, and eventually parts of their own learning dynamics.
|
| 284 |
|
| 285 |
-
**By Science AND FOR SCIENCE <3**
|
|
|
|
| 1 |
---
|
| 2 |
license: apache-2.0
|
| 3 |
language:
|
| 4 |
+
- en
|
| 5 |
tags:
|
| 6 |
+
- slm
|
| 7 |
+
- arithmetic
|
| 8 |
+
- math
|
| 9 |
+
- causal-lm
|
| 10 |
+
- text-generation
|
| 11 |
+
- custom_code
|
| 12 |
+
- safetensors
|
| 13 |
library_name: transformers
|
| 14 |
pipeline_tag: text-generation
|
| 15 |
metrics:
|
| 16 |
+
- accuracy
|
| 17 |
model-index:
|
| 18 |
+
- name: Arithmetic-SLM
|
| 19 |
+
results:
|
| 20 |
+
- task:
|
| 21 |
+
type: text-generation
|
| 22 |
+
name: Arithmetic continuation
|
| 23 |
+
dataset:
|
| 24 |
+
type: AxiomicLabs/ArithMark-2.0
|
| 25 |
+
name: ArithMark-2
|
| 26 |
+
metrics:
|
| 27 |
+
- type: accuracy
|
| 28 |
+
name: Overall
|
| 29 |
+
value: 78.6
|
| 30 |
+
datasets:
|
| 31 |
+
- WhirlwindAI/Arithmetic
|
| 32 |
---
|
| 33 |
|
| 34 |
|
|
|
|
| 284 |
|
| 285 |
It is an experiment in making small models learn precise arithmetic, numerical structure, and eventually parts of their own learning dynamics.
|
| 286 |
|
| 287 |
+
**By Science AND FOR SCIENCE <3**
|