class
AI::Provider::NoContentGeneratedError
- AI::Provider::NoContentGeneratedError
- AI::Provider::AISDKError
- Exception
- Reference
- Object
Overview
Error thrown when the AI provider fails to generate any content.
This error indicates that the model completed its response but did not produce any usable content.
Defined in:
ai/provider/errors/no_content_generated_error.crConstructors
-
.new(*, message : String = "No content generated.")
Creates a new NoContentGeneratedError.
Class Method Summary
-
.instance?(error) : Bool
Checks if the given value is an instance of NoContentGeneratedError.
Instance methods inherited from class AI::Provider::AISDKError
name : String
name,
to_s(io : IO) : Nil
to_s
Constructor methods inherited from class AI::Provider::AISDKError
new(*, name : String, message : String, cause : Exception | Nil = nil)
new
Class methods inherited from class AI::Provider::AISDKError
instance?(error) : Bool
instance?
Constructor Detail
def self.new(*, message : String = "No content generated.")
#
Creates a new NoContentGeneratedError.
Parameters:
- message: Optional custom message (defaults to "No content generated.")
Class Method Detail
def self.instance?(error) : Bool
#
Checks if the given value is an instance of NoContentGeneratedError.