Spaces:
Runtime error
Runtime error
Commit
·
fe7fe2a
1
Parent(s):
88b741a
support two models
Browse files
app.py
CHANGED
|
@@ -38,8 +38,8 @@ if torch.cuda.is_available():
|
|
| 38 |
tokenizer.use_default_system_prompt = False
|
| 39 |
|
| 40 |
model_id_zh = "FarReelAILab/Machine_Mindset_zh_INTJ"
|
| 41 |
-
model_zh = AutoModelForCausalLM.from_pretrained(model_id_zh, torch_dtype=torch.float16, device_map="auto")
|
| 42 |
-
tokenizer_zh = AutoTokenizer.from_pretrained(model_id_zh)
|
| 43 |
tokenizer_zh.use_default_system_prompt = False
|
| 44 |
|
| 45 |
|
|
|
|
| 38 |
tokenizer.use_default_system_prompt = False
|
| 39 |
|
| 40 |
model_id_zh = "FarReelAILab/Machine_Mindset_zh_INTJ"
|
| 41 |
+
model_zh = AutoModelForCausalLM.from_pretrained(model_id_zh, torch_dtype=torch.float16, device_map="auto", trust_remote_code=True)
|
| 42 |
+
tokenizer_zh = AutoTokenizer.from_pretrained(model_id_zh, trust_remote_code=True)
|
| 43 |
tokenizer_zh.use_default_system_prompt = False
|
| 44 |
|
| 45 |
|