Spaces:
Paused
Paused
Update app.py
Browse files
app.py
CHANGED
@@ -30,7 +30,7 @@ class OrcaChatBot:
|
|
30 |
self.system_message = system_message
|
31 |
|
32 |
def predict(self, user_message, temperature=0.4, max_new_tokens=70, top_p=0.99, repetition_penalty=1.9):
|
33 |
-
prompt = f"<|im_start|>system\n{self.system_message}<|im_end|>\n<|im_start|>user\n{user_message}<|im_end|>\n<|im_start|>assistant"
|
34 |
inputs = self.tokenizer(prompt, return_tensors='pt', add_special_tokens=False)
|
35 |
input_ids = inputs["input_ids"].to(self.model.device)
|
36 |
|
|
|
30 |
self.system_message = system_message
|
31 |
|
32 |
def predict(self, user_message, temperature=0.4, max_new_tokens=70, top_p=0.99, repetition_penalty=1.9):
|
33 |
+
prompt = f"<|im_start|>system\n{self.system_message}<|im_end|>\n<|im_start|>user\n{user_message}<|im_end|>\n<|im_start|>assistant"
|
34 |
inputs = self.tokenizer(prompt, return_tensors='pt', add_special_tokens=False)
|
35 |
input_ids = inputs["input_ids"].to(self.model.device)
|
36 |
|