Class: TheCompaniesAPI::Generated::Models::Llmanswer
- Inherits:
-
Object
- Object
- TheCompaniesAPI::Generated::Models::Llmanswer
- Defined in:
- lib/thecompaniesapi/generated/models/llmanswer.rb
Overview
An answer from a query made to the LLM.
Instance Attribute Summary collapse
-
#company_id ⇒ Float
CompanyId.
-
#explanation ⇒ String
Explanation.
-
#fields ⇒ Array
Fields.
-
#grounded ⇒ Boolean
Grounded.
-
#output ⇒ Hash
Output.
-
#question ⇒ String
Question.
-
#score ⇒ Float
Score.
Instance Method Summary collapse
-
#initialize(data = {}) ⇒ Llmanswer
constructor
Initialize a new Llmanswer.
-
#to_hash ⇒ Hash
(also: #to_h)
Convert to hash.
Constructor Details
#initialize(data = {}) ⇒ Llmanswer
Initialize a new Llmanswer
36 37 38 39 40 41 42 43 44 |
# File 'lib/thecompaniesapi/generated/models/llmanswer.rb', line 36 def initialize(data = {}) @company_id = data['companyId'] @explanation = data['explanation'] @fields = data['fields'] @grounded = data['grounded'] @output = data['output'] @question = data['question'] @score = data['score'] end |
Instance Attribute Details
#company_id ⇒ Float
Returns companyId.
12 13 14 |
# File 'lib/thecompaniesapi/generated/models/llmanswer.rb', line 12 def company_id @company_id end |
#explanation ⇒ String
Returns explanation.
15 16 17 |
# File 'lib/thecompaniesapi/generated/models/llmanswer.rb', line 15 def explanation @explanation end |
#fields ⇒ Array
Returns fields.
18 19 20 |
# File 'lib/thecompaniesapi/generated/models/llmanswer.rb', line 18 def fields @fields end |
#grounded ⇒ Boolean
Returns grounded.
21 22 23 |
# File 'lib/thecompaniesapi/generated/models/llmanswer.rb', line 21 def grounded @grounded end |
#output ⇒ Hash
Returns output.
24 25 26 |
# File 'lib/thecompaniesapi/generated/models/llmanswer.rb', line 24 def output @output end |
#question ⇒ String
Returns question.
27 28 29 |
# File 'lib/thecompaniesapi/generated/models/llmanswer.rb', line 27 def question @question end |
#score ⇒ Float
Returns score.
30 31 32 |
# File 'lib/thecompaniesapi/generated/models/llmanswer.rb', line 30 def score @score end |
Instance Method Details
#to_hash ⇒ Hash Also known as: to_h
Convert to hash
50 51 52 53 54 55 56 57 58 59 60 |
# File 'lib/thecompaniesapi/generated/models/llmanswer.rb', line 50 def to_hash { 'companyId' => @company_id, 'explanation' => @explanation, 'fields' => @fields, 'grounded' => @grounded, 'output' => @output, 'question' => @question, 'score' => @score, } end |