---
url: >-
  https://adk.nht.io/api/@nhtio/adk/batteries/llm/litert_lm/exceptions/variables/E_LITERT_LM_CONTEXT_OVERFLOW.md
description: >-
  Thrown when the total token weight of the resolved request exceeds
  `contextWindow`. Only raised when `tokenEncoding` is non-null. Carries `{
  total, contextWindow, tokenEncoding, perBucket }` in the message so middleware
  can target shedding.
---

# Variable: E\_LITERT\_LM\_CONTEXT\_OVERFLOW

```ts
const E_LITERT_LM_CONTEXT_OVERFLOW: CreatedException<
  [number, number, string, string]
>;
```

Defined in: [src/batteries/llm/litert\_lm/exceptions.ts:31](https://github.com/NHTIO/ADK/blob/v1.20260713.1/src/src/batteries/llm/litert_lm/exceptions.ts#L31)

Thrown when the total token weight of the resolved request exceeds `contextWindow`. Only raised
when `tokenEncoding` is non-null. Carries `{ total, contextWindow, tokenEncoding, perBucket }` in
the message so middleware can target shedding.
