Run this model with HF Jobs
Run peng12345/IF-decision-27b on Hugging Face's managed compute, monitor its progress, and retrieve the results when it's done.
Paste one of these prompts into your coding agent:
Fine-tune on my dataset
Use HF Jobs and TRL to fine-tune https://huggingface.co/peng12345/IF-decision-27b. Ask me which dataset to train on, then push the fine-tuned model to a new model repo. Run `hf jobs --help` first to learn the CLI.
Run batch inference
Use HF Jobs to run batch inference with https://huggingface.co/peng12345/IF-decision-27b on the inputs in a mounted HF Bucket. Ask me which Bucket to use, then write the outputs back to it and keep each input ID. Run `hf jobs --help` first to learn the CLI.
Evaluate on a benchmark
Use HF Jobs to evaluate https://huggingface.co/peng12345/IF-decision-27b. Ask me which benchmark to run, then save the scores and the per-example results to a new dataset repo. Run `hf jobs --help` first to learn the CLI.
Quantize for lower memory use
Use HF Jobs to create a 4-bit version of https://huggingface.co/peng12345/IF-decision-27b. Push it to a new model repo, then reload it from there and report its memory footprint. Run `hf jobs --help` first to learn the CLI.
Instructions to use peng12345/IF-decision-27b with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use peng12345/IF-decision-27b with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-text-to-text", model="peng12345/IF-decision-27b") messages = [ { "role": "user", "content": [ {"type": "image", "url": "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/p-blog/candy.JPG"}, {"type": "text", "text": "What animal is on the candy?"} ] }, ] pipe(text=messages)# pip install -U transformers accelerate # Load model directly from transformers import AutoProcessor, AutoModelForMultimodalLM processor = AutoProcessor.from_pretrained("peng12345/IF-decision-27b") model = AutoModelForMultimodalLM.from_pretrained("peng12345/IF-decision-27b", device_map="auto") messages = [ { "role": "user", "content": [ {"type": "image", "url": "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/p-blog/candy.JPG"}, {"type": "text", "text": "What animal is on the candy?"} ] }, ] inputs = processor.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(processor.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use peng12345/IF-decision-27b with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "peng12345/IF-decision-27b" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "peng12345/IF-decision-27b", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }'Use Docker
docker model run hf.co/peng12345/IF-decision-27b
- SGLang
How to use peng12345/IF-decision-27b 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 "peng12345/IF-decision-27b" \ --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": "peng12345/IF-decision-27b", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }'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 "peng12345/IF-decision-27b" \ --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": "peng12345/IF-decision-27b", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }' - Docker Model Runner
How to use peng12345/IF-decision-27b with Docker Model Runner:
docker model run hf.co/peng12345/IF-decision-27b
IF-decision-27b
IF Decision is a 27B structured decision model trained with LoRA on approximately 1.7 million collected, reconstructed, and generated decision examples for one epoch on 8 x A800 GPUs. The published artifact contains merged weights.
Verified base: Qwen/Qwen3.8-27B revision
37561816e66b5b9153b1b64c10968c18c1e6f4a0.
Architecture and inference
Full-attention layers occur every fourth layer (zero-based 3, 7, ..., 63).
Bidirectional prompt attention applies to those layers, not every layer.
Inference uses bfloat16 and the custom /v1/systemone path. Ordinary causal
chat generation is not equivalent to this decision path.
Each question is rendered without benchmark identifiers or expected answers. Original option keys are mapped reversibly to A-Z, and probabilities are read from the corresponding letter logits.
One pass supports 2-26 choices. Larger choices use a fixed wide-choice strategy: every option is scored in near-equal groups of at most 25, the best 3 per group advance (at most 26 overall), and a final pass assigns 0.999 probability mass to finalists. Non-finalists share 0.001 in proportion to first-round probability. Every original option key is restored in the final distribution.
Immutable release
- Tested model revision: https://huggingface.co/peng12345/IF-decision-27b/tree/eea6f72d588183d53fdf6cd312cf356e72e7f9eb
- Public results: https://huggingface.co/datasets/peng12345/decision-index-results/tree/81cb8444d7480f47b4ec7e6a9f71b9e1da419d3c/runs/IF-decision-27b-v1-text-public-0.3-28ef925de8
- Exact inference source: https://github.com/wuyu112/IF-decision-inference/tree/e5598568c8aace2c59088a29c5a8318743820ccf
- Reproduction test: https://github.com/wuyu112/IF-decision-inference/blob/e5598568c8aace2c59088a29c5a8318743820ccf/tests/reproduce_request.py
Later README-only commits are documentation revisions and do not change the
tested model pin. The same inference package is mirrored under inference/ in
the model repository.
Reproduce from this repository
Requirements:
- Linux, Python 3.12, Git and the Hugging Face CLI
- one NVIDIA GPU with at least 80 GB VRAM
- a CUDA environment supported by vLLM 0.31.0
- approximately 60 GB of free disk space for the download
Download the immutable tested revision into a new directory:
hf download peng12345/IF-decision-27b \
--revision eea6f72d588183d53fdf6cd312cf356e72e7f9eb \
--local-dir ./IF-decision-27b
Create an isolated environment and install the inference package bundled with the model:
python3.12 -m venv .venv
source .venv/bin/activate
python -m pip install --upgrade pip
python -m pip install -e './IF-decision-27b/inference[vllm]'
Start the service. The script enables the required prompt-bidirectional plugin, disables prefix caching and chunked prefill, and starts the SystemOne endpoint on loopback port 18080:
bash ./IF-decision-27b/inference/scripts/serve_if_decision.sh \
--model ./IF-decision-27b \
--port 18080 \
--vllm-port 18081 \
--gpu 0
In another shell, activate the same environment and run the bundled protocol test. It checks ordinary choice/noul output and a 29-option request, including original-key preservation and probability normalization:
source .venv/bin/activate
curl -fsS http://127.0.0.1:18080/health
python ./IF-decision-27b/inference/tests/reproduce_request.py \
--base-url http://127.0.0.1:18080
For Decision Index public evaluation, point the unmodified HTTP engine at the same endpoint:
python -m decision_index pipeline \
--engine http \
--option base_url=http://127.0.0.1:18080 \
--option model=IF-decision-27b-v1 \
--suite /path/to/suite-0.3 \
--out /path/to/run \
--edition 0.3 \
--compact
Decision Index integration
The server implements POST /v1/systemone and can be used by the unmodified
Decision Index HTTP engine. It returns a finite normalized probability for
every original option key.
Text Public 0.3 completed 140,620 attempted rows with status ok; the scorer
reported 140,178 scoreable requests, complete=true, Public Index 70.92, Raw
Index 77.51, and coverage 100%. These are public-suite results, not a private
Full score.
Data
Training data were collected, reconstructed and generated for structured decision post-training. Applicable source-data licences remain controlling.
References
The decision-head design and multi-pass inference strategy were informed by
the ideas described in StartLux-Decision.
See the inference package LICENSE and NOTICE for attribution details.
- Downloads last month
- 128