---
url: >-
  https://adk.nht.io/api/@nhtio/adk/batteries/llm/litert_lm/exceptions/variables/E_LITERT_LM_INVALID_TOOL_CALL_ARGS.md
description: Raised when a tool-call emitted by the model carries malformed `arguments`.
---

# Variable: E\_LITERT\_LM\_INVALID\_TOOL\_CALL\_ARGS

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

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

Raised when a tool-call emitted by the model carries malformed `arguments`.

## Remarks

Unlike OpenAI-wire batteries (where tool-call `arguments` arrive as a JSON **string** that may
fail to parse), LiteRT-LM delivers `ToolCall.function.arguments` already as a parsed object
(`Record<string, JsonValue>`). This exception therefore guards the rarer case where that field is
present but is not a plain object (e.g. an array or a primitive slipped through the wire shape).

Non-fatal. The adapter does NOT throw this — it instantiates it inside `executeAndPersistToolCall`,
pulls `.message` into a [@nhtio/adk!Tokenizable](../../../../../common/classes/Tokenizable.md), and persists a `ToolCall` record with
`isError: true` so the model can self-correct on the next iteration.

Printf args: `[reasonHeadline, rawArgs]`.
