Open jjccooooll12 opened 1 day ago
Hi @jjccooooll12 thanks for trying out Kùzu! We are not planning on maintaining the KnowledgeGraphIndex
going forward as this has largely been deprecated and replaced by the PropertyGraphIndex
API in LlamaIndex. Even the core LlamaIndex library maintainers won't be maintaining KnowledgeGraphIndex
as its functionality is superceded by the much more capable PropertyGraphIndex
. The only reason they still keep the documentation for this on their website is for legacy reasons and they encourage folks to not use it any more.
I'd recommend taking a look at this example notebook in our docs: https://colab.research.google.com/drive/1brAdNRNLG2XHD7Jv3ZwSQCOCJ_wmfd1B
You would then import PropertyGraphIndex
from llama_index.core
and upsert triplets via your desired schema using the .from_documents(...) method of the
PropertyGraphIndex` class instead.
from llama_index.core import PropertyGraphIndex
from llama_index.core.indices.property_graph import SchemaLLMPathExtractor
index = PropertyGraphIndex.from_documents(
documents,
embed_model=embed_model,
kg_extractors=[SchemaLLMPathExtractor(extract_llm)],
property_graph_store=graph_store,
show_progress=True,
)
Hope this works!
Kùzu version
v.0.6.1
What operating system are you using?
Windows 10
What happened?
Piece of code, from tutorial https://docs.llamaindex.ai/en/stable/examples/index_structs/knowledge_graph/KuzuGraphDemo/:
produces error:
AttributeError: 'KuzuPropertyGraphStore' object has no attribute 'upsert_triplet'
Full error track:
Instead, it should populate automatically the Kuzu graph db.
Are there known steps to reproduce?
No response