Update app.py
Browse files
app.py
CHANGED
|
@@ -11,7 +11,7 @@ HF_TOKEN = os.environ.get("HF_TOKEN", None)
|
|
| 11 |
|
| 12 |
DESCRIPTION = '''
|
| 13 |
<div>
|
| 14 |
-
<h1 style="text-align: center;">
|
| 15 |
</div>
|
| 16 |
'''
|
| 17 |
|
|
@@ -44,11 +44,10 @@ h1 {
|
|
| 44 |
"""
|
| 45 |
|
| 46 |
# Load the tokenizer and model
|
| 47 |
-
tokenizer = AutoTokenizer.from_pretrained("deepseek-ai/DeepSeek-R1-Distill-
|
| 48 |
-
model = AutoModelForCausalLM.from_pretrained("
|
| 49 |
terminators = [
|
| 50 |
tokenizer.eos_token_id,
|
| 51 |
-
tokenizer.convert_tokens_to_ids("<|eot_id|>")
|
| 52 |
]
|
| 53 |
|
| 54 |
@spaces.GPU(duration=120)
|
|
|
|
| 11 |
|
| 12 |
DESCRIPTION = '''
|
| 13 |
<div>
|
| 14 |
+
<h1 style="text-align: center;">unsloth/DeepSeek-R1-Distill-Qwen-32B-bnb-4bit</h1>
|
| 15 |
</div>
|
| 16 |
'''
|
| 17 |
|
|
|
|
| 44 |
"""
|
| 45 |
|
| 46 |
# Load the tokenizer and model
|
| 47 |
+
tokenizer = AutoTokenizer.from_pretrained("deepseek-ai/DeepSeek-R1-Distill-Qwen-32B")
|
| 48 |
+
model = AutoModelForCausalLM.from_pretrained("unsloth/DeepSeek-R1-Distill-Qwen-32B-bnb-4bit", device_map="auto") # to("cuda:0")
|
| 49 |
terminators = [
|
| 50 |
tokenizer.eos_token_id,
|
|
|
|
| 51 |
]
|
| 52 |
|
| 53 |
@spaces.GPU(duration=120)
|