Spaces:
Running
on
CPU Upgrade
Running
on
CPU Upgrade
lowering sensitivity of auto ban, should give 2 warnings now before ban
Browse files
app.py
CHANGED
|
@@ -35,7 +35,7 @@ logging.basicConfig(level=logging.DEBUG)
|
|
| 35 |
#rate_limiter = RateLimiter(max_calls=10, period=60) # needs testing
|
| 36 |
message_cache = {}
|
| 37 |
|
| 38 |
-
AUTO_BAN_ALERT_THRESHOLD =
|
| 39 |
AUTO_BAN_EXEMPT_ROLE_IDS = {897381378172264449, 897376942817419265}
|
| 40 |
# moderator = 1078351789843292311
|
| 41 |
|
|
@@ -107,7 +107,7 @@ async def on_message(message):
|
|
| 107 |
|
| 108 |
# cooldown_duration = 3; false_positive_threshld = 3; -> 99% spam at spam_count of 10+ (could still be wrong, so we timeout)
|
| 109 |
cooldown_duration = 7 # messages per n seconds, was 1, now 3, could try 5 (adjusted 5->7)
|
| 110 |
-
false_positive_threshold =
|
| 111 |
timeout_threshold = 10 # number of messages before issuing a timeout (similar function to ban, easier to reverse)
|
| 112 |
timeout_duration = 168 # timeout duration in hours (1 week)
|
| 113 |
|
|
|
|
| 35 |
#rate_limiter = RateLimiter(max_calls=10, period=60) # needs testing
|
| 36 |
message_cache = {}
|
| 37 |
|
| 38 |
+
AUTO_BAN_ALERT_THRESHOLD = 7
|
| 39 |
AUTO_BAN_EXEMPT_ROLE_IDS = {897381378172264449, 897376942817419265}
|
| 40 |
# moderator = 1078351789843292311
|
| 41 |
|
|
|
|
| 107 |
|
| 108 |
# cooldown_duration = 3; false_positive_threshld = 3; -> 99% spam at spam_count of 10+ (could still be wrong, so we timeout)
|
| 109 |
cooldown_duration = 7 # messages per n seconds, was 1, now 3, could try 5 (adjusted 5->7)
|
| 110 |
+
false_positive_threshold = 5 # big = alert less (catch less spam), small = alert more (catch more spam) # was 4
|
| 111 |
timeout_threshold = 10 # number of messages before issuing a timeout (similar function to ban, easier to reverse)
|
| 112 |
timeout_duration = 168 # timeout duration in hours (1 week)
|
| 113 |
|