feat: add cloudflare workers ai integration for lightrag
This commit is contained in:
parent
1aeac40c30
commit
6ef08e2302
1 changed files with 3 additions and 1 deletions
|
|
@ -267,7 +267,9 @@ async def main():
|
||||||
print(f"Test dict: {test_text}")
|
print(f"Test dict: {test_text}")
|
||||||
print(f"Detected embedding dimension: {embedding_dim}\n\n")
|
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())
|
await rag.ainsert(f.read())
|
||||||
|
|
||||||
# Perform naive search
|
# Perform naive search
|
||||||
Loading…
Add table
Reference in a new issue