-
Notifications
You must be signed in to change notification settings - Fork 2
/
base.ttl
195 lines (157 loc) · 4.3 KB
/
base.ttl
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
PREFIX : <http://relationlabs.ai/entity/>
PREFIX p: <http://relationlabs.ai/property/>
prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
prefix xsd: <http://www.w3.org/2001/XMLSchema#>
prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#>
###################
# Schema
###################
###################
# class
###################
:User a rdfs:Class ;
rdfs:label "user" ;
rdfs:comment "A User." .
:Identity a rdfs:Class ;
rdfs:label "user" ;
rdfs:comment "A User." .
:Medal a rdfs:Class ;
rdfs:label "user" ;
rdfs:comment "A User." .
:Favorite a rdfs:Class ;
rdfs:label "user" ;
rdfs:comment "A User." .
:Group a rdfs:Class ;
rdfs:label "user" ;
rdfs:comment "A User." .
:Message a rdfs:Class ;
rdfs:label "user" ;
rdfs:comment "A User." .
###################
# common property
###################
p:name a rdf:Property ;
rdfs:label "name" ;
rdfs:comment "The name of an entity" ;
rdfs:range xsd:string .
p:createdAt a rdf:Property ;
rdfs:label "createdAt" ;
rdfs:comment "The creation timestamp of an entity" ;
rdfs:range xsd:dateTime .
###################
# User property
###################
p:canisterId a rdf:Property ;
rdfs:label "canisterId" ;
rdfs:comment "The user's canisterId" ;
rdfs:domain :User ;
rdfs:range xsd:string .
p:name a rdf:Property ;
rdfs:label "name" ;
rdfs:comment "The user's name" ;
rdfs:domain :User ;
rdfs:range xsd:string .
p:avatar a rdf:Property ;
rdfs:label "avatar" ;
rdfs:comment "The user avatar" ;
rdfs:domain :User ;
rdfs:range xsd:string .
p:following a rdf:Property ;
rdfs:label "following" ;
rdfs:comment "The user following" ;
rdfs:domain :User ;
rdfs:range :User .
p:controller a rdf:Property ;
rdfs:label "controller" ;
rdfs:comment "The user's controller" ;
rdfs:domain :User ;
rdfs:range :Identity .
p:hold a rdf:Property ;
rdfs:label "hold" ;
rdfs:comment "The user's medal" ;
rdfs:domain :User ;
rdfs:range :Medal .
p:collect a rdf:Property ;
rdfs:label "collect" ;
rdfs:comment "The user's collect" ;
rdfs:domain :User ;
rdfs:range :Favorite .
###################
# Identity property
###################
p:principal a rdf:Property ;
rdfs:label "principal" ;
rdfs:comment "The identity's principal" ;
rdfs:domain :Identity ;
rdfs:range xsd:string .
###################
# Medal property
###################
p:image a rdf:Property ;
rdfs:label "image" ;
rdfs:comment "The medal's image" ;
rdfs:domain :Medal ;
rdfs:range xsd:string .
###################
# Favorite property
###################
p:icon a rdf:Property ;
rdfs:label "icon" ;
rdfs:comment "A icon of a Favorite" ;
rdfs:domain :Favorite ;
rdfs:range :string .
p:url a rdf:Property ;
rdfs:label "url" ;
rdfs:comment "A url of a Favorite" ;
rdfs:domain :Favorite ;
rdfs:range :string .
###################
# Group property
###################
p:groupId a rdf:Property ;
rdfs:label "groupId" ;
rdfs:comment "The id of a group" ;
rdfs:domain :Group;
rdfs:range xsd:string .
p:owner a rdf:Property ;
rdfs:label "owner" ;
rdfs:comment "The group's owner" ;
rdfs:domain :Group;
rdfs:range xsd:string .
p:avatar a rdf:Property ;
rdfs:label "avatar" ;
rdfs:comment "The group avatar" ;
rdfs:domain :Group ;
rdfs:range xsd:string .
p:member a rdf:Property ;
rdfs:label "member" ;
rdfs:comment "The group member" ;
rdfs:domain :Group ;
rdfs:range :User .
p:message a rdf:Property ;
rdfs:label "message" ;
rdfs:comment "The group message" ;
rdfs:domain :Group ;
rdfs:range :Message .
###################
# Message property
###################
p:sendUuid a rdf:Property ;
rdfs:label "sendUuid" ;
rdfs:comment "The sendUuid of message" ;
rdfs:domain :Message ;
rdfs:range xsd:string .
p:messageType a rdf:Property ;
rdfs:label "messageType" ;
rdfs:comment "The type of entity" ;
rdfs:range xsd:string .
p:content a rdf:Property ;
rdfs:label "messageContent" ;
rdfs:comment "The content of message" ;
rdfs:domain :Message ;
rdfs:range xsd:string .
p:from a rdf:Property ;
rdfs:label "from" ;
rdfs:comment "The from of message" ;
rdfs:domain :Message ;
rdfs:range :User .