Re: Notation3 Community Group Report Release

Hi Ivan,

Thanks for pointing that out. Note that there is an OWL2 RL implementation in N3, both a “regular” one [1] and an “optimized” [2] one, i.e., which instantiates the rules given a TBox. You can find an N3 implementation here: https://eulersharp.sourceforge.net/2003/03swap/eye-owl2.html 

It is true that prp-spo2 is tough to implement, as it pertains to a restriction on all list elements; eq-diff3 is easier as it defines a restriction on only 2 list members [3]. Some solutions for the likes of prp-spo2 include pre-processing, by instantiating prp-spo2 based on the TBox, or binarizing the input ontology; or modifying the ruleset, by adding auxiliary rules [3].

You are right that we should add more languages (OWL2, SWRL, ..) to our comparison section in the report.


William

[1] https://link.springer.com/chapter/10.1007/978-3-319-21542-6_31 
[2] https://link.springer.com/chapter/10.1007/978-3-319-33245-1_10 
[3] https://semantic-web-journal.net/system/files/swj1666.pdf (Section 4.2.3)

> On Jul 6, 2023, at 11:23 AM, Ivan Herman <ivan@w3.org> wrote:
> 
> William, (and Christopher)
> 
> just to add one thing to the comparison. 
> 
> Where N3 and OWL 2 "meet" in some ways is the RL profile of OWL 2[1]. This is a "subset" of OWL 2 that can be implemented using rules. Actually, the spec includes the list of rules[2] that can be implemented, e.g., by a forward chaining engine, to offer an OWL 2 reasoner. I think it would be worthwhile to add a comparison of N3 with OWL 2 RL in the document, b.t.w.
> 
> Cheers
> 
> Ivan
> 
> (At a first glance, the translation most of the rules in [2] into N3 looks trivial, ie, it is possible to create an N3 "graph" that can be used as a set of OWL 2 RL axioms. There are some rules where, I must admit, I do not see at first glance how to make this translation in general, like eq-diff3, prp-spo2; these all are not "rules" in [2] but more a family or rules for lists.)
> 
> [1] https://www.w3.org/TR/owl2-profiles/#OWL_2_RL
> [2] https://www.w3.org/TR/owl2-profiles/#Reasoning_in_OWL_2_RL_and_RDF_Graphs_using_Rules
> 
>> On 6 Jul 2023, at 16:11, William Van Woensel <william.vanwoensel@gmail.com> wrote:
>> 
>> Thanks for your question. (The report does have a section on relations with other languages, but it does not include OWL2!) 
>> 
>> Both are declarative formalisms for describing your domain or problem - you can then let a reasoner fill in the blanks or try and solve the problem. But, they differ in the kind of logic and reasoning they apply. Their usefulness depends on your use case, and, to some extent, your personal preferences. 
>> 
>> TL;DR 
>> OWL2 is related to Description Logics - you define class expressions in terms of constraints on their individuals, and then use a reasoner (such as hermit, pellet,...) to find inconsistencies, classify individuals (put them under the right class), or determine subsumption (subclass relations). Notation3 (N3) is a rule language - you can define logical implications, basically if-then rules, which state what can be inferred from other triples. A reasoner (such as eye, cwm or jen3) can then generate all applicable inferences given a set of triples. In addition, N3 has builtins for math, string, time and other operations, as well as builtins for scoped negation as failure (to "close" the world to an extent).
>> 
>> Longer answer: The question is complex and has multiple aspects. Since you asked from a developer point of view I try to emphasise that aspect.
>> 
>> OWL2 DL is based on description logics, which is a decidable fragment of first order logic. Decidability is a big advantage, but it also comes with certain restrictions on the things you can and can’t express. Intuitively, you rather think about classes and subclasses in which you can or cannot put individuals. OWL2 allows disjunctions (“or”) which are only partly supported by rule-based reasoning. If you want to add rules to that “class world", you can use SWRL.
>> 
>> N3 is a rule language for the Web. That means you can directly state which triples should be derived by which other triples. As N3 allows you to write rules introducing new blank nodes, we know that N3 - even without any built-ins or exotic patterns - is not decidable, because logically, we are dealing with existential rules. This, however, is in most practical cases a rather theoretical problem. 
>> 
>> That said, both OWL and N3 reasoners will sometimes need to capitulate and report a time-out for some corner cases.
>> 
>> Hope that clarifies matters.
>> 
>> 
>> William & Doerthe
>> 
>>> On Jul 5, 2023, at 3:00 PM, Christopher Yocum <cyocum@gmail.com> wrote:
>>> 
>>> Hi,
>>> 
>>> This seemed interesting so I went to have a look at it.  After reading
>>> a good part of the primer, I am wondering what the difference between
>>> N3 and OWL2 are and why I would choose one over the other or if they
>>> are complementary, how they relate to each other?  Is there a resource
>>> that covers this for the "middle of the road" developer? I did a quick
>>> Google but I am not coming up with anything that might help
>>> immediately.
>>> 
>>> Thanks and all the best,
>>> Chris
>>> 
>>> On Wed, Jul 5, 2023 at 6:12 AM Ivan Herman <ivan@w3.org> wrote:
>>>> 
>>>> Putting my W3C staff member's hat on… As Doerthe says below, N3 is not just a minor extension to RDF 1.2, so adding it now to the RDF Star WG's work would go beyond the charter of that WG. I believe it would be more appropriate for the N3 Community Group to prepare itself to propose a bona fide Working Group charter that would be scheduled to kick in once RDF 1.2 is properly closed. It will then have to go through the usual hooplas at W3C to get the charter (hopefully) accepted by the W3C membership and do the rest of the work to turn it into a formal Recommendation.
>>>> 
>>>> Hans, this is not a dumb suggestion at all.
>>>> 
>>>> Cheers
>>>> 
>>>> Ivan
>>>> 
>>>> On 4 Jul 2023, at 14:04, Doerthe Arndt <doerthe.arndt@tu-dresden.de> wrote:
>>>> 
>>>> Dear Hans,
>>>> 
>>>> It is a very good idea to combine efforts on N3 and RDF 1.2, but I am afraid that N3 is too complex to be added directly to RDF 1.2. More concrete: N3 allows the use of graphs as terms just like RDF-star supports triples as terms. The latter already causes a lot of discussions since different potential users (naturally) have different expectations. I guess a more complex construct of similar nature will even create more tension.
>>>> 
>>>> Therefore, the N3 working group plans to wait for the outcome of RDF 1.2 to then incorporate the (possible) changes of RDF to N3. Note that some reasoners like for example EYE (https://github.com/eyereasoner/eye) already support RDF-star. So far, I do not see major problems if we want to include RDF-star to N3 (of course that will also depend on the semantics chosen, EYE currently follows the community group report).
>>>> 
>>>> Kind regards,
>>>> Dörthe
>>>> 
>>>> 
>>>> 
>>>> Am 04.07.2023 um 10:16 schrieb hans.teijgeler@quicknet.nl:
>>>> 
>>>> Is it a dumb suggestion to combine this N3 effort with the earlier reported RDF 1.2 one, in order to avoid divergence?
>>>> 
>>>> -----Original Message-----
>>>> From: David Booth <david@dbooth.org>
>>>> Sent: Monday, 3 July 2023 21:11
>>>> To: semantic-web@w3.org
>>>> Subject: Re: Notation3 Community Group Report Release
>>>> 
>>>> On 7/3/23 13:29, William Van Woensel wrote:
>>>> 
>>>> We are happy to inform you that the first Notation3 Community Group
>>>> Report has been released: https://w3c.github.io/N3/spec/
>>>> <https://w3c.github.io/N3/spec/>
>>>> 
>>>> 
>>>> Awesome!   Great work!
>>>> 
>>>> Thanks,
>>>> David Booth
>>>> 
>>>> 
>>>> 
>>>> Notation3 (also known as N3) is an assertion and logic language that
>>>> is a superset of Turtle, featuring logical implications (rules), graph
>>>> terms, and builtins ranging from datatype operations to accessing
>>>> online knowledge and performing scoped negation as failure.
>>>> 
>>>> We also created an educational resource as a lightweight introduction
>>>> to
>>>> Notation3 (which also lists currently available resources):
>>>> https://notation3.org/ <https://notation3.org/>
>>>> 
>>>> We invite you to submit any feedback or issues to our GitHub page:
>>>> https://github.com/w3c/N3 <https://github.com/w3c/N3>
>>>> 
>>>> 
>>>> Kind regards,
>>>> 
>>>> W3C N3 CG Group
>>>> 
>>>> 
>>>> 
>>>> 
>>>> 
>>>> 
>>>> 
>>>> ----
>>>> Ivan Herman, W3C
>>>> Home: http://www.w3.org/People/Ivan/
>>>> mobile: +33 6 52 46 00 43
>>>> 
>>>> 
>>> 
>> 
> 
> 
> ----
> Ivan Herman, W3C 
> Home: http://www.w3.org/People/Ivan/
> mobile: +33 6 52 46 00 43
> 
> 

Received on Friday, 7 July 2023 12:22:54 UTC