Skip to content

EmbeddingFeature#

[source] EmbeddingFeature #

Represents an embedding feature.

PARAMETER DESCRIPTION
name

The name of the embedding feature.

TYPE: str DEFAULT: None

dimension

The dimensionality of the embedding feature.

TYPE: int DEFAULT: None

similarity_function_type

The type of similarity function used for the embedding feature. Available functions are L2, COSINE, and DOT_PRODUCT. Defaults to SimilarityFunctionType.L2.

TYPE: SimilarityFunctionType DEFAULT: SimilarityFunctionType.L2

model

hsml.model.Model A Model in hsml.

DEFAULT: None

feature_group

The feature group object that contains the embedding feature.

DEFAULT: None

embedding_index

EmbeddingIndex The index for managing embedding features.

DEFAULT: None

[source] dimension property #

dimension

int: The dimensionality of the embedding feature.

[source] dimenstion property #

dimenstion

The dimensionality of the embedding feature.

This one is excluded from the docs as the name is misspelled but kept to avoid breaking the API.

[source] embedding_index property writable #

embedding_index

EmbeddingIndex: The index for managing embedding features.

[source] feature_group property writable #

feature_group

FeatureGroup: The feature group object that contains the embedding feature.

[source] model property #

model

hsml.model.Model: The Model in hsml.

[source] name property #

name

str: The name of the embedding feature.

[source] similarity_function_type property #

similarity_function_type

SimilarityFunctionType: The type of similarity function used for the embedding feature.

[source] json #

json()

Serialize the EmbeddingFeature object to a JSON string.

[source] to_dict #

to_dict()

Convert the EmbeddingFeature object to a dictionary.

RETURNS DESCRIPTION

dict: A dictionary representation of the EmbeddingFeature object.