Update app.py
Browse files
app.py
CHANGED
@@ -6,9 +6,9 @@ import torch
|
|
6 |
with open("knowledge.txt", "r", encoding="utf-8") as file:
|
7 |
knowledge = file.read()
|
8 |
|
9 |
-
print(
|
10 |
|
11 |
-
cleaned_chunks = [chunk.strip() for chunk in
|
12 |
print(cleaned_chunks)
|
13 |
|
14 |
model = SentenceTransformer('all-MiniLM-L6-v2')
|
|
|
6 |
with open("knowledge.txt", "r", encoding="utf-8") as file:
|
7 |
knowledge = file.read()
|
8 |
|
9 |
+
print(knowledge)
|
10 |
|
11 |
+
cleaned_chunks = [chunk.strip() for chunk in knowledge.strip().split("\n") if chunk.strip()]
|
12 |
print(cleaned_chunks)
|
13 |
|
14 |
model = SentenceTransformer('all-MiniLM-L6-v2')
|