Explorar el Código

[chore] fix wrong import of LLMs from langchain (#1002)

Sidharth Mohanty hace 1 año
padre
commit
7910cee259
Se han modificado 3 ficheros con 3 adiciones y 3 borrados
  1. 1 1
      embedchain/llm/cohere.py
  2. 1 1
      embedchain/llm/huggingface.py
  3. 1 1
      embedchain/llm/llama2.py

+ 1 - 1
embedchain/llm/cohere.py

@@ -2,7 +2,7 @@ import importlib
 import os
 from typing import Optional
 
-from langchain.llms import Cohere
+from langchain.llms.cohere import Cohere
 
 from embedchain.config import BaseLlmConfig
 from embedchain.helpers.json_serializable import register_deserializable

+ 1 - 1
embedchain/llm/huggingface.py

@@ -3,7 +3,7 @@ import logging
 import os
 from typing import Optional
 
-from langchain.llms import HuggingFaceHub
+from langchain.llms.huggingface_hub import HuggingFaceHub
 
 from embedchain.config import BaseLlmConfig
 from embedchain.helpers.json_serializable import register_deserializable

+ 1 - 1
embedchain/llm/llama2.py

@@ -2,7 +2,7 @@ import importlib
 import os
 from typing import Optional
 
-from langchain.llms import Replicate
+from langchain.llms.replicate import Replicate
 
 from embedchain.config import BaseLlmConfig
 from embedchain.helpers.json_serializable import register_deserializable