lumen / README.md
harrrshall's picture
add lumen training curve
c83ad23 verified
|
Raw
History Blame Contribute Delete
3.4 kB
---
license: apache-2.0
library_name: peft
base_model: Qwen/Qwen3.5-4B
pipeline_tag: text-generation
tags:
- accessibility
- code
- react
- html
- saferepair
---
# Lumen estimated ~200× lower inference cost with frontier competitive saferepair
Lumen is a 4b model for automatically verifiable accessibility attribute repair in react and static html. on a matched 43-task development benchmark, Lumen completed 42 safe repairs, compared with 40 for gpt-5.6 sol and 43 for claude opus 4.8.
this repository is the lightweight 252 mb lora adapter edition of Lumen. it requires the exact qwen3.5 4b base checkpoint shown below.
most users should use the standalone [harrrshall/lumen-merged](https://huggingface.co/harrrshall/lumen-merged) repository instead. it is approximately 9.1 gb, loads directly with transformers, and does not require attaching a separate adapter.
## quick start for this adapter
```python
import torch
from peft import PeftModel
from transformers import AutoModelForImageTextToText, AutoProcessor
base_id = "Qwen/Qwen3.5-4B"
base_revision = "851bf6e806efd8d0a36b00ddf55e13ccb7b8cd0a"
processor = AutoProcessor.from_pretrained(base_id, revision=base_revision)
base = AutoModelForImageTextToText.from_pretrained(
base_id,
revision=base_revision,
dtype=torch.bfloat16,
device_map="auto",
)
model = PeftModel.from_pretrained(base, "harrrshall/lumen")
model.eval()
```
do not download both editions. choose `lumen-merged` for a simple standalone setup, or this adapter when you already store the pinned base model and want the smaller download.
Lumen generates small structured patches for automatically verifiable accessibility defects in react and static html source code.
## model details
| field | value |
|---|---|
| model name | Lumen |
| base model | qwen3.5 4b |
| training method | qlora supervised fine tuning |
| working context | 16,384 tokens |
| output | structured source patch |
| license | apache 2.0 |
## frontier comparison
| system | tasks | saferepair | cost per safe repair |
|---|---:|---:|---:|
| **Lumen** | 43 tasks | 42/43 (97.67%) | $0.000268 |
| gpt-5.6 sol | 43 tasks | 40/43 (93.02%) | $0.070857 |
| claude opus 4.8 | 43 tasks | 43/43 (100%) | $0.054012 |
## evaluation gate
browser saferepair requires target findings to be removed without new findings, plus passing builds, selected tests, keyboard and focus checks, semantic and functional invariants, visual policy, protected path checks, and evaluator evasion controls.
## training data
the current synthetic corpus contains 637 verified training tasks, 100 development tasks, and 100 sealed synthetic tasks. the trajectory set contains 30,576 training records and 100 development records. a11ybench is reserved for evaluation and excluded from training.
## training curve
![Lumen training curve](figures/lumen-training-curve.png)
## intended use
- accessibility repair assistance in code review
- validated patch generation for continuous integration
- scoped remediation for react and static html repositories
- private deployment for source sensitive workflows
## limitations
Lumen covers deterministic source repair families supported by its evaluator. it does not establish complete wcag or legal conformance. review every patch before merging, and involve qualified accessibility practitioners and assistive technology users for subjective decisions.