AurelioSparseEncoder Objects

class AurelioSparseEncoder(SparseEncoder, AsymmetricSparseMixin)
Sparse encoder using Aurelio Platform’s embedding API. Requires an API key from https://platform.aurelio.ai

__init__

def __init__(name: str | None = None, api_key: Optional[str] = None)
Initialize the AurelioSparseEncoder. Arguments:
  • name (str | None): The name of the model to use.
  • api_key (str | None): The API key to use.

__call__

def __call__(docs: list[str]) -> list[SparseEmbedding]
Encode a list of queries using the Aurelio Platform embedding API. Documents must be strings, sparse encoders do not support other types.

acall

async def acall(docs: list[str]) -> list[SparseEmbedding]
Asynchronously encode a list of documents using the Aurelio Platform embedding API. Documents must be strings, sparse encoders do not support other types. :param docs: The documents to encode. :type docs: list[str] :param input_type: :type semantic_router.encoders.encode_input_type.EncodeInputType :return: The encoded documents. :rtype: list[SparseEmbedding]

fit

def fit(docs: List[str])
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.