SemanticVector class

Immutable vector for semantic embeddings.

Constructors

SemanticVector(List<double> dimensions)
const

Properties

dimensions → List<double>
final
hashCode → int
The hash code for this object.
no setterinherited
length → int
no setter
magnitude → double
no setter
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

cosineSimilarity(SemanticVector other) → double
Cosine similarity between two vectors (0.0 – 1.0).
euclideanDistance(SemanticVector other) → double
Euclidean distance to another vector.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
override

Operators

operator ==(Object other) → bool
The equality operator.
inherited