memoryscope.core.models.llama_index_embedding_model
- class memoryscope.core.models.llama_index_embedding_model.LlamaIndexEmbeddingModel(*args, **kwargs)[source]
Bases:
BaseModel
Manages text embeddings utilizing the DashScopeEmbedding within the LlamaIndex framework, facilitating embedding operations for both sync and async modes, inheriting from BaseModel.
- classmethod register_model(model_name: str, model_class: type)[source]
Registers a new embedding model class with the model registry.
- Parameters:
model_name (str) – The name to register the model under.
model_class (type) – The class of the model to register.
- before_call(model_response: ModelResponse, **kwargs)[source]
- after_call(model_response: ModelResponse, **kwargs) ModelResponse [source]
- model_name: str
- module_name: str
- timeout: int
- max_retries: int
- retry_interval: float
- kwargs_filter: bool
- raise_exception: bool
- context: MemoryscopeContext
- kwargs: dict