TECHNOLOGY

Tavily max_age_hours: handle live-fetch capacity without silently weakening freshness

In this article
THE QUICK TAKE

Removing a freshness requirement can restore retrieval availability, but it changes the evidence contract and must remain visible to the caller.

Define the required acquisition age

An incident assistant may need a current status page, while a reference assistant can accept cached background documentation. Set the acquisition requirement from the task before considering fallback. A response that is available quickly but too old for the incident does not satisfy the original request merely because it contains a plausible explanation.

Understand the cache-age control

The Search reference defines max_age_hours as the allowed age of Tavily’s cached copy. It distinguishes live fetching, cache-only operation, and the default acquisition policy. Keep that meaning separate from publication age. A recently published page and a recently fetched copy answer different temporal questions.

Account for reduced result coverage

Search best practices explains that a page can be omitted when its cached copy is too old and live acquisition fails. Therefore fewer results than requested can reflect the freshness requirement rather than an absence of relevant URLs. Record acquisition policy alongside the returned set before interpreting coverage changes as ranking quality.

For an incident question, retain an unresolved state if the needed current status cannot be obtained. A cached troubleshooting guide may still help explain background concepts, but it cannot silently replace the missing current observation. Label the different evidence roles in the interface and final report.

Separate capacity from rate limiting

The rate-limits guide documents flex-capacity refusal with status 434, distinct from 429 rate limiting. It describes retrying or omitting freshness controls to use cache. Treat the latter as a policy change, not a transparent retry of the same task. Keep status and available retry metadata rather than matching only a message string.

Make fallback an explicit branch

Implement separate outcomes for fresh acquisition success, insufficient coverage, temporary capacity refusal, and permitted cached fallback. If the task requires current evidence, preserve failure or defer the answer under the application’s existing retry policy. If cached material is allowed, state the relaxed acquisition scope and keep the original requirement in the record.

The existing guides to task budgets and stale document evidence help review that decision. Test a capacity refusal and a smaller successful result independently. The consumer should preserve why evidence is missing without inventing current observations or promising that every retry reaches the live page.

Earn rental income from GPUs

Have idle GPUs or looking to fund AI infrastructure? Retrivium finds a rental platform, sets up the server and helps you assess income and costs with a pilot.

Explore GPU hosting
← All articles