Downloads · 30 days
14
6% of all-time downloads
JackYoung27/s0-tuning-qwen3.5-4b-humaneval
s0-tuning-qwen3.5-4b-humaneval is a machine learning model from JackYoung27. Use it for the machine learning task on the model card, and read the license before you ship it in a product. It is set up for s0-tuning. The card lists the license as mit.
S0 tuning adapts a recurrent language model to a task by learning its initial hidden states. These states are the model's working memory: matrices that carry information between tokens. We train their starting values…
Downloads · 30 days
14
6% of all-time downloads
All-time downloads
222
Public
Repo size
50.9 MB
Likes
0
Public
Click a slice to open those files.
.safetensors50.3 MB · 99%
From the Hugging Face model README
S0 tuning adapts a recurrent language model to a task by learning its initial hidden states. These states are the model's working memory: matrices that carry information between tokens. We train their starting values on prompt-completion pairs in place of the usual zero initialization. The model weights stay frozen.
Qwen3.5-4B on 84 held-out HumanEval problems, with thinking disabled. The S0 result is averaged across 10 seeds.
| Model | Score |
|---|---|
| Base model | 48.8% |
| With S0 tuning | 72.2% |
These are the reported experiment results, not a separate evaluation of this saved checkpoint.
python -m pip install huggingface_hub
hf download JackYoung27/s0-tuning-qwen3.5-4b-humaneval --local-dir s0-tuning
cd s0-tuning
python -m pip install -e .
Run from the downloaded directory:
from s0 import S0Trainer
trainer = S0Trainer.from_pretrained("Qwen/Qwen3.5-4B")
trainer.load(".")
trainer.activate()
print(trainer.generate("def fibonacci(n):\n", max_new_tokens=128))
The saved states require Qwen3.5-4B. Its weights download separately and must fit in local memory.
states.safetensors: 24 learned initial states for Qwen3.5-4B, totaling 48 MiB.config.json and meta.json: tuning settings, layer indices, and state dimensions.s0/ and pyproject.toml: code to load or train states.data/train.jsonl: 45 verified HumanEval training examples.examples/ and experiments/: training and evaluation code, plus saved results.