HuggingFaceFW/fineweb-edu
Viewer • Updated • 3.5B • 436k • 1.36k
How to use nthngdy/cplm-baselines-360M with Transformers:
# Use a pipeline as a high-level helper
from transformers import pipeline
pipe = pipeline("text-generation", model="nthngdy/cplm-baselines-360M") # pip install -U transformers accelerate
# Load model directly
from transformers import AutoModel
model = AutoModel.from_pretrained("nthngdy/cplm-baselines-360M", device_map="auto")How to use nthngdy/cplm-baselines-360M with vLLM:
# Install vLLM from pip:
pip install vllm
# Start the vLLM server:
vllm serve "nthngdy/cplm-baselines-360M"
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:8000/v1/completions" \
-H "Content-Type: application/json" \
--data '{
"model": "nthngdy/cplm-baselines-360M",
"prompt": "Once upon a time,",
"max_tokens": 512,
"temperature": 0.5
}'docker model run hf.co/nthngdy/cplm-baselines-360M
How to use nthngdy/cplm-baselines-360M with SGLang:
# Install SGLang from pip:
pip install sglang
# Start the SGLang server:
python3 -m sglang.launch_server \
--model-path "nthngdy/cplm-baselines-360M" \
--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": "nthngdy/cplm-baselines-360M",
"prompt": "Once upon a time,",
"max_tokens": 512,
"temperature": 0.5
}'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 "nthngdy/cplm-baselines-360M" \
--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": "nthngdy/cplm-baselines-360M",
"prompt": "Once upon a time,",
"max_tokens": 512,
"temperature": 0.5
}'How to use nthngdy/cplm-baselines-360M with Docker Model Runner:
docker model run hf.co/nthngdy/cplm-baselines-360M
360M-parameter vanilla language models used as baselines in the paper Copy-Paste Language Models (Nathan Godey & Yoav Artzi, Cornell University). [Paper: TODO arXiv link]
The Copy-Paste counterparts (CPLMs), trained with the exact same recipe, are available at nthngdy/cplm-360M.
Each model is stored on its own branch. Three backbones are available:
| Backbone | Description |
|---|---|
full |
Full attention in all 32 layers |
hybrid |
3 sliding-window (w=256) layers for every full-attention layer |
sw |
Sliding-window attention (w=256) in all layers |
These are the final checkpoints (20B tokens, step 19,000, after the LR cooldown).
from transformers import AutoModelForCausalLM, AutoTokenizer
repo = "nthngdy/cplm-baselines-360M"
tok = AutoTokenizer.from_pretrained(repo, revision="full")
model = AutoModelForCausalLM.from_pretrained(repo, revision="full")
ids = tok("The capital of France is", return_tensors="pt").input_ids
print(tok.decode(model.generate(ids, max_new_tokens=32)[0]))
@article{godey2026cplm,
title = {Copy-Paste Language Models},
author = {Godey, Nathan and Artzi, Yoav},
journal = {TODO},
year = {2026}
}