You need to agree to share your contact information to access this model

This repository is publicly accessible, but you have to accept the conditions to access its files and content.

Log in or Sign Up to review the conditions and access this model content.

YAML Metadata Warning:empty or missing yaml metadata in repo card

Check out the documentation for more information.

EXAMI Domain Reranker Adapters β€” MLX (Apple Silicon)

MLX-format domain LoRA adapters for the 4-bit base arthurcollet/Qwen3-VL-Reranker-2B-mlx-4bit, covering the 24 EXAMI domains. These are the MLX conversions of the PEFT adapters in Bei0001/reranker-domain-adaptors β€” same LoRA weights, applied on-device on top of the quantized base (no torch/PEFT at inference).

Design: 5 adapters + base for the Math/CS cluster

21 of 24 domains are served by 5 adapters. Mathematics, Computer_Science, and Information_Technology route to the BASE reranker (no adapter) β€” fine-tuning degrades Math (embedding-mined "hard negatives" are often valid answers), and CS/IT are already at ceiling on base.

Adapter Domains Hard-eval MRR (base β†’ adapter)
physical-sci-eng Physics, Chemistry, Engineering, Earth_and_Environmental_Sciences 0.961 β†’ 0.985
life-health Biology, Medicine, Agriculture_and_Veterinary 0.954 β†’ 0.998
social-behavioral Psychology, Economics, Social_Sciences, Education 0.973 β†’ 0.988
business-law-prof Business, Law, Communications_Journalism_and_Information, Services 0.968 β†’ 0.990
humanities-arts History, Philosophy, Literature, Religion_and_Theology, Art_and_Design, Music 0.890 β†’ 0.985

(Eval metrics in eval_hard/*.json are from the FP16/full-precision PEFT adapters; the MLX fp16 weights are numerically equivalent β€” applying onto the 4-bit base preserves the lift.)

Format

Per group: adapters.safetensors (224 tensors, ~25.7 MB, fp16) + adapter_config.json.

These differ from the PEFT adapter_model.safetensors in the source repo:

  • dtype fp32 β†’ fp16 (equivalent: e.g. 0.9996 vs 0.9997 on a probe).
  • layout PEFT ...lora_A/lora_B.weight ([r,in]/[out,r]) β†’ mlx-lm ...lora_a/lora_b (transposed to [in,r]/[r,out]); keys remapped to the base model's parameter paths (language_model.model.layers.N.self_attn.{q,k,v,o}_proj.lora_a/lora_b).
  • scale alpha/r = 64/32 = 2.0 is recorded in adapter_config.json (lora_parameters.scale), so it does not need to be folded into the weights.

Usage

from rerank import DomainReranker          # needs mlx, mlx-lm, transformers
rr = DomainReranker()                       # loads the 4-bit MLX base + scaffolds LoRA
results = rr.rerank("Biology", "How do vaccines create immunity?", [doc1, doc2, ...])
# Mathematics / Computer_Science / Information_Technology -> base (no adapter), handled automatically.

Scoring = sigmoid(logit_yes - logit_no) on the adapters' native judge prompt (rr_common framing, baked into rerank.py); results pass the two-signal cutoff (floor 0.05 + largest-gap).

Apply manually (mlx-lm):

from mlx_lm import load
from mlx_lm.tuner.utils import linear_to_lora_layers
import mlx.core as mx
model, tok = load("arthurcollet/Qwen3-VL-Reranker-2B-mlx-4bit")
linear_to_lora_layers(model, 28, {"keys": ["self_attn.q_proj","self_attn.k_proj",
    "self_attn.v_proj","self_attn.o_proj"], "rank": 32, "scale": 2.0, "dropout": 0.0})
model.load_weights("physical-sci-eng/adapters.safetensors", strict=False)

Files

  • <adapter>/ β€” adapters.safetensors (mlx-lm LoRA, fp16) + adapter_config.json
  • pipeline_config.json β€” base model, 24-domainβ†’adapter map (Math/CS/IT β†’ base), LoRA params, eval
  • rerank.py β€” MLX inference + scoring + two-signal cutoff
  • eval_hard/*.json β€” full hard-eval metrics per adapter (from the source PEFT adapters)

Source (PEFT/training) repo: Bei0001/reranker-domain-adaptors.

Downloads last month

-

Downloads are not tracked for this model. How to track
Inference Providers NEW
This model isn't deployed by any Inference Provider. πŸ™‹ Ask for provider support