Instructions to use chocokiddo/DICE-Policy with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use chocokiddo/DICE-Policy with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="chocokiddo/DICE-Policy") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("chocokiddo/DICE-Policy") model = AutoModelForCausalLM.from_pretrained("chocokiddo/DICE-Policy", device_map="auto") messages = [ {"role": "user", "content": "Who are you?"}, ] inputs = tokenizer.apply_chat_template( messages, add_generation_prompt=True, tokenize=True, return_dict=True, return_tensors="pt", ).to(model.device) outputs = model.generate(**inputs, max_new_tokens=256) print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use chocokiddo/DICE-Policy with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "chocokiddo/DICE-Policy" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "chocokiddo/DICE-Policy", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/chocokiddo/DICE-Policy
- SGLang
How to use chocokiddo/DICE-Policy with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "chocokiddo/DICE-Policy" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "chocokiddo/DICE-Policy", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "chocokiddo/DICE-Policy" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "chocokiddo/DICE-Policy", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use chocokiddo/DICE-Policy with Docker Model Runner:
docker model run hf.co/chocokiddo/DICE-Policy
DICE-Policy: Intervention-Aware Tutoring
DICE-Policy is the trained action-selection model introduced in DICE: Decoupling Capability from Intervention Necessity in LLM Tutoring (NeurIPS 2026).
Traditional AI tutors often respond to every student turn, even when further guidance is unnecessary. DICE addresses this by separating two decisions: whether to intervene and what pedagogical action to take.
This checkpoint predicts an appropriate tutoring action from the problem, reference solution, dialogue history, and student's latest response.
Model Details
This release contains the fully merged DICE policy, obtained by merging the IV-calibrated, KL-regularized LoRA adapter (qwen25_7b_tutor_policy_action_only_ivkl_lora) into Qwen2.5-7B-Instruct.
The model can be loaded directly through Hugging Face Transformers. No separate LoRA adapter is required.
| Property | Description |
|---|---|
| Base model | Qwen2.5-7B-Instruct |
| Architecture | Causal language model |
| Training method | Action-only LoRA fine-tuning |
| Optimization | Intervention Value (IV) weighting + KL regularization |
| Output | One of six pedagogical action labels |
| Primary domain | Mathematical tutoring |
| Language | English |
Pedagogical Action Space
The policy predicts one of six actions:
| Action | Description |
|---|---|
accept_and_advance |
Acknowledge correct progress and move forward |
arithmetic_repair |
Address a numerical or calculation error |
conceptual_hint |
Provide guidance for a conceptual misunderstanding |
handle_question |
Respond to a student's clarification question |
ask_for_justification |
Request additional reasoning or explanation |
refocus_subgoal |
Redirect the student toward the current objective |
Important: This is a policy model, not a standalone tutoring chatbot. It selects pedagogical actions; the full DICE framework generates action-conditioned responses and applies acceptance verification.
Loading the Model
from transformers import AutoModelForCausalLM, AutoTokenizer
model_id = "chocokiddo/DICE-Policy"
tokenizer = AutoTokenizer.from_pretrained(model_id)
model = AutoModelForCausalLM.from_pretrained(
model_id,
torch_dtype="auto",
device_map="auto",
)
model.eval()
The paper's evaluation pipeline scores the six candidate action labels using normalized token log-likelihoods, then applies the selected intervention-control rule.
For faithful reproduction, use the official DICE experiment runners rather than unrestricted text generation.
Reproducing the Experiments
Code: Sayantan-world/DICE
Benchmark: chocokiddo/DICE-Bench
Clone the repository and install the dependencies:
git clone https://github.com/Sayantan-world/DICE.git
cd DICE
pip install -r requirements.txt
python scripts/download_data.py --split triplets
Run the DICE-Cost session-level evaluation (intervention cost ฮป = 0.25):
POLICY_ADAPTER_PATH=chocokiddo/DICE-Policy \
DICE_MODE=dice_cost \
INTERVENTION_COST_LAMBDA=0.25 \
bash src/experiments/run_dice_session.sh
Despite its name, POLICY_ADAPTER_PATH also accepts a fully merged model. The runner automatically detects and loads the checkpoint appropriately.
The default experiment configuration uses Qwen2.5-7B-Instruct as the teacher and Qwen2.5-1.5B-Instruct as the simulated student. See the repository for hardware requirements and alternative evaluation configurations.
Training
DICE learns when an intervention is useful by estimating Intervention Value (IV): the difference in expected student progress between taking a pedagogical action and allowing the student to continue without additional guidance.
The policy is optimized using IV-weighted supervision with KL regularization toward a supervised reference policy.
| Hyperparameter | Value |
|---|---|
| LoRA rank | 16 |
| LoRA alpha | 32 |
| LoRA dropout | 0.05 |
| KL coefficient (ฮฒ) | 0.05 |
| Training epochs | 3 |
| Learning rate | 2e-4 |
| Maximum training sequence length | 2048 |
| Training precision | 4-bit QLoRA with BF16 computation |
The released checkpoint contains the merged weights. IV estimation and LoRA training scripts are available in the code repository.
Evaluation Results
In simulated session-level mathematical tutoring, using 250 problem triplets and a shared 20-turn budget:
| Metric | DICE-Cost | SocraticLM |
|---|---|---|
| All-three problem success | 56.4% | 37.6% |
| Average problems solved | 2.324 | 1.864 |
| Average turns | 11.94 | 14.88 |
| Over-intervention rate | 2.8% | 42.0% |
| Unsafe final-answer acceptance | 0.0% | 40.0% |
These are full-system results, not standalone policy-checkpoint measurements. They include DICE's action selection, response generation, and session-level acceptance safeguards.
Detailed experiments and ablations are provided in the paper.
Intended Use and Limitations
DICE-Policy is intended for research on AI tutoring, pedagogical action prediction, selective intervention, and interactive mathematical reasoning.
The current evaluation is limited to mathematical word problems and simulated students. Results should not be interpreted as demonstrated improvements in learning outcomes for human students.
The standalone policy does not guarantee mathematical correctness or safe acceptance of student answers. The full DICE framework includes additional verification mechanisms for these purposes.
Citation
If you use this model, benchmark, or framework, please cite:
@misc{pal2026dice,
title={DICE: Decoupling Capability from Intervention Necessity in LLM Tutoring},
author={Sayantan Pal and Kaiyi Ji and Rohini K. Srihari},
year={2026},
eprint={2610.04825},
archivePrefix={arXiv},
primaryClass={cs.AI},
url={https://arxiv.org/abs/2610.04825}
}
License
Apache License 2.0, consistent with the licensing of the underlying Qwen2.5-7B-Instruct model.
- Downloads last month
- -