diff --git a/rag/prompts/next_step.md b/rag/prompts/next_step.md index 493c19051..3e6b608fc 100644 --- a/rag/prompts/next_step.md +++ b/rag/prompts/next_step.md @@ -5,7 +5,7 @@ Your job is: 3. Use `complete_task` if no further step you need to take from tools. (All necessary steps done or little hope to be done) # ========== TASK ANALYSIS ============= -{{ task_analisys }} +{{ task_analysis }} # ========== TOOLS (JSON-Schema) ========== You may invoke only the tools listed below. diff --git a/rag/prompts/prompts.py b/rag/prompts/prompts.py index b15019b6f..13ea801b0 100644 --- a/rag/prompts/prompts.py +++ b/rag/prompts/prompts.py @@ -368,7 +368,7 @@ def next_step(chat_mdl, history:list, tools_description: list[dict], task_desc, hist[-1]["content"] += user_prompt else: hist.append({"role": "user", "content": user_prompt}) - json_str = chat_mdl.chat(template.render(task_analisys=task_desc, desc=desc, today=datetime.datetime.now().strftime("%Y-%m-%d")), + json_str = chat_mdl.chat(template.render(task_analysis=task_desc, desc=desc, today=datetime.datetime.now().strftime("%Y-%m-%d")), hist[1:], stop=["<|stop|>"]) tk_cnt = num_tokens_from_string(json_str) json_str = re.sub(r"^.*", "", json_str, flags=re.DOTALL)