Spaces:
Runtime error
Runtime error
from app.gen.openllm import ( | |
chat, | |
translate_messages, | |
) | |
async def chat(message, history): | |
messages = translate_messages(history) | |
messages.append({"role":"user", "content":message}) | |
full_resp = "" | |
async for resp in chat(messages): | |
full_resp = full_resp + resp | |
yield full_resp |