H-08Retry / Recovery Loop

/harnesses/retry-loop

On failure, classify what kind of failure it was — and only then decide how to retry.

Step-by-step walkthrough6 steps
  1. An attempt hits the environment…
  2. …and fails. The error is captured, not discarded.
  3. Classify: is this transient (rate limit) or systematic (wrong approach)?
  4. Transient → simply retry.
  5. Systematic → change strategy first. Blind retries repeat the failure.
  6. Retry with a genuinely different approach.
Key insight

The classification step is the whole pattern. Transient errors want patience; systematic errors want a different strategy.

Failure mode

Blind retries: re-running the identical attempt against a deterministic failure just multiplies cost by the retry budget.

Further reading

Elsewhere in the atlas