Downloads · 30 days
75
2% of all-time downloads
PrunaAI/dbrx-instruct-bnb-4bit
dbrx-instruct-bnb-4bit is a machine learning model from PrunaAI. Use it for the machine learning task on the model card, and read the license before you ship it in a product. It is set up for pruna-engine.
<div style="width: auto; margin-left: auto; margin-right: auto" <a href="https://www.pruna.ai/" target="blank" rel="noopener noreferrer" <img src="https://i.imgur.com/eDAlcgk.png" alt="PrunaAI" style="width: 100%; min…
Downloads · 30 days
75
2% of all-time downloads
All-time downloads
4.4K
Public
Parameters
136B
69.7 GB on disk
Likes
10
Public
Click a slice to open those files.
.safetensors69.7 GB · 100%
How the weights are stored.
U8134B · 99%
From the Hugging Face model README
Frequently Asked Questions
Getting started with DBRX models is easy with the transformers library. The model requires ~264GB of RAM and the following packages:
pip install "torch==2.4.0" "transformers>=4.39.2" "tiktoken>=0.6.0" "bitsandbytes"
If you'd like to speed up download time, you can use the hf_transfer package as described by Huggingface here.
pip install hf_transfer
export HF_HUB_ENABLE_HF_TRANSFER=1
You will need to request access to this repository to download the model. Once this is granted,
obtain an access token with read permission, and supply the token below.
from transformers import AutoTokenizer, AutoModelForCausalLM
import torch
tokenizer = AutoTokenizer.from_pretrained("PrunaAI/dbrx-instruct-bnb-4bit", trust_remote_code=True, token="hf_YOUR_TOKEN")
model = AutoModelForCausalLM.from_pretrained("PrunaAI/dbrx-instruct-bnb-4bit", device_map="auto", torch_dtype=torch.bfloat16, trust_remote_code=True, token="hf_YOUR_TOKEN")
input_text = "What does it take to build a great LLM?"
messages = [{"role": "user", "content": input_text}]
input_ids = tokenizer.apply_chat_template(messages, return_dict=True, tokenize=True, add_generation_prompt=True, return_tensors="pt").to("cuda")
outputs = model.generate(**input_ids, max_new_tokens=200)
print(tokenizer.decode(outputs[0]))
The license of the smashed model follows the license of the original model. Please check the license of the original model databricks/dbrx-instruct before using this model which provided the base model. The license of the pruna-engine is here on Pypi.
Want to use our optimized models right away? Try them via our API for fast, easy access to Pruna-powered inference.
<style> .model-button { display: inline-flex; flex-direction: row; justify-content: center; align-items: center; gap: 8px; padding: 8px 20px; border: none; border-radius: 8px; background: #9334e9; color: #ffffff; font-size: 14px; font-weight: 400; line-height: 1; text-decoration: none; white-space: nowrap; cursor: pointer; box-sizing: border-box; overflow: visible; opacity: 1; } </style><a href="https://dashboard.pruna.ai/login?utm_source=huggingface&utm_medium=model_card&utm_campaign=hf_traffic" class="model-button">Try our models</a>