Acceldata
AIO

Last updated: Oct 07, 2026 16:43 UTC

Find out what the Truncated output rule checks, what it needs, and how to set it for the provider your project uses.

Definition

Truncated output flags a model call that stopped because it hit its token limit. When that happens, the call succeeds, but the answer is cut off partway through.

The rule checks each LLM span, that is, each model call. It reads the finish reason that the provider reported for the call. If the finish reason matches the value you set in the rule, the call fails the check.

Property Value
Key truncated_output
Evaluates Span (one model call). Only LLM spans are checked.
Check kind Deterministic
Category Output integrity
Default severity MEDIUM
Result Pass or fail

When a call fails, the check result shows:

  • The observed value, which is the length of the output.
  • An excerpt of the output, up to 500 characters.
  • A reason such as "provider stopped at the token limit, finish_reason length".

Why it matters

A truncated answer looks like a success. The call doesn't fail, and it isn't a refusal. The user still gets an incomplete reply. This rule separates these cut-off answers from errors and refusals, so you can see how often your token limits are too tight.

What it requires

  • LLM spans with a finish reason. The rule checks only LLM spans. It compares the finish reason that your application's traces report for each call.
  • No model calls. This is a deterministic check. It doesn't call a model to decide, so it doesn't need a judge model.
  • Permission to change rules. To create the rule, you need permission to change rules in the project. For more information, see Project permissions.
  • One parameter. The rule has one required parameter:
Parameter Type Default What it does
Finish reason meaning "hit the limit" Text, at least 1 character length The finish reason that means the provider stopped at the token limit

Providers use different words for this finish reason. For example, OpenAI reports length and Anthropic reports max_tokens. Set the value your provider uses. The rule fires only when the finish reason is exactly the same as this value, so max_tokens and MAX_TOKENS count as different values.

If you leave the parameter blank, you see "Finish reason meaning "hit the limit" is required." when you try to save.

Configuration examples

To add this rule to a project:

  1. On the Rules page, select + New rule.
  2. On the New rule page, enter truncated in Search templates. Then on the Truncated output card, select Configure ›.

The New rule template catalog, with template cards grouped by category

  1. On the Configure rule page, for Finish reason meaning "hit the limit", enter the finish reason your provider uses. To use one of the examples shown under the field, select it.

The Configure rule page, with fields for name, project, severity, and the rule's parameter

  1. Select Save & enable.

For the Name, Project, and Severity fields, see Create a rule.

The following table shows values to enter for Finish reason meaning "hit the limit".

If your project uses Enter
OpenAI length
Anthropic max_tokens
A provider that reports the reason in capitals MAX_TOKENS

A rule matches one value, and a project can have only one rule from this template. If the project already has one, the Truncated output card on its New rule page is marked In use and you can't pick it. If you choose that project on the Configure rule page, you see "This project already has a rule using this template." and Save & enable is turned off. To use a different finish reason, edit the project's existing rule and change the parameter.

Next steps