Skip to content
Source
Sign inSign up
TanStack/ai
Open History to see the last commit

RunError.md

34 lines666 Bytes

1---
2id: RunError
3title: RunError
4---
5​
6Defined in: packages/ai/src/activities/chat/middleware/run-store.ts:99
7​
8Why a run failed.
9​
10A bare message is an LLM provider's prose: it changes between model
11versions and cannot be branched on. `code` is what a consumer switches over
12to decide whether to retry, escalate, or surface a specific UI.
13​
14## Properties
15​
16### code?
17​
18```ts
19optional code?: string;
20```
21​
22Defined in: packages/ai/src/activities/chat/middleware/run-store.ts:102
23​
24Stable, machine-branchable classification, when the provider supplies one.
25​
26***
27​
28### message
29​
30```ts
31message: string;
32```
33​
34Defined in: packages/ai/src/activities/chat/middleware/run-store.ts:100