Help:基本成员属性
此页简而言之:
|
前言
本页面旨在解释 隶属于 (P31)、上级分类 (P279)和所属实体 (P361) 三者的属性。在厘清三者的差异之前,首先我们要了解“个例”(instance)和“分类”(class)这两个专用名词。
定义
To understand the differences, it is important to be familiar with the terms instance and class. A class is an abstraction that describes a set (or collection) of things, called its instances. Typically, all the instances belonging to a class share a set of properties, which properties characterize the class.
If all the instances of class A necessarily also belong to class B, then we say A is a subclass of B.
示例
- 分类人类(Q5)包含亚伯拉罕·林肯(Q91)、圣雄甘地(Q1001)、艾萨克·牛顿(Q935)等实例。
- 分类灯塔(Q39715)包含Amrum Lighthouse (Q20669)、亚历山大灯塔(Q43244)等实例。
- 分类海洋(Q9430)包含大西洋(Q97)、太平洋(Q98)等实例。
- 分类选举(Q40231)包含2016年中华民国总统选举(Q20683626)等实例。
实作层面
- 每一个项目可以是个例,也可以是分类,也可能两者皆是。如果项目有 隶属于 (P31) 属性则是例。如果项目的值与其他项目的 隶属于 (P31) 有关联则是分类,(或者有 上级分类 (P279) 属性)。例如说,安格拉·默克尔(Q567)是政治人物(Q82955)的例,所以政治人物(Q82955)既是例也是分类。
- 完整由分类定义的例也许在维基数据上存在或是不存在
- 一般来说,分类的性质会由所有的例整合而成,例则会由其值来区别,而非自身拥有属性 (然而在维基数据这边并不强制)。
The relation between instances with a common feature and a class characterized by this feature is produced with the property 隶属于 (P31). We use 隶属于 (P31) instead of 上级分类 (P279) when we cannot say anything about instances with such relation. More specifically, it is an rdf:type.[1]
- Is used to state that all the instances of one class are instances of another[2]
- More specifically, it is an rdfs:subClassOf[3]
- If any instances of the subject class are not instances of the value class, 上级分类 (P279) is not appropriate. 部分重合物 (P1382) may be used to link overlapping classes where neither is a strict subclass of the other.
一些例子:
- 人脑(Q492038) 上级分类 (P279) 脑(Q1073)
- 脑(Q1073) 上级分类 (P279) 动物器官(Q24060765)
- 动物器官(Q24060765) 上级分类 (P279) 器官(Q712378)
另一个例子:
A lake and an ocean are not the same but all their instances share the common feature of being a body of water. Therefore we can use the class 水体(Q15324) to state that:
Now 贝加尔湖(Q5513), 伊利湖(Q5492), 大西洋(Q97) and 太平洋(Q98) will all be transitive (indirect) instances of 水体(Q15324). In general we can use more abstract objects (like 水体(Q15324)) instead of enumerations (湖泊(Q23397) and 海洋(Q9430)) both: 1. in our statements and 2. in our questions (not covered at this help page).
过渡性属性
The property 上级分类 (P279) is a 传递属性(Q18647515). This means: if a class A is a subclass of class B, and B is a subclass of class C, then A is implicitly also a subclass of C. There is then no general need to add an explicit statement to Wikidata declaring A to be a subclass of C.
For example, 树(Q10884) is a subclass of 木本植物(Q757163), and 木本植物(Q757163) is a subclass of 植物(Q756). Thus 树(Q10884) is implicitly also a subclass of 植物(Q756).
Similarly, if item x is an instance of class B, and B is a subclass of class C, then x is implicitly also an instance of C. There is then no general need to add an explicit statement to Wikidata declaring x to be an instance of C.
For example, 亚历山大灯塔(Q43244) is an instance of 灯塔(Q39715) and 灯塔(Q39715) is a subclass of 塔式建筑(Q12518). 亚历山大灯塔(Q43244) is thus an instance of 塔式建筑(Q12518).
The property 隶属于 (P31) is not transitive. Considering the example from above: 安格拉·默克尔(Q567) is an instance of 政治人物(Q82955), and 政治人物(Q82955) is an instance of 专业(Q28640), but it would be incorrect to say that 安格拉·默克尔(Q567) is an instance of 专业(Q28640).
Inferences based on transitivity do not take qualifiers into account, so 隶属于 (P31) and 上级分类 (P279) statements must be valid while ignoring any qualifiers; in other words, these statements should not have any 限制性修饰符(Q61719275), or any qualifier that is being used restrictively. For example, if A is often, but not always, a subclass of B, then it is not valid to state that A is a subclass of B with 声明状态 (P5102) = 经常(Q28962312), because this will lead to false inferences.
Items cannot be an instance of another non-class, but they can be part of another non-class. For example, 阿尔伯特·爱因斯坦的大脑(Q2464312) is a part of 阿尔伯特·爱因斯坦(Q937). On Wikidata we use 所属实体 (P361) for this relation.
类还可以是另一个类的一部分。例如,
The use of 隶属于 (P31) instead of 所属实体 (P361) would be wrong here because 人脑(Q492038) is not a person. Using 上级分类 (P279) would also be wrong because an instance of 人脑(Q492038) (e.g. 阿尔伯特·爱因斯坦的大脑(Q2464312)) is not an instance of the class 智人(Q15978631).
Like 上级分类 (P279), 所属实体 (P361) is a transitive property.
Inverse relations of 所属实体 (P361)
- 可分为 (P527) - is used to say that an instance has as part some other instance or that instances of a class have as part an instance of some other class
- 拥有此类别的一部分 (P2670) - is used to say that an instance (never a class) has as part an instance of a class. If the parent item is both an instance and a class, 拥有此类别的一部分 (P2670) should not be used.
例如,
- 希腊字母(Q8216) 可分为 (P527) Α(Q9887) (例-例)
- 全音素文字(Q9779) 可分为 (P527) 字母(Q9788) (分类-分类)
- 希腊字母(Q8216) 拥有此类别的一部分 (P2670) 希腊语字母(Q19793459) (例-分类)
In the first example, 可分为 (P527) is used because 希腊字母(Q8216) has as part Α(Q9887). 可分为 (P527) is also used in the second example because instances of 全音素文字(Q9779) have instances of 字母(Q9788) as parts. In the last example, we take 拥有此类别的一部分 (P2670) since 希腊字母(Q8216) has one or more instances of 希腊语字母(Q19793459) as parts.
示例
隶属于 (P31) vs. 上级分类 (P279) vs. 所属实体 (P361)
属性 | X | Y | 表示什么 | 例子 | 说明 | 不适用的时机 |
---|---|---|---|---|---|---|
<X> 隶属于 <Y> | 个例 | 分类 |
|
<尼米兹号航空母舰> 隶属于 <超级航空母舰> | <USS Nimitz> is a single concrete aircraft carrier, <supercarrier> is an aircraft carrier class which has many instances (aircraft carriers) |
|
<中华人民共和国> 隶属于 <主权国家> | <主权国家>是根据某些特性定义的一个概念,<中国>是一个符合这些特性的具体对象 |
| ||||
<太阳> 隶属于 <G型主序星> | The <Sun> is a specific star with the spectral characteristics of a G-type main-sequence star, and so is an instance of that class |
| ||||
<造帽师> 隶属于 <专业> | <造帽师>是一个职业的特定例子 |
| ||||
<道格拉斯·亚当斯> 隶属于 <人类> | <道格拉斯·亚当斯> is a specific human person (this is one of the most common cases for 隶属于) |
| ||||
<X> 上级分类 <Y> | 分类 | 分类 |
|
<超级航空母舰> 上级分类 <航空母舰> | <超级航空母舰>和<航空母舰>均是类且后者包含前者 |
|
<主权国家> 上级分类 <国> | 这两项都是分类,前者是带有所有基本功能并增加了拓展功能的后者,因此前者是后者的子类 |
| ||||
<G-type star> 上级分类 <恒星> | every individual G-class star (instances of <G-class star>) is also a star - i.e. belongs to the class <star> |
| ||||
<X> 所属实体 <Y> | 个例 | 个例 |
|
<尼米兹号航空母舰> 所属实体 <第11航空母舰打击群> | <USS Nimitz> is a concrete aircraft carrier, <CSG-11> is a concrete carrier strike group, <USS Nimitz> is one of <CSG-11>'s components (its flagship) |
|
<中华人民共和国> 所属实体 <亚洲> | <中国>和<亚洲>都是特定的地理特征,<中国>是<亚洲>大陆的一部分 |
| ||||
<太阳> 所属实体 <太阳系> | both of them are individual astronomical objects; the solar system is composed of the Sun, planets, and other objects in the Sun's vicinity |
| ||||
等级 | 等级 | an instance of class X is part of an instance of class Y | <飞行甲板> 所属实体 <航空母舰> | every aircraft carrier (instance of <aircraft carrier>) has its own flight deck (instance of <flight deck>) |
| |
<成员国> 所属实体 <国际组织> | an instance of <member state> is a component of an instance of <international organization> |
| ||||
<恒星> 所属实体 <星系> | a star typically is born and lives within a single galaxy which is made up of many stars and other astronomical objects |
| ||||
|
Here is a table that explains the difference between 可分为 (P527) and 拥有此类别的一部分 (P2670).
可分为 (P527) should be used for class-class and instance-instance relationships.
拥有此类别的一部分 (P2670) should be used for instance-class relationships.
If you see a constraint violation on an item with 拥有此类别的一部分 (P2670)...
- If the item is a class and has 上级分类 (P279), it should use 可分为 (P527) instead of 拥有此类别的一部分 (P2670), even if it also has 隶属于 (P31).
- The item may wrongly be a class and should instead be an instance. Remove 上级分类 (P279) and make sure it has a proper 隶属于 (P31).
属性 | X | Y | 表示什么 | 例子 | 解释 | 为何不用... |
---|---|---|---|---|---|---|
<X> 可分为 <Y> | 实例 | 实例 | instance X has instance Y among its parts or components | <美国国会> 可分为 <美国参议院> | the US Congress has two parts, the House of Representatives and the Senate |
|
<太阳系> 可分为 <火星> | <Mars> is one of the planets in the <Solar System> |
| ||||
等级 | 等级 | an instance of X has an instance of Y among its parts or components | <身体> 可分为 <头部> | in general a <body> (anatomical feature) has a <head> as one of its parts |
| |
<星系> 可分为 <恒星> | a <galaxy> has <stars> as one of its parts |
| ||||
<X> 拥有此类别的一部分 <Y> | 实例 | 等级 | the specific item X include some instance of class Y among its parts or components | <剑桥大学> 拥有此类别的一部分 <剑桥大学学院列表> | the <University of Cambridge> has colleges as parts |
|
<太阳系> 拥有此类别的一部分 <内行星> | our <Solar System> has one or more <inner planets> in its parts |
| ||||
<阿尔伯特·爱因斯坦> 拥有此类别的一部分 <人脑> | <Albert Einstein> had a <human brain> as a part |
|
Queries
Wikidata Queries can be used to find members of a given class, for example all subclasses of "Literary Work"; a Wikidata Query Builder is available to help.
导航框
|
See also
参考文献
- ↑ https://www.w3.org/TR/rdf-schema/#ch_type
- ↑ https://www.w3.org/TR/rdf-schema/#ch_subclassof
- ↑ https://www.w3.org/TR/rdf-schema/#ch_subclassof
外部链接
- Multi-Level Conceptual Modeling: Theory and Applications — explains differences between 隶属于 (P31) and 上级分类 (P279) under the conceptual framework of multi-level conceptual modelling. Skip to part 4 for Wikidata-related content.
- Collections and Individuals — explains differences between 隶属于 (P31) and 上级分类 (P279) (in the context of the Cyc(Q1147294) knowledge base)