encoders
semantic_router.encoders.aurelio
AurelioSparseEncoder Objects
Sparse encoder using Aurelio Platform’s embedding API. Requires an API key from https://platform.aurelio.ai
__init__
Initialize the AurelioSparseEncoder.
Arguments:
name
(str | None
): The name of the model to use.api_key
(str | None
): The API key to use.
__call__
Encode a list of documents using the Aurelio Platform embedding API. Documents
must be strings, sparse encoders do not support other types.
Arguments:
docs
(list[str]
): The documents to encode.
Returns:
list[SparseEmbedding]
: The encoded documents.
acall
Asynchronously encode a list of documents using the Aurelio Platform
embedding API. Documents must be strings, sparse encoders do not support other types.
Arguments:
docs
(list[str]
): The documents to encode.
Returns:
list[SparseEmbedding]
: The encoded documents.
fit
Fit the encoder to a list of documents. AurelioSparseEncoder does not support
fit yet.
Arguments:
docs
(list[str]
): The documents to fit the encoder to.