update
This commit is contained in:
@@ -349,9 +349,9 @@ function selfAwareness(a::agentReflex)
|
||||
</About yourself>
|
||||
<Your job>
|
||||
Use the following format strictly:
|
||||
Info extraction: from the latest observed result, repeat every word relates to wine
|
||||
Info extraction: break the latest observed result down to the smallest unit of information then repeat every important word
|
||||
Info mapping: based on extracted info, explicitly state what each info could possibly match which keyword memory's key
|
||||
Info matching: using JSON format, what key in my memory matches which info (Donot use nested JSON)
|
||||
Info matching: using JSON format, state every info relates to what key in my memory matches which value (Donot use nested JSON)
|
||||
</Your job>
|
||||
</|system|>
|
||||
<Example>
|
||||
@@ -573,7 +573,7 @@ function keywordMemoryToPlanMatching(a::agentReflex)
|
||||
<|assistant|>
|
||||
Info mapping:
|
||||
"""
|
||||
response = sendReceivePrompt(a, prompt, max_tokens=1024, temperature=0.2, timeout=180,
|
||||
response = sendReceivePrompt(a, prompt, max_tokens=1024, temperature=0.4, timeout=180,
|
||||
stopword=["/n/n", "END", "End", "Obs", "<|", "</"])
|
||||
response = split(response, "<|")[1]
|
||||
response = split(response, "</")[1]
|
||||
@@ -905,7 +905,7 @@ function actor_mistral_openorca(a::agentReflex, selfaware=nothing)
|
||||
keywordmemory = ""
|
||||
for (k, v) in a.memory[:keyword]
|
||||
if v === nothing
|
||||
keywordmemory *= "- The user preferred $k is null \n"
|
||||
keywordmemory *= "- I don't know the user preferred $k yet \n"
|
||||
else
|
||||
keywordmemory *= "- The user preferred $k is $v \n"
|
||||
end
|
||||
@@ -936,7 +936,7 @@ function actor_mistral_openorca(a::agentReflex, selfaware=nothing)
|
||||
</You have access to the following tools>
|
||||
<Your job>
|
||||
Use the following format:
|
||||
Thought: check the user info thoroughly to see if there is something you don't know (as indicates by null), you must address it the immediate next step. Otherwise, you must think about what is the immediate next step to do according to the plan (PS. 1. pay attention to correct numeral calculation and commonsense 2. you must assume nothing 3. do not ask for confirmation)
|
||||
Thought: you must look for the user's info you don't know, you must address it as the immediate next step. Otherwise, you must think about what is the immediate next step to do according to the plan (PS. 1. pay attention to correct numeral calculation and commonsense 2. you must assume nothing 3. do not ask for confirmation)
|
||||
Act: based on your thought what action to choose?, must be one of [{toolnames}].
|
||||
Actinput: your input to the action using JSON format (pay attention to the tool's input)
|
||||
Obs: observed result of the action
|
||||
|
||||
@@ -1001,6 +1001,8 @@ end
|
||||
|
||||
function checkSimilarKey(dict::AbstractDict, key::AbstractString)
|
||||
similar_k = nothing
|
||||
key = replace(key, "_" => " ")
|
||||
key = replace(key, "-" => " ")
|
||||
for (k, v) in dict
|
||||
if occursin(key, String(k))
|
||||
similar_k = k
|
||||
|
||||
Reference in New Issue
Block a user