Spaces:
Running
Running
broadfield
commited on
Update app.py
Browse files
app.py
CHANGED
@@ -176,13 +176,13 @@ def agent(prompt_in,history,mod=2):
|
|
176 |
outph= list(generate(prompt,history,mod,2400,seed,role,in_data))[0]
|
177 |
print(outph)
|
178 |
history=history+[{'role':'assistant','content':str(outph)}]
|
179 |
-
yield
|
180 |
role="MANAGER"
|
181 |
outp=generate(prompt,history,mod,128,seed,role,in_data)
|
182 |
outpp=list(outp)[0]
|
183 |
outp0 = re.sub('[^a-zA-Z0-9\s.,?!%()]', '', outpp)
|
184 |
history=history+[{'role':'assistant','content':str(outp0)}]
|
185 |
-
yield
|
186 |
for line in outp0.split("\n"):
|
187 |
if "action:" in line:
|
188 |
try:
|
|
|
176 |
outph= list(generate(prompt,history,mod,2400,seed,role,in_data))[0]
|
177 |
print(outph)
|
178 |
history=history+[{'role':'assistant','content':str(outph)}]
|
179 |
+
yield [{'role':'assistant','content':str(outph)}]
|
180 |
role="MANAGER"
|
181 |
outp=generate(prompt,history,mod,128,seed,role,in_data)
|
182 |
outpp=list(outp)[0]
|
183 |
outp0 = re.sub('[^a-zA-Z0-9\s.,?!%()]', '', outpp)
|
184 |
history=history+[{'role':'assistant','content':str(outp0)}]
|
185 |
+
yield [{'role':'assistant','content':str(outp0)}]
|
186 |
for line in outp0.split("\n"):
|
187 |
if "action:" in line:
|
188 |
try:
|