Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion backend/src/document_sources/web_pages.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ def get_documents_from_web_page(source_url:str):
try:
pages = WebBaseLoader(source_url, verify_ssl=False).load()
try:
file_name = pages[0].metadata['title']
file_name = pages[0].metadata['title'].strip()
if not file_name:
file_name = last_url_segment(source_url)
except:
Expand Down
2 changes: 1 addition & 1 deletion backend/src/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ def create_source_node_graph_web_url(graph, model, source_url, source_type):
message = f"Unable to read data for given url : {source_url}"
raise LLMGraphBuilderException(message)
try:
title = pages[0].metadata['title']
title = pages[0].metadata['title'].strip()
if not title:
title = last_url_segment(source_url)
language = pages[0].metadata['language']
Expand Down
3 changes: 2 additions & 1 deletion backend/src/post_processing.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
import time
from langchain_neo4j import Neo4jGraph
import os
from src.graph_query import get_graphDB_driver
from src.shared.common_fn import load_embedding_model
from langchain_core.output_parsers import JsonOutputParser
from langchain_core.prompts import ChatPromptTemplate
Expand Down Expand Up @@ -137,7 +138,7 @@ def create_vector_fulltext_indexes(uri, username, password, database):
logging.info("Starting the process of creating full-text indexes.")

try:
driver = GraphDatabase.driver(uri, auth=(username, password), database=database)
driver = get_graphDB_driver(uri, username, password,database)
driver.verify_connectivity()
logging.info("Database connectivity verified.")
except Exception as e:
Expand Down