From be771f7c2272aabcc584978da7ca9ddc5d409e42 Mon Sep 17 00:00:00 2001 From: Paillat Date: Tue, 15 Aug 2023 14:15:57 +0200 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9B=20fix(makeprompt.py):=20add=20miss?= =?UTF-8?q?ing=20'depth'=20parameter=20to=20recursive=20function=20call=20?= =?UTF-8?q?to=20prevent=20infinite=20recursion?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/makeprompt.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/makeprompt.py b/src/makeprompt.py index 67fd98f..690a95d 100644 --- a/src/makeprompt.py +++ b/src/makeprompt.py @@ -161,7 +161,7 @@ async def chatgpt_process(self, msgs, message: discord.Message, api_key, prompt, "Oh uh, it seems like i am calling functions recursively. I will stop now." ) raise FuntionCallError("Too many recursive function calls") - await chatgpt_process(self, msgs, message, api_key, prompt, model) + await chatgpt_process(self, msgs, message, api_key, prompt, model, depth) else: content = response.get("content", "") while len(content) != 0: