From b371bba60e90ab6be5353f8f7e4bbbc708af3d70 Mon Sep 17 00:00:00 2001 From: Untone Date: Thu, 26 Sep 2024 20:58:52 +0300 Subject: [PATCH] toxic-debug13 --- handlers/messages_routing.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/handlers/messages_routing.py b/handlers/messages_routing.py index 191e9b2..a1a1b9d 100644 --- a/handlers/messages_routing.py +++ b/handlers/messages_routing.py @@ -56,7 +56,7 @@ async def messages_routing(msg, state): message_id=mid ) else: - toxic_score = detector(text) + toxic_score = detector(text.lower()) toxic_perc = math.floor(toxic_score*100) await redis.set(f"toxic:{cid}", mid) await redis.set(f"toxic:{cid}:{uid}:{mid}", toxic_perc, ex=60*60*24*3)