在OWL

时间:2018-06-02 15:07:47

标签: rdf owl ontology

我有一个本体论,代表了我对职业和教育学位的看法。该模型在视觉上表示如下:

datamodel

作为我的本体论的一部分,我想将学位建模为职业"途径"每个学位(如上图所示)。以下是我试图描述的几个例子:

  • 如果我获得计算机科学学士学位,我可以成为任何类型的软件开发人员(包括Web Developer,它是软件开发人员的子类)。
  • 如果我获得护理学位,我可以成为任何类型的护士,但不能成为护士经理。

到目前为止,这是我的本体论:

@prefix : <http://www.test.org/jobs#> .
@prefix owl: <http://www.w3.org/2002/07/owl#> .
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix xml: <http://www.w3.org/XML/1998/namespace> .
@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@base <http://www.test.org/jobs> .

<http://www.test.org/jobs> rdf:type owl:Ontology .

:hasEducationLevel rdf:type owl:ObjectProperty ;
                   rdfs:domain :Degree ;
                   rdfs:range :EducationLevel .

:hasOccupation rdf:type owl:ObjectProperty ;
               rdfs:domain :Job ;
               rdfs:range :Occupation .

:programOfStudy rdf:type owl:ObjectProperty ;
                rdfs:domain :Degree ;
                rdfs:range :ProgramOfStudy .

:requiresEducation rdf:type owl:ObjectProperty ;
                   rdfs:domain :Job ;
                   rdfs:range :Degree .

:title rdf:type owl:DatatypeProperty ;
       rdfs:domain :Job ;
       rdfs:range xsd:string .

:Accounting rdf:type owl:Class ;
            rdfs:subClassOf :Finance .

:Audit rdf:type owl:Class ;
       rdfs:subClassOf :Finance .

:BachelorsDegree rdf:type owl:Class ;
                 owl:equivalentClass [ owl:intersectionOf ( :Degree
                                                            [ rdf:type owl:Restriction ;
                                                              owl:onProperty :hasEducationLevel ;
                                                              owl:hasValue :BachelorsEducationLevel
                                                            ]
                                                          ) ;
                                       rdf:type owl:Class
                                     ] .

:Computer_Science rdf:type owl:Class ;
                  rdfs:subClassOf :ProgramOfStudy .

:Degree rdf:type owl:Class .

:EducationLevel rdf:type owl:Class .

:Finance rdf:type owl:Class ;
         rdfs:subClassOf :ProgramOfStudy .

:Job rdf:type owl:Class .

:Licensed_Practical_Nurse rdf:type owl:Class ;
                          rdfs:subClassOf :Nurse .

:MastersDegree rdf:type owl:Class ;
               owl:equivalentClass [ owl:intersectionOf ( :Degree
                                                          [ rdf:type owl:Restriction ;
                                                            owl:onProperty :hasEducationLevel ;
                                                            owl:hasValue :MastersEducationLevel
                                                          ]
                                                        ) ;
                                     rdf:type owl:Class
                                   ] .

:Mobile_Developer rdf:type owl:Class ;
                  rdfs:subClassOf :Software_Developer .

:Nurse rdf:type owl:Class ;
       rdfs:subClassOf :Nursing_Occupation .

:Nurse_Manager rdf:type owl:Class ;
               rdfs:subClassOf :Nursing_Occupation .

:Nursing rdf:type owl:Class ;
         rdfs:subClassOf :ProgramOfStudy .

:NursingDegree rdf:type owl:Class ;
               owl:equivalentClass [ owl:intersectionOf ( :Degree
                                                          [ rdf:type owl:Restriction ;
                                                            owl:onProperty :programOfStudy ;
                                                            owl:someValuesFrom :Nursing
                                                          ]
                                                        ) ;
                                     rdf:type owl:Class
                                   ] .

:Nursing_Occupation rdf:type owl:Class ;
                    rdfs:subClassOf :Occupation .

:Occupation rdf:type owl:Class .

:ProgramOfStudy rdf:type owl:Class .

:Registered_Nurse rdf:type owl:Class ;
                  rdfs:subClassOf :Nurse .

:Software_Developer rdf:type owl:Class ;
                    rdfs:subClassOf :Occupation .

:Web_Developer rdf:type owl:Class ;
               rdfs:subClassOf :Software_Developer .

:BachelorsEducationLevel rdf:type owl:NamedIndividual ,
                                  :EducationLevel .

:MastersEducationLevel rdf:type owl:NamedIndividual ,
                                :EducationLevel .

我考虑过使用对象属性和个人,但我不确定如何在指定单个对象属性的值时实现我想要的泛化。 / p>

有人可以就如何将这些程度模拟为OWL中的职业途径提出建议吗?谢谢。

1 个答案:

答案 0 :(得分:0)

如果Software developer是CS学位的兼容职业等级的顶层,那么你就断言

Software developer subClassOf存在hasDegree CS degree

要阻止Nurse manager只需要Nursing degree(我怀疑他们需要某种管理课程吗?),你可以做类似的事情:

Nurse manager subClassOf存在hasDegree Management role

现在,没有这种学位的个人将不被归类为Nurse manager(潜在)。但是,如果你断言他们是护士经理,那么系统就不会抱怨。