Interface: ToolIdentityRule
Defined in: src/batteries/validation/types.ts:370
Requires a replayed tool result to name a tool the request actually declares.
Remarks
A ROOT CAUSE of the silent empty-generation class. Gemini matches a functionResponse.name against its functionDeclarations; a name that resolves to nothing — an opaque call id, or a tool no longer offered this turn — makes it return an empty candidate (parts: [{text: ''}], STOP, no candidatesTokenCount) a large fraction of the time. The gateway then forwards that as an ordinary finish_reason: stop with content: null and NO error, so the caller sees a successful turn that produced nothing.
Requires the tool registry; the evaluator skips this rule when none is supplied.
Properties
| Property | Type | Description | Defined in |
|---|---|---|---|
id | string | Stable identifier used in findings. | src/batteries/validation/types.ts:374 |
severity? | "blocking" | "advisory" | See OrderRule.severity. Omitted means advisory. | src/batteries/validation/types.ts:376 |
type | "toolIdentity" | Discriminator selecting the tool-identity evaluator. | src/batteries/validation/types.ts:372 |