Skip to content

Commit 9439fe5

Browse files
CopilotVinciGit00
andcommitted
Fix langchain import issues blocking tests
Co-authored-by: VinciGit00 <88108002+VinciGit00@users.noreply.github.com>
1 parent 6d13212 commit 9439fe5

20 files changed

+25
-25
lines changed

scrapegraphai/graphs/abstract_graph.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
from abc import ABC, abstractmethod
1010
from typing import Optional, Type
1111

12-
from langchain.chat_models import init_chat_model
12+
from langchain_core.language_models.chat_models import init_chat_model
1313
from langchain_core.rate_limiters import InMemoryRateLimiter
1414
from pydantic import BaseModel
1515

scrapegraphai/nodes/description_node.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
from typing import List, Optional
66

7-
from langchain.prompts import PromptTemplate
7+
from langchain_core.prompts import PromptTemplate
88
from langchain_core.runnables import RunnableParallel
99
from tqdm import tqdm
1010

scrapegraphai/nodes/generate_answer_csv_node.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
from typing import List, Optional
66

7-
from langchain.prompts import PromptTemplate
7+
from langchain_core.prompts import PromptTemplate
88
from langchain_core.output_parsers import JsonOutputParser
99
from langchain_core.runnables import RunnableParallel
1010
from langchain_mistralai import ChatMistralAI

scrapegraphai/nodes/generate_answer_node.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
import time
77
from typing import List, Optional
88

9-
from langchain.prompts import PromptTemplate
9+
from langchain_core.prompts import PromptTemplate
1010
from langchain_aws import ChatBedrock
1111
from langchain_community.chat_models import ChatOllama
1212
from langchain_core.output_parsers import JsonOutputParser

scrapegraphai/nodes/generate_answer_node_k_level.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
from typing import List, Optional
66

7-
from langchain.prompts import PromptTemplate
7+
from langchain_core.prompts import PromptTemplate
88
from langchain_aws import ChatBedrock
99
from langchain_community.chat_models import ChatOllama
1010
from langchain_core.output_parsers import JsonOutputParser

scrapegraphai/nodes/generate_answer_omni_node.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
from typing import List, Optional
66

7-
from langchain.prompts import PromptTemplate
7+
from langchain_core.prompts import PromptTemplate
88
from langchain_community.chat_models import ChatOllama
99
from langchain_core.output_parsers import JsonOutputParser
1010
from langchain_core.runnables import RunnableParallel

scrapegraphai/nodes/generate_code_node.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@
1212
from bs4 import BeautifulSoup
1313
from jsonschema import ValidationError as JSONSchemaValidationError
1414
from jsonschema import validate
15-
from langchain.output_parsers import ResponseSchema, StructuredOutputParser
16-
from langchain.prompts import PromptTemplate
15+
from langchain_core.output_parsers import ResponseSchema, StructuredOutputParser
16+
from langchain_core.prompts import PromptTemplate
1717
from langchain_community.chat_models import ChatOllama
1818
from langchain_core.output_parsers import StrOutputParser
1919

scrapegraphai/nodes/generate_scraper_node.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
from typing import List, Optional
66

7-
from langchain.prompts import PromptTemplate
7+
from langchain_core.prompts import PromptTemplate
88
from langchain_core.output_parsers import JsonOutputParser, StrOutputParser
99

1010
from .base_node import BaseNode

scrapegraphai/nodes/get_probable_tags_node.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@
44

55
from typing import List
66

7-
from langchain.output_parsers import CommaSeparatedListOutputParser
8-
from langchain.prompts import PromptTemplate
7+
from langchain_core.output_parsers import CommaSeparatedListOutputParser
8+
from langchain_core.prompts import PromptTemplate
99

1010
from ..prompts import TEMPLATE_GET_PROBABLE_TAGS
1111
from .base_node import BaseNode

scrapegraphai/nodes/html_analyzer_node.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
from typing import List, Optional
66

7-
from langchain.prompts import PromptTemplate
7+
from langchain_core.prompts import PromptTemplate
88
from langchain_community.chat_models import ChatOllama
99
from langchain_core.output_parsers import StrOutputParser
1010

0 commit comments

Comments
 (0)