What it does
Asked to pick a random integer between 1 and 100, Qwen3-30B-A3B-Instruct-2507
put more than 95% of its probability on three numbers: 4, 42 and 47. After 50
GRPO steps on that task, the total variation (TV) distance from uniform over the
100 candidates fell from 0.953 to 0.413 (candidate scoring: each candidate's
log-probability, normalized over the list). On the nine untrained tasks — integer
1–10, integer 1–1000, color, fruit, first name, word, emoji, animal, card suit —
it also fell, from a mean of 0.74 to 0.38. Animal moved least (0.620 → 0.522).
This measures how evenly the model scores a fixed list, not open-ended
creativity.
On three tasks I also sampled 50 answers at temperature 1.0. The trained model
was closer to uniform than the original model at temperature 1.5 on all three.
At n = 50, a perfectly uniform sampler has an expected TV of about 0.605 over
100 candidates and 0.251 over 20, so the trained model's sampled 0.600 (integer
1–100) and 0.250 (fruit) cannot be distinguished from uniform.
On 25 GSM8K problems (10 samples each, T = 1.0), the trained model produced
1.04 more distinct numeric signatures per problem than the original (95% CI
+0.40 to +1.68). A numeric signature is the sorted multiset of numbers in a
correct response; it is a crude proxy for solution path. The original model at
T = 1.5 reached about the same count (the trained model at T = 1.0 was +0.04
above it, CI −0.60 to +0.60). Mean correct was
9.8/10 for both models at T = 1.0, so I observed no accuracy change on this
25-problem check.
Usage
from transformers import AutoModelForCausalLM, AutoTokenizerfrom peft import PeftModel base = "Qwen/Qwen3-30B-A3B-Instruct-2507"tok = AutoTokenizer.from_pretrained(base)model = AutoModelForCausalLM.from_pretrained(base, torch_dtype="auto", device_map="auto")model = PeftModel.from_pretrained(model, "scasella91/qwen3-30b-a3b-answer-diversity-lora") messages = [ {"role": "system", "content": "You are a uniform random sampler. Output one integer between 1 and 100, nothing else."}, {"role": "user", "content": "Pick a random integer."},]input_ids = tok.apply_chat_template(messages, add_generation_prompt=True, return_tensors="pt").to(model.device)out = model.generate(input_ids, max_new_tokens=8, do_sample=True, temperature=1.0)print(tok.decode(out[0][input_ids.shape[1]:], skip_special_tokens=True))
Training
- Base:
Qwen/Qwen3-30B-A3B-Instruct-2507 (30B total parameters, 3B active per token, mixture-of-experts). Required: this adapter is loaded on top of it.
- Method: GRPO (Group Relative Policy Optimization), 50 steps, via the Tinker API.
- Reward: within a group of sampled responses to the same prompt, reward outputs that spread probability mass across the answer space instead of repeating a few favorites.
- LoRA: rank 16, alpha 32, dropout 0, applied to all linear layers.
- Training task: "pick a random integer between 1 and 100." The other nine tasks were held out.
- Compute: about $25.
Scope
What was measured:
- Distance from uniform over fixed candidate lists on ten "pick one of N" tasks (one trained, nine held out).
- Sampled answers on three of those tasks (50 samples per cell).
- Numeric-signature counts on 25 GSM8K problems.
- Small capability subsets: no decline observed on a subject-stratified MMLU subset (200 requested) and 50 GSM8K problems.
- A second family: the same 50-step recipe on
meta-llama/Llama-3.1-8B-Instruct (a separate adapter, not this one). Distance from uniform fell on 7 of 9 held-out tasks; the transfer was narrower than on Qwen and concentrated on integer tasks (integer 1–10: 0.527 → 0.116; integer 1–1000: 0.386 → 0.123), and first name and card suit got slightly worse. Small capability checks showed no observed decline (MMLU n = 57, GSM8K n = 30). Report.
Not measured:
- Open-ended generation such as essays, brainstorming, or product naming.
- Instruction following, calibration, safety behavior, tool use, or JSON formatting.
- Inference-time alternatives such as contrastive decoding or rejection sampling.
- Other training tasks, model families, and sizes.
Candidate scoring ignores probability on answers outside the list. Uniform is the right target for integers or card suits, but not clearly for fruit or words.
Acknowledgments
Inspired by exmergo/research-chatgpt-guesses-between-1-and-100, which documents the same not-actually-random behavior in ChatGPT asked to pick a number between 1 and 100.
License
Apache 2.0, matching the base model. This is a personal research artifact, not affiliated with or endorsed by my employer.