Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -12,7 +12,7 @@ client = InferenceClient(api_key=os.environ.get('HF_TOKEN'))
|
|
12 |
# Constants for EOU calculation
|
13 |
PUNCS = string.punctuation.replace("'", "")
|
14 |
MAX_HISTORY = 4
|
15 |
-
MAX_HISTORY_TOKENS =
|
16 |
EOU_THRESHOLD = 0.5
|
17 |
|
18 |
# Initialize tokenizer and ONNX session
|
@@ -85,9 +85,9 @@ def chatbot(user_input):
|
|
85 |
stream = client.chat.completions.create(
|
86 |
model="deepseek-ai/DeepSeek-R1-Distill-Qwen-1.5B",
|
87 |
messages=messages,
|
88 |
-
temperature=0.
|
89 |
-
max_tokens=
|
90 |
-
top_p=0.
|
91 |
stream=True
|
92 |
)
|
93 |
|
|
|
12 |
# Constants for EOU calculation
|
13 |
PUNCS = string.punctuation.replace("'", "")
|
14 |
MAX_HISTORY = 4
|
15 |
+
MAX_HISTORY_TOKENS = 1024
|
16 |
EOU_THRESHOLD = 0.5
|
17 |
|
18 |
# Initialize tokenizer and ONNX session
|
|
|
85 |
stream = client.chat.completions.create(
|
86 |
model="deepseek-ai/DeepSeek-R1-Distill-Qwen-1.5B",
|
87 |
messages=messages,
|
88 |
+
temperature=0.95,
|
89 |
+
max_tokens=1024,
|
90 |
+
top_p=0.6,
|
91 |
stream=True
|
92 |
)
|
93 |
|