Spaces:
Running
on
Zero
Running
on
Zero
Update app.py
Browse files
app.py
CHANGED
@@ -5,7 +5,7 @@ import spaces
|
|
5 |
import torch
|
6 |
from transformers import AutoModelForCausalLM, AutoTokenizer, TextIteratorStreamer
|
7 |
|
8 |
-
MAX_NEW_TOKENS =
|
9 |
MODEL_NAME = "Azure99/Blossom-V6.1-8B"
|
10 |
|
11 |
model = AutoModelForCausalLM.from_pretrained(
|
@@ -29,7 +29,6 @@ def get_input_ids(inst, history):
|
|
29 |
)
|
30 |
|
31 |
|
32 |
-
@spaces.GPU(duration=60)
|
33 |
def chat(inst, history, temperature, top_p, repetition_penalty):
|
34 |
streamer = TextIteratorStreamer(
|
35 |
tokenizer, skip_prompt=True, skip_special_tokens=True
|
|
|
5 |
import torch
|
6 |
from transformers import AutoModelForCausalLM, AutoTokenizer, TextIteratorStreamer
|
7 |
|
8 |
+
MAX_NEW_TOKENS = 4096
|
9 |
MODEL_NAME = "Azure99/Blossom-V6.1-8B"
|
10 |
|
11 |
model = AutoModelForCausalLM.from_pretrained(
|
|
|
29 |
)
|
30 |
|
31 |
|
|
|
32 |
def chat(inst, history, temperature, top_p, repetition_penalty):
|
33 |
streamer = TextIteratorStreamer(
|
34 |
tokenizer, skip_prompt=True, skip_special_tokens=True
|