简体   繁体   English

RDFS与owl:equivalentClass类似吗?

[英]RDFS analogue to owl:equivalentClass?

I have triples that say patient P participates in health care encounter E which has output M , a drug prescription. 我有三元组,表示患者P参加医疗保健遭遇会E ,该医疗会输出药物处方M Prescriptions can mention a drug from the Drug Ontology, or DrOn. 处方可以mention药物本体论或DrOn中的药物。

In this case, let's say that M1 mentions the cholesterol-lowering medication atorvastatin, which was imported into DrOn from ChEBI as http://purl.obolibrary.org/obo/CHEBI_39548 : 在这种情况下,假设M1提到了降胆固醇药物阿托伐他汀,该药物是从ChEBI导入DrOn的, 网址http://purl.obolibrary.org/obo/CHEBI_39548

prefix obo: <http://purl.obolibrary.org/obo/> :M1 obo:IAO_0000142 obo:CHEBI_39548 .

ChEBI has an axiom that obo:CHEBI_39548 has the role http://purl.obolibrary.org/obo/CHEBI_35821 , "anticholesteremic drug". ChEBI有一个公理,obo:CHEBI_39548的角色为http://purl.obolibrary.org/obo/CHEBI_35821 ,“抗胆固醇药”。 That makes it easy to find patients who have been prescribed atorvastatin, or other drugs with the same role. 这样可以很容易地找到接受阿托伐他汀或其他具有相同作用的药物的患者。

Unfortunately, DrOn created its own terms for some drugs instead of importing them from ChEBI. 不幸的是,DrOn为某些药物创建了自己的术语,而不是从ChEBI导入它们。 For example, another cholesterol-lowering drug, rosuvastatin, is modeled as http://purl.obolibrary.org/obo/DRON_00018679 instead of http://purl.obolibrary.org/obo/CHEBI_38545 . 例如,另一种降低胆固醇的药物罗舒伐他汀被建模为http://purl.obolibrary.org/obo/DRON_00018679而不是http://purl.obolibrary.org/obo/CHEBI_38545 ChEBI's term for rosuvastatin is also annotated with the role obo:CHEBI_39548, but obo:DRON_00018679 is not. ChEBI的瑞舒伐他汀一词也带有obo:CHEBI_39548的角色,但没有obo:DRON_00018679的角色。 So patients in my dataset who were prescribed rosuvastatin do not show up in my existing role-based query. 因此,在我的数据集中开了瑞舒伐他汀的患者不会出现在我现有的基于角色的查询中。

I have these data in a GraphDB RDFS-plus repository, and I'd prefer not to change the reasoning level right now. 我将这些数据保存在GraphDB RDFS-plus存储库中,并且我现在不希望更改推理级别。 If it was an OWL repository, I would just say 如果它是一个OWL存储库,我会说

obo:CHEBI_38545 owl:equivalentClass obo:DRON_00018679

Is there something similar I can do with RDFS, or a GraphDB custom ruleset? 我可以使用RDFS或GraphDB自定义规则集执行类似的操作吗?

If it was an OWL repository, I would just say 如果它是一个OWL存储库,我会说

obo:CHEBI_38545 owl:equivalentClass obo:DRON_00018679

Is there something similar I can do with RDFS, or a GraphDB custom ruleset? 我可以使用RDFS或GraphDB自定义规则集执行类似的操作吗?

First 第一

You obviously can replace owl:equivalentClass with two reciprocal rdfs:subClassOf . 您显然可以用两个倒数的rdfs:subClassOf代替owl:equivalentClass As for the very equivalence of these formulations, I suppose this is relevant: 至于这些公式的等效性,我认为这是相关的:

Second 第二

owl:equivalentClass is already within RDFS-Plus. owl:equivalentClass已经在RDFS-Plus中。

From chapter 7 of the 1st edition of Semantic Web for the Working Ontologist , where RDFS-Plus was first introduced: 从第一版面向工作本体语义网的第7章中,首次引入RDFS-Plus:

RDFS-Plus provides a more intuitive expression of class equivalence, using the construct owl:equivalentClass . RDFS-Plus使用结构owl:equivalentClass提供了更直观的类等效表达。

In GraphDB, the RDFS-Plus and RDFS-Plus (Optimized) rulesets support owl:equivalentClass . 在GraphDB中, RDFS-PlusRDFS-Plus(优化)规则集支持owl:equivalentClass There are the following rule in the builtin_rdfsPlus-optimized.pie file: builtin_rdfsPlus-optimized.pie文件中包含以下规则:

Id: owl_EquivClassBySubClass

  a <rdfs:subClassOf> b [Constraint b != a]
  b <rdfs:subClassOf> a [Cut]
------------------------------------
  a <owl:equivalentClass> b

and the following axioms: 以及以下公理:

<owl:equivalentClass> <rdf:type> <owl:TransitiveProperty>
<owl:equivalentClass> <rdf:type> <owl:SymmetricProperty>
<owl:equivalentClass> <rdfs:subPropertyOf> <rdfs:subClassOf>

In higher profiles, two rules are used instead: 在更高的配置文件中,使用两个规则代替:

Id: scm_eqc1
  c1 <owl:equivalentClass> c2            [Constraint c1 != c2 ]
  -------------------------------
  c1 <rdfs:subClassOf> c2
  c2 <rdfs:subClassOf> c1

Id: scm_eqc2
  c1 <rdfs:subClassOf> c2                [Constraint c1 != c2 ]
  c2 <rdfs:subClassOf> c1                
  -------------------------------
  c1 <owl:equivalentClass> c2

When I use @StanislavKralin's reciprocal rdfs:subClassOf appraoch in an RDFS+ GraphDB repo... 当我在RDFS + GraphDB存储库中使用@StanislavKralin的对等rdfs:subClassOf方法时...

  • inserting some triples about classes :x and :y , with instance :z of class :x 插入有关类:x:y三元组,以及类:x实例:z
  • asserting that :x and :y are subclasses of one another 断言:x:y是彼此的子类

PREFIX owl: <http://www.w3.org/2002/07/owl#> PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#> prefix : <http://localhost/> insert data { :xa owl:Class . :ya owl:Class . :za :x . :x rdfs:subClassOf :y . :y rdfs:subClassOf :x . }

Then query for all triples about :x , :y , and :z 然后查询有关:x:y:z所有三元组

select * where { ?s ?p ?o . filter(regex(str(?s), "localhost")) } order by ?s ?p ?o

I get the owl:equivalentClass for free! 我免费获得owl:equivalentClass

+----+---------------------+-----------+ | s | p | o | +----+---------------------+-----------+ | :x | rdf:type | owl:Class | | :x | rdfs:subClassOf | :x | | :x | rdfs:subClassOf | :y | | :x | owl:equivalentClass | :x | | :x | owl:equivalentClass | :y | | :y | rdf:type | owl:Class | | :y | rdfs:subClassOf | :x | | :y | rdfs:subClassOf | :y | | :y | owl:equivalentClass | :x | | :y | owl:equivalentClass | :y | | :z | rdf:type | :x | | :z | rdf:type | :y | +----+---------------------+-----------+

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM