Follow an AI assistant that accepts PDFs and makes them searchable within three minutes. A queue holds accepted work, workers process it, and a policy decides when to buffer, scale, or refuse new work. The rates and durations below are illustrative assumptions, not measurements of InterviewLayer.
Protect the completion promise
A quick upload response can hide a growing completion delay.
A user uploads a PDF. The API durably accepts its processing job, returns a receipt, and a worker later extracts, embeds, and indexes the document. Acceptance means that our service has taken responsibility for this job; searchable completion is a later event. The three-minute target runs from acceptance to that completion.
Suppose uploads keep succeeding immediately while documents wait longer in the queue. The upload API can look healthy even as users wait too long to search their documents. We therefore measure accepted-to-searchable time as well as response time. Waiting is part of the user experience even when it happens outside the HTTP request.
The queue lets already accepted work survive a worker interruption and wait for another attempt. That is useful, but it cannot make workers finish faster. Our next decision is how much waiting the product can absorb, when additional workers help, and what to do before accepting work we cannot safely finish.
Separate what can finish from what does finish
Capacity is a tested ability; throughput is an observed completion rate.
Normally four documents arrive each second. Tests on this workload suggest that the current worker fleet can finish about five documents per second when it has enough work. Five per second is its useful capacity under those test conditions. With only four arriving and no backlog, actual throughput is about four, because there is no fifth document to finish.
Once enough work is waiting, completions can approach the tested five-per-second rate. If fifteen are accepted each second while five finish, unfinished work increases by about ten each second. Count successful document completions, rather than worker starts or attempts, because a failed attempt can consume resources without producing a searchable document.
Our estimates assume similarly sized jobs, arrival-order waiting, roughly even completions, and a stable useful service rate. We count waiting documents separately from documents already being processed. Those assumptions make the arithmetic understandable; they do not guarantee an exact deadline for every PDF. A different document mix needs another capacity measurement.
Let a finite spike drain
A burst can be buffered when later spare capacity and the waiting budget are sufficient.
Start with almost no waiting work. Uploads jump from four to fifteen per second for thirty seconds.