Skip to content

StreamAbortContext

Namespace: Vercel.AI

public sealed class StreamAbortContext

Passed to OnAbort.

Inheritance: object

View source

StreamAbortContext(IReadOnlyList<StepResult>, Exception)

Section titled “StreamAbortContext(IReadOnlyList<StepResult>, Exception)”
public StreamAbortContext(IReadOnlyList<StepResult> steps, Exception exception)

Creates a context.

Parameters

Name Type Description
steps IReadOnlyList<StepResult>
exception Exception

View source

public Exception Exception { get; }

The cancellation exception, or the abort reason when it is an exception.

Value: Exception

View source

public IReadOnlyList<StepResult> Steps { get; }

Steps that finished before the abort.

Value: IReadOnlyList<StepResult>

View source

Apache-2.0 · Copyright 2023 Vercel, Inc. · unofficial community port, not an official Vercel product