Class: MistralModels::Embedding

Inherits:
Object
  • Object
show all
Defined in:
lib/mistral_rb/response_models.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(embedding_hash) ⇒ Embedding

Returns a new instance of Embedding.



48
49
50
51
52
# File 'lib/mistral_rb/response_models.rb', line 48

def initialize(embedding_hash)
  @object = embedding_hash["object"]
  @embedding = embedding_hash["embedding"]
  @index = embedding_hash["index"]
end

Instance Attribute Details

#embeddingObject (readonly)

Returns the value of attribute embedding.



46
47
48
# File 'lib/mistral_rb/response_models.rb', line 46

def embedding
  @embedding
end

#indexObject (readonly)

Returns the value of attribute index.



46
47
48
# File 'lib/mistral_rb/response_models.rb', line 46

def index
  @index
end

#objectObject (readonly)

Returns the value of attribute object.



46
47
48
# File 'lib/mistral_rb/response_models.rb', line 46

def object
  @object
end