Update app.py
Browse files
app.py
CHANGED
@@ -55,7 +55,7 @@ def compress_history(formatted_prompt):
|
|
55 |
|
56 |
generate_kwargs = dict(
|
57 |
temperature=temperature,
|
58 |
-
max_new_tokens=
|
59 |
top_p=0.95,
|
60 |
repetition_penalty=1.0,
|
61 |
do_sample=True,
|
@@ -222,7 +222,7 @@ def generate(prompt, history, agent_name=agents[0], sys_prompt="", temperature=0
|
|
222 |
prompt=prompt.strip(' \"')
|
223 |
|
224 |
formatted_prompt = format_prompt(f"{system_prompt}, {prompt}", history)
|
225 |
-
if len(formatted_prompt) < (
|
226 |
print(len(formatted_prompt))
|
227 |
|
228 |
|
|
|
55 |
|
56 |
generate_kwargs = dict(
|
57 |
temperature=temperature,
|
58 |
+
max_new_tokens=10480,
|
59 |
top_p=0.95,
|
60 |
repetition_penalty=1.0,
|
61 |
do_sample=True,
|
|
|
222 |
prompt=prompt.strip(' \"')
|
223 |
|
224 |
formatted_prompt = format_prompt(f"{system_prompt}, {prompt}", history)
|
225 |
+
if len(formatted_prompt) < (40000):
|
226 |
print(len(formatted_prompt))
|
227 |
|
228 |
|