Embedding class

A single embedding object.

Contains the embedding vector and its index in the input list.

Annotations
  • @immutable

Constructors

Embedding({required String object, required List<double> embedding, required int index})
Creates an Embedding.
const
Embedding.fromJson(Map<String, dynamic> json)
Creates an Embedding from JSON.
factory

Properties

dimensions int
The number of dimensions in this embedding.
no setter
embedding List<double>
The embedding vector.
final
hashCode int
The hash code for this object.
no setteroverride
index int
The index of this embedding in the input list.
final
object String
The object type (always "embedding").
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() Map<String, dynamic>
Converts to JSON.
toString() String
A string representation of this object.
override

Operators

operator ==(Object other) bool
The equality operator.
override