Skip to content

Commit

Permalink
add oracle support
Browse files Browse the repository at this point in the history
  • Loading branch information
jin38324 committed Nov 12, 2024
1 parent 273600d commit 45156ef
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 10 deletions.
11 changes: 8 additions & 3 deletions examples/lightrag_api_oracle_demo..py
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,7 @@
from typing import Optional

import sys, os
print(os.getcwd())
from pathlib import Path
script_directory = Path(__file__).resolve().parent.parent
sys.path.append(os.path.abspath(script_directory))

import asyncio
import nest_asyncio
Expand All @@ -21,6 +18,14 @@
from lightrag.kg.oracle_impl import OracleDB


print(os.getcwd())

script_directory = Path(__file__).resolve().parent.parent
sys.path.append(os.path.abspath(script_directory))




# Apply nest_asyncio to solve event loop issues
nest_asyncio.apply()

Expand Down
10 changes: 3 additions & 7 deletions examples/lightrag_oracle_demo.py
Original file line number Diff line number Diff line change
@@ -1,20 +1,16 @@


import sys, os
print(os.getcwd())
from pathlib import Path
script_directory = Path(__file__).resolve().parent.parent
sys.path.append(os.path.abspath(script_directory))

import asyncio
from lightrag import LightRAG, QueryParam
from lightrag.llm import openai_complete_if_cache, openai_embedding
from lightrag.utils import EmbeddingFunc
import numpy as np
from datetime import datetime

from lightrag.kg.oracle_impl import OracleDB

print(os.getcwd())
script_directory = Path(__file__).resolve().parent.parent
sys.path.append(os.path.abspath(script_directory))

WORKING_DIR = "./dickens"

Expand Down

0 comments on commit 45156ef

Please sign in to comment.