Text Generation
Transformers
Safetensors
English
gpt2
open-reason
causal-lm
cpu
text-generation-inference
Instructions to use theworker02/open-reason-large with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use theworker02/open-reason-large with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="theworker02/open-reason-large")# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("theworker02/open-reason-large") model = AutoModelForCausalLM.from_pretrained("theworker02/open-reason-large", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use theworker02/open-reason-large with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "theworker02/open-reason-large" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "theworker02/open-reason-large", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/theworker02/open-reason-large
- SGLang
How to use theworker02/open-reason-large 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 "theworker02/open-reason-large" \ --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": "theworker02/open-reason-large", "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 "theworker02/open-reason-large" \ --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": "theworker02/open-reason-large", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use theworker02/open-reason-large with Docker Model Runner:
docker model run hf.co/theworker02/open-reason-large
Polish large CPU model card (91,544,064 params, host CPU, not 1B)
Browse files
README.md
CHANGED
|
@@ -12,27 +12,32 @@ datasets:
|
|
| 12 |
base_model: gpt2-scratch
|
| 13 |
---
|
| 14 |
|
| 15 |
-
# Open Reason
|
| 16 |
|
| 17 |
-
This is a **large** GPT-2-style causal LM trained from scratch on the Open Reason SFT split. It is larger than `theworker02/open-reason-medium` and is **not** a 1B model and is **not** `theworker02/open-reason-1b`.
|
| 18 |
|
| 19 |
-
|
| 20 |
-
|
| 21 |
-
|
| 22 |
-
|
| 23 |
-
-
|
| 24 |
-
-
|
| 25 |
-
-
|
| 26 |
-
-
|
| 27 |
-
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 28 |
|
| 29 |
-
Related checkpoints (none of these is a 1B model):
|
| 30 |
- Dataset: https://huggingface.co/datasets/theworker02/open-reason
|
| 31 |
-
- Small: https://huggingface.co/theworker02/open-reason-small
|
| 32 |
-
- Medium: https://huggingface.co/theworker02/open-reason-medium
|
| 33 |
-
- Large: https://huggingface.co/theworker02/open-reason-large
|
|
|
|
| 34 |
|
| 35 |
-
No Reddit sources.
|
| 36 |
|
| 37 |
```python
|
| 38 |
from transformers import AutoModelForCausalLM, AutoTokenizer
|
|
|
|
| 12 |
base_model: gpt2-scratch
|
| 13 |
---
|
| 14 |
|
| 15 |
+
# Open Reason large (CPU)
|
| 16 |
|
| 17 |
+
This is a **large** GPT-2-style causal LM trained from scratch on the Open Reason SFT split. It is larger than [`theworker02/open-reason-medium`](https://huggingface.co/theworker02/open-reason-medium) (13,867,008 parameters) and is **not** a 1B model and is **not** `theworker02/open-reason-1b`.
|
| 18 |
|
| 19 |
+
Weights live on this Hub repo. They are not stored in the GitHub git tree.
|
| 20 |
+
|
| 21 |
+
## Training facts
|
| 22 |
+
|
| 23 |
+
- **Parameters:** 91,544,064
|
| 24 |
+
- **Architecture:** GPT-2-style from scratch; `n_layer=12`, `n_embd=768`, `n_head=12`, `vocab_size=8192`, `max_seq_len=256`
|
| 25 |
+
- **Steps:** 400 (batch size 2)
|
| 26 |
+
- **Final training loss:** 5.7361 (next-token NLL on training batches; not a benchmark score)
|
| 27 |
+
- **SFT rows:** 3,175 from `data/release/all.jsonl`
|
| 28 |
+
- **Dataset:** [`theworker02/open-reason`](https://huggingface.co/datasets/theworker02/open-reason) pipeline **1.4.0**
|
| 29 |
+
- **License:** Apache-2.0
|
| 30 |
+
- **Hardware:** AMD Ryzen 9 9950X host **CPU**; `torch 2.12.0+cpu`; `torch.cuda.is_available()=False`; Docker **not installed** and **not used**; `nvidia-smi` not present. NVIDIA CUDA was not used. AMD GPU / ROCm / DirectML were not used.
|
| 31 |
+
|
| 32 |
+
## Related
|
| 33 |
|
|
|
|
| 34 |
- Dataset: https://huggingface.co/datasets/theworker02/open-reason
|
| 35 |
+
- Small (~1.3M): https://huggingface.co/theworker02/open-reason-small
|
| 36 |
+
- Medium (13,867,008): https://huggingface.co/theworker02/open-reason-medium
|
| 37 |
+
- Large (this repo, 91,544,064): https://huggingface.co/theworker02/open-reason-large
|
| 38 |
+
- GitHub: https://github.com/theworker02/open-reason
|
| 39 |
|
| 40 |
+
No Reddit sources.
|
| 41 |
|
| 42 |
```python
|
| 43 |
from transformers import AutoModelForCausalLM, AutoTokenizer
|