From 7c46ea7a86b7200ef9915416cf2a3cfcc3651250 Mon Sep 17 00:00:00 2001 From: Nate Sesti Date: Sat, 25 Nov 2023 20:05:58 -0700 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9B=20fix=20max=5Ftokens=20bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- server/continuedev/core/steps.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server/continuedev/core/steps.py b/server/continuedev/core/steps.py index 8439d45db..6948f4755 100644 --- a/server/continuedev/core/steps.py +++ b/server/continuedev/core/steps.py @@ -625,7 +625,7 @@ Please output the code to be inserted at the cursor in order to fulfill the user params.update(template.dict(exclude={"prompt"})) # type: ignore params.update( - {"max_tokens": min(max_tokens, model_to_use.context_length // 2)} + {"max_tokens": min(max_tokens, model_to_use.context_length // 2, 4096)} ) generator = model_to_use.stream_complete(**params)