A rank-1 LoRA adapter for sudoingx/DeepSeek-V4.1-Flash-1017-EXL3-2.8bpw, built from 8,000 English and Chinese activation samples using a direction-ablation method based on Heretic and pqhaz's V4.1 recipe.
| Property | Value |
|---|---|
| Original model | DeepSeek-V4.1-Flash-1017 |
| Quantized base revision | aba08ea002ae271ee2a2724bcc0c6dc6e1c457b8 |
| Target modules | Attention output projection wo_b |
| Layers | 2–39, zero-based |
| LoRA rank / alpha | 1 / 1 |
| Projection strength | 2.5 |
| Factor precision | FP32 |
| Row normalization | Off |
The capture set contains 4,000 refusal-side prompts and 4,000 ordinary prompts. Each side contains equal numbers of English and Chinese prompts. The tuning set contains 400 prompts, and the final evaluation set contains 600 prompts, with the same language balance.
Capture inputs consist of questions and required context, up to 512 tokens. Preparation uses cross-source lexical deduplication and sampling matched by domain, language and length. data_provenance.json records source revisions, selection counts, domain distributions, the random seed and split hashes.
| Source | Capture prompts | Revision |
|---|---|---|
| OpenSafetyLab/Salad-Data | 1083 | d21a325e276a99bd69b1fbb8aa51a9f249486b72 |
| PKU-Alignment/PKU-SafeRLHF | 917 | 9421ffafec3fa40a1f1a7d567b4d525079477ecb |
| bench-llm/or-bench | 1871 | e36d8b80e81837c8a8f264bbb2a49f1b32c7e272 |
| HuggingFaceH4/no_robots | 129 | e6f9a4ac5c37faeb744ba9ecf0473184d7f8105b |
| thu-coai/Safety-Prompts | 2410 | 559ab9f24ce4621e3f839ef05e1075b6c4f125ee |
| m-a-p/COIG-CQIA | 1590 | 8b55868c6168adf86c30e7ca0f782cca1c514297 |
d.wo_b weights one block at a time. For each selected layer, construct A = d.T @ W and B = -2.5 * d, giving ΔW = B @ A. Export the factors as a PEFT adapter.Explicit refusal rates on the final refusal-side set, scored with bilingual lexical markers:
| Language | Base | Dev |
|---|---|---|
| en | 112/150 (74.7%) | 0/150 (0.0%) |
| zh | 36/150 (24.0%) | 0/150 (0.0%) |
Capability results on fixed subsets of MMLU (500 questions), GSM8K (100) and MBPP (100):
| Benchmark | Base | Dev | Difference |
|---|---|---|---|
| MMLU | 87.0% | 86.0% | -1.0 pp |
| GSM8K | 98.0% | 99.0% | +1.0 pp |
| MBPP | 88.0% | 89.0% | +1.0 pp |
The MBPP evaluation uses zero-shot prompts containing the task and public tests to specify the function interface, followed by execution in a restricted Python grader. Refusal evaluation uses the same concise-answer instruction for both models.
| Distribution metric | Measured | Screening target |
|---|---|---|
| Mean first-token KL on ordinary prompts | 0.99771 | ≤0.20 |
evaluation.json contains paired differences, confidence intervals, ordinary-prompt refusal rates, uncertain-output counts, KL statistics and API validation results.
Runtime: the patched vLLM v2.0/v5 engine from sudoingX/dgx-spark-deepseek-v41, with the included EXL3/multimodal LoRA compatibility patch and TP2 across two DGX Sparks.
Apply the patch inside the v5 image:
python3 runtime/apply.py --feature lora \
--site-packages /usr/local/lib/python3.12/dist-packages
Add these options to vllm serve:
--enable-lora \
--max-loras 1 \
--max-lora-rank 8 \
--lora-target-modules wo_b \
--lora-modules dev=/path/to/adapter
Select dev as the request's model ID. The base model ID and the adapter share one loaded base. The adapter rank is 1; the runtime rank capacity is 8.
API validation used eager execution, two concurrent sequences, a 16,384-token context limit, a 2,048-token scheduling batch, 0.5 GiB KV per rank and up to eight images.
adapter_model.safetensors and adapter_config.json: PEFT adapter.recipe.json: base revision, projection settings and weight hashes.data_provenance.json: dataset sources and sampling records.evaluation.json: evaluation results.runtime/: LoRA compatibility patch, installer and source fingerprints.checksums.json: file checksums.Model license: MIT. Runtime patches: Apache-2.0. Source datasets retain their respective licenses.