datacequia / go-dogg3rz

Decentralized Knowledge Orchestration Tool
Apache License 2.0
8 stars 1 forks source link

How to resolve a resource within a nested named graph #33

Open adpadilla opened 3 years ago

adpadilla commented 3 years ago

From what I have gathered, it is conformant to create any number of named graphs within other named graphs in JSON-LD ( or TRiG notation). However, it's unclear how you might construct an IRI to reference a resource within nested named graphs. If I take the following resource ( @id="class1"), How would I construct an IRI to resolve it? My guess is that it could be any of the following (assume domain is 'example.org')

http://example.org/mygraph2#class1

OR

http://example.org/mygraph1/mygraph2#class1

or something else?


{
   "@context" : {
      "rdfs" : "http://www.w3.org/2000/01/rdf-schema#",

   }
   "@graph" : [
      {
         "@graph" : [
                    {
                   "@id" : "mygraph2",
                     "@graph" : [
                           {
                               "@id":"class1"
                               "@type":"rdfs:Class"
                           }
                     ]
                  }

         ],
         "@id" : "mygraph"
      },
   ],