Replies: 6 comments
-
@yashdeepyds you need to have some existing knowledge graph to connect to. Can you share more details? |
Beta Was this translation helpful? Give feedback.
-
Could you plz share your code? In case it’s kgquery engine no index should be required indeed. |
Beta Was this translation helpful? Give feedback.
-
Before doing this i have created a knowledge graph. from llama_index.query_engine import RetrieverQueryEngine space_name = "abc" graph_store = NebulaGraphStore( graph_rag_retriever_with_nl2graphquery = KnowledgeGraphRAGRetriever( query_engine_with_nl2graphquery = RetrieverQueryEngine.from_args( response = query_engine_with_nl2graphquery.query( |
Beta Was this translation helpful? Give feedback.
-
Hi @wey-gu |
Beta Was this translation helpful? Give feedback.
-
🤖 Hello @wey-gu, Yes, the The To properly create or load an index in the LlamaIndex framework, you can follow these steps:
index = BaseIndex.from_documents(
documents=your_documents,
storage_context=your_storage_context,
service_context=your_service_context,
)
your_storage_context.persist(your_directory)
new_storage_context = StorageContext.from_defaults(persist_dir=your_directory)
new_index = load_index_from_storage(
storage_context=new_storage_context,
service_context=your_service_context
)
new_nodes = new_index.as_retriever().retrieve(your_query) Please replace I hope this helps! If you have any other questions, feel free to ask. Best, Sources
This response is meant to be useful and save you time. It is not meant to be a precise solution, but rather a starting point for your own research. Help me be more useful! Please leave a 👍 if this is helpful and 👎 if it is irrelevant. If you want to continue the conversation, start your reply with @dosu-bot. |
Beta Was this translation helpful? Give feedback.
-
🤖 Hello @wey-gu, Yes, the The To properly create or load an index in the LlamaIndex framework, you can follow these steps:
index = BaseIndex.from_documents(
documents=your_documents,
storage_context=your_storage_context,
service_context=your_service_context,
)
your_storage_context.persist(your_directory)
new_storage_context = StorageContext.from_defaults(persist_dir=your_directory)
new_index = load_index_from_storage(
storage_context=new_storage_context,
service_context=your_service_context
)
new_nodes = new_index.as_retriever().retrieve(your_query) Please replace I hope this helps! If you have any other questions, feel free to ask. Best, Sources
This response is meant to be useful and save you time. It is not meant to be a precise solution, but rather a starting point for your own research. Help me be more useful! Please leave a 👍 if this is helpful and 👎 if it is irrelevant. If you want to continue the conversation, start your reply with @dosu-bot. |
Beta Was this translation helpful? Give feedback.
-
Question Validation
Question
@wey-gu
While using the nl2graphquery i am getting this error. For the context i havent index anything but this nl2graphquery suppose to give the answer from the knowledge graph itself or do I need to index some document for reference. Please help to find the solution
Param: {}Error message: Error found in optimization stage: IndexNotFound: No valid index found
Thanks.
Beta Was this translation helpful? Give feedback.
All reactions