# `Nous.Errors.MaxIterationsExceeded`
[🔗](https://github.com/nyo16/nous/blob/v0.17.1/lib/nous/errors.ex#L185)

Error when agent loop exceeds maximum iterations.

Raised when an agent makes too many back-and-forth calls
with the model, possibly indicating an infinite loop.

# `t`

```elixir
@type t() :: %Nous.Errors.MaxIterationsExceeded{
  __exception__: true,
  max_iterations: pos_integer() | nil,
  message: String.t()
}
```

---

*Consult [api-reference.md](api-reference.md) for complete listing*
