Fix: removes ontology resolver initialization at import (#876)

<!-- .github/pull_request_template.md -->

## Description
Removes ontology resolver initialization at import.

## DCO Affirmation
I affirm that all code in every commit of this pull request conforms to
the terms of the Topoteretes Developer Certificate of Origin.
This commit is contained in:
hajdul88 2025-05-27 15:23:42 +02:00 committed by GitHub
parent 965033e161
commit ec68e99438
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -15,12 +15,15 @@ from cognee.modules.ontology.rdf_xml.OntologyResolver import OntologyResolver
def expand_with_nodes_and_edges(
data_chunks: list[DocumentChunk],
chunk_graphs: list[KnowledgeGraph],
ontology_resolver: OntologyResolver = OntologyResolver(),
ontology_resolver: OntologyResolver = None,
existing_edges_map: Optional[dict[str, bool]] = None,
):
if existing_edges_map is None:
existing_edges_map = {}
if ontology_resolver is None:
ontology_resolver = OntologyResolver()
added_nodes_map = {}
added_ontology_nodes_map = {}
relationships = []