Semantic Web Applications: Semantic Wikis

OBSOLETE

Before the lab

Software:

NOTE: Log in with a username and appropriate password given by a teacher.

Introduction

Lab instructions

1 Semantic Wikis - Introduction

  • Browse the slides up to the BREAK slide (no.106).
  • Read the Introduction to the Semantic MediaWiki

2 Semantic MediaWiki - Categories

  1. Log in with your username and password given by the teacher to the SMW test installation.
  2. Create a page
    http://loki.ia.agh.edu.pl/smw/index.php/jsi2012/<your-name>

    e.g.

    http://loki.ia.agh.edu.pl/smw/index.php/jsi2012/wtadrian
    1. Enter the link to the navigation bar
    2. If the page doesn't exist (and it shouldn't exist yet ;-) ) click edit this page

      and shortly describe yourself, e.g.
      My name is Example student. I am 12 years old.
      Currently I study at AGH UST, faculty of electrical engineering.
      I belong to group <put your lab group number here>. The other members of my group are:
  3. Based on the SMW tutorial, add the page to the Student category.
  4. 8-) Paste the wiki page source (markup) in the report.
  5. Create a new page as:
    http://loki.ia.agh.edu.pl/smw/index.php/AGH-UST/Subjects/subject-name

    and assign it to the category University subject.

  6. 8-) Paste the wiki page source (markup) in the report.

3 Semantic MediaWiki - Properties

  1. Based on the Properties and Types section annotate the content of your Student page so that it contains the following semantic information about you:
    • Name (first + last name)
    • Age
    • Group (choose one)
  • 8-) include the updated wikipage source code (markup) in the report.
  1. Edit the created page that belong to the University subject category so that it contains the following properties:
    • lead by
    • room
    • duration
  • 8-) include the updated wikipage source code (markup) in the report.

e.g.

lead by: [[lead by::prof Ligeza]]
room: [[room::B1 121]]
duration: [[duration::90]] min

4 Semantic MediaWiki - Inline queries

  1. Read the manual section on Inline queries
  2. Using the inline queries add to your page the list of the students that are members of your group
    1. Format the output of the query as unordered list
    2. 8-) Put the query in the report.
  3. Build another query listing the students from your group:
    1. Display it as a table
    2. Sort by age, then by the name
    3. Define a default value which will be displayed if the required field (e.g. age) is empty.
    4. 8-) Put the query in the report.

5 Loki - Introduction

  1. Go to the Loki website.
  2. Read the About page to get to know the system better.
  3. With your username and password log in to Loki installation.
  4. Read about the Loki possibilities in Documentation section (especially pluginapi[1/2]).

6 Loki - Use Cases

Choose and do one of the following two tasks: (they are also described in Loki)

6.1 Movie recommendation system

  1. Create a page of a movie in the movie: namespace. Assign it to the movie category.
  2. Describe the movie in english using semantic annotations, according to an example filmy:poszukiwacze_zaginionej_arki in polish and an example bookstore:book:the_call_of_cthulhu in english (use the movie relations and the genre attribute (and possibly more if you want)).
  3. Describe shortly one of the actors in the person: namespace and assign it to the actor category.
  4. 8-) Copy the wiki pages sources and paste them into the report.

6.2 Geographic Wiki

  1. Create a page of a city in the city: namespace. Assign it to the city category.
  2. Describe the city in english using semantic annotations, according to the example: miasta:warszawa. You can add more semantic relations and attributes than in the examples.
  3. Describe shortly the country of this city, assign it to the country category.
  4. 8-) Copy the wiki pages sources and paste them into the report.

7 Loki - Semantic Web Standards

  1. Create a page for yourself in the user namespace, assign it to the user category.
  2. Read the Plugin API v.2.0, section on SPARQL.
  3. On your page, build an example SPARQL query which asks for specific kind of movies or cities (you decide what criteria to use in the query!).
  4. Observe the results. 8-) Put the query into the report.
  5. Read the Plugin API v.2.0, section on RDF export.
  6. Export the page you created about a movie or a city. Analyze the exported file. Find the category, relations and attributes that you entered - how are they represented?

8 Loki - Reasoning

In Loki it is possible to embed Prolog code within <pl>…</pl> tags. Using Prolog code create a set of custom recommendations, e.g.: „Movies, where the leading lady is X and the movie was made before 1940” or „City which is located in a country which is by a sea and is not listed as a member of the EU”.

  1. Read the Plugin API v.1.0, section on Prolog.
  2. On your user page create a section My Recommendations
  3. Create a Prolog goal so that the movies interesting for you are found. Optionally, you can define the interesting movies/cities with a Prolog rule and use it directly in the goal.
  4. If you encounter problems, use the debug functionality of Loki.

8-) Put the goal in the report. :!: NOTE: This can give you an extra point. If you don't do this exercise, you don't loose a point. Just a present for the end… ;-)

NOTE: Plugin API v.1.0 and this presentation may be useful.

Control questions

  • What is the difference between classical wikis a semantic ones?
  • What are the semantic annotations?
  • Does the Semantic Media Wiki support category hierarchy?
  • How to create a subcategory?
  • How to create a subproperty?

If you want to know more

pl/dydaktyka/semantic_web/new-semweb-apps.txt · ostatnio zmienione: 2017/07/17 08:08 (edycja zewnętrzna)
www.chimeric.de Valid CSS Driven by DokuWiki do yourself a favour and use a real browser - get firefox!! Recent changes RSS feed Valid XHTML 1.0