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.

Neosemantics with Neo4j V4

Hi,

Following some investigation into upgrading from V3 to V4, am I correct in my conclusion that there is not yet a version of Neosemantics that can run in a V4 database?

And if so, are there any timescales for an update?

Many thanks,
Simon

ps This is the kind of error I am seeing using the latest jar file.

CALL semantics.importRDF(...)

Failed to invoke procedure semantics.importRDF: Caused by: java.lang.NoSuchMethodError: 'org.neo4j.graphdb.schema.Schema org.neo4j.graphdb.GraphDatabaseService.schema()'

21 REPLIES 21

Hi Simon, you're right. Unfortunately we are a bit behind schedule on neosemantics for v4.
We are introducing some breaking changes and want to make sure they're all in the first v4 release.
My expectation is that it'll be out in the next 2-3 weeks (around 15 Feb).

Thanks,

JB.

Hi JB,

Many thanks for your swift response. I shall look out for the new version.

Regards,
Simon

Hi Simon and Jesus,

Thanks for starting this thread. I too am interested in using the new version of neosemantics which will work with v4 Neo4j. Do you think Feb. 15 is still the estimated release date?

Very excited to get to use it!

Thanks,
Hayden

Me too i am intereseted in a V4 Version of neosemantics

Well, as you can see the initial objective of the 15th Feb was not met 😞 but we're working hard to get the 4.0 release out asap. The good news is we're very close.
I'm hoping that the changes introduced will significantly simplify the use of neosemantics and also make it more consistent. Watch this space...

PS: We're also preparing a training at GraphConnect NYC on using RDF with Neo4j. Check it out here.

Hi Jesus,

Thanks for your recent update. Any idea how far off you are now?

Many thanks,
Simon Wren

Hi, I've just pushed a beta for 4.0. Please try and give feedback.
Sorry for the delay

Hello Jesus,

thanks for the new version. Got the origin errormessage while testing your example: https://jbarrasa.com/2019/12/05/quickgraph10-enrich-your-neo4j-knowledge-graph-by-querying-wikidata/
With the new versions of neosemantics it works right now. But there are some changes which needs some adjustments in the example (renaming of procedures, handling namespaces, creating index).

Regards

Tino

Hi Tino, thanks for the feedback. Great to hear it works for you.

You're right, as I mention in the release notes the whole naming scheme has changed so
the original script in the blog post on importing from Wikidata that you mention

CALL semantics.importRDF("https://query.wikidata.org/sparql?query=" + apoc.text.urlencode($sparql),
        "JSON-LD", 
        { headerParams: { Accept: "application/ld+json"} , handleVocabUris: "IGNORE"})

in the new 4.0 version, becomes something like this:

call n10s.graphconfig.init({ handleVocabUris: "IGNORE" });

call n10s.rdf.import.fetch("https://query.wikidata.org/sparql?query=" + apoc.text.urlencode($sparql),
        "JSON-LD", 
        { headerParams: { Accept: "application/ld+json"} });

This is minimally described in the README (We're currently working on updating the manual ).

Thanks for the heads up on the blog post! Unless you have a better suggestion I think I'll edit it and add a note/warning saying that the code was written for 3.5 and that 4.0 has changed significantly and point to the README for now and to the 4.0 manual as soon as it's available.

Cheers,

JB.

Hello Jesus,

thanks for your reply. I used exactly your linked README because it is linked in the release notes. I like your suggestion to add a note to the article/tutorial. This could save some time to get it working.
I have one addition. I also called the following statement to be able to use the RDF-Import:

CREATE CONSTRAINT n10s_unique_uri ON (r:Resource) ASSERT r.uri IS UNIQUE

Regards

Tino

What is the correct serilization format for OWL files?

CALL n10s.onto.import.fetch("file:///Users/satishviswanatham/src/knowledgebase/ontology/owl/sgo_40.owl", "Turtle")

Turtle does not work:

"KO" 0 0 null "IRI included an unencoded space: '32' [line 1]"
{

}

Here are fist few lines looks like in the owl file

<?xml version="1.0"?>

<rdf:RDF xmlns="http://www.semanticweb.org/ericarutherford/ontologies/2017/2/SecondGenomeDraftCompleteOntology.owl#"
xml:base="http://www.semanticweb.org/ericarutherford/ontologies/2017/2/SecondGenomeDraftCompleteOntology.owl"
xmlns:skos2="http://www.semanticweb.org/ericarutherford/ontologies/2017/2/SecondGenomeDraftCompleteOntology.owl#s..."
xmlns:SecondGenomeDraftCompleteOntology="http://www.semanticweb.org/ericarutherford/ontologies/2017/2/SecondGenomeDraftCompleteOntology.owl#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:owl="http://www.w3.org/2002/07/owl#"
xmlns:xsd="http://www.w3.org/2001/XMLSchema#"
xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#">
<owl:Ontology rdf:about="http://www.semanticweb.org/ericarutherford/ontologies/2017/2/SecondGenomeDraftCompleteOntology.owl"/>

<!--
///////////////////////////////////////////////////////////////////////////////////////
//
// Annotation properties
//
///////////////////////////////////////////////////////////////////////////////////////
 -->




<!-- http://www.semanticweb.org/ericarutherford/ontologies/2017/2/SecondGenomeDraftCompleteOntology.owl#definition -->

appereciate your help

Hi @satish, This is "RDF/XML".
Let us know how it goes.

Cheers,

JB.

thanks for your help here. it looks better now.

how can i debug that not all 4951 triples are not loaded. 3424 of them got loaded, not sure about the rest.

It's explained in the manual. Have a look at the section on importing ontologies.

I copy here the relevant excerpt:

this procedure exclusively import the following:

  1. Named class (category) declarations with both rdfs:Class and owl:Class .
  2. Explicit class hierarchies defined with rdf:subClassOf statements.
  3. Property definitions with owl:ObjectProperty , owl:DatatypeProperty and rdfs:Property
  4. Explicit property hierarchies defined with rdfs:subPropertyOf statements.
  5. Domain and range information for properties described as rdfs:domain and rdfs:range statements.

Does Neosemantics work in the free Neo4j Desktop version or do you need the enterprise version? Really like to see our RDF in it before committing. I can't see the various paths and config files referenced on GitHub for neosemantics anywhere on my PC - or perhaps I'm just missing where they are. Any help appreciated.

Hi David, neosemantics works both on community and enterprise editions.

I'd recommend you watch this video (from 8:20) for a step by step installation from scratch of both the plugin and the GraphApp.

Hope this helps.

JB.

My screen doesn't show the open icon against the gallery. Fresh download today.

Any pointers on how to get the Graphs App Gallery to show? Really keen to get my RDF data in there!

You can try CMD+K /Ctrl+K to open up the shortcut bar and type Graph App Gallery or go to https://install.graphapp.io. The install link should still work there.

If for any reason it doesn't, you can copy the following link into the install form at the bottom of the Graph Apps pane:
https://registry.npmjs.org/@graphapps/neosemantics

Got it, thanks. Had to paste in the URL - could get to see the Gallery but install button just flicked the screen.

All data's come in beautifully, thanks