risunobushi commited on
Commit
52b13b2
·
verified ·
1 Parent(s): 2023b16

Update to new Demo rate limits. Unlimited use on studio.yourmirror.io

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -96,8 +96,8 @@ except Exception as exc:
96
  # Rate Limiting
97
  # -----------------------------------------------------------------------------
98
 
99
- # Rate limiter: 30 requests per IP per hour
100
- RATE_LIMIT_REQUESTS = 30
101
  RATE_LIMIT_WINDOW = 3600 # 1 hour in seconds
102
  request_tracker = defaultdict(deque)
103
 
@@ -362,7 +362,7 @@ def generate(
362
  # Rate limiting check
363
  client_ip = get_client_ip(request)
364
  if not check_rate_limit(client_ip):
365
- raise gr.Error("Rate limit exceeded. Please try again later (30 requests per hour limit).")
366
 
367
  # NSFW content filtering - only check product image
368
  print(f"[NSFW] Checking product image for inappropriate content...")
 
96
  # Rate Limiting
97
  # -----------------------------------------------------------------------------
98
 
99
+ # Rate limiter: 5 requests per IP per hour
100
+ RATE_LIMIT_REQUESTS = 5
101
  RATE_LIMIT_WINDOW = 3600 # 1 hour in seconds
102
  request_tracker = defaultdict(deque)
103
 
 
362
  # Rate limiting check
363
  client_ip = get_client_ip(request)
364
  if not check_rate_limit(client_ip):
365
+ raise gr.Error("Rate Limit Quota Exceeded - Visit studio.yourmirror.io to sign up for unlimited use")
366
 
367
  # NSFW content filtering - only check product image
368
  print(f"[NSFW] Checking product image for inappropriate content...")