Rate Limit

Nanonets API enforces rate limits to ensure fair usage and maintain optimal performance for all users. Getting a 429 response code from our API means that you have reached our rate-limit.

The rate limit applies to all POST requests within the OCR Predict section, including:

  • Prediction for Image URL
  • Prediction for Image File
  • Async Prediction for Image URL
  • Async Prediction for Image File

Rate Limits by Plan

Unpaid and Pay As You Go Plans:

  • Custom Models:
    • Initial Capacity: For the first 50 pages, the rate is set at 5 pages per minute. This allows users to handle moderate loads efficiently.
    • Extended Usage: Beyond the initial 50 pages, the rate limit decreases to 2 pages per minute. This adjustment helps in managing server loads and maintaining service quality across all users.
  • Instant Learning Models (IL Model):
    • Initial Capacity: Like custom models, these start with a limit of 5 pages per minute for up to 50 pages, catering to typical usage scenarios.
    • Extended Usage: The rate drops to 2 pages per minute after 50 pages, which balances system utilization during prolonged operations.

Pro and Enterprise Plans:

  • Custom Models:
    • These plans feature an enhanced rate of 150 pages per minute by default
  • Instant Learning Models (IL Model):
    • Instant learning models have a rate limit of 75 pages per minute
      Note: These are only the upper limits on our platform and we don't guarantee these rate limits

What’s the difference between Sync Call and Async Call?

  • Sync: Your files will get uploaded and processed, and you will see the results on the screen.
  • Async: your files will get uploaded and processed at a later point in time (usually within 5 minutes). Recommended if you are processing a lot of large files (> 3 pages of PDFs)

How does Rate-limit impact a customer

  1. If the rate-limit threshold is breached, then
    1. [for Sync] No new files can be uploaded
    2. [for Async] Files will still get uploaded to a queue but will be processed at Rate-limit value and queue will have a maximum limit of 5000 pages
  2. What will happen if a file with more than 150 pages is uploaded to non-LLM model
    1. [Sync] The whole file will get uploaded, but will be processed at rate limit. Since model will be rate limited, no new files can be uploaded unless model reaches within rate limit threshold
    2. [Async] The file will get upload and will be processed at rate limit. User can upload more files (or pages) which we will be queued for processing. Max queue length for asycn processing is 5000 pages

You can reduce rate-limiting errors using one of these approaches:

  • Handling 429 Errors
    • Implement logic in your application to handle 429 (Too Many Requests) errors gracefully. This could include:
      • Retrying the request after a delay.
      • Exponential backoff strategies to reduce the frequency of retries.
      • Alerting or logging when rate limits are approached or exceeded.
  • Contact Sales team to upgrade the rate-limits
    • If consistent rate limiting is impacting your application, consider contacting Sales team to upgrade the rate-limits to allows more requests.
    • Reach out to us at [email protected].