On the cross-fertilization of geospatial and semantic web technology

Learn To Edit Semantic MediaWiki In 10-Minutes

Semantic MediaWiki (SMW) is an extension of MediaWiki with semantic technology. Not only users can create and edit Wiki pages, but also they can make semantic assertions. SMW allows users to annotate Wiki contents using various types of knowledge representation constructs.

In this post, I overview the basic features of SMW and show its usage with few simple examples. At the end, I show how semantically annotated Wiki knowledge can be used to enable structured search queries, which are more expressive than the typical free-text search (e.g., Google web search).

The Basics: Categories and Relations

Two of the constructs provided by SMW are category and relation. The category construct allows users to define different classes of SMW things. For example, there is a category of countries and a category of people. In SMW, users can explicitly model the relations between different Wiki pages. The relation construct is created for this purpose. For example, to say a person is located in a particular geographical location, we can use the relation vocabulary “is located in“, and to say a person is affiliated with a particular organization, we can use the vocabulary “Affiliation“.

Category Examples

To define a SMW thing (i.e., a SMW Wiki page) belongs to a specific category (e.g., Person), we simply tag the SMW Wiki page using the following syntax:

[code lang=""]
[[Category:Person]]
[/code]

Adding the above tag to my SMW page is to assert that Harry Chen is a person. By doing so, I joined the list of other people in the Person category. (Note: Since I’ve created the page under “User:HarryChen”, look under “U” not “H” I notice my name didn’t show up in the page as of 2006-08-16. In theory, it should!)

SMW allows users to create new categories if they don’t already exist in the system. For example, I can create a category called “HappyPeople“, and the intended semantics is that “all people of this category are happy people”. Since I tagged my SMW page using this category, if you go to the HappyPeople category page, you will see my name listed on that page.

Relation Examples

In SMW, relations exist between links. These links maybe URL points to other SMW pages or external Web pages. Assertions about different relations are typically defined inline with the text paragraphs. In my SMW page, in the same text that describes my affiliations and geographical location, I explicitly asserted the following:

[code lang=""]
[[works at::Image Matters LLC]]

[[is located in::Maryland]]
[/code]

Having the above statements defined, I joined a list of other SMW people on the Affiliation relation page.

In addition to the above two SMW constructs that I have described, there are few others that you may want to explore. They can be found on the main user page. If you are interested to use SMW with other Semantic Web applications, look here.

Simple Semantic Search

Here is an interesting feature that you don’t typically see on other Wiki systems — SMW’s Simple Semantic Search. Because all the SMW knowledge representation constructs are created based on a simple Triple model of RDF, we can formulate simple but powerful structured search queries. Let’s say that I want to find all people that located in the state of Maryland. In the tripe format, I would define my query as the following:

subject: any person, relation: is located in, object: Maryland.

If you try entering the above in the search page — leave the subject text field blank for “any person”, you should see my name in the search result.

Sharing is Good. These icons link to social bookmarking sites where readers can share and discover new web pages.
  • del.icio.us
  • YahooMyWeb
  • Reddit
  • co.mments
  • Furl
  • Ma.gnolia
  • NewsVine
  • Simpy
  • bodytext
  • E-mail this story to a friend!
  • Facebook
  • Google
  • StumbleUpon
  • Technorati
  • TwitThis

2 Comments

  1. Hi Harry! Thanks for this great tutorial, we are linking it from ontoworld now. By the way, you indeed are in the Category Person already (there never should be a delay for that): you just have to look under ‘U’, not under ‘H’, because you added your User-Page, instead of creating a page in the main space (which I would recommend, btw)
    Cheers, denny

    Comment by denny — August 17, 2006 @ 4:55 pm

  2. [...] Recently I learned about Centiare from Gregory Kohs, a co-developer of the application. Centiare is a new Wiki application that builds on the Semantic MediaWiki features. Centiare is a unique online reference directory that anyone can use. You can set up your very own Directory page about yourself or your business, and no other users can edit it. That’s how the Directory pages work — if you create it, you own it. [...]

    Pingback by Geospatial Semantic Web Blog - GIS Data Integration, Geo Ontology, Geo Tagging & Geo Web 2.0 News » Blog Archive » Centiare: Semanitc MediaWiki opens for business — January 5, 2007 @ 10:28 am

Leave a comment

XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>