cancel
Showing results for 
Search instead for 
Did you mean: 

Head's Up! These forums are read-only. All users and content have migrated. Please join us at community.neo4j.com.

Couldnt use Cosine similarity Algorithm in my Neo4j Desktop

Getting unknown function 'algo.similarity.cosine' while trying to use RETURN algo.similarity.cosine([3,8,7,5,2,9], [10,8,6,6,4,5]) AS similarity in community edition Neo4J Desktop

Reference:https://neo4j.com/docs/graph-algorithms/current/algorithms/similarity-cosine/

I have installed graph algorithm install for the whole project .

I have this dbms.security.procedures.unrestricted=apoc.,algo. enabled in my config.

When i execute CALL algo.list() , i'm not seeing 'algo.similarity.cosine' procedure/function listed .but could see lot of other algo.* functions and procs

Am i missing anything ? Help is much appreciated .

1 ACCEPTED SOLUTION

3.4.8 was just released, Desktop needs to be modified to allow installation of the libraries. Also, if any code changes are needed to work with the latest version that may require an additional release to the algo library, but that's not always the case.

View solution in original post

4 REPLIES 4

You may be using an older version of the algo library.

Cosine and other similarity functions and procedures were only added with the latest 3.4.7.0 release. I believe this is only compatible with the 3.4.x versions of Neo4j.

You may need to stop your db, uninstall the plugin, and install again (you should see the version change upon uninstalling the older version).

Thanks Andrew for quick response , I tried installing the plugins with latest version of Neo4j db installed , getting plugin not supported error . Am i still missing something .!

image|690x260

Thanks in advance for your help with this.

It works when i use 3.4.7 exactly ... earlier it didnt work for latest version (3.4.8) ...

Thanks for you help Andrew.

3.4.8 was just released, Desktop needs to be modified to allow installation of the libraries. Also, if any code changes are needed to work with the latest version that may require an additional release to the algo library, but that's not always the case.