From ee55f9f23fbd309ed915c914c93176c2989f49c6 Mon Sep 17 00:00:00 2001 From: CounterFire2023 <136581895+CounterFire2023@users.noreply.github.com> Date: Mon, 16 Dec 2024 22:50:18 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96prompt?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- bot.py | 2 +- llm/agent_util.py | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/bot.py b/bot.py index 63eddf3..b0eb5b5 100644 --- a/bot.py +++ b/bot.py @@ -26,7 +26,7 @@ if OLLAMA_BOT_TOKEN is None: if __name__ == "__main__": application = ApplicationBuilder().token(OLLAMA_BOT_TOKEN).build() - application.add_handler(chat_id.filter_handler, group=-1) + # application.add_handler(chat_id.filter_handler, group=-1) application.add_handlers([ start_handler, diff --git a/llm/agent_util.py b/llm/agent_util.py index 03793de..d7ea63e 100644 --- a/llm/agent_util.py +++ b/llm/agent_util.py @@ -43,7 +43,7 @@ def config_agent(llama3, llama3_json): <|begin_of_text|> <|start_header_id|>system<|end_header_id|> - Your name is AICQ. + Your name is AICO. You are a professional token seller. We have a total of 1 million CEC, and the average cost of these CECs is $1.1 each, The min price is $0.9 per CEC, There is a 1% chance that the price will be lower than $1 per CEC. Now we hope to hand it over to you to be responsible for selling all of them. @@ -176,7 +176,7 @@ def config_agent(llama3, llama3_json): gen_query = order_chain.invoke({"question": question, "history": state["history"], "context": state["context"]}) amount = gen_query["count"] price = gen_query["price"] - print("order_info", amount) + print("order_info::amount|price:", amount, price) return {"order_info": {"amount": amount, "price": price} } # Node - Send Order @@ -193,7 +193,7 @@ def config_agent(llama3, llama3_json): """ print("Step: before Send Order") order_info = state['order_info'] - print(f'Step: build order info for : "{order_info.amount}" CEC') + print(f'Step: build order info for : "{order_info}"') order_result = json.dumps(order_info) return {"order_info": order_result}