Spaces:
Runtime error
Runtime error
Commit
Β·
9b91ee0
1
Parent(s):
5a9298b
change model
Browse files
app.py
CHANGED
|
@@ -31,8 +31,8 @@ bnb_config = BitsAndBytesConfig(
|
|
| 31 |
bnb_4bit_compute_dtype=torch.bfloat16
|
| 32 |
)
|
| 33 |
|
| 34 |
-
tokenizer = AutoTokenizer.from_pretrained("
|
| 35 |
-
model = AutoModelForCausalLM.from_pretrained("
|
| 36 |
if torch.__version__ >= "2":
|
| 37 |
model = torch.compile(model)
|
| 38 |
print(f"Successfully loaded the model {model_name} into memory")
|
|
@@ -179,7 +179,7 @@ with gr.Blocks(theme='gradio/soft') as demo:
|
|
| 179 |
repetition_penalty = gr.Slider(label="Repetition Penalty", minimum=1.0, maximum=2.0, value=1.08, step=0.01)
|
| 180 |
|
| 181 |
info = gr.HTML(f"""
|
| 182 |
-
<p>π Leveraging the <a href='https://huggingface.co/
|
| 183 |
""")
|
| 184 |
|
| 185 |
|
|
|
|
| 31 |
bnb_4bit_compute_dtype=torch.bfloat16
|
| 32 |
)
|
| 33 |
|
| 34 |
+
tokenizer = AutoTokenizer.from_pretrained("bigscience/bloomz-7b1")
|
| 35 |
+
model = AutoModelForCausalLM.from_pretrained("bigscience/bloomz-7b1", device_map="auto")
|
| 36 |
if torch.__version__ >= "2":
|
| 37 |
model = torch.compile(model)
|
| 38 |
print(f"Successfully loaded the model {model_name} into memory")
|
|
|
|
| 179 |
repetition_penalty = gr.Slider(label="Repetition Penalty", minimum=1.0, maximum=2.0, value=1.08, step=0.01)
|
| 180 |
|
| 181 |
info = gr.HTML(f"""
|
| 182 |
+
<p>π Leveraging the <a href='https://huggingface.co/bigscience/bloomz-7b1'><strong>Vicuna model</strong></a> with int4 quantization.</p>
|
| 183 |
""")
|
| 184 |
|
| 185 |
|