update
This commit is contained in:
@@ -295,7 +295,7 @@ function decisionMaker(a::T)::Dict{Symbol, Any} where {T<:agent}
|
|||||||
]
|
]
|
||||||
|
|
||||||
# put in model format
|
# put in model format
|
||||||
prompt = GeneralUtils.formatLLMtext(_prompt, "llama3instruct")
|
prompt = GeneralUtils.formatLLMtext(_prompt; formatname="llama3instruct")
|
||||||
prompt *=
|
prompt *=
|
||||||
"""
|
"""
|
||||||
<|start_header_id|>assistant<|end_header_id|>
|
<|start_header_id|>assistant<|end_header_id|>
|
||||||
@@ -1210,7 +1210,7 @@ function thinkCheckInventory(a::T)::Dict{Symbol, Any} where {T<:agent}
|
|||||||
]
|
]
|
||||||
|
|
||||||
# put in model format
|
# put in model format
|
||||||
prompt = GeneralUtils.formatLLMtext(_prompt, "llama3instruct")
|
prompt = GeneralUtils.formatLLMtext(_prompt; formatname="llama3instruct")
|
||||||
prompt *=
|
prompt *=
|
||||||
"""
|
"""
|
||||||
<|start_header_id|>assistant<|end_header_id|>
|
<|start_header_id|>assistant<|end_header_id|>
|
||||||
@@ -1334,7 +1334,7 @@ function generatechat(memory::Dict, chathistory::Vector, text2textInstructLLM::F
|
|||||||
]
|
]
|
||||||
|
|
||||||
# put in model format
|
# put in model format
|
||||||
prompt = GeneralUtils.formatLLMtext(_prompt, "llama3instruct")
|
prompt = GeneralUtils.formatLLMtext(_prompt; formatname="llama3instruct")
|
||||||
prompt *=
|
prompt *=
|
||||||
"""
|
"""
|
||||||
<|start_header_id|>assistant<|end_header_id|>
|
<|start_header_id|>assistant<|end_header_id|>
|
||||||
@@ -1521,7 +1521,7 @@ function generatequestion(a, text2textInstructLLM::Function)::String
|
|||||||
]
|
]
|
||||||
|
|
||||||
# put in model format
|
# put in model format
|
||||||
prompt = GeneralUtils.formatLLMtext(_prompt, "llama3instruct")
|
prompt = GeneralUtils.formatLLMtext(_prompt; formatname="llama3instruct")
|
||||||
prompt *=
|
prompt *=
|
||||||
"""
|
"""
|
||||||
<|start_header_id|>assistant<|end_header_id|>
|
<|start_header_id|>assistant<|end_header_id|>
|
||||||
@@ -1624,7 +1624,7 @@ function generateSituationReport(a, text2textInstructLLM::Function)::Dict
|
|||||||
]
|
]
|
||||||
|
|
||||||
# put in model format
|
# put in model format
|
||||||
prompt = GeneralUtils.formatLLMtext(_prompt, "llama3instruct")
|
prompt = GeneralUtils.formatLLMtext(_prompt; formatname="llama3instruct")
|
||||||
prompt *=
|
prompt *=
|
||||||
"""
|
"""
|
||||||
<|start_header_id|>assistant<|end_header_id|>
|
<|start_header_id|>assistant<|end_header_id|>
|
||||||
@@ -1720,7 +1720,7 @@ end
|
|||||||
# ]
|
# ]
|
||||||
|
|
||||||
# # put in model format
|
# # put in model format
|
||||||
# prompt = GeneralUtils.formatLLMtext(_prompt, "llama3instruct")
|
# prompt = GeneralUtils.formatLLMtext(_prompt; formatname="llama3instruct")
|
||||||
# prompt *=
|
# prompt *=
|
||||||
# """
|
# """
|
||||||
# <|start_header_id|>assistant<|end_header_id|>
|
# <|start_header_id|>assistant<|end_header_id|>
|
||||||
|
|||||||
@@ -393,7 +393,7 @@ function extractWineAttributes_1(a::T1, input::T2)::String where {T1<:agent, T2<
|
|||||||
]
|
]
|
||||||
|
|
||||||
# put in model format
|
# put in model format
|
||||||
prompt = GeneralUtils.formatLLMtext(_prompt, "llama3instruct")
|
prompt = GeneralUtils.formatLLMtext(_prompt; formatname="llama3instruct")
|
||||||
prompt *=
|
prompt *=
|
||||||
"""
|
"""
|
||||||
<|start_header_id|>assistant<|end_header_id|>
|
<|start_header_id|>assistant<|end_header_id|>
|
||||||
@@ -584,7 +584,7 @@ function extractWineAttributes_2(a::T1, input::T2)::String where {T1<:agent, T2<
|
|||||||
]
|
]
|
||||||
|
|
||||||
# put in model format
|
# put in model format
|
||||||
prompt = GeneralUtils.formatLLMtext(_prompt, "llama3instruct")
|
prompt = GeneralUtils.formatLLMtext(_prompt; formatname="llama3instruct")
|
||||||
prompt *=
|
prompt *=
|
||||||
"""
|
"""
|
||||||
<|start_header_id|>assistant<|end_header_id|>
|
<|start_header_id|>assistant<|end_header_id|>
|
||||||
@@ -722,7 +722,7 @@ end
|
|||||||
# ]
|
# ]
|
||||||
|
|
||||||
# # put in model format
|
# # put in model format
|
||||||
# prompt = GeneralUtils.formatLLMtext(_prompt, "llama3instruct")
|
# prompt = GeneralUtils.formatLLMtext(_prompt; formatname="llama3instruct")
|
||||||
# prompt *=
|
# prompt *=
|
||||||
# """
|
# """
|
||||||
# <|start_header_id|>assistant<|end_header_id|>
|
# <|start_header_id|>assistant<|end_header_id|>
|
||||||
@@ -958,7 +958,7 @@ end
|
|||||||
# ]
|
# ]
|
||||||
|
|
||||||
# # put in model format
|
# # put in model format
|
||||||
# prompt = GeneralUtils.formatLLMtext(_prompt, "llama3instruct")
|
# prompt = GeneralUtils.formatLLMtext(_prompt; formatname="llama3instruct")
|
||||||
# prompt *=
|
# prompt *=
|
||||||
# """
|
# """
|
||||||
# <|start_header_id|>assistant<|end_header_id|>
|
# <|start_header_id|>assistant<|end_header_id|>
|
||||||
|
|||||||
@@ -6,18 +6,18 @@ using Base.Threads
|
|||||||
|
|
||||||
config = copy(JSON3.read("config.json"))
|
config = copy(JSON3.read("config.json"))
|
||||||
|
|
||||||
instanceInternalTopic = config[:serviceInternalTopic][:mqtttopic] * "/1"
|
# instanceInternalTopic = config[:serviceInternalTopic][:mqtttopic] * "/1"
|
||||||
|
|
||||||
client, connection = MakeConnection(config[:mqttServerInfo][:broker],
|
# client, connection = MakeConnection(config[:mqttServerInfo][:broker],
|
||||||
config[:mqttServerInfo][:port])
|
# config[:mqttServerInfo][:port])
|
||||||
|
|
||||||
receiveUserMsgChannel = Channel{Dict}(4)
|
receiveUserMsgChannel = Channel{Dict}(4)
|
||||||
receiveInternalMsgChannel = Channel{Dict}(4)
|
# receiveInternalMsgChannel = Channel{Dict}(4)
|
||||||
println(typeof(connection))
|
# println(typeof(connection))
|
||||||
msgMeta = GeneralUtils.generate_msgMeta(
|
# msgMeta = GeneralUtils.generate_msgMeta(
|
||||||
"N/A",
|
# "N/A",
|
||||||
replyTopic = config[:servicetopic][:mqtttopic] # ask frontend reply to this instance_chat_topic
|
# replyTopic = config[:servicetopic][:mqtttopic] # ask frontend reply to this instance_chat_topic
|
||||||
)
|
# )
|
||||||
|
|
||||||
function executeSQL(sql::T) where {T<:AbstractString}
|
function executeSQL(sql::T) where {T<:AbstractString}
|
||||||
DBconnection = LibPQ.Connection("host=192.168.88.12 port=5432 dbname=yiem_wine_assistant user=yiem password=yiem@Postgres_0.0")
|
DBconnection = LibPQ.Connection("host=192.168.88.12 port=5432 dbname=yiem_wine_assistant user=yiem password=yiem@Postgres_0.0")
|
||||||
@@ -77,7 +77,7 @@ end
|
|||||||
main()
|
main()
|
||||||
|
|
||||||
"""
|
"""
|
||||||
I'm joining a graduation party this evening. I want a bottle of full bodied, dry white wine from the U.S. and I'm ok with all price range.
|
I'm joining a graduation party this evening. I want a bottle of full bodied, dry white wine from the United States. I'm ok with all price range.
|
||||||
Well, the party is small casual with close friends and no food serving.
|
Well, the party is small casual with close friends and no food serving.
|
||||||
I'm open to suggestion since I have no specific idea about wine.
|
I'm open to suggestion since I have no specific idea about wine.
|
||||||
|
|
||||||
|
|||||||
@@ -188,3 +188,5 @@ outgoingMsg = Dict(
|
|||||||
result = GeneralUtils.sendMqttMsg(outgoingMsg)
|
result = GeneralUtils.sendMqttMsg(outgoingMsg)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user