This commit is contained in:
narawat lamaiin
2024-05-31 11:47:43 +07:00
parent 3f38fdbb70
commit 3196842296
17 changed files with 5607 additions and 179 deletions

View File

@@ -39,7 +39,7 @@ tools=Dict( # update input format
# "winestock"=> Dict(
# :description => "<winestock tool description>A handy tool for searching wine in your inventory that match the user preferences.</winestock tool description>",
# :input => """<input>Input is a JSON-formatted string that contains a detailed and precise search query.</input><input example>{\"wine type\": \"rose\", \"price\": \"max 35\", \"sweetness level\": \"sweet\", \"intensity level\": \"light bodied\", \"Tannin level\": \"low\", \"Acidity level\": \"low\"}</input example>""",
# :output => """<output>Output are wines that match the search query in JSON format.""",
# :output => """<output>Output are wines that match the search query in JSON format.""",
# :func => ChatAgent.winestock,
# ),
"finalanswer"=> Dict(
@@ -59,25 +59,25 @@ tools=Dict( # update input format
# response = YiemAgent.conversation(a, Dict(:text=> "newtopic",) )
# response = YiemAgent.conversation(a, Dict(:text=> "Hello, I would like a get a bottle of wine",
# :select=> nothing,
# :reward=> 0,
# :isterminal=> false,
# ) )
# println("---> YiemAgent: ", response)
response = YiemAgent.conversation(a, Dict(:text=> "Hello, I would like a get a bottle of wine",
:select=> nothing,
:reward=> 0,
:isterminal=> false,
) )
println("---> YiemAgent: ", response)
# #BUG mcts do not start at current chat history
# response = YiemAgent.conversation(a, Dict(:text=> "I'm having a graduation party this evening. I'll pay at most 30 bucks.",
# :select=> nothing,
# :reward=> 0,
# :isterminal=> false,
# ) )
# println("---> YiemAgent: ", response)
#BUG mcts do not start at current chat history
response = YiemAgent.conversation(a, Dict(:text=> "I'm having a graduation party this evening. I'll pay at most 30 bucks.",
:select=> nothing,
:reward=> 0,
:isterminal=> false,
) )
println("---> YiemAgent: ", response)
dummyinput = "price < 50, full-bodied red wine with sweetness level 2, low tannin level and medium acidity level, Thai dishes"
dummyinput = "price below 50, full-bodied red wine with sweetness level 2, low tannin level and medium acidity level, Thai dishes"
response = YiemAgent.winestock(a, dummyinput)
@@ -86,11 +86,12 @@ response = YiemAgent.winestock(a, dummyinput)
"""
Write me SQL command to search the database for wines that fits: {"wine_type": "red","sweetness": 2,"acidity": 3,"tannin": 1,"intensity": 5}
"""
mctsparam = Dict{Symbol, Any}()