Instructions to use RedHatAI/Inkling-NVFP4-FP8-BLOCK with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use RedHatAI/Inkling-NVFP4-FP8-BLOCK with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-text-to-text", model="RedHatAI/Inkling-NVFP4-FP8-BLOCK") 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)# Load model directly from transformers import AutoProcessor, AutoModelForMultimodalLM processor = AutoProcessor.from_pretrained("RedHatAI/Inkling-NVFP4-FP8-BLOCK") model = AutoModelForMultimodalLM.from_pretrained("RedHatAI/Inkling-NVFP4-FP8-BLOCK", 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=40) print(processor.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use RedHatAI/Inkling-NVFP4-FP8-BLOCK with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "RedHatAI/Inkling-NVFP4-FP8-BLOCK" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "RedHatAI/Inkling-NVFP4-FP8-BLOCK", "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/RedHatAI/Inkling-NVFP4-FP8-BLOCK
- SGLang
How to use RedHatAI/Inkling-NVFP4-FP8-BLOCK 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 "RedHatAI/Inkling-NVFP4-FP8-BLOCK" \ --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": "RedHatAI/Inkling-NVFP4-FP8-BLOCK", "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 "RedHatAI/Inkling-NVFP4-FP8-BLOCK" \ --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": "RedHatAI/Inkling-NVFP4-FP8-BLOCK", "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 RedHatAI/Inkling-NVFP4-FP8-BLOCK with Docker Model Runner:
docker model run hf.co/RedHatAI/Inkling-NVFP4-FP8-BLOCK
RedHatAI/Inkling-NVFP4-FP8-BLOCK
This is a quantized version of thinkingmachines/Inkling with MoE layers quantized to NVFP4 and attention layers quantized to FP8 Block.
Usage
This model is intended for deployment with vLLM. You can serve the model using 4xB200s:
vllm serve RedHatAI/Inkling-NVFP4-FP8-BLOCK \
--tokenizer-mode inkling \
--tensor-parallel-size 4 \
--enable-auto-tool-choice \
--tool-call-parser inkling \
--reasoning-parser inkling \
--enable-expert-parallel \
--max-model-len 100000 \
--max-num-seqs 32 \
--enable-chunked-prefill \
--trust-remote-code \
Evaluation
Evaluations were performed with inspectai:
inspect eval hf/Idavidrein/gpqa/diamond \
--model RedHatAI/Inkling-NVFP4-FP8-BLOCK \
--reasoning-effort high \
--model-base-url http://localhost:8000/v1 \
| Benchmark | thinkingmachines/Inkling |
RedHatAI/Inkling-NVFP4-FP8-BLOCK |
|---|---|---|
| GPQA Diamond | 87.2 | 84.5 |
Note: A bug in inspectai currently misscores markdown-formatted multiple choice answers (e.g. ANSWER: $B$ rather than ANSWER: B), which the Inkling models often include in their response. Scores are manually evaluated to account for discrepancy. More information at https://github.com/UKGovernmentBEIS/inspect_ai/issues/5145
- Downloads last month
- 126
Model tree for RedHatAI/Inkling-NVFP4-FP8-BLOCK
Base model
thinkingmachines/Inkling