You can subscribe to this list here.
| 2004 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
(11) |
Aug
(1) |
Sep
(4) |
Oct
|
Nov
(5) |
Dec
(1) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2005 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
(4) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2006 |
Jan
(3) |
Feb
|
Mar
(8) |
Apr
(21) |
May
(12) |
Jun
(2) |
Jul
|
Aug
(3) |
Sep
(2) |
Oct
|
Nov
|
Dec
|
| 2007 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(6) |
Jul
(69) |
Aug
(37) |
Sep
(23) |
Oct
(30) |
Nov
(67) |
Dec
(63) |
| 2008 |
Jan
(79) |
Feb
(80) |
Mar
(99) |
Apr
(75) |
May
(54) |
Jun
(41) |
Jul
(145) |
Aug
(72) |
Sep
(42) |
Oct
(53) |
Nov
(49) |
Dec
(57) |
| 2009 |
Jan
(36) |
Feb
(20) |
Mar
(73) |
Apr
(27) |
May
(91) |
Jun
(32) |
Jul
(64) |
Aug
(77) |
Sep
(58) |
Oct
(85) |
Nov
(58) |
Dec
(70) |
| 2010 |
Jan
(61) |
Feb
(102) |
Mar
(66) |
Apr
(96) |
May
(46) |
Jun
(74) |
Jul
(86) |
Aug
(50) |
Sep
(88) |
Oct
(76) |
Nov
(52) |
Dec
(73) |
| 2011 |
Jan
(113) |
Feb
(84) |
Mar
(57) |
Apr
(63) |
May
(66) |
Jun
(101) |
Jul
(123) |
Aug
(109) |
Sep
(111) |
Oct
(126) |
Nov
(135) |
Dec
(85) |
| 2012 |
Jan
(57) |
Feb
(60) |
Mar
(81) |
Apr
(66) |
May
(117) |
Jun
(94) |
Jul
(166) |
Aug
(194) |
Sep
(75) |
Oct
(46) |
Nov
(93) |
Dec
(76) |
| 2013 |
Jan
(79) |
Feb
(130) |
Mar
(79) |
Apr
(63) |
May
(111) |
Jun
(49) |
Jul
(64) |
Aug
(50) |
Sep
(74) |
Oct
(82) |
Nov
(98) |
Dec
(76) |
| 2014 |
Jan
(52) |
Feb
(47) |
Mar
(83) |
Apr
(42) |
May
(15) |
Jun
(54) |
Jul
(77) |
Aug
(72) |
Sep
(25) |
Oct
(42) |
Nov
(41) |
Dec
(62) |
| 2015 |
Jan
(56) |
Feb
(16) |
Mar
(17) |
Apr
(19) |
May
(18) |
Jun
(47) |
Jul
(24) |
Aug
(31) |
Sep
(26) |
Oct
(40) |
Nov
(35) |
Dec
(39) |
| 2016 |
Jan
(62) |
Feb
(102) |
Mar
(62) |
Apr
(6) |
May
(10) |
Jun
(30) |
Jul
(27) |
Aug
(21) |
Sep
(32) |
Oct
(7) |
Nov
(8) |
Dec
(47) |
| 2017 |
Jan
(43) |
Feb
(30) |
Mar
(17) |
Apr
(33) |
May
(11) |
Jun
(12) |
Jul
(14) |
Aug
(1) |
Sep
(11) |
Oct
(36) |
Nov
(2) |
Dec
(5) |
| 2018 |
Jan
(23) |
Feb
|
Mar
|
Apr
(3) |
May
|
Jun
(7) |
Jul
(1) |
Aug
(14) |
Sep
|
Oct
|
Nov
|
Dec
(1) |
| 2019 |
Jan
|
Feb
(1) |
Mar
|
Apr
|
May
|
Jun
(1) |
Jul
|
Aug
|
Sep
|
Oct
(1) |
Nov
|
Dec
|
| 2020 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
(9) |
Aug
|
Sep
|
Oct
|
Nov
(3) |
Dec
|
| 2021 |
Jan
|
Feb
|
Mar
|
Apr
(1) |
May
(1) |
Jun
|
Jul
|
Aug
(18) |
Sep
|
Oct
|
Nov
|
Dec
|
| 2022 |
Jan
|
Feb
(1) |
Mar
(3) |
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2023 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(1) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2025 |
Jan
(7) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
|
From: Ignazio P. <ipa...@gm...> - 2021-08-03 19:43:30
|
On Tue, 3 Aug 2021, 22:23 Shyama Wilson, <sh...@uw...> wrote:
> Thank You very much for your prompt reply
>
> I used the below dependencies only. Please kindly let me know still I have
> version issue with regards to my issue.
>
> <dependencies>
> <dependency>
> <groupId>net.sourceforge.owlapi</groupId>
> <artifactId>owlapi-distribution</artifactId>
> <version>5.1.17</version>
> </dependency>
> <dependency>
> <groupId>net.sourceforge.owlapi</groupId>
> <artifactId>org.semanticweb.hermit</artifactId>
> <version>1.4.3.517</version>
> </dependency>
> <dependency>
> <groupId>net.sourceforge.owlapi</groupId>
> <artifactId>owlexplanation</artifactId>
> <version>2.0.0</version>
> <type>jar</type>
> </dependency>
>
>
These look correct.
Can you add this as first line to your Java code and post back the result?
System.out.println(System.getProperty("java.class.path"));
Cheers,
Ignazio
> ------------------
>
> Cheers!
>
> On Wed, Aug 4, 2021 at 12:08 AM Ignazio Palmisano <
> ipa...@gm...> wrote:
>
>>
>>
>> On Tue, 3 Aug 2021, 21:30 Shyama, <shy...@gm...> wrote:
>>
>>> HI
>>>
>>> Could Anyone please kindly assists me to resolve this issue.
>>>
>>> I have written a code to test an inconsistency Explanation. The code
>>> does not show any syntax error, but it got exceptions while running the
>>> code as follows; For your information, the code and the OWL explanation
>>> dependency are attached at the end.
>>> -------------------------------------------
>>> Exception in thread "main" java.lang.NoSuchMethodError:
>>> org.semanticweb.owlapi.model.OWLOntologyManager.createOntology(Ljava/util/Set;)Lorg/semanticweb/owlapi/model/OWLOntology;
>>>
>> --------------------------------------------
>>>
>>> Used HermiT reasoner
>>>
>>
>>
>> Hi,
>> Which version of HermiT?
>>
>> The stack trace is typical of situations where two versions of OWLAPI are
>> on the classpath, and old versions of HermiT (1.3.8, for example) include
>> the OWLAPI classes in the HermiT jar, making it very hard to use with newer
>> libraries. At compile time this goes unnoticed because classpath order
>> differs.
>>
>> Cheers,
>> Ignazio
>>
>>
>>> Dependency used
>>> ---------------------
>>> <dependency>
>>> <groupId>net.sourceforge.owlapi</groupId>
>>> <artifactId>owlexplanation</artifactId>
>>> <version>2.0.0</version>
>>> <type>jar</type>
>>> </dependency>
>>> -------------------------------
>>>
>>> *code Snippet*
>>>
>>> public static void main(String[] args) throws IOException,
>>> OWLOntologyCreationException {
>>> OWLOntologyManager man = OWLManager.createOWLOntologyManager();
>>> IRI IOR = IRI.create("
>>> http://www.sln4mop.org/ontologies/2021/GoviOntologyV1");
>>>
>>> OWLOntology o;
>>>
>>>
>>> o = man.createOntology(IOR);
>>> OWLDataFactory df =
>>> o.getOWLOntologyManager().getOWLDataFactory();
>>>
>>> OWLClass A = df.getOWLClass(IOR + "#A");
>>> OWLClass B = df.getOWLClass(IOR + "#B");
>>> OWLClass X = df.getOWLClass(IOR + "#X");
>>> OWLObjectProperty R = df.getOWLObjectProperty(IOR + "#R");
>>> OWLObjectProperty S = df.getOWLObjectProperty(IOR + "#S");
>>> OWLSubClassOfAxiom ax =
>>> df.getOWLSubClassOfAxiom(df.getOWLObjectSomeValuesFrom(R, A),
>>> df.getOWLObjectSomeValuesFrom(S, B));
>>> o.add(ax);
>>>
>>> // create an inconsistent ontology by declaring an
>>> individual member of two disjoint classes
>>> OWLIndividual i = df.getOWLNamedIndividual(IOR +
>>> "#testInv");
>>> OWLDisjointClassesAxiom ax2 =
>>> df.getOWLDisjointClassesAxiom(A, B);
>>> o.add(ax2 );
>>> o.add(df.getOWLClassAssertionAxiom(A, i));
>>> o.add( df.getOWLClassAssertionAxiom(B, i))
>>>
>>> OWLReasonerFactory hermitreasonerFactory = new
>>> ReasonerFactory();
>>> OWLReasoner r = hermitreasonerFactory.createReasoner(o);
>>>
>>> System.out.println("check consistency"+ r.isConsistent());
>>>
>>> //create the explanation generator --- this code is not
>>> working..............
>>>
>>>
>>>
>>>
>>> * ExplanationGenerator<OWLAxiom> explainInconsistency = new
>>> InconsistentOntologyExplanationGeneratorFactory(hermitreasonerFactory,1000L).createExplanationGenerator(o);
>>> // Ask for an explanation of `Thing subclass of Nothing` - this axiom is
>>> entailed in any inconsistent ontology Set<Explanation<OWLAxiom>>
>>> explanations =
>>> explainInconsistency.getExplanations(df.getOWLSubClassOfAxiom(df
>>> .getOWLThing(), df.getOWLNothing()));
>>> System.out.println("TestExplanation.main() " + explanations);*
>>>
>>> }
>>>
>>>
>>> Cheers!
>>>
>>> --
>>> Shyama Wilson
>>> Department of Computer Science and Informatics
>>> Uva Wellassa University: www.uwu.ac.lk
>>> Badulla, Sri Lanka
>>> email: sh...@uw... <am...@uw...>
>>>
>>>
>>>
>>>
>>>
>>> _______________________________________________
>>> Owlapi-developer mailing list
>>> Owl...@li...
>>> https://lists.sourceforge.net/lists/listinfo/owlapi-developer
>>>
>> _______________________________________________
>> Owlapi-developer mailing list
>> Owl...@li...
>> https://lists.sourceforge.net/lists/listinfo/owlapi-developer
>>
>
>
> --
> Department of Computer Science and Informatics
> Faculty of Applied Sciences
> Uva Wellassa University
> Badulla
> _______________________________________________
> Owlapi-developer mailing list
> Owl...@li...
> https://lists.sourceforge.net/lists/listinfo/owlapi-developer
>
|
|
From: Shyama W. <sh...@uw...> - 2021-08-03 19:23:06
|
Thank You very much for your prompt reply
I used the below dependencies only. Please kindly let me know still I have
version issue with regards to my issue.
<dependencies>
<dependency>
<groupId>net.sourceforge.owlapi</groupId>
<artifactId>owlapi-distribution</artifactId>
<version>5.1.17</version>
</dependency>
<dependency>
<groupId>net.sourceforge.owlapi</groupId>
<artifactId>org.semanticweb.hermit</artifactId>
<version>1.4.3.517</version>
</dependency>
<dependency>
<groupId>net.sourceforge.owlapi</groupId>
<artifactId>owlexplanation</artifactId>
<version>2.0.0</version>
<type>jar</type>
</dependency>
------------------
Cheers!
On Wed, Aug 4, 2021 at 12:08 AM Ignazio Palmisano <
ipa...@gm...> wrote:
>
>
> On Tue, 3 Aug 2021, 21:30 Shyama, <shy...@gm...> wrote:
>
>> HI
>>
>> Could Anyone please kindly assists me to resolve this issue.
>>
>> I have written a code to test an inconsistency Explanation. The code
>> does not show any syntax error, but it got exceptions while running the
>> code as follows; For your information, the code and the OWL explanation
>> dependency are attached at the end.
>> -------------------------------------------
>> Exception in thread "main" java.lang.NoSuchMethodError:
>> org.semanticweb.owlapi.model.OWLOntologyManager.createOntology(Ljava/util/Set;)Lorg/semanticweb/owlapi/model/OWLOntology;
>>
> --------------------------------------------
>>
>> Used HermiT reasoner
>>
>
>
> Hi,
> Which version of HermiT?
>
> The stack trace is typical of situations where two versions of OWLAPI are
> on the classpath, and old versions of HermiT (1.3.8, for example) include
> the OWLAPI classes in the HermiT jar, making it very hard to use with newer
> libraries. At compile time this goes unnoticed because classpath order
> differs.
>
> Cheers,
> Ignazio
>
>
>> Dependency used
>> ---------------------
>> <dependency>
>> <groupId>net.sourceforge.owlapi</groupId>
>> <artifactId>owlexplanation</artifactId>
>> <version>2.0.0</version>
>> <type>jar</type>
>> </dependency>
>> -------------------------------
>>
>> *code Snippet*
>>
>> public static void main(String[] args) throws IOException,
>> OWLOntologyCreationException {
>> OWLOntologyManager man = OWLManager.createOWLOntologyManager();
>> IRI IOR = IRI.create("
>> http://www.sln4mop.org/ontologies/2021/GoviOntologyV1");
>>
>> OWLOntology o;
>>
>>
>> o = man.createOntology(IOR);
>> OWLDataFactory df =
>> o.getOWLOntologyManager().getOWLDataFactory();
>>
>> OWLClass A = df.getOWLClass(IOR + "#A");
>> OWLClass B = df.getOWLClass(IOR + "#B");
>> OWLClass X = df.getOWLClass(IOR + "#X");
>> OWLObjectProperty R = df.getOWLObjectProperty(IOR + "#R");
>> OWLObjectProperty S = df.getOWLObjectProperty(IOR + "#S");
>> OWLSubClassOfAxiom ax =
>> df.getOWLSubClassOfAxiom(df.getOWLObjectSomeValuesFrom(R, A),
>> df.getOWLObjectSomeValuesFrom(S, B));
>> o.add(ax);
>>
>> // create an inconsistent ontology by declaring an
>> individual member of two disjoint classes
>> OWLIndividual i = df.getOWLNamedIndividual(IOR +
>> "#testInv");
>> OWLDisjointClassesAxiom ax2 =
>> df.getOWLDisjointClassesAxiom(A, B);
>> o.add(ax2 );
>> o.add(df.getOWLClassAssertionAxiom(A, i));
>> o.add( df.getOWLClassAssertionAxiom(B, i))
>>
>> OWLReasonerFactory hermitreasonerFactory = new
>> ReasonerFactory();
>> OWLReasoner r = hermitreasonerFactory.createReasoner(o);
>>
>> System.out.println("check consistency"+ r.isConsistent());
>>
>> //create the explanation generator --- this code is not
>> working..............
>>
>>
>>
>>
>> * ExplanationGenerator<OWLAxiom> explainInconsistency = new
>> InconsistentOntologyExplanationGeneratorFactory(hermitreasonerFactory,1000L).createExplanationGenerator(o);
>> // Ask for an explanation of `Thing subclass of Nothing` - this axiom is
>> entailed in any inconsistent ontology Set<Explanation<OWLAxiom>>
>> explanations =
>> explainInconsistency.getExplanations(df.getOWLSubClassOfAxiom(df
>> .getOWLThing(), df.getOWLNothing()));
>> System.out.println("TestExplanation.main() " + explanations);*
>>
>> }
>>
>>
>> Cheers!
>>
>> --
>> Shyama Wilson
>> Department of Computer Science and Informatics
>> Uva Wellassa University: www.uwu.ac.lk
>> Badulla, Sri Lanka
>> email: sh...@uw... <am...@uw...>
>>
>>
>>
>>
>>
>> _______________________________________________
>> Owlapi-developer mailing list
>> Owl...@li...
>> https://lists.sourceforge.net/lists/listinfo/owlapi-developer
>>
> _______________________________________________
> Owlapi-developer mailing list
> Owl...@li...
> https://lists.sourceforge.net/lists/listinfo/owlapi-developer
>
--
Department of Computer Science and Informatics
Faculty of Applied Sciences
Uva Wellassa University
Badulla
|
|
From: Ignazio P. <ipa...@gm...> - 2021-08-03 18:38:45
|
On Tue, 3 Aug 2021, 21:30 Shyama, <shy...@gm...> wrote:
> HI
>
> Could Anyone please kindly assists me to resolve this issue.
>
> I have written a code to test an inconsistency Explanation. The code does
> not show any syntax error, but it got exceptions while running the code as
> follows; For your information, the code and the OWL explanation dependency
> are attached at the end.
> -------------------------------------------
> Exception in thread "main" java.lang.NoSuchMethodError:
> org.semanticweb.owlapi.model.OWLOntologyManager.createOntology(Ljava/util/Set;)Lorg/semanticweb/owlapi/model/OWLOntology;
>
--------------------------------------------
>
> Used HermiT reasoner
>
Hi,
Which version of HermiT?
The stack trace is typical of situations where two versions of OWLAPI are
on the classpath, and old versions of HermiT (1.3.8, for example) include
the OWLAPI classes in the HermiT jar, making it very hard to use with newer
libraries. At compile time this goes unnoticed because classpath order
differs.
Cheers,
Ignazio
> Dependency used
> ---------------------
> <dependency>
> <groupId>net.sourceforge.owlapi</groupId>
> <artifactId>owlexplanation</artifactId>
> <version>2.0.0</version>
> <type>jar</type>
> </dependency>
> -------------------------------
>
> *code Snippet*
>
> public static void main(String[] args) throws IOException,
> OWLOntologyCreationException {
> OWLOntologyManager man = OWLManager.createOWLOntologyManager();
> IRI IOR = IRI.create("
> http://www.sln4mop.org/ontologies/2021/GoviOntologyV1");
>
> OWLOntology o;
>
>
> o = man.createOntology(IOR);
> OWLDataFactory df =
> o.getOWLOntologyManager().getOWLDataFactory();
>
> OWLClass A = df.getOWLClass(IOR + "#A");
> OWLClass B = df.getOWLClass(IOR + "#B");
> OWLClass X = df.getOWLClass(IOR + "#X");
> OWLObjectProperty R = df.getOWLObjectProperty(IOR + "#R");
> OWLObjectProperty S = df.getOWLObjectProperty(IOR + "#S");
> OWLSubClassOfAxiom ax =
> df.getOWLSubClassOfAxiom(df.getOWLObjectSomeValuesFrom(R, A),
> df.getOWLObjectSomeValuesFrom(S, B));
> o.add(ax);
>
> // create an inconsistent ontology by declaring an individual
> member of two disjoint classes
> OWLIndividual i = df.getOWLNamedIndividual(IOR +
> "#testInv");
> OWLDisjointClassesAxiom ax2 =
> df.getOWLDisjointClassesAxiom(A, B);
> o.add(ax2 );
> o.add(df.getOWLClassAssertionAxiom(A, i));
> o.add( df.getOWLClassAssertionAxiom(B, i))
>
> OWLReasonerFactory hermitreasonerFactory = new
> ReasonerFactory();
> OWLReasoner r = hermitreasonerFactory.createReasoner(o);
>
> System.out.println("check consistency"+ r.isConsistent());
>
> //create the explanation generator --- this code is not
> working..............
>
>
>
>
> * ExplanationGenerator<OWLAxiom> explainInconsistency = new
> InconsistentOntologyExplanationGeneratorFactory(hermitreasonerFactory,1000L).createExplanationGenerator(o);
> // Ask for an explanation of `Thing subclass of Nothing` - this axiom is
> entailed in any inconsistent ontology Set<Explanation<OWLAxiom>>
> explanations =
> explainInconsistency.getExplanations(df.getOWLSubClassOfAxiom(df
> .getOWLThing(), df.getOWLNothing()));
> System.out.println("TestExplanation.main() " + explanations);*
>
> }
>
>
> Cheers!
>
> --
> Shyama Wilson
> Department of Computer Science and Informatics
> Uva Wellassa University: www.uwu.ac.lk
> Badulla, Sri Lanka
> email: sh...@uw... <am...@uw...>
>
>
>
>
>
> _______________________________________________
> Owlapi-developer mailing list
> Owl...@li...
> https://lists.sourceforge.net/lists/listinfo/owlapi-developer
>
|
|
From: Shyama <shy...@gm...> - 2021-08-03 18:26:44
|
HI
Could Anyone please kindly assists me to resolve this issue.
I have written a code to test an inconsistency Explanation. The code does
not show any syntax error, but it got exceptions while running the code as
follows; For your information, the code and the OWL explanation dependency
are attached at the end.
-------------------------------------------
Exception in thread "main" java.lang.NoSuchMethodError:
org.semanticweb.owlapi.model.OWLOntologyManager.createOntology(Ljava/util/Set;)Lorg/semanticweb/owlapi/model/OWLOntology;
at
org.semanticweb.owl.explanation.impl.blackbox.checker.ConsistencyEntailmentChecker.isEntailed(ConsistencyEntailmentChecker.java:110)
at
org.semanticweb.owl.explanation.impl.blackbox.InconsistentOntologyExpansionStrategy.doExpansion(InconsistentOntologyExpansionStrategy.java:44)
at
org.semanticweb.owl.explanation.impl.blackbox.BlackBoxExplanationGenerator2.doExpansion(BlackBoxExplanationGenerator2.java:258)
at
org.semanticweb.owl.explanation.impl.blackbox.BlackBoxExplanationGenerator2.computeExplanation(BlackBoxExplanationGenerator2.java:179)
at
org.semanticweb.owl.explanation.impl.blackbox.BlackBoxExplanationGenerator2.generateExplanation(BlackBoxExplanationGenerator2.java:289)
at
org.semanticweb.owl.explanation.impl.blackbox.hst.HittingSetTree.buildHittingSetTree(HittingSetTree.java:116)
at
org.semanticweb.owl.explanation.impl.blackbox.BlackBoxExplanationGenerator2.getExplanations(BlackBoxExplanationGenerator2.java:114)
at
org.semanticweb.owl.explanation.impl.blackbox.BlackBoxExplanationGenerator2.getExplanations(BlackBoxExplanationGenerator2.java:91)
at com.mycompany.owltutorial.OWLAPIFirst.main(OWLAPIFirst.java:103)
Command execution failed.
org.apache.commons.exec.ExecuteException: Process exited with an error: 1
(Exit value: 1)
at org.apache.commons.exec.DefaultExecutor.executeInternal
(DefaultExecutor.java:404)
at org.apache.commons.exec.DefaultExecutor.execute
(DefaultExecutor.java:166)
at org.codehaus.mojo.exec.ExecMojo.executeCommandLine
(ExecMojo.java:982)
at org.codehaus.mojo.exec.ExecMojo.executeCommandLine
(ExecMojo.java:929)
at org.codehaus.mojo.exec.ExecMojo.execute (ExecMojo.java:457)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo
(DefaultBuildPluginManager.java:137)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute
(MojoExecutor.java:210)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute
(MojoExecutor.java:156)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute
(MojoExecutor.java:148)
at
org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject
(LifecycleModuleBuilder.java:117)
at
org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject
(LifecycleModuleBuilder.java:81)
at
org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build
(SingleThreadedBuilder.java:56)
at org.apache.maven.lifecycle.internal.LifecycleStarter.execute
(LifecycleStarter.java:128)
at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:305)
at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:192)
at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:105)
at org.apache.maven.cli.MavenCli.execute (MavenCli.java:957)
at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:289)
at org.apache.maven.cli.MavenCli.main (MavenCli.java:193)
at sun.reflect.NativeMethodAccessorImpl.invoke0 (Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke
(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke
(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke (Method.java:498)
at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced
(Launcher.java:282)
at org.codehaus.plexus.classworlds.launcher.Launcher.launch
(Launcher.java:225)
at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode
(Launcher.java:406)
at org.codehaus.plexus.classworlds.launcher.Launcher.main
(Launcher.java:347)
--------------------------------------------
Used HermiT reasoner
Dependency used
---------------------
<dependency>
<groupId>net.sourceforge.owlapi</groupId>
<artifactId>owlexplanation</artifactId>
<version>2.0.0</version>
<type>jar</type>
</dependency>
-------------------------------
*code Snippet*
public static void main(String[] args) throws IOException,
OWLOntologyCreationException {
OWLOntologyManager man = OWLManager.createOWLOntologyManager();
IRI IOR = IRI.create("
http://www.sln4mop.org/ontologies/2021/GoviOntologyV1");
OWLOntology o;
o = man.createOntology(IOR);
OWLDataFactory df =
o.getOWLOntologyManager().getOWLDataFactory();
OWLClass A = df.getOWLClass(IOR + "#A");
OWLClass B = df.getOWLClass(IOR + "#B");
OWLClass X = df.getOWLClass(IOR + "#X");
OWLObjectProperty R = df.getOWLObjectProperty(IOR + "#R");
OWLObjectProperty S = df.getOWLObjectProperty(IOR + "#S");
OWLSubClassOfAxiom ax =
df.getOWLSubClassOfAxiom(df.getOWLObjectSomeValuesFrom(R, A),
df.getOWLObjectSomeValuesFrom(S, B));
o.add(ax);
// create an inconsistent ontology by declaring an individual
member of two disjoint classes
OWLIndividual i = df.getOWLNamedIndividual(IOR +
"#testInv");
OWLDisjointClassesAxiom ax2 =
df.getOWLDisjointClassesAxiom(A, B);
o.add(ax2 );
o.add(df.getOWLClassAssertionAxiom(A, i));
o.add( df.getOWLClassAssertionAxiom(B, i))
OWLReasonerFactory hermitreasonerFactory = new ReasonerFactory();
OWLReasoner r = hermitreasonerFactory.createReasoner(o);
System.out.println("check consistency"+ r.isConsistent());
//create the explanation generator --- this code is not
working..............
* ExplanationGenerator<OWLAxiom> explainInconsistency = new
InconsistentOntologyExplanationGeneratorFactory(hermitreasonerFactory,1000L).createExplanationGenerator(o);
// Ask for an explanation of `Thing subclass of Nothing` - this axiom is
entailed in any inconsistent ontology Set<Explanation<OWLAxiom>>
explanations =
explainInconsistency.getExplanations(df.getOWLSubClassOfAxiom(df
.getOWLThing(), df.getOWLNothing()));
System.out.println("TestExplanation.main() " + explanations);*
}
Cheers!
--
Shyama Wilson
Department of Computer Science and Informatics
Uva Wellassa University: www.uwu.ac.lk
Badulla, Sri Lanka
email: sh...@uw... <am...@uw...>
|
|
From: Ignazio P. <ipa...@gm...> - 2021-08-01 18:15:24
|
Hi all, New releases available in Maven central, as usual. Minor bug fixes and dependency updates to remove references to known vulnerabilities. Cheers, I. |
|
From: Raghava M. <m.v...@gm...> - 2021-05-12 12:31:20
|
Dear All, TL;DR ************************* We are organizing a challenge centered around reasoning. We invite you to make submissions that can be in one or more of the following categories - 1) an ontology developed for a real-world application, but proved to be a challenge for the existing reasoners, 2) A traditional description logic reasoner that was developed or made improvements to in the last few years, 3) A neuro-symbolic reasoner that approximates entailments or predicts missing axioms. If you have any questions, please contact us (email IDs are given in the cc). Further details are on the website: https://semrec.github.io/ ************************* Longer version ************************* Despite the development of several ontology reasoning optimizations, the traditional methods either do not scale well or only cover a subset of OWL 2 language constructs. As an alternative, neuro-symbolic approaches are gaining significant attention. However, the existing methods still can not deal with very expressive ontology languages. To find and improve these performance bottlenecks of the reasoners, we ideally need several real-world ontologies that span the broad spectrum in terms of their size and expressivity. However, that is often not the case. One of the potential reasons for the ontology developers to not build ontologies that vary in terms of size and expressivity is the performance bottleneck of the reasoners. This challenge includes three tasks that aim to deal with this chicken and egg problem. Task-1 - Submit a real-world ontology that is a challenge in terms of the reasoning time or memory consumed during reasoning. We will be evaluating the submitted ontologies based on the time and the memory consumed for a reasoning task, such as classification. Task-2 - Submit a description logic reasoner that makes use of traditional techniques such as tableau algorithms and saturation rules. We will evaluate the performance and the scalability of the submitted systems on the datasets based on the time taken and memory consumed on the ontology classification task. This will provide an insight into the progress in the development of reasoners since the last reasoner evaluation challenge (ORE 2015). Task-3 - Submit an ontology/RDFS reasoner that makes use of neuro-symbolic techniques for reasoning and optimization. We will be evaluating two types of neuro-symbolic systems: (a) that approximate the entailment reasoning for addressing the time complexity problem, or (b) predicting missing and plausible axioms for completion. We will evaluate the submitted systems on the test datasets based on the time taken, memory consumed, precision and recall. Submission Details Participants are requested to make a manuscript submission describing their entry. For Task 1, we expect a detailed description of the ontology along with the analysis of the reasoning performance, the workarounds, if any, that were used to make the ontology less challenging (for example, dropping of a few axioms, redesigning the ontology, etc.), and the (potential) applications in which the ontology could be used. For Tasks 2 and 3, we expect a detailed description of the system, including evaluating the system on the provided datasets. The submissions can be either in the form of short papers of length 5 pages or long papers of length 10-12 pages. All the submissions must be in English and follow the 1-column CEUR-ART style (link to the overleaf page would be updated soon). The proceedings will be published as a volume of CEUR-WS. Submissions should be made in the form of a pdf document on EasyChair (link will be updated soon). Website: https://semrec.github.io/ Organizers Gunjan Singh, IIIT-Delhi, India. Raghava Mutharaju, IIIT-Delhi, India. Pavan Kapanipathi, IBM T.J. Watson Research Center, USA. Best regards, Raghava. |
|
From: Raghava M. <m.v...@gm...> - 2021-04-07 18:16:43
|
Dear All, While building an ontology, there are several things to consider such as reusing concepts/properties from the existing ontologies, using ontology design patterns (ODPs), following the naming conventions for concepts/properties and designing a good class hierarchy. These are issues that beginner ontology engineers find hard and can be tricky for experienced ones as well. OntoSeer (https://github.com/kracr/ontoseer) is a Protege plugin that overlooks the ontology that is being built in Protege and offers different types of recommendations. We would love it if you can try OntoSeer (takes around 15 mins) and give us your anonymous feedback (takes less than 10 mins) at https://docs.google.com/forms/d/e/1FAIpQLSfhZkcGmXleV5vLGL6cDbyMl70OCpJVr9U-K-qfFBQEMYpUKg/viewform?usp=sf_link . Installation of OntoSeer is quite straightforward and the instructions are available at https://github.com/kracr/ontoseer#exe. They have been reproduced below. 1) Download the latest jar from https://github.com/kracr/ontoseer/releases. 2) Put the jar in the plugins directory of Protege installation directory. 3) Start/restart Protege. 4) In the About section of Protege, you should notice the OntoSeer plugin. 5) Under the Window menu, please select Tabs/OntoSeer. A new tab named OntoSeer will show up. 6) Now you can start building an ontology or use an existing ontology to get the recommendations by clicking on different buttons in the OntoSeer tab. Your feedback will be valuable to improve this tool. In case of any questions, please feel free to send an email to Pramit ( pra...@ii...) and/or me (rag...@ii...). Best regards, Raghava. -------------------------- Raghava Mutharaju, Assistant Professor (CSE), IIIT-Delhi, India. http://faculty.iiitd.ac.in/~raghavam |
|
From: Ignazio P. <ipa...@gm...> - 2020-11-17 12:03:10
|
Hi, Can you share the code and specify which OWLAPI version you're using? Also, did the code become slower when you updated? Cheers, Ignazio On Tue, 17 Nov 2020 at 12:01, Shyama Wilson <sh...@uw...> wrote: > > hi > > my program contains a simple code to retrieve individuals of a class that is taking more times to process. May I know the reason for that? > > Thanks > > On Sat, Nov 7, 2020 at 2:20 PM Ignazio Palmisano <ipa...@gm...> wrote: >> >> Hi all, >> a number of bug fixes released and available on the usual channels. >> >> 4.5.19 and 5.1.17 >> >> >> Cheers, >> Ignazio >> >> >> _______________________________________________ >> Owlapi-developer mailing list >> Owl...@li... >> https://lists.sourceforge.net/lists/listinfo/owlapi-developer > > > > -- > Department of Computer Science and Informatics > Faculty of Applied Sciences > Uva Wellassa University > Badulla > _______________________________________________ > Owlapi-developer mailing list > Owl...@li... > https://lists.sourceforge.net/lists/listinfo/owlapi-developer |
|
From: Shyama W. <sh...@uw...> - 2020-11-17 04:10:22
|
hi my program contains a simple code to retrieve individuals of a class that is taking more times to process. May I know the reason for that? Thanks On Sat, Nov 7, 2020 at 2:20 PM Ignazio Palmisano < ipa...@gm...> wrote: > Hi all, > a number of bug fixes released and available on the usual channels. > > 4.5.19 and 5.1.17 > > > Cheers, > Ignazio > > > _______________________________________________ > Owlapi-developer mailing list > Owl...@li... > https://lists.sourceforge.net/lists/listinfo/owlapi-developer > -- Department of Computer Science and Informatics Faculty of Applied Sciences Uva Wellassa University Badulla |
|
From: Ignazio P. <ipa...@gm...> - 2020-11-07 19:19:53
|
Hi all, a number of bug fixes released and available on the usual channels. 4.5.19 and 5.1.17 Cheers, Ignazio |
|
From: Lewis J. M. <lew...@gm...> - 2020-07-18 22:03:00
|
Fantastic. Thank you On Sat, Jul 18, 2020 at 01:21 Ignazio Palmisano < ipa...@gm...> wrote: > On Fri, 17 Jul 2020 at 23:54, Lewis John Mcgibbney > <lew...@gm...> wrote: > > > > I have loads of OWLClass'es peppered throughout a large ontology suite > which DO NOT have a skos:definition specified as a OWLPropertyAnnotation. > > I would like to execute some code only on each of those OWLClass'es > which does NOT yet have a skos:definition. > > I looked at OWLClass.annotationPropertiesInSignature().filter() but I am > not sure if filtering the Stream is the correct way to go here or if there > is a preferred way... > > annotationPropertiesInSignature() returns any annotation properties > used inside the object, but OWLClass does not use any annotation > property - the annotations on a class are not part of the class, > they're part of an axiom (in this case an annotation assertion axiom). > > You can use > > Entitysearcher.getAnnotationObjects(owlClass, ontology, > skosDefinition).count()==0 > > to verify if a certain class is annotated within an ontology. If you > need to check if the class is annotated anywhere in an imports > closure, the method is overloaded for this purpose: > > Entitysearcher.getAnnotationObjects(owlClass, > ontology.importsClosure(), skosDefinition).count()==0 > > Cheers, > I. > > > Any pointers? > > Thank you > > > > -- > > Lewis > > Dr. Lewis J. McGibbney Ph.D, B.Sc > > Skype: lewis.john.mcgibbney > > > > > > > > _______________________________________________ > > Owlapi-developer mailing list > > Owl...@li... > > https://lists.sourceforge.net/lists/listinfo/owlapi-developer > > > _______________________________________________ > Owlapi-developer mailing list > Owl...@li... > https://lists.sourceforge.net/lists/listinfo/owlapi-developer > -- *Lewis* Dr. Lewis J. McGibbney Ph.D, B.Sc *Skype*: lewis.john.mcgibbney |
|
From: Ignazio P. <ipa...@gm...> - 2020-07-18 08:21:27
|
On Fri, 17 Jul 2020 at 23:54, Lewis John Mcgibbney <lew...@gm...> wrote: > > I have loads of OWLClass'es peppered throughout a large ontology suite which DO NOT have a skos:definition specified as a OWLPropertyAnnotation. > I would like to execute some code only on each of those OWLClass'es which does NOT yet have a skos:definition. > I looked at OWLClass.annotationPropertiesInSignature().filter() but I am not sure if filtering the Stream is the correct way to go here or if there is a preferred way... annotationPropertiesInSignature() returns any annotation properties used inside the object, but OWLClass does not use any annotation property - the annotations on a class are not part of the class, they're part of an axiom (in this case an annotation assertion axiom). You can use Entitysearcher.getAnnotationObjects(owlClass, ontology, skosDefinition).count()==0 to verify if a certain class is annotated within an ontology. If you need to check if the class is annotated anywhere in an imports closure, the method is overloaded for this purpose: Entitysearcher.getAnnotationObjects(owlClass, ontology.importsClosure(), skosDefinition).count()==0 Cheers, I. > Any pointers? > Thank you > > -- > Lewis > Dr. Lewis J. McGibbney Ph.D, B.Sc > Skype: lewis.john.mcgibbney > > > > _______________________________________________ > Owlapi-developer mailing list > Owl...@li... > https://lists.sourceforge.net/lists/listinfo/owlapi-developer |
|
From: Lewis J. M. <lew...@gm...> - 2020-07-17 22:54:04
|
I have loads of OWLClass'es peppered throughout a large ontology suite which DO NOT have a skos:definition specified as a OWLPropertyAnnotation. I would like to execute some code only on each of those OWLClass'es which does NOT yet have a skos:definition. I looked at OWLClass.annotationPropertiesInSignature().filter() but I am not sure if filtering the Stream is the correct way to go here or if there is a preferred way... Any pointers? Thank you -- *Lewis* Dr. Lewis J. McGibbney Ph.D, B.Sc *Skype*: lewis.john.mcgibbney |
|
From: Lewis J. M. <lew...@gm...> - 2020-07-17 22:09:48
|
Excellent Ignazio. Thank you for this. I hope the thread can be of use to others. Lewis On Fri, Jul 17, 2020 at 2:43 PM Ignazio Palmisano < ipa...@gm...> wrote: > Hi, > A list of annotations as value of an annotation property is not a > common use case; you've already found a workaround. > Another workaround would have been to add the annotations on the > skos:definition annotation, leaving the comment as value of the > annotation. > Code for how I'd have implemented the two variants: > > String soreac = "http://sweetontology.net/realmCryo/"; > String skos = "http://www.w3.org/2004/02/skos/core#"; > String dcterms = "http://purl.org/dc/terms/"; > String prov = "http://www.w3.org/ns/prov#"; > > OWLClass alpineTundra = df.getOWLClass(soreac + "AlpineTundra"); > OWLClass tundra = df.getOWLClass(soreac + "Tundra"); > OWLAnnotationProperty definition = > df.getOWLAnnotationProperty(skos + "definition"); > OWLAnnotation close = > df.getOWLAnnotation(df.getOWLAnnotationProperty(skos + "closeMatch"), > IRI.create("http://purl.obolibrary.org/obo/ENVO_01001371")); > OWLLiteral commentValue = df.getOWLLiteral("A tundra ecosystem > which exists at high altitudes and where vegetation is stunted due to > low temperatures and high winds."); > OWLAnnotation comment = df.getRDFSComment(commentValue); > OWLAnnotation dcsource = > df.getOWLAnnotation(df.getOWLAnnotationProperty(dcterms + "source"), > IRI.create("https://orcid.org/0000-0003-4808-4736")); > OWLAnnotation dccreated = > df.getOWLAnnotation(df.getOWLAnnotationProperty(dcterms + "created"), > df.getOWLLiteral("2019-12-10T06:11:13-08:00Z", > OWL2Datatype.XSD_DATE_TIME_STAMP)); > OWLAnnotation dccreator = > df.getOWLAnnotation(df.getOWLAnnotationProperty(dcterms + "creator"), > IRI.create("https://orcid.org/0000-0003-4091-6059")); > OWLAnnotation derived = > df.getOWLAnnotation(df.getOWLAnnotationProperty(prov + > "wasDerivedFrom"), > IRI.create("http://purl.obolibrary.org/obo/ENVO_01001371")); > IRI alpine = alpineTundra.getIRI(); > OWLAnnotation label = df.getRDFSLabel(df.getOWLLiteral("alpine > tundra")); > > TurtleDocumentFormat format = new TurtleDocumentFormat(); > format.setPrefix("soreac:", soreac); > format.setPrefix("skos:", skos); > format.setPrefix("dcterms:", dcterms); > format.setPrefix("prov:", prov); > > OWLOntology o1 = m.createOntology(); > o1.add(df.getOWLSubClassOfAxiom(alpineTundra, tundra), > df.getOWLAnnotationAssertionAxiom(alpine, label), > df.getOWLAnnotationAssertionAxiom(alpine, close), > df.getOWLAnnotationAssertionAxiom(alpine, > df.getOWLAnnotation(definition, commentValue, Arrays.asList(dcsource, > dccreated, dccreator, derived)))); > String s1 = saveOntology(o1, format).toString(); > System.out.println("Check.should() " + s1); > > OWLOntology o2 = m.createOntology(); > OWLAnonymousIndividual i = df.getOWLAnonymousIndividual(); > o2.add(df.getOWLSubClassOfAxiom(alpineTundra, tundra), > df.getOWLAnnotationAssertionAxiom(alpine, label), > df.getOWLAnnotationAssertionAxiom(alpine, close), > df.getOWLAnnotationAssertionAxiom(alpine, > df.getOWLAnnotation(definition, i)), > df.getOWLAnnotationAssertionAxiom(i, comment), > df.getOWLAnnotationAssertionAxiom(i, dcsource), > df.getOWLAnnotationAssertionAxiom(i, dccreated), > df.getOWLAnnotationAssertionAxiom(i, dccreator), > df.getOWLAnnotationAssertionAxiom(i, derived)); > String s2 = saveOntology(o2, format).toString(); > System.out.println("Check.should() " + s2); > > Cheers, > I. > > On Fri, 17 Jul 2020 at 19:06, Lewis John Mcgibbney > <lew...@gm...> wrote: > > > > OK I have arrived at a satisfactory solution > > > > +:Behavior rdf:type owl:Class ; > > + rdfs:subClassOf :PsychologicalParameter ; > > + rdfs:label "behavior"@en ; > > + skos:definition _:genid1 . > > + > > +_:genid1 dcterms:created "2020-07-17T10:17:18.889"^^xsd:dateTime ; > > + dcterms:creator <https://orcid.org/0000-0003-2185-928X> ; > > + dcterms:source <http://www.wikidata.org/entity/Q9332> ; > > + rdfs:comment "way that one acts in different situations"@en ; > > + prov:wasDerivedFrom <http://www.wikidata.org/entity/Q9332> . > > > > This was achieved as follows > > > > if (wikidataDescription != null) { > > //skos:definition > > val defProp = df.getOWLAnnotationProperty(" > http://www.w3.org/2004/02/skos/core#definition") > > val skosAnno = df.getOWLAnnotation(defProp, > df.getOWLAnonymousIndividual) > > val skosAxiom = df.getOWLAnnotationAssertionAxiom(owlClass.getIRI(), > skosAnno) > > changes.add(new AddAxiom(owlOntology, skosAxiom)) > > //rdfs:comment > > val commentAnno = df.getOWLAnnotation( > > df.getRDFSComment, > > df.getOWLLiteral(wikidataDescription.get(1))) > > val commentAxiom = df.getOWLAnnotationAssertionAxiom( > > df.getOWLAnnotationProperty(" > http://www.w3.org/2000/01/rdf-schema#comment"), > > skosAxiom.anonymousIndividualValue().get(), > commentAnno.annotationValue()) > > changes.add(new AddAxiom(owlOntology, commentAxiom)) > > //prov:wasDerivedFrom > > val wdfProp = df.getOWLAnnotationProperty(" > http://www.w3.org/ns/prov#wasDerivedFrom") > > val provAnno = df.getOWLAnnotation(wdfProp, > IRI.create(wikidataDescription.get(0))) > > val provAxiom = df.getOWLAnnotationAssertionAxiom( > > wdfProp, skosAxiom.anonymousIndividualValue().get(), > provAnno.annotationValue()) > > changes.add(new AddAxiom(owlOntology, provAxiom)) > > //dcterms:source > > val sProp = df.getOWLAnnotationProperty(" > http://purl.org/dc/terms/source") > > val sourceAnno = df.getOWLAnnotation(sProp, > IRI.create(wikidataDescription.get(0))) > > val sourceAxiom = df.getOWLAnnotationAssertionAxiom( > > sProp, skosAxiom.anonymousIndividualValue().get(), > sourceAnno.annotationValue()) > > changes.add(new AddAxiom(owlOntology, sourceAxiom)) > > //dcterms:created > > val ldt = LocalDateTime.now(); > > val cProp = df.getOWLAnnotationProperty(" > http://purl.org/dc/terms/created") > > val createdAnno = df.getOWLAnnotation(cProp, > df.getOWLLiteral(ldt.toString, OWL2Datatype.XSD_DATE_TIME)) > > val createdAxiom = df.getOWLAnnotationAssertionAxiom( > > cProp, skosAxiom.anonymousIndividualValue().get(), > createdAnno.annotationValue()) > > changes.add(new AddAxiom(owlOntology, createdAxiom)) > > //dcterms:creator > > val crProp = df.getOWLAnnotationProperty(" > http://purl.org/dc/terms/creator") > > val creatorAnno = df.getOWLAnnotation(crProp, IRI.create(" > https://orcid.org/0000-0003-2185-928X")) > > val creatorAxiom = df.getOWLAnnotationAssertionAxiom( > > crProp, skosAxiom.anonymousIndividualValue().get(), > creatorAnno.annotationValue()) > > changes.add(new AddAxiom(owlOntology, creatorAxiom)) > > } > > > > > > Quite a lot of code and maybe not implemented correctly but it is the > only solution I found. > > Lewis > > > > > > On Fri, Jul 17, 2020 at 9:52 AM Lewis John Mcgibbney < > lew...@gm...> wrote: > >> > >> Defining the value as an anonymous individual seems to do the trick > >> > >> val skosAnno = df.getOWLAnnotation(df.getOWLAnnotationProperty(" > http://www.w3.org/2004/02/skos/core#definition"), > df.getOWLAnonymousIndividual) > >> val skosAxiom = df.getOWLAnnotationAssertionAxiom(owlClass.getIRI(), > skosAnno) > >> changes.add(new AddAxiom(owlOntology, skosAxiom)) > >> > >> Which results in the following > >> > >> +:Behavior rdf:type owl:Class ; > >> + rdfs:subClassOf :PsychologicalParameter ; > >> + dcterms:created "2020-07-17T09:46:30.492"^^xsd:dateTime ; > >> + dcterms:creator <https://orcid.org/0000-0003-2185-928X> ; > >> + dcterms:source <http://www.wikidata.org/entity/Q9332> ; > >> + rdfs:comment "way that one acts in different situations@en"@en > ; > >> + rdfs:label "behavior"@en ; > >> + skos:definition [ ] ; > >> +prov:wasDerivedFrom <http://www.wikidata.org/entity/Q9332> . > >> > >> Which is an improvement. Now I just need to insert the subsequent > annotations into the skos:definition collection. > >> > >> > >> On Fri, Jul 17, 2020 at 9:28 AM Lewis John Mcgibbney < > lew...@gm...> wrote: > >>> > >>> Hi Folks, > >>> I am struggling to create the following > >>> > >>> ### http://sweetontology.net/realmCryo/AlpineTundra > >>> soreac:AlpineTundra rdf:type owl:Class ; > >>> rdfs:subClassOf soreac:Tundra ; > >>> rdfs:label "alpine tundra"@en ; > >>> skos:closeMatch < > http://purl.obolibrary.org/obo/ENVO_01001371> ; > >>> skos:definition [ > >>> rdfs:comment "A tundra ecosystem which exists > at high altitudes and where vegetation is stunted due to low temperatures > and high winds."@en ; > >>> dcterms:source < > https://orcid.org/0000-0003-4808-4736> ; > >>> dcterms:created > "2019-12-10T06:11:13-08:00Z"^^xsd:dateTimeStamp ; > >>> dcterms:creator < > https://orcid.org/0000-0003-4091-6059> ; > >>> prov:wasDerivedFrom < > http://purl.obolibrary.org/obo/ENVO_01001371> ; > >>> ] . > >>> > >>> > >>> I've only got so far > >>> > >>> ### http://sweetontology.net/realmCryo/AlpineTundra > >>> soreac:AlpineTundra rdf:type owl:Class ; > >>> rdfs:subClassOf soreac:Tundra ; > >>> rdfs:label "alpine tundra"@en ; > >>> skos:closeMatch < > http://purl.obolibrary.org/obo/ENVO_01001371> ; > >>> rdfs:comment "A tundra ecosystem which exists at > high altitudes and where vegetation is stunted due to low temperatures and > high winds."@en ; > >>> dcterms:source < > https://orcid.org/0000-0003-4808-4736> ; > >>> dcterms:created > "2019-12-10T06:11:13-08:00Z"^^xsd:dateTimeStamp ; > >>> dcterms:creator < > https://orcid.org/0000-0003-4091-6059> ; > >>> prov:wasDerivedFrom < > http://purl.obolibrary.org/obo/ENVO_01001371> ; > >>> > >>> How do I add the skos:definition collection? > >>> I think the issue is with creating the skos Annotation and then > applying it to the Class before adding all other axioms to the new skos > Annotation. > >>> I've got the following... which doesn't compile. > >>> > >>> val skosAnno = df.getOWLAnnotationProperty(" > http://www.w3.org/2004/02/skos/core#definition") //this needs to be an > Annotation NOT AnnotationProperty > >>> val skosAxiom = df.getOWLAnnotationAssertionAxiom(owlClass.getIRI(), > skosAnno) > >>> changes.add(new AddAxiom(owlOntology, skosAxiom)) > >>> > >>> Thanks in advance for any pointers. > >>> > >>> -- > >>> Lewis > >>> Dr. Lewis J. McGibbney Ph.D, B.Sc > >>> Skype: lewis.john.mcgibbney > >>> > >>> > >>> > >>> > >>> > >>> -- > >>> Lewis > >>> Dr. Lewis J. McGibbney Ph.D, B.Sc > >>> Skype: lewis.john.mcgibbney > >>> > >>> > >>> > >> > >> > >> -- > >> Lewis > >> Dr. Lewis J. McGibbney Ph.D, B.Sc > >> Skype: lewis.john.mcgibbney > >> > >> > >> > > > > > > -- > > Lewis > > Dr. Lewis J. McGibbney Ph.D, B.Sc > > Skype: lewis.john.mcgibbney > > > > > > > > _______________________________________________ > > Owlapi-developer mailing list > > Owl...@li... > > https://lists.sourceforge.net/lists/listinfo/owlapi-developer > > > _______________________________________________ > Owlapi-developer mailing list > Owl...@li... > https://lists.sourceforge.net/lists/listinfo/owlapi-developer > -- *Lewis* Dr. Lewis J. McGibbney Ph.D, B.Sc *Skype*: lewis.john.mcgibbney |
|
From: Ignazio P. <ipa...@gm...> - 2020-07-17 21:43:07
|
Hi,
A list of annotations as value of an annotation property is not a
common use case; you've already found a workaround.
Another workaround would have been to add the annotations on the
skos:definition annotation, leaving the comment as value of the
annotation.
Code for how I'd have implemented the two variants:
String soreac = "http://sweetontology.net/realmCryo/";
String skos = "http://www.w3.org/2004/02/skos/core#";
String dcterms = "http://purl.org/dc/terms/";
String prov = "http://www.w3.org/ns/prov#";
OWLClass alpineTundra = df.getOWLClass(soreac + "AlpineTundra");
OWLClass tundra = df.getOWLClass(soreac + "Tundra");
OWLAnnotationProperty definition =
df.getOWLAnnotationProperty(skos + "definition");
OWLAnnotation close =
df.getOWLAnnotation(df.getOWLAnnotationProperty(skos + "closeMatch"),
IRI.create("http://purl.obolibrary.org/obo/ENVO_01001371"));
OWLLiteral commentValue = df.getOWLLiteral("A tundra ecosystem
which exists at high altitudes and where vegetation is stunted due to
low temperatures and high winds.");
OWLAnnotation comment = df.getRDFSComment(commentValue);
OWLAnnotation dcsource =
df.getOWLAnnotation(df.getOWLAnnotationProperty(dcterms + "source"),
IRI.create("https://orcid.org/0000-0003-4808-4736"));
OWLAnnotation dccreated =
df.getOWLAnnotation(df.getOWLAnnotationProperty(dcterms + "created"),
df.getOWLLiteral("2019-12-10T06:11:13-08:00Z",
OWL2Datatype.XSD_DATE_TIME_STAMP));
OWLAnnotation dccreator =
df.getOWLAnnotation(df.getOWLAnnotationProperty(dcterms + "creator"),
IRI.create("https://orcid.org/0000-0003-4091-6059"));
OWLAnnotation derived =
df.getOWLAnnotation(df.getOWLAnnotationProperty(prov +
"wasDerivedFrom"),
IRI.create("http://purl.obolibrary.org/obo/ENVO_01001371"));
IRI alpine = alpineTundra.getIRI();
OWLAnnotation label = df.getRDFSLabel(df.getOWLLiteral("alpine
tundra"));
TurtleDocumentFormat format = new TurtleDocumentFormat();
format.setPrefix("soreac:", soreac);
format.setPrefix("skos:", skos);
format.setPrefix("dcterms:", dcterms);
format.setPrefix("prov:", prov);
OWLOntology o1 = m.createOntology();
o1.add(df.getOWLSubClassOfAxiom(alpineTundra, tundra),
df.getOWLAnnotationAssertionAxiom(alpine, label),
df.getOWLAnnotationAssertionAxiom(alpine, close),
df.getOWLAnnotationAssertionAxiom(alpine,
df.getOWLAnnotation(definition, commentValue, Arrays.asList(dcsource,
dccreated, dccreator, derived))));
String s1 = saveOntology(o1, format).toString();
System.out.println("Check.should() " + s1);
OWLOntology o2 = m.createOntology();
OWLAnonymousIndividual i = df.getOWLAnonymousIndividual();
o2.add(df.getOWLSubClassOfAxiom(alpineTundra, tundra),
df.getOWLAnnotationAssertionAxiom(alpine, label),
df.getOWLAnnotationAssertionAxiom(alpine, close),
df.getOWLAnnotationAssertionAxiom(alpine,
df.getOWLAnnotation(definition, i)),
df.getOWLAnnotationAssertionAxiom(i, comment),
df.getOWLAnnotationAssertionAxiom(i, dcsource),
df.getOWLAnnotationAssertionAxiom(i, dccreated),
df.getOWLAnnotationAssertionAxiom(i, dccreator),
df.getOWLAnnotationAssertionAxiom(i, derived));
String s2 = saveOntology(o2, format).toString();
System.out.println("Check.should() " + s2);
Cheers,
I.
On Fri, 17 Jul 2020 at 19:06, Lewis John Mcgibbney
<lew...@gm...> wrote:
>
> OK I have arrived at a satisfactory solution
>
> +:Behavior rdf:type owl:Class ;
> + rdfs:subClassOf :PsychologicalParameter ;
> + rdfs:label "behavior"@en ;
> + skos:definition _:genid1 .
> +
> +_:genid1 dcterms:created "2020-07-17T10:17:18.889"^^xsd:dateTime ;
> + dcterms:creator <https://orcid.org/0000-0003-2185-928X> ;
> + dcterms:source <http://www.wikidata.org/entity/Q9332> ;
> + rdfs:comment "way that one acts in different situations"@en ;
> + prov:wasDerivedFrom <http://www.wikidata.org/entity/Q9332> .
>
> This was achieved as follows
>
> if (wikidataDescription != null) {
> //skos:definition
> val defProp = df.getOWLAnnotationProperty("http://www.w3.org/2004/02/skos/core#definition")
> val skosAnno = df.getOWLAnnotation(defProp, df.getOWLAnonymousIndividual)
> val skosAxiom = df.getOWLAnnotationAssertionAxiom(owlClass.getIRI(), skosAnno)
> changes.add(new AddAxiom(owlOntology, skosAxiom))
> //rdfs:comment
> val commentAnno = df.getOWLAnnotation(
> df.getRDFSComment,
> df.getOWLLiteral(wikidataDescription.get(1)))
> val commentAxiom = df.getOWLAnnotationAssertionAxiom(
> df.getOWLAnnotationProperty("http://www.w3.org/2000/01/rdf-schema#comment"),
> skosAxiom.anonymousIndividualValue().get(), commentAnno.annotationValue())
> changes.add(new AddAxiom(owlOntology, commentAxiom))
> //prov:wasDerivedFrom
> val wdfProp = df.getOWLAnnotationProperty("http://www.w3.org/ns/prov#wasDerivedFrom")
> val provAnno = df.getOWLAnnotation(wdfProp, IRI.create(wikidataDescription.get(0)))
> val provAxiom = df.getOWLAnnotationAssertionAxiom(
> wdfProp, skosAxiom.anonymousIndividualValue().get(), provAnno.annotationValue())
> changes.add(new AddAxiom(owlOntology, provAxiom))
> //dcterms:source
> val sProp = df.getOWLAnnotationProperty("http://purl.org/dc/terms/source")
> val sourceAnno = df.getOWLAnnotation(sProp, IRI.create(wikidataDescription.get(0)))
> val sourceAxiom = df.getOWLAnnotationAssertionAxiom(
> sProp, skosAxiom.anonymousIndividualValue().get(), sourceAnno.annotationValue())
> changes.add(new AddAxiom(owlOntology, sourceAxiom))
> //dcterms:created
> val ldt = LocalDateTime.now();
> val cProp = df.getOWLAnnotationProperty("http://purl.org/dc/terms/created")
> val createdAnno = df.getOWLAnnotation(cProp, df.getOWLLiteral(ldt.toString, OWL2Datatype.XSD_DATE_TIME))
> val createdAxiom = df.getOWLAnnotationAssertionAxiom(
> cProp, skosAxiom.anonymousIndividualValue().get(), createdAnno.annotationValue())
> changes.add(new AddAxiom(owlOntology, createdAxiom))
> //dcterms:creator
> val crProp = df.getOWLAnnotationProperty("http://purl.org/dc/terms/creator")
> val creatorAnno = df.getOWLAnnotation(crProp, IRI.create("https://orcid.org/0000-0003-2185-928X"))
> val creatorAxiom = df.getOWLAnnotationAssertionAxiom(
> crProp, skosAxiom.anonymousIndividualValue().get(), creatorAnno.annotationValue())
> changes.add(new AddAxiom(owlOntology, creatorAxiom))
> }
>
>
> Quite a lot of code and maybe not implemented correctly but it is the only solution I found.
> Lewis
>
>
> On Fri, Jul 17, 2020 at 9:52 AM Lewis John Mcgibbney <lew...@gm...> wrote:
>>
>> Defining the value as an anonymous individual seems to do the trick
>>
>> val skosAnno = df.getOWLAnnotation(df.getOWLAnnotationProperty("http://www.w3.org/2004/02/skos/core#definition"), df.getOWLAnonymousIndividual)
>> val skosAxiom = df.getOWLAnnotationAssertionAxiom(owlClass.getIRI(), skosAnno)
>> changes.add(new AddAxiom(owlOntology, skosAxiom))
>>
>> Which results in the following
>>
>> +:Behavior rdf:type owl:Class ;
>> + rdfs:subClassOf :PsychologicalParameter ;
>> + dcterms:created "2020-07-17T09:46:30.492"^^xsd:dateTime ;
>> + dcterms:creator <https://orcid.org/0000-0003-2185-928X> ;
>> + dcterms:source <http://www.wikidata.org/entity/Q9332> ;
>> + rdfs:comment "way that one acts in different situations@en"@en ;
>> + rdfs:label "behavior"@en ;
>> + skos:definition [ ] ;
>> +prov:wasDerivedFrom <http://www.wikidata.org/entity/Q9332> .
>>
>> Which is an improvement. Now I just need to insert the subsequent annotations into the skos:definition collection.
>>
>>
>> On Fri, Jul 17, 2020 at 9:28 AM Lewis John Mcgibbney <lew...@gm...> wrote:
>>>
>>> Hi Folks,
>>> I am struggling to create the following
>>>
>>> ### http://sweetontology.net/realmCryo/AlpineTundra
>>> soreac:AlpineTundra rdf:type owl:Class ;
>>> rdfs:subClassOf soreac:Tundra ;
>>> rdfs:label "alpine tundra"@en ;
>>> skos:closeMatch <http://purl.obolibrary.org/obo/ENVO_01001371> ;
>>> skos:definition [
>>> rdfs:comment "A tundra ecosystem which exists at high altitudes and where vegetation is stunted due to low temperatures and high winds."@en ;
>>> dcterms:source <https://orcid.org/0000-0003-4808-4736> ;
>>> dcterms:created "2019-12-10T06:11:13-08:00Z"^^xsd:dateTimeStamp ;
>>> dcterms:creator <https://orcid.org/0000-0003-4091-6059> ;
>>> prov:wasDerivedFrom <http://purl.obolibrary.org/obo/ENVO_01001371> ;
>>> ] .
>>>
>>>
>>> I've only got so far
>>>
>>> ### http://sweetontology.net/realmCryo/AlpineTundra
>>> soreac:AlpineTundra rdf:type owl:Class ;
>>> rdfs:subClassOf soreac:Tundra ;
>>> rdfs:label "alpine tundra"@en ;
>>> skos:closeMatch <http://purl.obolibrary.org/obo/ENVO_01001371> ;
>>> rdfs:comment "A tundra ecosystem which exists at high altitudes and where vegetation is stunted due to low temperatures and high winds."@en ;
>>> dcterms:source <https://orcid.org/0000-0003-4808-4736> ;
>>> dcterms:created "2019-12-10T06:11:13-08:00Z"^^xsd:dateTimeStamp ;
>>> dcterms:creator <https://orcid.org/0000-0003-4091-6059> ;
>>> prov:wasDerivedFrom <http://purl.obolibrary.org/obo/ENVO_01001371> ;
>>>
>>> How do I add the skos:definition collection?
>>> I think the issue is with creating the skos Annotation and then applying it to the Class before adding all other axioms to the new skos Annotation.
>>> I've got the following... which doesn't compile.
>>>
>>> val skosAnno = df.getOWLAnnotationProperty("http://www.w3.org/2004/02/skos/core#definition") //this needs to be an Annotation NOT AnnotationProperty
>>> val skosAxiom = df.getOWLAnnotationAssertionAxiom(owlClass.getIRI(), skosAnno)
>>> changes.add(new AddAxiom(owlOntology, skosAxiom))
>>>
>>> Thanks in advance for any pointers.
>>>
>>> --
>>> Lewis
>>> Dr. Lewis J. McGibbney Ph.D, B.Sc
>>> Skype: lewis.john.mcgibbney
>>>
>>>
>>>
>>>
>>>
>>> --
>>> Lewis
>>> Dr. Lewis J. McGibbney Ph.D, B.Sc
>>> Skype: lewis.john.mcgibbney
>>>
>>>
>>>
>>
>>
>> --
>> Lewis
>> Dr. Lewis J. McGibbney Ph.D, B.Sc
>> Skype: lewis.john.mcgibbney
>>
>>
>>
>
>
> --
> Lewis
> Dr. Lewis J. McGibbney Ph.D, B.Sc
> Skype: lewis.john.mcgibbney
>
>
>
> _______________________________________________
> Owlapi-developer mailing list
> Owl...@li...
> https://lists.sourceforge.net/lists/listinfo/owlapi-developer
|
|
From: Lewis J. M. <lew...@gm...> - 2020-07-17 17:33:40
|
OK I have arrived at a satisfactory solution +:Behavior rdf:type owl:Class ; + rdfs:subClassOf :PsychologicalParameter ; + rdfs:label "behavior"@en ; + skos:definition _:genid1 . + +_:genid1 dcterms:created "2020-07-17T10:17:18.889"^^xsd:dateTime ; + dcterms:creator <https://orcid.org/0000-0003-2185-928X> ; + dcterms:source <http://www.wikidata.org/entity/Q9332> ; + rdfs:comment "way that one acts in different situations"@en ; + prov:wasDerivedFrom <http://www.wikidata.org/entity/Q9332> . This was achieved as follows if (wikidataDescription != null) { //skos:definition val defProp = df.getOWLAnnotationProperty("http://www.w3.org/2004/02/skos/core#definition") val skosAnno = df.getOWLAnnotation(defProp, df.getOWLAnonymousIndividual) val skosAxiom = df.getOWLAnnotationAssertionAxiom(owlClass.getIRI(), skosAnno) changes.add(new AddAxiom(owlOntology, skosAxiom)) //rdfs:comment val commentAnno = df.getOWLAnnotation( df.getRDFSComment, df.getOWLLiteral(wikidataDescription.get(1))) val commentAxiom = df.getOWLAnnotationAssertionAxiom( df.getOWLAnnotationProperty("http://www.w3.org/2000/01/rdf-schema#comment"), skosAxiom.anonymousIndividualValue().get(), commentAnno.annotationValue()) changes.add(new AddAxiom(owlOntology, commentAxiom)) //prov:wasDerivedFrom val wdfProp = df.getOWLAnnotationProperty("http://www.w3.org/ns/prov#wasDerivedFrom") val provAnno = df.getOWLAnnotation(wdfProp, IRI.create(wikidataDescription.get(0))) val provAxiom = df.getOWLAnnotationAssertionAxiom( wdfProp, skosAxiom.anonymousIndividualValue().get(), provAnno.annotationValue()) changes.add(new AddAxiom(owlOntology, provAxiom)) //dcterms:source val sProp = df.getOWLAnnotationProperty("http://purl.org/dc/terms/source") val sourceAnno = df.getOWLAnnotation(sProp, IRI.create(wikidataDescription.get(0))) val sourceAxiom = df.getOWLAnnotationAssertionAxiom( sProp, skosAxiom.anonymousIndividualValue().get(), sourceAnno.annotationValue()) changes.add(new AddAxiom(owlOntology, sourceAxiom)) //dcterms:created val ldt = LocalDateTime.now(); val cProp = df.getOWLAnnotationProperty("http://purl.org/dc/terms/created") val createdAnno = df.getOWLAnnotation(cProp, df.getOWLLiteral(ldt.toString, OWL2Datatype.XSD_DATE_TIME)) val createdAxiom = df.getOWLAnnotationAssertionAxiom( cProp, skosAxiom.anonymousIndividualValue().get(), createdAnno.annotationValue()) changes.add(new AddAxiom(owlOntology, createdAxiom)) //dcterms:creator val crProp = df.getOWLAnnotationProperty("http://purl.org/dc/terms/creator") val creatorAnno = df.getOWLAnnotation(crProp, IRI.create("https://orcid.org/0000-0003-2185-928X")) val creatorAxiom = df.getOWLAnnotationAssertionAxiom( crProp, skosAxiom.anonymousIndividualValue().get(), creatorAnno.annotationValue()) changes.add(new AddAxiom(owlOntology, creatorAxiom)) } Quite a lot of code and maybe not implemented correctly but it is the only solution I found. Lewis On Fri, Jul 17, 2020 at 9:52 AM Lewis John Mcgibbney < lew...@gm...> wrote: > Defining the value as an anonymous individual seems to do the trick > > val skosAnno = df.getOWLAnnotation(df.getOWLAnnotationProperty("http://www.w3.org/2004/02/skos/core#definition"), df.getOWLAnonymousIndividual) > val skosAxiom = df.getOWLAnnotationAssertionAxiom(owlClass.getIRI(), skosAnno) > changes.add(new AddAxiom(owlOntology, skosAxiom)) > > Which results in the following > > +:Behavior rdf:type owl:Class ; > + rdfs:subClassOf :PsychologicalParameter ; > + dcterms:created "2020-07-17T09:46:30.492"^^xsd:dateTime ; > + dcterms:creator <https://orcid.org/0000-0003-2185-928X> ; > + dcterms:source <http://www.wikidata.org/entity/Q9332> ; > + rdfs:comment "way that one acts in different situations@en"@en ; > + rdfs:label "behavior"@en ; > + skos:definition [ ] ; > +prov:wasDerivedFrom <http://www.wikidata.org/entity/Q9332> . > > Which is an improvement. Now I just need to insert the subsequent annotations into the skos:definition collection. > > > On Fri, Jul 17, 2020 at 9:28 AM Lewis John Mcgibbney < > lew...@gm...> wrote: > >> Hi Folks, >> I am struggling to create the following >> >> ### http://sweetontology.net/realmCryo/AlpineTundra >> soreac:AlpineTundra rdf:type owl:Class ; >> rdfs:subClassOf soreac:Tundra ; >> rdfs:label "alpine tundra"@en ; >> skos:closeMatch <http://purl.obolibrary.org/obo/ENVO_01001371> ; >> skos:definition [ >> rdfs:comment "A tundra ecosystem which exists at high altitudes and where vegetation is stunted due to low temperatures and high winds."@en ; >> dcterms:source <https://orcid.org/0000-0003-4808-4736> ; >> dcterms:created "2019-12-10T06:11:13-08:00Z"^^xsd:dateTimeStamp ; >> dcterms:creator <https://orcid.org/0000-0003-4091-6059> ; >> prov:wasDerivedFrom <http://purl.obolibrary.org/obo/ENVO_01001371> ; >> ] . >> >> >> I've only got so far >> >> ### http://sweetontology.net/realmCryo/AlpineTundra >> soreac:AlpineTundra rdf:type owl:Class ; >> rdfs:subClassOf soreac:Tundra ; >> rdfs:label "alpine tundra"@en ; >> skos:closeMatch <http://purl.obolibrary.org/obo/ENVO_01001371> ; >> rdfs:comment "A tundra ecosystem which exists at high altitudes and where vegetation is stunted due to low temperatures and high winds."@en ; >> dcterms:source <https://orcid.org/0000-0003-4808-4736> ; >> dcterms:created "2019-12-10T06:11:13-08:00Z"^^xsd:dateTimeStamp ; >> dcterms:creator <https://orcid.org/0000-0003-4091-6059> ; >> prov:wasDerivedFrom <http://purl.obolibrary.org/obo/ENVO_01001371> ; >> >> How do I add the skos:definition collection? >> I think the issue is with creating the skos Annotation and then applying >> it to the Class before adding all other axioms to the new skos Annotation. >> I've got the following... which doesn't compile. >> >> val skosAnno = df.getOWLAnnotationProperty("http://www.w3.org/2004/02/skos/core#definition") //this needs to be an Annotation NOT AnnotationProperty >> val skosAxiom = df.getOWLAnnotationAssertionAxiom(owlClass.getIRI(), skosAnno) >> changes.add(new AddAxiom(owlOntology, skosAxiom)) >> >> Thanks in advance for any pointers. >> >> -- >> >> *Lewis* >> Dr. Lewis J. McGibbney Ph.D, B.Sc >> *Skype*: lewis.john.mcgibbney >> >> >> >> >> >> -- >> >> *Lewis* >> Dr. Lewis J. McGibbney Ph.D, B.Sc >> *Skype*: lewis.john.mcgibbney >> >> >> >> > > -- > > *Lewis* > Dr. Lewis J. McGibbney Ph.D, B.Sc > *Skype*: lewis.john.mcgibbney > > > > -- *Lewis* Dr. Lewis J. McGibbney Ph.D, B.Sc *Skype*: lewis.john.mcgibbney |
|
From: Lewis J. M. <lew...@gm...> - 2020-07-17 16:52:36
|
Defining the value as an anonymous individual seems to do the trick
val skosAnno = df.getOWLAnnotation(df.getOWLAnnotationProperty("http://www.w3.org/2004/02/skos/core#definition"),
df.getOWLAnonymousIndividual)
val skosAxiom = df.getOWLAnnotationAssertionAxiom(owlClass.getIRI(), skosAnno)
changes.add(new AddAxiom(owlOntology, skosAxiom))
Which results in the following
+:Behavior rdf:type owl:Class ;
+ rdfs:subClassOf :PsychologicalParameter ;
+ dcterms:created "2020-07-17T09:46:30.492"^^xsd:dateTime ;
+ dcterms:creator <https://orcid.org/0000-0003-2185-928X> ;
+ dcterms:source <http://www.wikidata.org/entity/Q9332> ;
+ rdfs:comment "way that one acts in different situations@en"@en ;
+ rdfs:label "behavior"@en ;
+ skos:definition [ ] ;
+prov:wasDerivedFrom <http://www.wikidata.org/entity/Q9332> .
Which is an improvement. Now I just need to insert the subsequent
annotations into the skos:definition collection.
On Fri, Jul 17, 2020 at 9:28 AM Lewis John Mcgibbney <
lew...@gm...> wrote:
> Hi Folks,
> I am struggling to create the following
>
> ### http://sweetontology.net/realmCryo/AlpineTundra
> soreac:AlpineTundra rdf:type owl:Class ;
> rdfs:subClassOf soreac:Tundra ;
> rdfs:label "alpine tundra"@en ;
> skos:closeMatch <http://purl.obolibrary.org/obo/ENVO_01001371> ;
> skos:definition [
> rdfs:comment "A tundra ecosystem which exists at high altitudes and where vegetation is stunted due to low temperatures and high winds."@en ;
> dcterms:source <https://orcid.org/0000-0003-4808-4736> ;
> dcterms:created "2019-12-10T06:11:13-08:00Z"^^xsd:dateTimeStamp ;
> dcterms:creator <https://orcid.org/0000-0003-4091-6059> ;
> prov:wasDerivedFrom <http://purl.obolibrary.org/obo/ENVO_01001371> ;
> ] .
>
>
> I've only got so far
>
> ### http://sweetontology.net/realmCryo/AlpineTundra
> soreac:AlpineTundra rdf:type owl:Class ;
> rdfs:subClassOf soreac:Tundra ;
> rdfs:label "alpine tundra"@en ;
> skos:closeMatch <http://purl.obolibrary.org/obo/ENVO_01001371> ;
> rdfs:comment "A tundra ecosystem which exists at high altitudes and where vegetation is stunted due to low temperatures and high winds."@en ;
> dcterms:source <https://orcid.org/0000-0003-4808-4736> ;
> dcterms:created "2019-12-10T06:11:13-08:00Z"^^xsd:dateTimeStamp ;
> dcterms:creator <https://orcid.org/0000-0003-4091-6059> ;
> prov:wasDerivedFrom <http://purl.obolibrary.org/obo/ENVO_01001371> ;
>
> How do I add the skos:definition collection?
> I think the issue is with creating the skos Annotation and then applying
> it to the Class before adding all other axioms to the new skos Annotation.
> I've got the following... which doesn't compile.
>
> val skosAnno = df.getOWLAnnotationProperty("http://www.w3.org/2004/02/skos/core#definition") //this needs to be an Annotation NOT AnnotationProperty
> val skosAxiom = df.getOWLAnnotationAssertionAxiom(owlClass.getIRI(), skosAnno)
> changes.add(new AddAxiom(owlOntology, skosAxiom))
>
> Thanks in advance for any pointers.
>
> --
>
> *Lewis*
> Dr. Lewis J. McGibbney Ph.D, B.Sc
> *Skype*: lewis.john.mcgibbney
>
>
>
>
>
> --
>
> *Lewis*
> Dr. Lewis J. McGibbney Ph.D, B.Sc
> *Skype*: lewis.john.mcgibbney
>
>
>
>
--
*Lewis*
Dr. Lewis J. McGibbney Ph.D, B.Sc
*Skype*: lewis.john.mcgibbney
|
|
From: Lewis J. M. <lew...@gm...> - 2020-07-17 16:29:26
|
Hi Folks, I am struggling to create the following ### http://sweetontology.net/realmCryo/AlpineTundra soreac:AlpineTundra rdf:type owl:Class ; rdfs:subClassOf soreac:Tundra ; rdfs:label "alpine tundra"@en ; skos:closeMatch <http://purl.obolibrary.org/obo/ENVO_01001371> ; skos:definition [ rdfs:comment "A tundra ecosystem which exists at high altitudes and where vegetation is stunted due to low temperatures and high winds."@en ; dcterms:source <https://orcid.org/0000-0003-4808-4736> ; dcterms:created "2019-12-10T06:11:13-08:00Z"^^xsd:dateTimeStamp ; dcterms:creator <https://orcid.org/0000-0003-4091-6059> ; prov:wasDerivedFrom <http://purl.obolibrary.org/obo/ENVO_01001371> ; ] . I've only got so far ### http://sweetontology.net/realmCryo/AlpineTundra soreac:AlpineTundra rdf:type owl:Class ; rdfs:subClassOf soreac:Tundra ; rdfs:label "alpine tundra"@en ; skos:closeMatch <http://purl.obolibrary.org/obo/ENVO_01001371> ; rdfs:comment "A tundra ecosystem which exists at high altitudes and where vegetation is stunted due to low temperatures and high winds."@en ; dcterms:source <https://orcid.org/0000-0003-4808-4736> ; dcterms:created "2019-12-10T06:11:13-08:00Z"^^xsd:dateTimeStamp ; dcterms:creator <https://orcid.org/0000-0003-4091-6059> ; prov:wasDerivedFrom <http://purl.obolibrary.org/obo/ENVO_01001371> ; How do I add the skos:definition collection? I think the issue is with creating the skos Annotation and then applying it to the Class before adding all other axioms to the new skos Annotation. I've got the following... which doesn't compile. val skosAnno = df.getOWLAnnotationProperty("http://www.w3.org/2004/02/skos/core#definition") //this needs to be an Annotation NOT AnnotationProperty val skosAxiom = df.getOWLAnnotationAssertionAxiom(owlClass.getIRI(), skosAnno) changes.add(new AddAxiom(owlOntology, skosAxiom)) Thanks in advance for any pointers. -- *Lewis* Dr. Lewis J. McGibbney Ph.D, B.Sc *Skype*: lewis.john.mcgibbney -- *Lewis* Dr. Lewis J. McGibbney Ph.D, B.Sc *Skype*: lewis.john.mcgibbney |
|
From: Ignazio P. <ipa...@gm...> - 2020-07-02 12:28:57
|
Hi all OWLAPI 4.5.17 and 5.1.15 have been released today. A number of bug fixes included. Cheers, Ignazio |
|
From: Ignazio P. <ipa...@gm...> - 2019-10-20 16:51:30
|
Hi all, new releases available on Maven Central. Bug fixes only. Cheers, Ignazio |
|
From: Ignazio P. <ipa...@gm...> - 2019-06-03 06:14:16
|
Hi all, new releases available on Maven central. These are maintenance releases, containing a number of bug fixes, including updates to most recent Jackson libraries, to remove security vulnerabilities. Cheers, Ignazio |
|
From: Wynne, R. (NIH/NLM/L. [C] <wy...@ma...> - 2019-02-06 17:58:46
|
Hi all, [Apologies for cross-posting; not sure if this a Protégé/owlapi/ELK question.] I am working with a pre-existing ontology in EL++ with multiple defined classes. I used the owlapi to add more classes in the same namespace with definitions equivalent to one or more of the existing defined classes. After running the ELK reasoner, and switching to the Inferred hierarchy view, these identical classes are properly displayed such as ‘A ≡<https://en.wikipedia.org/wiki/%E2%89%A1_(disambiguation)> B’. [1] How would I use Protégé, or the owlapi, to report these? I have tried the following.. owlapi with the ELK 0.50 reasoner: for( OWLClass cls : reasoner.getSubClasses(rootClass, false).entities().collect((Collectors.toSet())) ) { for( OWLClass eqClass : reasoner.getEquivalentClasses(cls).getEntitiesMinus(cls) ) { //without minus this only seems to return cls System.out.println(eqClass.getIRI().toString() + " equivalent to " + cls.getIRI().toString()); } } Also (in hopes of generating an inferred OWL to work with): ArrayList<InferredAxiomGenerator<? extends OWLAxiom>> gens = new ArrayList<InferredAxiomGenerator<? extends OWLAxiom>>(); gens.add(new InferredSubClassAxiomGenerator()); gens.add(new InferredEquivalentClassAxiomGenerator()); System.out.println("Instantiating InferredOntologyGenerator.."); InferredOntologyGenerator iog = new InferredOntologyGenerator(reasoner, gens); System.out.println("Filling new ontology with inferred axioms.."); iog.fillOntology(outputOntologyManager.getOWLDataFactory(), infOnt); System.out.println("Saving new ontology with inferred axioms.."); outputOntologyManager.saveOntology(infOnt, IRI.create((new File("./RxNorm2Snomed_DRAFT_Inf.owl").toURI()))); (Though this resulted in an ontology less than half the size of the unmodified original.) I have traced through some Protégé classes, such as InferredOWLClassHierarchyProvider. Method getEquivalents seems to make the same call, though does this use ELK or the included StructuralReasoner? Would I need to somehow refresh ELK after the new classes are added? [1] [cid:image001.gif@01D4BE19.1BB95E60] Thanks! Rob |
|
From: Ignazio P. <ipa...@gm...> - 2018-12-02 22:36:28
|
Hi all, maintenance releases now available on Maven Central. Cheers, Ignazio |
|
From: Ignazio P. <ipa...@gm...> - 2018-08-20 22:45:04
|
Looks like a multithread problem in some internal Pellet cache. Have you tried Openllet? A number of multithread bugs has been fixed in its code base in the last few months. Cheers, Ignazio On Mon, 20 Aug 2018 at 22:52, Jens Pelzetter via Owlapi-developer <owl...@li...> wrote: > > Hello everyone, > > I'm using Pellet and the OWLAPI (version 4) in a web application. The > web application provides access to an ontology via a RESTful API and is > build with CDI, EJB and JAX-RS. > > When I send requests manually to the web service (via the HTTPie tool) > everything is fine. But one of the applications sends in large number of > requests in a short time. More exactly it retrieves some individiuals, > looks on some object properties and retrieves these individuals and so > one. This causes strange exceptions in Pellet. An example is attached. > > The same request which causes the exceptions works another time without > problems when executed manually. But then an another may fail with a > similar exception. And sometimes all requests work without problems. > > At the moment I'm able to work around this problem by delaying the > creation of the requests in the client. > > The resoner itself is encapsulated in a Singleton EJB bean which is used > by several other CDI beans to access the reasoner. > > The OWLOntologyManager instance used in the application is also managed > by the EJB bean and is created using > > OWLManager.createConcurrentOWLOntologyManager() > > Has anybody experienced similar problems and might have some suggestion > solve this? > > Best regards > > Jens Pelzetter > > > > ------------------------------------------------------------------------------ > Check out the vibrant tech community on one of the world's most > engaging tech sites, Slashdot.org! http://sdm.link/slashdot_______________________________________________ > Owlapi-developer mailing list > Owl...@li... > https://lists.sourceforge.net/lists/listinfo/owlapi-developer |
|
From: Michael S. <Mic...@ut...> - 2018-08-20 21:57:27
|
> > > First thing, ensure you're not adding each element of the disjunct > > > as equivalent to each other element, but only one other conjunct. > > > If you have five conjuncts, you should have four axioms: > > > Equivalent(A1, A2...A5)= > > > Equivalent(A1,A2) > > > Equivalent(A2,A3) > > > Equivalent(A3,A4) > > > Equivalent(A4,A5) > > > (What I did landed me with twenty axioms instead, for this example) > > > > I have yet to try this because I find a workaround that makes the original > procedure potentially unnecessary. > > > > However I seem to be having a similar problem that I can't pin down. > When I reason over my ontology and save it out with the inferred axioms as > asserted, and I then try to reason over that ontology just as an experiment, I > expect it to finish in a second because it's already reasoned. But, to my > surprise, the reasoner struggles and takes a very long time (too long for me > to wait to finish). Do you have any idea what might be causing this? > > > > It's difficult to guess exactly what the reason is - I've seen this in the past for > more than one reasoner. My best guess is that part of the problem is the > same phenomenon described above - the materialised inferences are the > same as the pairwise equivalent axioms. > > The reasoner does not know in advance that the extra axioms are inferred > from the original ontology, and it has to treat them all as if they were > asserted axioms, as well - this can make some of the initial operations much > harder, for example absorption (the removal of redundant parts of the > ontology and the substitution of certain complex axioms with equivalent, > simplified form). Absorption is essential to reasoning speed - I have reasoner > developers friends telling me absorption algorithms might be the secret > sauce separating the fastest reasoners from the rest of the pack. > That's very interesting to know, thanks. For what it's worth, I tried using both JFact and FaCT++ and they both ground to a halt. |