hf_mirrors/LemonDecider
Model Introduction
Files & versions
Analysis

LemonDecider 4B

Model ID: lemondecider-4b-20261104-v3
Base model: Qwen/Qwen3.5-4B

This v3 release makes typed decisions from a shared text state and named questions. It returns choice probabilities, yes/no probabilities (noul), or ordinal scores without generating an answer token stream. Requests that fit use one joint forward; overlength question lists are recursively bisected, preserving the complete state and every option in each chunk. Inputs are never truncated.

Model description

PropertyValue
ArchitectureQwen3.5-4B hybrid backbone with a 255-option decision readout
Loadermodeling_lemondecider.LemonDeciderForDecisionClassification, trust_remote_code=True
Model type / protocollemondecider_decision / lemondecider-v1
AttentionNoncausal periodic full-attention layers; hybrid recurrent layers; SDPA
ReadoutNative inline joint-question readout (joint_readout.predict_joint)
Temperature1.0026751894886363, inherited from the parent checkpoint; not refit
Capacity8192 tokens per chunk including template; at most 255 options per question
Serving strategyrecursive-question-bisection-v1; short requests are not split
PrecisionBF16 loading; model-specific readout precision preserved by packaged implementation
Serialized tensors724
ModalitiesPublished HTTP service is text-only
RuntimePython 3.12; evaluated runtime recorded Torch 2.9.0, Transformers 5.17.0, FLA 0.5.2

Training

LemonDecider 4B v3 was fine-tuned (SFT) from a common Qwen3.5-4B initialization on 1,199,692 decision/QA rows (about 1.20M training rows, with separate development, calibration and test splits). The released weights are a uniform FP32 average of four checkpoints from the same SFT run, followed by scalar temperature calibration—not a combination of two independent training runs.

Question formats: choice (up to 255 options; 84.4%), noul (no/yes; 15.2%) and score (ordinal ratings; 0.4%). This training run is text-only, with the vision tower frozen. The original training corpus retains joint-question grouping where applicable; the single-record export preserves the question-level content but removes grouping metadata and is not an exact reproduction of the original joint-training layout.

Data categories:

  • Service and action decisions — user-intent routing, case classification, agent-action safety and policy judgments;
  • Language judgment — sentiment, sarcasm, natural language inference, factuality and paraphrase-style checks;
  • Knowledge and reasoning QA — multiple-choice knowledge, commonsense and logical reasoning, arithmetic and math word problems;
  • Retrieval and selection — relevance judgments, information retrieval and product selection;
  • Preference and quality judgments — helpfulness, correctness, safety and response-quality comparisons;
  • Probability and ordinal judgments — yes/no probabilities and ordered ratings.

Training parameters (from the recorded configuration and training log):

  • Distributed FSDP with full sharding on 16 accelerators;
  • One epoch, 4,690 optimization steps, effective batch size 256, learning rate 2e-6;
  • Maximum sequence length and token budget 8,192; native joint-question inline readout;
  • Objective recorded as option_cross_entropy; choice permutation global-reference; text-only inputs and frozen vision tower;
  • Warmup ratio 0.15, weight decay 0.01, gradient clipping 1.0, gradient checkpointing enabled;
  • Precision policy fp32-master-bf16, BF16 serving load, SDPA with noncausal full attention;
  • Four-checkpoint weight averaging; final temperature 1.0026751894886363, fitted on 1,448 held-out calibration rows.

The corpus manifest records fingerprint-based filtering against protected JevBench and Decision Index evaluation inputs, while some source collections include benchmark training splits. This is not a blanket guarantee of zero overlap, nor a claim that every upstream source has permissive redistribution terms; source-specific terms still require review.

Package artifacts

Weight files

FileBytesSHA-256
model-00001-of-00002.safetensors4,973,336,47249d5d5302c6457507ec3d0bc424248352344d44fab47a216a4a8e73e4975d490
model-00002-of-00002.safetensors4,106,591,800f1b25448bae5837b10bdf1d7854fd75414d2c7439b1f288331e740d7fbdf43a9
tokenizer.json19,989,4926f32ce20dc35f57a7f9ad1eac03525bd7d30f9df8cea6507e958279cc3657706
model.safetensors.index.json68,426f78614fd6c201725fe3f749e71474375eabe2c2f3029c5eb7d1880da42143320

The repository keeps the HF model/processor/tokenizer layout. joint_readout.py is required for the reproducing joint bridge; code/ provides the joint CLI and local HTTP service; tests/ contains chunking regression tests. The root model.py remains only for the old independent-question path and is not the recommended reproducing CLI.

Evaluation results

1) Decision Index, edition 0.4 — full public suite

On 2026-11-04, this model was evaluated over the complete public 0.4 suite using 16 PPU-ZW810E workers. The run was joint inference plus iterative question bisection. The official scorer reported complete: true. The underlying selected file contains 140,620 rows: 140,178 scoreable requests and 442 officially excluded requests. The benchmark-native summary counts 140,148 answered / 30 unsupported requests; unsupported requests remain in index coverage.

HeadlineValue
Decision Index (public 0.4)61.67
Raw index70.84
Breadth skill60.28
Median / mean / p95 request latency49.9 ms / 121.2 ms / 286.9 ms

This is a self-evaluated complete public-suite run, not a private Full score or submission-accepted leaderboard result. Latency is HTTP request wall time on a 16-worker PPU run, not official single-GPU latency admission.

Per-area scores

AreaRawSkillCoverageBenchmarks
Knowledge & Reasoning0.53200.40630.999811
Language Understanding0.76160.66741.00009
Retrieval & Classification0.76800.69091.00006
Tools & Automation0.80290.78170.99865
Arts & Human Taste0.73450.57900.99796

Per-benchmark native scores (★ = included in the public index)

The Score column uses each benchmark's native headline metric. Skill and coverage come from the official index report; area weighting and chance correction can therefore make Skill differ from Score. iSarcasmEval uses its English track-A headline, matching the suite's selected summary. All values are generated from this model run, not from the earlier v3 card.

#BenchmarkMetricRequestsScoreSkillCov.
1BFCL ★case exact accuracy1,6940.95280.93621.0000
2ToolRet ★nDCG@106850.63540.57680.9971
3API-Bank ★accuracy5080.84780.84150.9961
4BANKING77 ★macro-F13,0800.93170.93081.0000
5CLINC150+OOS ★macro-F15,5000.94230.94201.0000
6RouterBenchselected quality (quality objective)10,0000.79360.51611.0000
9Home appliance simulator ★case exact accuracy880.64770.64771.0000
10SGD/SGD-Xmacro-F12,5000.42530.04381.0000
11ContractNLI ★macro-F11230.86840.80971.0000
12ANLI ★macro-F13,2000.72030.58101.0000
20BPoMP ★accuracy5,0000.98580.97151.0000
21Humicroedit ★accuracy2,6280.63200.26411.0000
22POP909-CL ★accuracy2,0000.83390.81970.9875
23cfcolor ★accuracy5,0000.74460.43361.0000
24MMLUaccuracy14,0330.79400.72531.0000
25GPQA Diamond ★accuracy1960.46430.28571.0000
26ARC-Easyaccuracy2,3760.98820.98431.0000
27ARC-Challengeaccuracy1,1720.95480.93971.0000
28WinoGrande ★accuracy1,2670.89420.78841.0000
29HellaSwag ★accuracy10,0420.95110.93481.0000
30GSM8K ★accuracy2,6380.63910.56801.0000
31ChessBench ★accuracy5,0000.12200.04371.0000
32MuSR ★accuracy7520.60370.37001.0000
33SATA-Bench ★case exact accuracy1,6500.26360.25381.0000
34SimpleBenchaccuracy100.10000.00001.0000
36BRIGHT ★nDCG@102200.44850.37621.0000
37Amazon ESCI ★macro-F15,0000.60070.49911.0000
38ACOS ★per-review F11,5650.33410.31281.0000
39FinEntity ★macro-F19790.93310.90161.0000
40iSarcasmEval ★see separate subtask tracks4,6000.60760.49521.0000
41VAST ★macro-F13,0060.76830.65241.0000
42NLI4CT ★macro-F15,5000.80510.62081.0000
43CRUXEval ★accuracy5700.63330.41821.0000
44CLadder ★accuracy5,0000.79600.59201.0000
45HLE ★accuracy5010.11400.00000.9980
50Habermas Machine ★accuracy1,6760.60920.43281.0000
56PhishNChips phishing decisions ★accuracy2,0000.78900.57801.0000
57MMLU-Pro ★accuracy12,0320.59100.54001.0000
58BBH fixed-option tasks ★accuracy5,5070.70860.57761.0000
59RAGTruth response-level hallucination ★F1 on hallucinated class2,7000.83710.66221.0000
61HoVer claim verification ★accuracy4,0000.89220.78441.0000
62When2Call MCQ ★accuracy3,6520.89760.86351.0000
64New Yorker caption matching ★accuracy5280.64200.55251.0000

The repository intentionally omits results.jsonl, benchmark labels, raw logs and suite inputs. If separately publishing evaluation evidence, attach immutable model weights and an immutable results dataset rather than editing predictions.

Usage

Install a hardware-compatible Torch 2.9.0 build in a Python 3.12 environment, then install the stated pure-Python dependencies. The requirements file is a candidate recipe rather than a vendor-validated NVIDIA lockfile. Download the entire model directory before loading; custom code executes during loading, so inspect configuration_lemondecider.py, modeling_lemondecider.py and joint_readout.py first.

python -m pip install -r requirements.txt

Python: native joint decisions with capacity-aware chunking

import json
import sys
from pathlib import Path

checkpoint = Path("./LemonDecider").resolve()
sys.path.insert(0, str(checkpoint / "code"))
from serve_312k import LemonDeciderHFService

service = LemonDeciderHFService(checkpoint, "cuda:0", None)
request = {
    "state": "The customer wants to return a damaged package.",
    "questions": {
        "action": {
            "type": "choice",
            "instructions": "Choose the next action.",
            "criteria": {
                "refund": "Offer a refund",
                "tracking": "Check tracking"
            }
        },
        "damaged": {
            "type": "noul",
            "instructions": "Is the package damaged?"
        }
    }
}
print(json.dumps(service.predict(request), indent=2))

CLI and HTTP

From this repository root:

python code/verify_files.py
python tests/test_chunking.py
CUDA_VISIBLE_DEVICES=0 python code/infer.py --input examples/request.json
# Alternatively, start the local HTTP service:
CUDA_VISIBLE_DEVICES=0 bash code/serve.sh
# In another terminal:
python code/smoke_test.py

HTTP endpoints are GET /health, GET /v1/models, and POST /v1/systemone. The service binds to localhost by default. Use LEMONDECIDER_API_KEY for optional bearer authentication. The local smoke client assumes that variable is unset.

A long question list is recursively bisected in original order. Each chunk contains the complete state and every option. Planning finishes before the first model forward, so a singleton that cannot fit rejects the entire request with HTTP 422. Answers retain their original IDs, and input usage sums all chunks including repeated state. No reread, option pruning or benchmark-specific rendering is performed.

No new GPU inference was performed merely to rename the public loader. The AutoConfig loader is checked offline in this package, the remote-code modeling implementation is functionally equivalent to the evaluated implementation after class and protocol naming normalization, and the two safetensors files retain the exact evaluated model hashes above. Path-adjusted users should still run tests/test_chunking.py; production users should smoke-test once on their own hardware and accelerator build.

Intended use & limitations

  • Designed for option-based routing, classification, structured choices and typed decision endpoints, not open-ended text generation.
  • A probability output does not imply a correctness or calibration guarantee.
  • Capacity is 8192 tokens per chunk, not the backbone's 262144-position setting.
  • A long shared state cannot be shortened to make a question fit.
  • The HTTP bridge is text-only. Vision tensors in the checkpoint do not imply a supported public image API or a reported vision benchmark result.
  • Iterative bisection is part of the release contract; omitting it changes behavior on overlength joint requests.
  • Unsupported cases remain in scoring coverage. Public results do not establish performance on private tests, unseen domains or real-world traffic.
  • The published service is not a safety system. Validate decisions for the domain, locale, language and affected population before deployment.

License

LICENSE is Apache-2.0 and LICENSE.code is MIT. Both are retained from the LemonDecider export. The Qwen3.5-4B base model remains subject to its own upstream terms. Applicable upstream copyright, license and notice obligations pass through to users. This packaging does not expand rights over training data or evaluation data.

Acknowledgements

This model family builds on the Qwen backbone and the typed-decision runtime work used in LemonDecider. Attribution and notices remain in the packaged license files.