From 8d2ebff6f3a6f25d001eaaf31be0fffb9fe7c57a Mon Sep 17 00:00:00 2001 From: Pavel_Duron Date: Mon, 6 Feb 2023 22:45:18 +1000 Subject: [PATCH] change davinci position on handlers --- handlers/davinci.py | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/handlers/davinci.py b/handlers/davinci.py index bd7cd0e..069abbb 100644 --- a/handlers/davinci.py +++ b/handlers/davinci.py @@ -6,7 +6,7 @@ token = '5947963644:AAF_GKgMmU5ovqMpc1KXIpcf4aN0JMyKPqc' openai.api_key = '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' @dp.message_handler() -async def send(message : types.Message): +async def send(message: types.Message): if 'тупица' in message.text.lower(): response = openai.Completion.create( @@ -17,10 +17,9 @@ async def send(message : types.Message): top_p=1.0, frequency_penalty=0.0, presence_penalty=0.6, - stop=["You:"] + stop=["сброс"] ) await message.reply(response['choices'][0]['text']) - else: - pass +