When an AI-generated result cannot arrive quickly enough to hide its latency, schedule the work before the user needs it. In a learning app built by Michael Hairetis for his two children, generating the next question during the current one still sometimes left a spinner between questions. His redesign prepared complete lessons ahead of time, so opening one was a database read rather than a new agent call.
Why generating the next item on demand still caused a wait
Hairetis describes building a small learning app for his two children on agent infrastructure he also used for other platforms. In an unattended orchestration job, a slow call was less visible; in the app, a child waiting between questions made the delay immediate.
The first design made one question per agent call and prefetched the next question while the child worked. That moved some of the generation into otherwise useful time, but it did not guarantee the next question would be ready. If prefetching was still underway when the child finished, the app showed a spinner.
Move generation ahead of the interaction
The revised design planned three lessons at once and generated each lesson completely in one call before the child saw it. Hairetis reports that the first lesson took “a minute or two”; later lessons could be built in the background while the child worked on the first. The initial wait remained, but it happened before the active sequence rather than between its questions.
#1 Best Overall
- Used Book in Good Condition
Once a lesson was complete, opening it became a database read. Hairetis reports measuring that operation at six milliseconds in his own app. This is an author-reported implementation measurement, not an independent benchmark or a general guarantee about database reads or agent systems.
What makes this pattern work
Prepare usable work, not a promise of future work
A pre-generated lesson needs to be genuinely complete enough for the user to start. If it is only a plan containing placeholders, the app still has to call the agent during the session, putting the wait back in the user’s path.
Rank #2
Let background work survive interruption
Background generation must be durable across server restarts. Hairetis warns that an in-flight asynchronous task can die silently, leaving a lesson marked “building” without a result. A production design therefore needs a way to persist work state and detect, retry, or otherwise recover interrupted generation instead of treating a launched task as a completed one.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.When to move the wait—and when not to
This approach trades an up-front wait for fewer interruptions during use; it does not make generation itself faster. It fits best when there is a predictable next interaction, the user can wait before beginning or keep using the current item while preparation runs, and the output can be completed in advance.
What’s actually slowing this PC down?
Pick the symptom - the matching free tool is one click away.
Rank #3
- Used Book in Good Condition
For a design decision, compare the alternatives by asking where the wait lands, what the user can do while work runs, whether the prepared output is actually complete, and how interrupted background work is detected and recovered. If the user needs to shape the result step by step, or the next task cannot be predicted, pre-generating a complete unit may not remove the important wait.
Hairetis’s account is a concrete design example, not evidence that all users prefer an up-front delay or that this architecture improves performance in every app. Its useful insight is narrower: when a call cannot be made invisible, changing when it runs can make the user-facing interaction feel immediate.
Quick Recap
Rank #4
- BIG POWER: Create without compromise on a powerhouse laptop for AI and productivity with the Galaxy Book6 Ultra
- UNCOMPROMISED CREATIVE POWER FOR YOU: With a dedicated NVIDIA GeForce RTX 5070 graphics card this powerful PC elevates every frame, shot and render of GPU intensive projects like 3D animations and AI generated videos
- DYNAMIC AMOLED 2X DISPLAY: With the power to show rich and vibrant colors and a refresh rate of up to 120Hz, all your creative projects come alive in vivid clarity
- SIX SPEAKERS: Tuned with Dolby ATMOS, the six-speaker system is a first for Galaxy PC computers
- SLIM & LIGHT LAPTOP: Experience a premium two-tone keyboard, a slimmer hinge and a lightweight, symmetrical frame that's easy to carry
Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.




