Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -10,8 +10,11 @@ from langchain.vectorstores import FAISS
|
|
10 |
|
11 |
# === 1. Build the FAISS vectorstore from CUAD ===
|
12 |
print(" Loading CUAD and building index...")
|
|
|
|
|
|
|
|
|
13 |
|
14 |
-
cuad_data = load_dataset("cuad")
|
15 |
texts = [item["text"] for item in cuad_data["train"] if "text" in item]
|
16 |
|
17 |
splitter = RecursiveCharacterTextSplitter(chunk_size=500, chunk_overlap=50)
|
|
|
10 |
|
11 |
# === 1. Build the FAISS vectorstore from CUAD ===
|
12 |
print(" Loading CUAD and building index...")
|
13 |
+
#new
|
14 |
+
from datasets import load_dataset
|
15 |
+
|
16 |
+
cuad_data = load_dataset("lex_glue", "cuad")
|
17 |
|
|
|
18 |
texts = [item["text"] for item in cuad_data["train"] if "text" in item]
|
19 |
|
20 |
splitter = RecursiveCharacterTextSplitter(chunk_size=500, chunk_overlap=50)
|