ChatGPT
ChatGPT copied to clipboard
[BUG] Maxium recursion depth reached
Description Getting this error when trying to ask() in browserless version.
File "C:\Users\User\AppData\Local\Programs\Python\Python310\lib\site-packages\revChatGPT\Official.py", line 108, in ask
self.prompt.construct_prompt(user_request),
File "C:\Users\User\AppData\Local\Programs\Python\Python310\lib\site-packages\revChatGPT\Official.py", line 242, in construct_prompt
prompt = self.construct_prompt(new_prompt)
File "C:\Users\User\AppData\Local\Programs\Python\Python310\lib\site-packages\revChatGPT\Official.py", line 242, in construct_prompt
prompt = self.construct_prompt(new_prompt)
File "C:\Users\User\AppData\Local\Programs\Python\Python310\lib\site-packages\revChatGPT\Official.py", line 242, in construct_prompt
prompt = self.construct_prompt(new_prompt)
[Previous line repeated 975 more times]
File "C:\Users\User\AppData\Local\Programs\Python\Python310\lib\site-packages\revChatGPT\Official.py", line 237, in construct_prompt
if len(ENCODER.encode(prompt)) > max_tokens:
File "C:\Users\User\AppData\Local\Programs\Python\Python310\lib\site-packages\tiktoken\core.py", line 96, in encode
if match := _special_token_regex(disallowed_special).search(text):
RecursionError: maximum recursion depth exceeded in comparison
I think I have the buffer too high
Yeh setting my buffer to a lower number has fixed the issue
Maximum buffer is 4000 iirc
One lower than that actually, as I had my buffer at 4000 (testing)