Views
No views yet
Qwen/Qwen3-4B-Base at the fixed
revision 906bfd4b4dc7f14ee4320094d8b41684abff8539.A-NH025 is the Phase A no-head arm. Starting from the completed source LoRA,
every selected transformer-body LoRA B tensor is multiplied by 0.25 in
FP32, while the lm_head LoRA B tensor is multiplied by 0, making its
effective head/shared-embedding delta exactly zero. LoRA A tensors are
unchanged. With lora_alpha=128 and r=64, PEFT applies the intended body
delta without a language-model-head delta across the 253 declared modules.lm_head adapter is omitted from the release state and
target list; this is exactly equivalent to its validated zero delta and avoids
packaging any base-layer tensor. MODULE_SCALE_MANIFEST.json retains the
explicit zero-head contract and records every logical module, source tensor
key, physical base weight, and scale. This release is from the completed Phase
A delta-scaling line; it is not the later failed NEXTGEN route and does not
include subsequent protocol-repair experiments.transformers and peft versions. Load the fixed base first, then
attach this adapter:1from peft import PeftModel
2from transformers import AutoModelForCausalLM, AutoTokenizer
3
4base_id = "Qwen/Qwen3-4B-Base"
5base_revision = "906bfd4b4dc7f14ee4320094d8b41684abff8539"
6adapter_id = "modrill/Qwen3-4B-Base-ThinkCode-A-NH025"
7
8tokenizer = AutoTokenizer.from_pretrained(base_id, revision=base_revision)
9base = AutoModelForCausalLM.from_pretrained(
10 base_id,
11 revision=base_revision,
12 torch_dtype="auto",
13 device_map="auto",
14)
15model = PeftModel.from_pretrained(base, adapter_id)
16
17messages = [{"role": "user", "content": "Write a Python function that checks whether a number is prime."}]
18prompt = tokenizer.apply_chat_template(
19 messages,
20 tokenize=False,
21 add_generation_prompt=True,
22 enable_thinking=False,
23)
24inputs = tokenizer(prompt, return_tensors="pt").to(model.device)
25eos_ids = [
26 tokenizer.eos_token_id,
27 tokenizer.convert_tokens_to_ids("<|im_end|>"),
28]
29outputs = model.generate(**inputs, max_new_tokens=2048, eos_token_id=eos_ids)
30print(tokenizer.decode(outputs[0][inputs.input_ids.shape[-1]:], skip_special_tokens=True))enable_thinking. Disable it for
direct code generation matching the concise screening style, or enable it when
explicit reasoning is desired. Pass both <|endoftext|> and <|im_end|> as
EOS IDs. Keep the combined prompt and generated sequence within 32K tokens,
the fixed base model configuration limit, unless a separate long-context
extension is validated.code_only aggregate was
794/3165 = 25.09%. Relative to the fixed BASE, the estimated change was
approximately +0.98 percentage points, with an approximate 95% confidence
interval of [+0.095, +1.833] percentage points. The Holm-adjusted
p-value was 0.489.seed=3407, some outcomes flipped between
PASS and TLE because of the execution environment. Those cases were resolved
by fixed single-CPU serial rejudgment, which does not eliminate all scorer,
timing, or environment uncertainty.