Instructions to use Glax147/kev-4b-ba-lora with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- PEFT
How to use Glax147/kev-4b-ba-lora with PEFT:
from peft import PeftModel from transformers import AutoModel base_model = AutoModel.from_pretrained("Qwen/Qwen3.5-4B-Base") model = PeftModel.from_pretrained(base_model, "Glax147/kev-4b-ba-lora") - Notebooks
- Google Colab
- Kaggle
KEV-4B BA-LoRA
KEV-4B BA-LoRA is a bias-aware post-trained direct-decision model. Given a state, a question, and a predefined candidate set, it assigns a probability to each candidate in a single forward pass rather than generating a free-form answer. This checkpoint was trained to improve candidate-space utilization on ordinal decision tasks while retaining the original KEV decision interface.
Model lineage
| Component | Source | Revision |
|---|---|---|
| Foundation model | Qwen/Qwen3.5-4B-Base |
1001bb4d826a52d1f399e183466143f4da7b741b |
| Initialization checkpoint | jaredpalmer/kev-4b |
139fdd94f1b6a6ad80cc15e08fcb99cac885a101 |
| Weights and configuration | Glax147/kev-4b-ba-lora |
7945a3045d890bfe8b92a6c283f103fee0b56e76 |
The released adapter_model.safetensors is the complete updated LoRA adapter relative to the pinned Qwen foundation model. It is not a second adapter that must be stacked on top of the original KEV adapter. The original KEV adapter and pointer head were used to initialize training; the complete updated adapter and jointly trained pointer head are included here.
Architecture and artifact contents
The checkpoint consists of:
- a PEFT LoRA adapter (
adapter_model.safetensors); - a KEV pointer head (
head.pt) trained jointly with the adapter; - tokenizer and chat-template files;
- the exact training configuration and training metrics.
The adapter uses rank 16, alpha 32, and dropout 0.05. It targets the attention, MLP, and Qwen3.5 hybrid projection modules: q_proj, k_proj, v_proj, o_proj, gate_proj, up_proj, down_proj, in_proj_qkv, in_proj_z, in_proj_a, in_proj_b, and out_proj.
head.pt is required. Loading the PEFT adapter alone does not reconstruct the direct-decision model.
Reproducibility environment
The run used Python 3.13.11 on Ubuntu 20.04.6 LTS with CUDA 12.4 and NVIDIA driver 550.54.14. The host exposed four NVIDIA GeForce RTX 4090 devices reported with 48 GB each, but this checkpoint was trained by a single CUDA process (world_size=1) on one GPU. The training code was run from commit 946c5ebad29350c67c086c2a01e7cc81d58c6440 of the accompanying experiment repository. See environment.json for the machine-readable run provenance and requirements.txt for the pinned reproduction dependencies.
Loading and inference
Use the official KEV codebase, which loads the adapter and pointer head and automatically downloads the pinned Qwen foundation model on first use:
git clone https://github.com/jaredpalmer/kev.git
cd kev
uv run --extra serve python -m kev.serve \
--run Glax147/kev-4b-ba-lora@7945a3045d890bfe8b92a6c283f103fee0b56e76 \
--port 8008
The model serves KEV's TypeSafe-compatible decision API. It is a direct-decision model, not a text-generation checkpoint, and should not be loaded as a conventional causal-language-model chat endpoint.
Training data
Training used a frozen index of 32,000 labeled training examples, with 4,000 indexed examples from each of eight sources selected for severe baseline candidate-space compression and the availability of public labeled training data:
- Civil Comments Toxicity;
- Word Concreteness;
- WMT20 Translation Quality;
- Measuring Hate Speech;
- RealToxicity Continuation;
- Wine Quality;
- IBM Argument Quality;
- HelpSteer2 Correctness.
Five indexed records exceeded the training context limit and were dropped deterministically, leaving 31,995 training requests. No validation split was used. Evaluation records were excluded from training by source identifier and normalized-text hash. Dataset licenses remain governed by their respective sources.
Training procedure
| Setting | Value |
|---|---|
| Method | BA-LoRA warm-started from KEV-4B |
| Trainable parameters | 33.8M adapter parameters plus pointer head |
| Epochs / optimizer steps | 2 / 1,000 |
| Learning rate | 1.5e-5 for adapter and pointer head |
| Micro-batch / gradient accumulation | 8 / 8 |
| Effective batch size | 64 |
| Optimizer | AdamW |
| Weight decay | 0.01 |
| Scheduler | OneCycleLR, pct_start=0.1 |
| Global gradient clipping | 1.0 |
| Precision | BF16 |
| Gradient checkpointing | Enabled |
| Seed | 42 |
| Maximum state length | 2,048 tokens |
| Maximum branch / packed length | 2,688 / 3,712 tokens |
| Wall-clock training time | 21,220.9 s (single CUDA process) |
Bias-aware regularization used an anchor/consistency weight of 0.025 with temperature 2.0 and cosine decay, diversity weight 0.005, and SVD weight 0.005 using the top 10 singular values with Frobenius normalization. The two-phase focus schedule used a 20% warm-up and 5% ramp. The released model is the final checkpoint after the fixed two-epoch run; no validation set or evaluation result was used for checkpoint selection.
Evaluation
The table reports dataset-level macro-averages before and after post-training. The evaluation panel contains 36 ordinal and four nominal datasets. The eight training-source evaluation subsets are disjoint from the post-training records by source ID and normalized-text hash. Higher is better for accuracy, hard-label utilization (U_arg), and QWK; lower is better for absolute support deviation (D_R), TVD, and normalized MAE.
| Evaluation group | Datasets | Accuracy | U_arg | D_R | TVD | nMAE | QWK |
|---|---|---|---|---|---|---|---|
| Training-source ordinal | 8 | 17.3 -> 32.7 | 45.7 -> 83.9 | 53.6 -> 14.4 | 52.9 -> 19.0 | 32.5 -> 17.8 | .240 -> .664 |
| Unseen-source ordinal | 28 | 38.0 -> 39.4 | 70.9 -> 78.0 | 26.8 -> 18.7 | 33.1 -> 27.6 | 22.5 -> 19.7 | .517 -> .590 |
| All ordinal | 36 | 33.4 -> 37.9 | 65.3 -> 79.3 | 32.8 -> 17.7 | 37.5 -> 25.7 | 24.7 -> 19.3 | .456 -> .606 |
| Nominal | 4 | 79.7 -> 80.3 | 94.8 -> 94.3 | 1.9 -> 1.4 | 9.9 -> 9.6 | -- | -- |
D_R = 100 |R - 1|, where R is the predicted-to-gold effective-support ratio. All percentage-valued metrics are reported in percentage points.
Intended use and limitations
This checkpoint is intended for research on direct-decision models, candidate-space utilization, ordinal decisions, and bias-aware post-training. It expects explicitly supplied candidate sets and does not generate open-ended answers. Results may depend on candidate wording, ordering, semantic coupling, and candidate-set size. Performance outside the evaluated task families has not been established.
License
The released adapter and pointer head are provided under the Apache License 2.0, following the licenses of the Qwen3.5 foundation model and the original KEV checkpoint. Training datasets retain their original licenses and terms of use.
Citation
@misc{glax1472026kev4bbalora,
title = {KEV-4B BA-LoRA: Bias-Aware Post-Training for Candidate-Space Utilization},
author = {Glax147},
year = {2026},
howpublished = {Hugging Face model repository},
url = {https://huggingface.co/Glax147/kev-4b-ba-lora},
note = {Weights and configuration revision 7945a3045d890bfe8b92a6c283f103fee0b56e76}
}
- Downloads last month
- 47
Model tree for Glax147/kev-4b-ba-lora
Base model
Qwen/Qwen3.5-4B-Base