Exception: Langchain::OutputParsers::OutputParserException

Inherits:
StandardError
  • Object
show all
Defined in:
lib/langchain/output_parsers/output_parser_exception.rb

Instance Method Summary collapse

Constructor Details

#initialize(message, text) ⇒ OutputParserException

Returns a new instance of OutputParserException.



2
3
4
5
# File 'lib/langchain/output_parsers/output_parser_exception.rb', line 2

def initialize(message, text)
  @message = message
  @text = text
end

Instance Method Details

#to_sObject



7
8
9
# File 'lib/langchain/output_parsers/output_parser_exception.rb', line 7

def to_s
  "#{@message}\nText: #{@text}"
end