Search Mailing List Archives


Limit search to: Subject & Body Subject Author
Sort by: Reverse Sort
Limit to: All This Week Last Week This Month Last Month
Select Date Range     through    

[protege-owl] Create Rules in Eclipse using Protege 3.4.4

aros aros at fotonik.dtu.dk
Sun Jul 18 23:05:53 PDT 2010


Is there any way to design rules that can modify the already existing content on my ontology through my java application?

I am modeling a home scenario where I have an ontology with all the appliances. An example of a rule that I want to build in is:

If (light_sensor detects >80% light) then turn off lamp

In my ontology this would mean:
light_sensor(?s) ^ hasState(?s,?state) ^swrlb:greaterThan(?state, 80) -> light(?l) ^hasState(?l, false)

light_sensor state can change at any time and more than once (as the light sensor state can go down and up again).

Can I use Jess to do this? Do you have any example code of how to do it?

Thanks



Ana Rossello Busquet

Ph.D. Student

Networks Technology and Service Platforms

DTU Fotonik



Technical University of Denmark

[cid:image001.gif at 01CB2718.3EB41A00]

Department of Photonics Engineering

Ørsteds Plads

Building 343

2800  Kgs. Lyngby

Direct +45 45256380
Mob. +45 2830 0805

aros at fotonik.dtu.dk<mailto:aros at fotonik.dtu.dk>

www.fotonik.dtu.dk<http://www.fotonik.dtu.dk/>



From: Martin O'Connor [via Protege Ontology Editor & Knowledge Acquisition System] [mailto:ml-node+2291789-1621202953-267499 at n4.nabble.com]
Sent: 16. juli 2010 20:32
To: Ana Rossello Busquet
Subject: Re: Create Rules in Eclipse using Protege 3.4.4


That should probably have read:

SWRL rules cannot be used to modify *existing* information in an ontology.

SWRL can modify an ontology in the sense that rule can generate new
inferences in the ontology.

If you want modify existing information you will generally need to do it
programmatically (or via the GUI).

Martin

aros wrote:

> Hi,
>
> I haven't actually tried to use SWRL to modify my ontology but I found this:
>
> source: http://protege.cim3.net/cgi-bin/wiki.pl?SWRLLanguageFAQ
>
> Does SWRL support Nonmonotonic Inference?
>
> No. Like OWL, SWRL supports monotonic inference only. Hence, SWRL rules
> cannot be used to modify information in an ontology. If SWRL rules allowed
> ontology modifications nonmonotonicity  would ensue. For this reason, it is
> also not possible to retract or remove information from an ontology using
> SWRL.    (9LH)
>
> For example, assume we have a rule that indicates that a driver older than
> 25 is insurable by assigning a boolean property to true:    (9L4)
>
>     * Driver(?d) ^ hasAge(?d, ?age) ^ swrlb:greaterThan(?age, 25) ->
> isInsurable(?d, true)    (9L5)
>
> This rule will add the value of true to the isInsurable property for all
> drivers that satisfy the antecedent. It does not change the existing value
> for that property. If, for example, a driver has a previous assignment of
> false for that property, a successful firing of this rule for that driver
> will result in the property having two values. If the isInsurable value if
> functional (which it most likely should be), an OWL reasoner will indicate
> an inconsistency when applied to the resulting ontology.
>
>

_______________________________________________
protege-owl mailing list
[hidden email]</user/SendEmail.jtp?type=node&node=2291789&i=0>
https://mailman.stanford.edu/mailman/listinfo/protege-owl

Instructions for unsubscribing: http://protege.stanford.edu/doc/faq.html#01a.03

________________________________
View message @ http://protege-ontology-editor-knowledge-acquisition-system.136.n4.nabble.com/Create-Rules-in-Eclipse-using-Protege-3-4-4-tp2288368p2291789.html
To unsubscribe from Re: Create Rules in Eclipse using Protege 3.4.4, click here<http://protege-ontology-editor-knowledge-acquisition-system.136.n4.nabble.com/subscriptions/Unsubscribe.jtp?code=YXJvc0Bmb3RvbmlrLmR0dS5ka3wyMjkxMzE4fC0yMTc5MTQ5NDk=>.


 
-- 
View this message in context: http://protege-ontology-editor-knowledge-acquisition-system.136.n4.nabble.com/Create-Rules-in-Eclipse-using-Protege-3-4-4-tp2288368p2293583.html
Sent from the Protege OWL mailing list archive at Nabble.com.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.stanford.edu/pipermail/protege-owl/attachments/20100718/4e1599bd/attachment.html>


More information about the protege-owl mailing list