Fixing db.index.vector.queryNodes Deprecation in Neo4j

Resumo

This Neo4j community announcement addresses the deprecation of the db.index.vector.queryNodes procedure in favor of the new SEARCH clause. It explains how to resolve related warnings in GraphRAG workshops by updating dependencies and migrating legacy code. This update is essential for developers ensuring their GenAI projects remain compatible with the latest Neo4j standards and best practices.

hazelshadow-34 OP

Running into these warnings every time I run GraphRAG retrieval on the workshop-genai repo:
Received notification from DBMS server: <GqlStatusObject gql_status='01N01', status_description='warn: feature deprecated with replacement. db.index.vector.queryNodes is deprecated. It is replaced by SEARCH.'...

Any suggestions on what's going on?

hazelshadow-34 OP

Bumping for visibility

brightfrost-77

Apologies for the delay!

The warning is stating that db.index.vector.queryNodes is no longer the primary way to do a vector index search, as it has been replaced with the SEARCH clause.

Deprecated features remain supported for a while to allow users to migrate their code to the new feature.

You can read more about the SEARCH clause here

When and where did you find a guide/documentation that suggested that you use db.index.vector.queryNodes? I am asking so that we can see if there is some official source that has not yet been updated!

@brightfrost-77 Apologies for the delay! The warning is stating that `db.index.vector.queryNodes` is no longer the…
hazelshadow-34 OP

I'm only following along with the GenAI course (workshop-genai repo). This just seems to be broadcast by the DBMS everytime I run a query.

brightfrost-77

Alright, it looks like that workshop has not been updated since the introduction of the SEARCH clause and subsequent deprecation of db.index.vector.queryNodes. I'll reach out to the folks who manage the workshop repos and see if it can be updated

brightfrost-77

I now see the issue, the requirements.txt has not been updated in that repo to use a newer version of the Neo4j Python GraphRAG package, it's still using 1.14.0, when the new SEARCH clause was supported in 1.16.0.

Could you try updating the installed version of the neo4j-graphrag package, (installed by line 25 in the requirements.txt file in the repo that reads neo4j-graphrag == 1.14.0) and tell me if it still works and the warnings dissapear

hazelshadow-34 OP

That was one of the first things I tried, yeah

As últimas novidades de Neo4j