Lev – Open-Source Decision Model Developed by Lehigh University and Others: On-Demand Deep Thinking under Native Cyclic Architecture

Executive Summary:
Lev is an open-source decision model introduced by academic institutions including Lehigh University. Its core innovation lies in its native cyclic architecture (Ouro/Nanbeige), which enables the same...
1. What is Lev
Lev is an open-source decision model introduced by academic institutions including Lehigh University. Its core innovation lies in its native cyclic architecture (Ouro/Nanbeige), which enables the same set of weights to be repeatedly computed across multiple cycles. In each cycle, it reads the option probabilities and uses a lightweight stopper mechanism to dynamically determine the number of computation cycles based on the difficulty of the question—simple questions are answered in one cycle, while complex ones undergo multiple cycles. On the JevBench benchmark, the same checkpoint achieved an accuracy increase from 63.2% with one cycle to 76.2% with four cycles, while consuming only about 80% of the computational resources, with an accuracy loss of less than 1 percentage point. This design breaks the traditional dilemma in decision models where latency and accuracy cannot be simultaneously optimized, offering a novel technical approach for decision scenarios requiring real-time responses.

Technical Positioning and Domain: Lev belongs to the intersection of natural language processing and decision intelligence, focusing on decision tasks that directly output option probabilities from text states and candidate options. Its uniqueness lies in treating "cyclic depth" as a dynamically adjustable computational dimension, rather than the fixed forward pass used in traditional models.
Development Background: Developed by academic teams from Lehigh University and others, Lev serves as an open-source counterpart to TypeSafe AI's commercial product Jev. The team chose to use the native cyclic language models Ouro and Nanbeige4.2, which are pre-trained with per-cycle supervision, as the foundation, rather than retrofitting cycles onto dense models. This choice reflects a deep consideration of the model architecture at the foundational level.
Core Value: The central problem Lev addresses is the rigid trade-off between latency and accuracy in decision scenarios. Traditional approaches require deploying multiple models for different budgets, whereas Lev covers the entire range—from millisecond-level quick responses to deep thinking—using a single set of weights. Furthermore, the stopper mechanism automatically allocates computational resources to complex questions, achieving the principle of "computing where it matters most."
Technical Features: It employs a native cyclic architecture to enable multi-cycle computation, with the same set of decoding layers running repeatedly and reading option probabilities in each cycle. The stopper mechanism allows per-question on-demand stopping, calibrated not for "correct answers" but for "alignment with the deepest answer," supporting label-free self-calibration. In the low-latency range of 39–46ms, Lev outperforms cascaded solutions by 7.0–8.8 percentage points.
2. Key Features
One-pass Forward Decision-Making: After reading in the state, question, and candidate options, it directly outputs the probability distribution for each option without generating any reasoning text. This "decision-as-classification" interface design significantly reduces inference latency, avoiding the common verbose intermediate outputs of generative models in decision-making tasks, allowing the model to complete the core task with minimal computational overhead.
Iterative Deep Thinking: The same set of decoding layers runs multiple rounds, with each round continuing computation based on the hidden states from the previous round and re-reading the option probabilities. Due to full weight sharing, a single model supports arbitrary depth of reasoning, from one-round fast responses to four-rounds or even deeper fine-grained reasoning, all covered by a single checkpoint without the need to separately train or deploy models for different depths.
Per-Question On-Demand Termination: A lightweight stopper is built-in to predict whether the current answer is consistent with the answer from the deepest round. It automatically determines the number of computation rounds based on the difficulty of the question. Easy questions can exit after one round, while complex ones are automatically allocated more computational resources, achieving dynamic allocation of computational load at the question level, rather than a fixed depth of computation for all inputs.
Switchable Latency and Accuracy: A single set of weights can flexibly switch between millisecond-level fast responses and deep reasoning. Users can adjust the maximum number of iterations based on their business needs without deploying multiple models for different latency budgets. This feature is reflected in JevBench as a continuous adjustable accuracy range for the same checkpoint, from 63.2% with one round to 76.2% with four rounds.
Unsupervised Self-Calibration: The stopper is calibrated based on the target of "whether the current answer is consistent with the deepest answer," rather than the traditional "whether the answer is correct." This allows direct calibration using unlabeled traffic from proprietary business scenarios, requiring only about 500 questions per fold. This design significantly lowers the deployment threshold, enabling enterprises to fine-tune the stopper's threshold without manual labeling.
Resume Calculation Without Re-reading: Computation resumes directly from the hidden states of the previous round, avoiding the latency cost of re-reading the input each time reasoning depth increases in cascaded approaches. For decision-making scenarios involving long states and multiple questions, this feature significantly reduces resource waste caused by redundant computations.
3. Application Scenarios
Intelligent Customer Service Intent Routing: In customer service systems, simple inquiries (such as checking account balances or changing passwords) can be resolved in one pass with millisecond-level response times, while complex complaints or multi-turn dialogues automatically undergo additional passes to improve routing accuracy. A single weight configuration can balance response speed and intent recognition quality, eliminating the maintenance costs of traditional dual-system approaches.
Content Moderation with Tiered Handling: For clearly违规 or fully compliant content, the model can quickly approve or block it in one pass. For ambiguous content in the gray area, the stopper automatically allocates more computational depth for precise judgment. In practical deployment, this can save 15%–24% of computational resources while reducing missed judgments and false positives.
Agent Tool Calling Selection: When an agent is performing a task, mechanical steps (such as reading files or formatting output) can be handled in one pass to maintain smooth execution, while key decision points (such as selecting which API to call or determining the user's true intent) automatically require deeper computation to avoid wasting time and resources on incorrect tool choices.
E-commerce Recommendation Real-time Re-ranking: For regular traffic, shallow sorting is used to ensure response speed, while high-value positions such as the first screen during major promotions or personalized recommendation slots automatically undergo deeper computation to improve sorting accuracy. The stopper dynamically allocates computational resources based on the difficulty of each task, ensuring stable service quality even during traffic peaks.
Financial Compliance Document Classification: Financial scenarios have strict data compliance requirements, and Lev can be fully offline and self-hosted to prevent data from leaving the domain. Enterprises can use their own unlabeled business traffic to calibrate the stopper. For complex compliance document samples, the model automatically increases computational depth to reduce the risk of misjudgment, balancing compliance requirements with processing efficiency.
4. How to Use
Environment Requirements: Requires a Linux or Windows environment that supports PyTorch. It is recommended to have an NVIDIA GPU with at least 8GB of VRAM to run the 2.6B model. Additionally, you need to install the Hugging Face Transformers library and the PEFT library to load the LoRA adapter.
Get the Code and Model: Clone the Lev repository from GitHub using the command
git clone https://github.com/OpenLAIR/lev.git; then download the corresponding base model (Ouro or Nanbeige4.2), as well as the Lev checkpoint and LoRA weights from Hugging Face, and place them in the designated directory.Prepare Input Data: Package the state, question, and their respective options into a single sequence. The model uses block causal masking to ensure that each question can only see the shared state and its own question text. The state is encoded only once, but each question can be answered independently. The input format must strictly follow the example template provided in the repository.
Select Loop Depth and Load the Model: Determine the maximum number of loops (e.g., 1 to 4), and load the shared pointer head and LoRA adapter. You can specify the inference depth via a configuration file or command-line arguments. The model will dynamically decide the actual number of computational loops per question within this range.
Iterative Inference and Output: The same set of decoding layers runs iteratively. After each loop, read the probability at the end of each option and the
<decide>marker. Since the hidden state from the previous loop can be directly used for the next calculation, there is no need to re-read the input, keeping the additional overhead of multi-loop inference at a low level.Apply Stoppers and Deploy Calibration: Use the trained logistic regression stopper to determine whether the current answer has already aligned with the deepest loop's answer. If so, inference can be stopped early. Before deployment, it is recommended to calibrate the temperature and stop thresholds for each depth using unlabeled requests from your own business. Set the threshold to the minimum value that ensures at least 98% consistency with the deepest answer, to better align with the actual business distribution.
5. Pros and Cons Analysis
| Pros |
|---|
| Single Weight with Multiple Workload Points: The same checkpoint can flexibly switch between quick responses and deep thinking by adjusting the number of iterations, eliminating the need to deploy separate models for different latency budgets and significantly reducing deployment and maintenance costs. |
| Significant Gains on Challenging Tasks: On JevBench, the same weight achieves a 63.2% accuracy with one iteration and improves to 76.2% with four iterations. The improvement mainly comes from standard and challenging questions, indicating that the iterative mechanism provides substantial assistance for complex decision-making. |
| High Computational Efficiency: The stopper automatically allocates more computation to challenging tasks, achieving near-full-depth accuracy with only about 76%–85% of the computational resources. This results in better computational resource utilization compared to fixed-depth approaches. |
| Label-Free Self-Calibration Mechanism: The stopper aims to align with the deepest answer and can be directly calibrated using internal business traffic. Approximately 500 questions per fold are sufficient, significantly lowering deployment barriers. |
| Dominant in Low Latency Range: In the 39–46ms latency range, it outperforms the cascaded approach by 7.0–8.8 percentage points and the best dense approach by 5.4–7.5 percentage points, effectively balancing speed and quality. |
6. Comparative Analysis with Similar Tools
| Comparison Dimension | Lev (Example: Lev-2.6B) | Jev | Traditional Dense Decision Model |
|---|---|---|---|
| Core Architecture | Native cyclic base (Ouro), same set of layers reused in multiple cycles, probabilities read out sequentially per cycle | Dense architecture, single forward pass with a single readout, no cyclic mechanism | Standard Transformer, single forward pass outputting probabilities |
| Parameter Scale | 2.6B (other versions available: 1.4B, 3B) | Not disclosed | Varies by model, typically 1B–10B |
| JevBench Accuracy | 76.2% (four cycles); 63.2% with one cycle | Approximately 86.6% (200/231, third-party tested) | Varies by specific model, typically lower than cyclic approaches |
| Latency Performance | Local latency 39–150ms (varies by depth) | Hosted API p50 ~616ms (includes network transmission) | Fixed latency, typically 30–80ms |
| Computational Depth Adjustment | One set of weights with multiple operating points, automatically computes more for difficult tasks | Fixed single forward pass, no depth adjustment capability | Fixed computational load, cannot be adjusted on demand |
| Calibration Method | Temperature scaling and stopper calibration per depth (no labels required) | Ready-to-use, high calibration quality (ECE 0.053) | Requires manually annotated validation set for calibration |
| Deployment Method | Fully offline self-hosted, supports private deployment | Closed-source hosted API, data must leave the domain | Can be self-hosted or via API call |
| Open Source License | Fully open source (code/weights/data) | Closed-source commercial product | Varies by model |
| Cost Structure | Weights are free, self-hosting cost depends on your own GPU | Approximately $32 per million decisions (with examples), billed by input tokens | Self-hosting or API costs |
| Ecosystem Maturity | Academic prototype, community under development | Production-grade commercial service, continuously iterated | Mature ecosystem, comprehensive toolchain |
Selection Recommendations: For teams requiring full data compliance and wishing to have autonomous control over the trade-off between latency and accuracy, Lev's open-source nature and calibration mechanism without the need for labels are highly attractive, especially for enterprises with existing GPU infrastructure and a willingness to invest in engineering optimization. Its cyclic architecture provides accuracy advantages in the low-latency range (39–46ms), making it a strong candidate for real-time decision-making scenarios such as customer service routing and content moderation.
**For teams prioritizing maximum accuracy and out-of-the-box experience,**Jev's hosted API, although higher in latency (p50 ~616ms) and requiring data to leave the domain, offers an 86.6% JevBench accuracy and the convenience of not needing self-calibration. This makes it more suitable for scenarios with extremely high accuracy requirements and less stringent data compliance needs. While the cascaded approach can achieve similar performance, the hardware costs and operational complexity of deploying multiple models typically result in a lower overall cost-effectiveness compared to Lev.
7. Editor's Summary
Lev proposes an innovative technical approach in the field of decision-making models—treating "thinking depth" as a dynamically adjustable dimension rather than a fixed architectural property. Its choice of using a native cyclic foundation instead of retrofitting cycles onto dense models is a notable architectural decision. The Ouro and Nanbeige4.2 foundations, which are pre-trained with per-cycle supervision, ensure that each cycle's computation receives effective gradient signals from the training phase, avoiding the common issue of training-inference inconsistency that arises in post-hoc modifications. In terms of practical results, the performance increase from 63.2% for one cycle to 76.2% for four cycles using the same checkpoint validates the effectiveness of the cyclic mechanism for complex decision-making tasks. Moreover, the stopper's design, which uses "alignment with the deepest answer" as a calibration target, cleverly circumvents the challenge of lacking human-labeled data in decision-making tasks, making self-calibration without labels feasible.
From a practical value perspective, Lev addresses the long-standing "latency-accuracy" rigid trade-off in decision-making scenarios. A single weight set that covers the entire range from millisecond-level quick responses to deep thinking, combined with a per-question on-demand stopping mechanism, enables computational resources to dynamically allocate to challenging problems, saving 15%–24% of overall computing power. For scenarios with high real-time requirements, such as intelligent customer service, content moderation, and Agent tool calling, this feature has clear engineering significance. The fully open-source release (code/weights/data) also provides convenience for academic research and enterprise private deployment.
Lev is particularly suitable for the following groups: enterprise teams with strict data compliance requirements who need fully offline deployment; developers who already have GPU infrastructure and are willing to invest in engineering optimization to achieve a flexible balance between latency and accuracy; and researchers interested in the application of cyclic architectures in decision-making tasks. Its current main limitations lie in the absolute accuracy ceiling caused by the base model size (1.4B–3B), as well as the incomplete toolchain and documentation typical of academic prototypes. As larger-scale native cyclic foundations emerge and the community ecosystem gradually develops, the potential of this technical approach in the field of decision intelligence is worth continued attention.
8. FAQ
Q: What distinguishes Lev from traditional generative decision-making models?
A: Traditional generative models typically require generating reasoning text first and then extracting the answer, leading to high latency and computational waste. Lev directly outputs option probabilities without generating intermediate text; it also uses a cyclic mechanism to "think" within hidden states, outputting probabilities in each cycle, with the stopper determining the computational depth. This achieves a dynamic balance between latency and accuracy.
Q: How is the stopper calibrated without labels?
A: The stopper's calibration objective is to determine "whether the current answer is consistent with the answer from the deepest cycle," rather than "whether the answer is correct." Since the deepest answer is the model's own output, no human labels are required. In practice, use unlabeled requests from your own business as input, and fit a logistic regression classifier for each depth. The threshold is set to the minimum value that ensures at least 98% consistency with the deepest answer, and calibration can be completed with approximately 500 questions per fold.
Q: What is the maximum cycle depth supported by Lev?
A: There is no theoretical hard limit on cycle depth, but in practice, it is recommended to choose between 1 to 4 cycles depending on task complexity and latency budget. Experiments on JevBench show that four cycles significantly outperform one cycle (63.2% → 76.2%), with diminishing returns beyond four cycles. The model dynamically determines the actual number of computational cycles per question within the set maximum depth range, guided by the stopper.
Q: Can Lev run on consumer-grade GPUs?
A: Lev offers three model sizes: 1.4B, 2.6B, and 3B. The 1.4B version can run on consumer-grade GPUs with 8GB VRAM (e.g., RTX 3070/4060), while the 2.6B and 3B versions are recommended for GPUs with 16GB or more VRAM. Inference speed depends on GPU performance and the maximum cycle depth set. For real-time performance on consumer-grade GPUs, it is advised to use 1–2 cycles.
Q: Will Lev's stopper sacrifice accuracy by stopping early?
A: The stopper's threshold is set to ensure at least 98% consistency with the deepest answer, meaning that in the majority of cases, the early-stopped answer will be the same as the answer obtained after running all cycles. Experimental data shows that with the stopper enabled, only about 76%–85% of the computational resources are used, and the accuracy loss is less than 1 percentage point. This trade-off is generally acceptable in most real-world scenarios.
Q: How can Lev be integrated into existing business systems?
A: Lev provides a standard Hugging Face interface, allowing the model to be loaded and called via the Transformers library. The input format is a single sequence containing "state + question + options," and the output is the probability distribution of each option. When integrating, ensure the block causal mask is correctly configured, and it is recommended to first perform stopper calibration using your own business traffic to adapt to the actual data distribution.
9. Project Links
- Project Website: https://openlair.github.io/lev/
- GitHub Repository: https://github.com/OpenLAIR/lev
- Hugging Face Model Library: https://huggingface.co/collections/songdj/lev
- arXiv Technical Paper: https://arxiv.org/pdf/2610.20951
© All Rights Reserved. Some content on this site is partially generated by AI with human review.


