Skip to content

Commit 6c7ae3f

Browse files
committed
chore: fix typo.
1 parent 77aa83d commit 6c7ae3f

File tree

2 files changed

+2
-9
lines changed

2 files changed

+2
-9
lines changed

apps/setting/models_provider/impl/azure_model_provider/model/embedding.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -16,14 +16,10 @@
1616
class AzureOpenAIEmbeddingModel(MaxKBBaseModel, AzureOpenAIEmbeddings):
1717
@staticmethod
1818
def new_instance(model_type, model_name, model_credential: Dict[str, object], **model_kwargs):
19-
return AzureOpenAIEmbeddings(
19+
return AzureOpenAIEmbeddingModel(
2020
model=model_name,
2121
openai_api_key=model_credential.get('api_key'),
2222
azure_endpoint=model_credential.get('api_base'),
2323
openai_api_version=model_credential.get('api_version'),
2424
openai_api_type="azure",
2525
)
26-
27-
28-
def is_cache_model(self):
29-
return True

apps/setting/models_provider/impl/gemini_model_provider/model/embedding.py

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,7 @@
1616
class GeminiEmbeddingModel(MaxKBBaseModel, GoogleGenerativeAIEmbeddings):
1717
@staticmethod
1818
def new_instance(model_type, model_name, model_credential: Dict[str, object], **model_kwargs):
19-
return GoogleGenerativeAIEmbeddings(
19+
return GeminiEmbeddingModel(
2020
google_api_key=model_credential.get('api_key'),
2121
model=model_name,
2222
)
23-
24-
def is_cache_model(self):
25-
return False

0 commit comments

Comments
 (0)