refactoting of imports

This commit is contained in:
Marco Vinciguerra 2024-09-12 10:16:15 +02:00
parent ed8e1738c3
commit c64ce88db8
4 changed files with 12 additions and 4 deletions

View File

@ -8,7 +8,8 @@ from .base_node import BaseNode
class ConcatAnswersNode(BaseNode):
"""
A node responsible for concatenating the answers from multiple graph instances into a single answer.
A node responsible for concatenating the answers from multiple
graph instances into a single answer.
Attributes:
verbose (bool): A flag indicating whether to show print statements during execution.

View File

@ -11,7 +11,10 @@ from langchain_mistralai import ChatMistralAI
from langchain_community.chat_models import ChatOllama
from tqdm import tqdm
from .base_node import BaseNode
from ..prompts import TEMPLATE_CHUNKS, TEMPLATE_NO_CHUNKS, TEMPLATE_MERGE, TEMPLATE_CHUNKS_MD, TEMPLATE_NO_CHUNKS_MD, TEMPLATE_MERGE_MD
from ..prompts import (TEMPLATE_CHUNKS,
TEMPLATE_NO_CHUNKS, TEMPLATE_MERGE,
TEMPLATE_CHUNKS_MD, TEMPLATE_NO_CHUNKS_MD,
TEMPLATE_MERGE_MD)
class GenerateAnswerNode(BaseNode):
"""

View File

@ -11,7 +11,9 @@ from langchain_mistralai import ChatMistralAI
from tqdm import tqdm
from langchain_community.chat_models import ChatOllama
from .base_node import BaseNode
from ..prompts.generate_answer_node_omni_prompts import TEMPLATE_NO_CHUNKS_OMNI, TEMPLATE_CHUNKS_OMNI, TEMPLATE_MERGE_OMNI
from ..prompts.generate_answer_node_omni_prompts import (TEMPLATE_NO_CHUNKS_OMNI,
TEMPLATE_CHUNKS_OMNI,
TEMPLATE_MERGE_OMNI)
class GenerateAnswerOmniNode(BaseNode):
"""

View File

@ -12,7 +12,9 @@ from tqdm import tqdm
from langchain_community.chat_models import ChatOllama
from ..utils.logging import get_logger
from .base_node import BaseNode
from ..prompts.generate_answer_node_pdf_prompts import TEMPLATE_CHUNKS_PDF, TEMPLATE_NO_CHUNKS_PDF, TEMPLATE_MERGE_PDF
from ..prompts.generate_answer_node_pdf_prompts import (TEMPLATE_CHUNKS_PDF,
TEMPLATE_NO_CHUNKS_PDF,
TEMPLATE_MERGE_PDF)
class GenerateAnswerPDFNode(BaseNode):
"""