Skip to contents

Requests cooperative cancellation of the async generation submitted through exactly this handle. The promise rejects with relm_error_cancelled; it never resolves to partial text. An in-flight native decode or image encoder call may need to finish before cancellation takes effect. The handle becomes reusable after completion is collected on R's event loop.

Usage

llm_cancel(m)

Arguments

m

An open llm handle from llm().

Value

An invisible logical: TRUE only for the first accepted cancellation before native terminal publication; FALSE when idle, already cancelling, native-terminal, or when another handle submitted the active job.