From 6ef08e230234a775fb7a72d9a34c4eb9cb7058df Mon Sep 17 00:00:00 2001 From: al1k <58782397+al1kss@users.noreply.github.com> Date: Thu, 10 Jul 2025 12:58:35 +0600 Subject: [PATCH] feat: add cloudflare workers ai integration for lightrag --- ...lighrag_cloudflare_demo.py => lightrag_cloudflare_demo.py} | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) rename examples/unofficial-sample/{lighrag_cloudflare_demo.py => lightrag_cloudflare_demo.py} (98%) diff --git a/examples/unofficial-sample/lighrag_cloudflare_demo.py b/examples/unofficial-sample/lightrag_cloudflare_demo.py similarity index 98% rename from examples/unofficial-sample/lighrag_cloudflare_demo.py rename to examples/unofficial-sample/lightrag_cloudflare_demo.py index bb00406a..0d57806c 100644 --- a/examples/unofficial-sample/lighrag_cloudflare_demo.py +++ b/examples/unofficial-sample/lightrag_cloudflare_demo.py @@ -267,7 +267,9 @@ async def main(): print(f"Test dict: {test_text}") print(f"Detected embedding dimension: {embedding_dim}\n\n") - with open("./book.txt", "r", encoding="utf-8") as f: + # Locate the location of what is needed to be added to the knowledge + # Can add several simultaneously by modifying code + with open("./book.txt", "r", encoding="utf-8") as f: await rag.ainsert(f.read()) # Perform naive search