practical introduction to the semantic mediawiki
TRANSCRIPT
![Page 1: Practical Introduction to the Semantic Mediawiki](https://reader033.vdocuments.mx/reader033/viewer/2022052904/557c2267d8b42a925b8b4b73/html5/thumbnails/1.jpg)
Semantic mediawiki AIFB
Some slide takenfrom Danny Drandevic
![Page 2: Practical Introduction to the Semantic Mediawiki](https://reader033.vdocuments.mx/reader033/viewer/2022052904/557c2267d8b42a925b8b4b73/html5/thumbnails/2.jpg)
2
Semantic MediaWiki Extension of MediaWiki
Popular Wiki engine Powers Wikipedia
Extends MediaWiki by enabling… Typed links Property – Value Inline queries New ways to explore the content
Open source and well documented
![Page 3: Practical Introduction to the Semantic Mediawiki](https://reader033.vdocuments.mx/reader033/viewer/2022052904/557c2267d8b42a925b8b4b73/html5/thumbnails/3.jpg)
3
An example RDF Schema
Writer hasWritten Book
FamousWriter
/twain/mark ../ISBN00010475
Schema(RDFS)Data(RDF)
hasWrittentype
subClassOf
domain range
type
Annotation of WWW resources and semantic links
![Page 4: Practical Introduction to the Semantic Mediawiki](https://reader033.vdocuments.mx/reader033/viewer/2022052904/557c2267d8b42a925b8b4b73/html5/thumbnails/4.jpg)
4
Concepts
INSTANCE <=> PAGE CLASS <=> CATEGORY RELATION <=> PROPERTY
![Page 5: Practical Introduction to the Semantic Mediawiki](https://reader033.vdocuments.mx/reader033/viewer/2022052904/557c2267d8b42a925b8b4b73/html5/thumbnails/5.jpg)
5
Instance <-> Page
![Page 6: Practical Introduction to the Semantic Mediawiki](https://reader033.vdocuments.mx/reader033/viewer/2022052904/557c2267d8b42a925b8b4b73/html5/thumbnails/6.jpg)
6
Class <-> Category
![Page 7: Practical Introduction to the Semantic Mediawiki](https://reader033.vdocuments.mx/reader033/viewer/2022052904/557c2267d8b42a925b8b4b73/html5/thumbnails/7.jpg)
7
Relation <-> Property
![Page 8: Practical Introduction to the Semantic Mediawiki](https://reader033.vdocuments.mx/reader033/viewer/2022052904/557c2267d8b42a925b8b4b73/html5/thumbnails/8.jpg)
8
Instance <-> Page
![Page 9: Practical Introduction to the Semantic Mediawiki](https://reader033.vdocuments.mx/reader033/viewer/2022052904/557c2267d8b42a925b8b4b73/html5/thumbnails/9.jpg)
9
Instance
Blue linksmean there isa page aboutit
Red linkmeans thereis no pageabout it
![Page 10: Practical Introduction to the Semantic Mediawiki](https://reader033.vdocuments.mx/reader033/viewer/2022052904/557c2267d8b42a925b8b4b73/html5/thumbnails/10.jpg)
10
Class <-> Category
There are pages describingcategories
![Page 11: Practical Introduction to the Semantic Mediawiki](https://reader033.vdocuments.mx/reader033/viewer/2022052904/557c2267d8b42a925b8b4b73/html5/thumbnails/11.jpg)
11
Class <-> Category
Subclass (subcategory) of
![Page 12: Practical Introduction to the Semantic Mediawiki](https://reader033.vdocuments.mx/reader033/viewer/2022052904/557c2267d8b42a925b8b4b73/html5/thumbnails/12.jpg)
12
Class <-> Category
Extensional descriptionList of all instancesBut: only direct ones
![Page 13: Practical Introduction to the Semantic Mediawiki](https://reader033.vdocuments.mx/reader033/viewer/2022052904/557c2267d8b42a925b8b4b73/html5/thumbnails/13.jpg)
13
Categories
Informal description Can be discussed Can be edited
![Page 14: Practical Introduction to the Semantic Mediawiki](https://reader033.vdocuments.mx/reader033/viewer/2022052904/557c2267d8b42a925b8b4b73/html5/thumbnails/14.jpg)
14
Relation <-> Property
There are pages describingproperties
![Page 15: Practical Introduction to the Semantic Mediawiki](https://reader033.vdocuments.mx/reader033/viewer/2022052904/557c2267d8b42a925b8b4b73/html5/thumbnails/15.jpg)
15
Relation <-> Property
Datatype definition
![Page 16: Practical Introduction to the Semantic Mediawiki](https://reader033.vdocuments.mx/reader033/viewer/2022052904/557c2267d8b42a925b8b4b73/html5/thumbnails/16.jpg)
16
Data values and types Attributes like [[birthdate::February 27 1978]] or
[[population::3,635,389]] must know the type of the value This is done by adding [[has type::T]] on the page of the
attribute Available, predefined types:
o Annotation URIo Dateo Emailo Enumerationo Floato Geographic coordinate
IntegerPageStringTemperatureTextURL
![Page 17: Practical Introduction to the Semantic Mediawiki](https://reader033.vdocuments.mx/reader033/viewer/2022052904/557c2267d8b42a925b8b4b73/html5/thumbnails/17.jpg)
17
Special:Categories
![Page 18: Practical Introduction to the Semantic Mediawiki](https://reader033.vdocuments.mx/reader033/viewer/2022052904/557c2267d8b42a925b8b4b73/html5/thumbnails/18.jpg)
18
Special:Properties
![Page 19: Practical Introduction to the Semantic Mediawiki](https://reader033.vdocuments.mx/reader033/viewer/2022052904/557c2267d8b42a925b8b4b73/html5/thumbnails/19.jpg)
19
Special:Ask
![Page 20: Practical Introduction to the Semantic Mediawiki](https://reader033.vdocuments.mx/reader033/viewer/2022052904/557c2267d8b42a925b8b4b73/html5/thumbnails/20.jpg)
20
Query examples - CategoryFor example, the query:
[[Category:Teacher]]
is a query for all pages within the category Teacher,i.e. for all teachers. If you enter this in Special:Askand click "Find results", SMW executes the queryand displays results as a simple list of all requestedpages. If there are many results, they can bebrowsed via the navigations links at the top andbottom of the query results
![Page 21: Practical Introduction to the Semantic Mediawiki](https://reader033.vdocuments.mx/reader033/viewer/2022052904/557c2267d8b42a925b8b4b73/html5/thumbnails/21.jpg)
21
Query examples - SubcategoriesFor example, the query:
[[Category:Person]]
Will find all pages in the categories Teachers, Students andOrganizer if these categories are subcategories of Person
![Page 22: Practical Introduction to the Semantic Mediawiki](https://reader033.vdocuments.mx/reader033/viewer/2022052904/557c2267d8b42a925b8b4b73/html5/thumbnails/22.jpg)
22
Query examples - combining queries (AND)
For example, the query:
[[Category:Person]] [[has nationality::Italy]]
Will find all items in category Person that have the property ofbeing italian. (AND)
![Page 23: Practical Introduction to the Semantic Mediawiki](https://reader033.vdocuments.mx/reader033/viewer/2022052904/557c2267d8b42a925b8b4b73/html5/thumbnails/23.jpg)
23
Query examples - combining queries (OR)
For example, the query:
[[Category:Organizer || Teacher]]Will find all items that are category Organizer OR in category
Teacher (Set Union).
[[Category:Organizer]] || [[has nationality::Italy]]
Will find all items that are category Person PLUS (Union) allthose that have the property of being italian. (OR)
![Page 24: Practical Introduction to the Semantic Mediawiki](https://reader033.vdocuments.mx/reader033/viewer/2022052904/557c2267d8b42a925b8b4b73/html5/thumbnails/24.jpg)
24
Query examples - PropertiesFor example, the query:
[[has nationality::Italy]]
Will find all occurencies that have the specified property.
![Page 25: Practical Introduction to the Semantic Mediawiki](https://reader033.vdocuments.mx/reader033/viewer/2022052904/557c2267d8b42a925b8b4b73/html5/thumbnails/25.jpg)
25
Query examples - conditions on attributes
For example, the query:
[[Category:City]] [[Has population>1,000,000]]
Will find all pages in the category City, having more than onemillion inhabitants.
![Page 26: Practical Introduction to the Semantic Mediawiki](https://reader033.vdocuments.mx/reader033/viewer/2022052904/557c2267d8b42a925b8b4b73/html5/thumbnails/26.jpg)
26
All cities having a has population property
[[Category:City]] [[has population::+]]
![Page 27: Practical Introduction to the Semantic Mediawiki](https://reader033.vdocuments.mx/reader033/viewer/2022052904/557c2267d8b42a925b8b4b73/html5/thumbnails/27.jpg)
27
All cities having and their population
[[Category:City]] [[has population::*]]
![Page 28: Practical Introduction to the Semantic Mediawiki](https://reader033.vdocuments.mx/reader033/viewer/2022052904/557c2267d8b42a925b8b4b73/html5/thumbnails/28.jpg)
28
All cities with more than 1,000,000 peopleand their population
[[Category:City]] [[has population::>1,000,000]][[has population::*]]
![Page 29: Practical Introduction to the Semantic Mediawiki](https://reader033.vdocuments.mx/reader033/viewer/2022052904/557c2267d8b42a925b8b4b73/html5/thumbnails/29.jpg)
29
Embedding queries into pages
<ask>…</ask>
![Page 30: Practical Introduction to the Semantic Mediawiki](https://reader033.vdocuments.mx/reader033/viewer/2022052904/557c2267d8b42a925b8b4b73/html5/thumbnails/30.jpg)
30
Formatting and sorting
Seehttp://ontoworld.org/wiki/Help:Inline_queries
![Page 31: Practical Introduction to the Semantic Mediawiki](https://reader033.vdocuments.mx/reader033/viewer/2022052904/557c2267d8b42a925b8b4b73/html5/thumbnails/31.jpg)
31
Social aspects
You are free to define categories and properties, but…
How to decide which properties and categories areimportant?
How to define the properties or categories? How to ensure high quality data? What does it mean? How to control the wiki knowledge base and its growth?
![Page 32: Practical Introduction to the Semantic Mediawiki](https://reader033.vdocuments.mx/reader033/viewer/2022052904/557c2267d8b42a925b8b4b73/html5/thumbnails/32.jpg)
32
Querying and social aspects
Querying can only be done on aligned vocabularies If half of the people use “affiliation” and the other half “works
for” you cannot query the knowledge easily
Inside SMW, information integration usually happenswith social tools, not with technology
Gardening tools can help with aligning vocabularies,but not replace them Tools that allow you to rename a property throughout the wiki Or to join two different names
![Page 33: Practical Introduction to the Semantic Mediawiki](https://reader033.vdocuments.mx/reader033/viewer/2022052904/557c2267d8b42a925b8b4b73/html5/thumbnails/33.jpg)
33
Exporting the data Every page can export its knowledge as RDF
![Page 34: Practical Introduction to the Semantic Mediawiki](https://reader033.vdocuments.mx/reader033/viewer/2022052904/557c2267d8b42a925b8b4b73/html5/thumbnails/34.jpg)
34
Go to the wiki!
If you are e.g. Bjorn Hassler, and your user page is Bjorn: Copy the content of your User:Bjorn page into a new page
called Bjorn Hassler Add to it the right categories (e.g. Man, Teacher) Add to it the right properties and values (e.g. Has nationality, Has e-
mail) Replace the content of your old User: page User:Bjorn with a link
to your new page [[Bjorn Hassler]] Go to the Special:Ask page and play with queries
Discuss in group and propose new Categories and Properties