al1k
commited on
feat: add cloudflare workers ai integration for lightrag
Browse files
examples/unofficial-sample/{lighrag_cloudflare_demo.py → lightrag_cloudflare_demo.py}
RENAMED
@@ -267,7 +267,9 @@ async def main():
|
|
267 |
print(f"Test dict: {test_text}")
|
268 |
print(f"Detected embedding dimension: {embedding_dim}\n\n")
|
269 |
|
270 |
-
|
|
|
|
|
271 |
await rag.ainsert(f.read())
|
272 |
|
273 |
# Perform naive search
|
|
|
267 |
print(f"Test dict: {test_text}")
|
268 |
print(f"Detected embedding dimension: {embedding_dim}\n\n")
|
269 |
|
270 |
+
# Locate the location of what is needed to be added to the knowledge
|
271 |
+
# Can add several simultaneously by modifying code
|
272 |
+
with open("./book.txt", "r", encoding="utf-8") as f:
|
273 |
await rag.ainsert(f.read())
|
274 |
|
275 |
# Perform naive search
|