This commit is contained in:
narawat lamaiin
2024-04-24 06:38:59 +07:00
parent 3b4565cb39
commit b3161e152e

View File

@@ -312,8 +312,8 @@ function planner_mistral_openorca(a::agentReflex)
Plan:
"""
response = sendReceivePrompt(a, prompt, a.config[:text2text][:mqtttopic], max_tokens=512,
timeout=180, stopword=["<|user|>", "</"])
response = sendReceivePrompt(a, prompt, a.config[:text2text][:mqtttopic], max_tokens=1024,
timeout=180, stopword=["<|eot_id|>"])
response = split(response, "<|")[1]
response = split(response, "</")[1]
@@ -1288,10 +1288,8 @@ function conversation(a::agentReflex, usermsg::String; attemptlimit::Int=3)
#TODO paraphrase msg so that it is human friendlier word.
else
response = chat_mistral_openorca(a)
response = split(response, "\n\n")[1]
response = split(response, "\n\n")[1]
end
response = removeTrailingCharacters(response)
# response = removeTrailingCharacters(response)
_ = addNewMessage(a, "assistant", response)
return response
end