Nokia Makes AnyJev Open Source: A Training-Free Layer That Converts Any Open LLM into a Calibrated Decision Model
Nokia open-sources AnyJev, a Python layer that calibrates open LLM decisions via cyclic shifts, prior correction, and optional L1 scaling.
Key Takeaways
- Nokia AnyJev is an Apache-2.0 Python library that turns open LLMs into calibrated decision models without training, using next-token probabilities for fixed-set choices.
- It addresses two common flaws in simple label-score methods: position bias via cyclic shifts and prior bias via calibration, with L0 requiring zero labels.
- L1 optionally adds temperature scaling using 100–500 labels per question, improving confidence calibration without changing answer rankings.
- Benchmarks show large gains over raw logits: lower option-order flip rates, higher accuracy, lower expected calibration error, and more auto-decidable predictions.
- It supports practical deployment through PyPI, transformers/vLLM backends, shared-prefix scoring, and typed questions for routing, tagging, and triage.
Meta description: Nokia AnyJev is an Apache-2.0 Python library that turns open LLMs into calibrated decision models without training, using cyclic shifts and prior correction.
Tags: Nokia AnyJev, open LLM, decision model, calibration, Apache-2.0
Featured image: abstract technology style, no real people, no company logos, no text.
Nokia AnyJev, open-sourced by Nokia's applied research team, is a Python library that turns an open LLM into a decision model without training. The package installs from PyPI under Apache-2.0 and provides transformers and vLLM backends with shared-prefix scoring. It matters because many production systems need to pick one answer from a fixed set rather than write a sentence, and unstable next-token scores can make routing, tagging and triage harder to automate.
Background: Jev's Interface Arrives as a Training-Free Layer
The release follows TypeSafe AI's September 2026 launch of Jev, a System One decision model. AnyJev borrows Jev's interface: a user supplies a typed question and receives a decision with a probability that can be thresholded. The probability comes from the model's next-token distribution. Nothing is generated, parsed, or trained. The target is a common production job: choosing one answer from a fixed set instead of writing a sentence.
Development: L0 and L1 Address Position and Prior Bias
AnyJev supports 3 question types: a choice question picks one of K options; a noul question is yes or no; a score question places the answer in one of several ordered bins. Nokia's research team notes that many open projects restrict the next token to option labels and read scores. It flags 2 flaws: the answer can change when options are reordered, and probabilities are not calibrated. The levels doc names prior bias and position bias. Prior bias means the model favors labels such as "Yes" over "No" whatever the input. Position bias means the model favors certain slots in the option list.
Each decision carries a level field. L0, zero labels and on by default, applies 2 fixes. Cyclic shifts show a K-option list in K rotations so every option appears in every position once. Results are combined in log space as a geometric mean. If position bias is additive in logit space, this removes it exactly. Prior correction uses batch calibration by default, keeping a running mean of predicted distributions on real inputs and dividing it out at strength 0.75 after 8 items. L0 costs K prefills per decision, batched over a shared prefix. With K = 20, the report cites about 0.25 s per decision at batch 32 on one H100.
L1, using 100 to 500 labels per question, adds temperature scaling on top of L0. Fitted values are saved as a small JSON artifact. L1 reshapes confidence but does not change the ranking of answers.
Progress: Benchmarks, Serving and Open-Source Use
On Qwen3-8B with BANKING77, a 20-way task with 300 test items, raw logits required 0 labels, had a flip rate when options reversed of 0.230, accuracy of 0.747, expected calibration error (ECE) of 0.240, and 7.7% auto-decidable at 5% error. AnyJev L0 also required 0 labels, cut the flip rate to 0.073, raised accuracy to 0.803, reduced ECE to 0.184, and made 46.3% auto-decidable at 5% error. AnyJev L1 required 100 to 500 labels, had a 0.077 flip rate, 0.807 accuracy, 0.095 ECE, and 52.0% auto-decidable at 5% error.
The repo reports that L0 reduced order flips on all 9 model and task rows tested. On a typed-decisions set, Qwen3-32B with L1 reached an ECE of 0.036, compared with 0.144 published for Jev. On accuracy, the fine-tuned Laya still leads. The full ablation table covers Qwen, OLMo, Granite, Phi and Mistral models. Wu says the team tried AnyJev on an internal Nokia routing problem and saw promising results.
Usage begins with `pip install "anyjev[hf]"`. After `from anyjev import Decider, Question` and `from anyjev.backends.hf import HFBackend`, a developer can create `Decider(HFBackend("Qwen/Qwen3-8B"))`, define `Question.choice("Which team should handle this?", ["billing", "technical", "sales", "other"], name="route")`, call `d.decide({"conversation": [...]}, [route])`, and read `r["route"].distribution` for probabilities per option. For serving, vLLM can be started with prefix caching and a `VLLMBackend` can point to it.
AnyJev is now a training-free layer for fixed-set decisions. The original item appeared first on MarkTechPost. The next point to watch is how teams apply its level field in production: L0 for zero-label calibration, L1 when 100 to 500 labels per question are available, and shared-prefix serving when latency matters.
Comments
No comments yet. Be the first to comment.