Spaces:
Running
on
CPU Upgrade
Running
on
CPU Upgrade
selfitcamera
commited on
Commit
·
4c96973
1
Parent(s):
84f4995
init
Browse files
app.py
CHANGED
|
@@ -33,9 +33,9 @@ def t(key, lang="en"):
|
|
| 33 |
|
| 34 |
# Configuration parameters
|
| 35 |
|
| 36 |
-
TIP_TRY_N =
|
| 37 |
-
FREE_TRY_N =
|
| 38 |
-
SLOW_TRY_N =
|
| 39 |
SLOW2_TRY_N = 12 # Slow phase start: 32 tries
|
| 40 |
RATE_LIMIT_60 = 15 # Full restriction: blocked after 40 tries
|
| 41 |
|
|
@@ -44,7 +44,7 @@ PHASE_1_WINDOW = 5 # 15-25 tries: 5 minutes
|
|
| 44 |
PHASE_2_WINDOW = 10 # 25-32 tries: 10 minutes
|
| 45 |
PHASE_3_WINDOW = 20 # 32-40 tries: 20 minutes
|
| 46 |
MAX_IMAGES_PER_WINDOW = 2 # Max images per time window
|
| 47 |
-
high_priority_n = 2 # 每个ip
|
| 48 |
|
| 49 |
IP_Dict = {}
|
| 50 |
# IP generation statistics and time window tracking
|
|
|
|
| 33 |
|
| 34 |
# Configuration parameters
|
| 35 |
|
| 36 |
+
TIP_TRY_N = 4 # Show like button tip after 12 tries
|
| 37 |
+
FREE_TRY_N = 6 # Free phase: first 15 tries without restrictions
|
| 38 |
+
SLOW_TRY_N = 9 # Slow phase start: 25 tries
|
| 39 |
SLOW2_TRY_N = 12 # Slow phase start: 32 tries
|
| 40 |
RATE_LIMIT_60 = 15 # Full restriction: blocked after 40 tries
|
| 41 |
|
|
|
|
| 44 |
PHASE_2_WINDOW = 10 # 25-32 tries: 10 minutes
|
| 45 |
PHASE_3_WINDOW = 20 # 32-40 tries: 20 minutes
|
| 46 |
MAX_IMAGES_PER_WINDOW = 2 # Max images per time window
|
| 47 |
+
high_priority_n = 2 # 每个ip只有第一个任务是高优先级的
|
| 48 |
|
| 49 |
IP_Dict = {}
|
| 50 |
# IP generation statistics and time window tracking
|