[Esip-schema-dot-org] namespace, issue #52

Dave Vieglais dave.vieglais at gmail.com
Thu May 28 13:57:55 EDT 2020


Hi All,
unfortunately I will not be able to make the upcoming science-on-schema.org call. I expect issue #52 will come up and wanted to put down a couple of key bullet points for consideration:

1. The correct namespace for schema.org appears to be `http://schema.org/`. Despite the `https` variant appearing in various places (mostly instance documents in the wild), the schema.org sources are consistent. Resolving the URLs `https://schema.org/` and `http://schema.org/` and content relative to those seem to return equivalent content in all cases, and the namespace in returned documents is consistently "http://schema.org/". e.g. [1, 2]

2. I have been unable to find a mechanism with json-ld contexts or framing to reliably enable programmatic equivalence of terms in the `https://schema.org/` and `http://schema.org/` namespaces. There was a bug in version 1.0 of the json-ld spec that may have provided a mechanism, however that issue allowed circular reference within a context definition, producing indeterminate results. [3]. It may be possible to do something like apply an imported context [4] to recast terms to a different namespace, though if it works then the context would need to be generally imported to all, and so would be challenging with respect to bullet 4 below.

3. Equivalence could be asserted through an ontology that mapped all terms between the two namespaces. This would likely have significant performance impacts. It would also require ongoing maintenance of the map.

4. Namespaces can be converted programmatically on loading the documents, and this works for limited cases. However, libraries and other third party software can, and often will load content from other sources. Those sources loaded by the third party may not have the namespace changed on load, leading to unexpected results. e.g. a json-ld processor may load an external context that in turn could import additional context [5]. This can easily create a mixed use of namespaces and lead to inconsistent results.

Although it is a little painful to change the namespace use by science-on-schema.org from "https://schema.org/" to "http://schema.org/", my impression is that making this change sooner will save confusion and incompatibility issues in the future.


[1] https://schema.org/version/latest/schema.ttl

[2] https://schema.org/docs/jsonldcontext.jsonld

[3] https://w3c.github.io/json-ld-syntax/#iri-expansion-within-a-context

[4] https://w3c.github.io/json-ld-syntax/#imported-contexts

[5] https://www.w3.org/TR/json-ld-api/#algorithm


- Dave




More information about the Esip-schema-dot-org mailing list