Update rag_chain.py
Browse files- rag_chain.py +1 -1
rag_chain.py
CHANGED
@@ -133,7 +133,7 @@ def query_preprocessor(query: str) -> str:
|
|
133 |
|
134 |
# === Load and process PDF ===
|
135 |
def build_rag_chain(pdf_path: str, rebuild_index=False):
|
136 |
-
embeddings = SentenceTransformerEmbeddings(model_name="
|
137 |
final_chunks = [] # ✅ ensure it's always defined
|
138 |
|
139 |
if not rebuild_index and os.path.exists("/tmp/faiss_index"):
|
|
|
133 |
|
134 |
# === Load and process PDF ===
|
135 |
def build_rag_chain(pdf_path: str, rebuild_index=False):
|
136 |
+
embeddings = SentenceTransformerEmbeddings(model_name="intfloat/e5-small-v2")
|
137 |
final_chunks = [] # ✅ ensure it's always defined
|
138 |
|
139 |
if not rebuild_index and os.path.exists("/tmp/faiss_index"):
|