CancelledError

org.llm4s.error.CancelledError
See theCancelledError companion object
@Stable
final case class CancelledError extends LLMError, NonRecoverableError

The operation was cancelled by interrupting its thread.

Interruption is how llm4s cancels work: an interrupted provider or tool call returns Left(CancelledError) and leaves the thread's interrupt flag set, so its caller can still see the interrupt. It is never retried.

Value parameters

operation

what was cancelled, e.g. "http.POST" or "openai.complete"

Attributes

Companion
object
Source
CancelledError.scala
Graph
Supertypes
trait LLMError
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any
Show all

Members list

Value members

Inherited methods

Optional error code for programmatic handling

Optional error code for programmatic handling

Attributes

Inherited from:
LLMError
Source
LLMError.scala

Error correlation IDs for debugging

Error correlation IDs for debugging

Attributes

Inherited from:
LLMError
Source
LLMError.scala

Formatted error message with context

Formatted error message with context

Attributes

Inherited from:
LLMError
Source
LLMError.scala

Attributes

Inherited from:
Product

Attributes

Inherited from:
Product

Concrete fields

override val context: Map[String, String]

Additional context information

Additional context information

Attributes

Source
CancelledError.scala