File tree Expand file tree Collapse file tree 1 file changed +5
-2
lines changed
backend/app/rag/indices/knowledge_graph/graph_store Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -1082,6 +1082,7 @@ def get_chunks_by_relationships(
10821082 }
10831083
10841084 if chunk_ids :
1085+ logger .info (f"Getting chunks for relationships: { chunk_ids } " )
10851086 # Query chunks
10861087 chunks = session .exec (
10871088 select (self ._chunk_model ).where (self ._chunk_model .id .in_ (chunk_ids ))
@@ -1104,11 +1105,13 @@ def get_chunks_by_relationships(
11041105 ]
11051106
11061107 document_ids = {
1107- rel .meta . get ( " document_id" )
1108+ rel .document_id
11081109 for rel in relationships
1109- if rel .meta . get ( " document_id" ) is not None
1110+ if rel .document_id is not None
11101111 }
11111112
1113+ logger .info (f"Getting documents for relationships: { document_ids } " )
1114+
11121115 documents = session .exec (
11131116 select (Document ).where (Document .id .in_ (document_ids ))
11141117 ).all ()
You can’t perform that action at this time.
0 commit comments