Semantic_Web by wpr1947


									Semantic Web


         What is Semantic Web?
 Semantic web is an extension of the www
   Describes things in a way that they are understandable by the Computer

"If HTML and the Web made all the online documents look like one huge book,
 RDF, schema, and inference languages will make all the data in the world look
like one huge database"
                                      Tim Berners-Lee, Weaving the Web, 1999
  How can they be understood by
Semantic web uses some descriptive
 technologies like

 Resource Descriptive Framework (RDF)
 Web Ontology Language (OWL)
 Extensible Markup Language (XML)
                    Semantic Web Layer
•   XML provides a surface syntax for
    structured documents.

•   XML Schema is a language for restricting
    the structure and content elements of XML

•   RDF is a simple data model for referring to
    objects and how they are related.

•   RDF Schema is a vocabulary for
    describing properties and classes of RDF

•   OWL adds more vocabulary for describing
    properties and classes,

•   SPARQL is a protocol and query language
    for Semantic Web data sources.

                                                  “courtesy :”
    Resource Descriptive Framework

•   RDF is a W3C Recommendation and part of a semantic web activity

•   RDF is a framework for describing resources on the web

•   RDF provides a model for data, and a syntax so that independent parties can
    exchange and use it

•   RDF is designed to be read and understood by computers

•   RDF is not designed for being displayed to people

•   RDF is written in XML
                  Structure of RDF
• It is a collection of triples
                  Subject (Resource)
                  predicate (Property)
                  Object (property

• A set of such triples are called RDF graph
                 Example for RDF
<?xml version="1.0"?>

   <Description about="">
        <author>Jan Egil Refsnes</author>

     “The author of is Jan Egil Refsnes".
RDF graph for example



                   Jan Egil Refsnes
             RDF Elements
            Root element          <rdf:RDF>

            Description element <rdf:Description>

<?xml version="1.0"?>

    rdf:about="http://www.recshop.fake/cd/Empire Burlesque">
       <cd:artist>Bob Dylan</cd:artist>
                                   RDF Container
                                  Unordered List        <rdf:Bag>

                                  Ordered List          <rdf:Seq>

                                  Alternate values      <rdf:Alt>

<?xml version="1.0"?>
<rdf:RDF                                                        <?xml version="1.0"?>
xmlns:rdf=           <rdf:RDF
xmlns:cd="http://www.recshop.fake/cd#">                         xmlns:rdf=
<rdf:Description                                                xmlns:cd="http://www.recshop.fake/cd#">
  rdf:about="http://www.recshop.fake/cd/Beatles">               <rdf:Description
  <cd:artist>                                                     rdf:about="http://www.recshop.fake/cd/Beatles">
   <rdf:Bag>                                                      <cd:artist>
     <rdf:li>John</rdf:li>                                         <rdf:Seq>
     <rdf:li>Ringo</rdf:li>                                          <rdf:li>John</rdf:li>
     <rdf:li>Paul</rdf:li>                                           <rdf:li>Paul</rdf:li>
    <rdf:li>George</rdf:li>                                          <rdf:li>Ringo</rdf:li>
   </rdf:Bag>                                                      </rdf:Seq>
  </cd:artist>                                                    </cd:artist>
</rdf:Description>                                              </rdf:Description>
</rdf:RDF>                                                      </rdf:RDF>
                  Collection element
Container are not closed
Collections specify only these members are allowed other are not allowed
A collection is described by the attribute rdf:parseType="Collection".

   <?xml version="1.0"?>
        <cd:artist rdf:parseType="Collection">
        <rdf:Description rdf:about="http://recshop.fake/cd/Beatles/George"/>
        <rdf:Description rdf:about="http://recshop.fake/cd/Beatles/John"/>
        <rdf:Description rdf:about="http://recshop.fake/cd/Beatles/Paul"/>
        <rdf:Description rdf:about="http://recshop.fake/cd/Beatles/Ringo"/>
               RDF Schema (RDFS)
•   RDF Schema provides the framework to describe application-specific classes and
•   RDFS allows resources to be defined as instances of classes, and subclasses of

               <?xml version="1.0"?>
               xmlns:rdf= ""
               xml:base= "http://www.animals.fake/animals#">
               <rdf:Description rdf:ID="animal">
               <rdf:Description rdf:ID="horse">
                 <rdfs:subClassOf rdf:resource="#animal"/>
• Web Ontology Language
• OWL is used to publish and share sets of
  terms called ontologies
• Supports advanced web search and
  knowledge management.
• An ontology is a description (like a formal
  specification of a program) of the concepts
  and relationships that can exist for an
  agent or a community of agents
                        -Tom Gruber, Stanford University

• An ontology defines a common vocabulary
  for researchers who need to share
  information in a domain.
  Elements Of An Ontology…..
• Individuals
       - Individuals (instances) are the basic
  components of an ontology

• Classes
      - Classes (concepts) are abstract
  groups or collections of objects.
     Elements of An Ontology
• Attributes
        - Describes objects in the ontology
        - Used to store information specific to
  the object
• Relationships
       - Important use of attributes is to
  describe relationships between objects.
Basic Ontology

   Why develop an ontology?
• To share common understanding of the
  structure of information among people or
  software agents
• To enable reuse of domain knowledge
• To make domain assumptions explicit
• To separate domain knowledge from the
  operational knowledge
• To analyze domain knowledge
• OWL is a language for making ontological
• OWL can formally describe the semantics
  of classes and properties used in web
• OWL is used to publish and share
• The OWL Web Ontology Language is designed
  for use by applications that need to process the
  content of information instead of just presenting
  information to humans.
• OWL facilitates greater machine interpretability
  of Web content than that supported by XML,
  RDF and RDF-S by providing additional
  vocabulary along with a formal semantics.
   Vocabulary Added by OWL
• Relation between classes
   - Ex: disjointness
• Cardinality
   - Ex: exactly one
• Characteristics of properties
   - Ex: symmetry
• Enumerated Classes
      Sublanguages of OWL
 OWL provides three increasingly
 expressive sublanguages for use by
 specific communities of users:

• OWL Lite
• OWL Full
               OWL Lite
• Less expressive language
• Supports users primarily needing a
  classification hierarchy and simple
• Lower formal complexity than other
               OWL DL
• Supports users who want maximum
• Retains:
          - computational completeness
          - decidability
• Named due to its correspondence with
  descriptive logic
               OWL Full
• Attains maximum expressiveness and
  syntactic freedom
• No computational guarantees
• Unlikely that any reasoning software could
  support all the features of OWL Full
           More About OWL
• OWL Full and OWL DL support the same
  set of OWL language constructs
• Difference lies in the restrictions on use of
  some of the features
• OWL DL puts constraints on mixing with
  RDF and requires disjointness of classes,
  properties, attributes…
• OWL Full allows free mixing of OWL with
  RDF schema
• OWL Lite supports only a subset of OWL
  language constructs.
• Particularly targeted at tool builders, who
  want to start with a simple set of language
• OWL Lite abides by the same semantic
  restrictions as OWL DL
              OWL Syntax
A class is declared as follows:
<owl:Class rdf:ID="ConsumableThing" />

Properties are created as:
<owl:ObjectProperty rdf:ID="madeFromFruit">
<rdfs:domain rdf:resource="#ConsumableThing" />
  <rdfs:range rdf:resource="#Fruit" />
       OWL Class Descriptions
• A class description describes an OWL class, either by a
  class name or by specifying the class extension of an
  unnamed anonymous class.
• OWL distinguishes six types of class descriptions:
      a class identifier (a URI reference)
      an exhaustive enumeration of individuals that
  together form the instances of a class
      a property restriction
      the intersection of two or more class descriptions
      the union of two or more class descriptions
      the complement of a class description
    Type 1 Class description

   <owl:Class rdf:ID="Human"/>

This will assert the tuple
    ex:Human rdf:type owl:Class .

Where “ex” is the namespace of relevant
                 Enumeration type
• A class description of the "enumeration"
  kind is defined with the owl:oneOf property
     <owl:oneOf rdf:parseType="Collection">
          <owl:Thing rdf:about="#Eurasia"/>
          <owl:Thing rdf:about="#Africa"/>
          <owl:Thing rdf:about="#NorthAmerica"/>
          <owl:Thing rdf:about="#SouthAmerica"/>
          <owl:Thing rdf:about="#Australia"/>
          <owl:Thing rdf:about="#Antarctica"/>
     Intersection Type
   <owl:intersectionOf rdf:parseType="Collection">
          <owl:oneOf rdf:parseType="Collection">
              <owl:Thing rdf:about="#Tosca" />
              <owl:Thing rdf:about="#Salome" />
          <owl:oneOf rdf:parseType="Collection">
              <owl:Thing rdf:about="#Turandot" />
              <owl:Thing rdf:about="#Tosca" />
                       Union Type
An owl:unionOf statement describes the union of class
 descriptions in the list.
              <owl:unionOf rdf:parseType="Collection">
                   <owl:oneOf rdf:parseType="Collection">
                          <owl:Thing rdf:about="#Tosca" />
                          <owl:Thing rdf:about="#Salome" />
                    <owl:oneOf rdf:parseType="Collection">
                          <owl:Thing rdf:about="#Turandot" />
                          <owl:Thing rdf:about="#Tosca" />
• Semantic Web Rule Language
• It is roughly an Union of OWL AND
  RULEML language
• It is proposed to W3C by National
  Research Council of Canada, Network
  inference and Stanford university in 2004
hasParent(?x1,?x2) ∧ hasBrother(?x2,?x3) ⇒ hasUncle(?x1,?x3)

     <ruleml:_rlab ruleml:href="#example1"/>
        <swrlx:individualPropertyAtom swrlx:property="hasParent">
         <swrlx:individualPropertyAtom swrlx:property="hasBrother">
         <swrlx:individualPropertyAtom swrlx:property="hasUncle">
•   SWRLTab is an extension to Protege that supports editing and execution of SWRL
•   R2ML (REWERSE Rule Markup Language) supports SWRL
•   Bossam, a forward-chaining rule engine supports SWRL
•   Hoolet, an implementation of an OWL-DL reasoner that uses a first order prover
    supports SWRL
•   Pellet, an open-source Java OWL DL reasoner has SWRL-support
•   KAON2 is an infrastructure for managing OWL-DL, SWRL, and F-Logic ontologies
•   RacerPro, supports processing of rules in a SWRL-based syntax by translating them
    into nRQL rules
• Rule Interchange Format will provide a
  way to allow rules written for one
  application to be published, shared,
  merged and reused in other applications
  by other rule engines
• It is a W3C proposal
                The idea
• RIF working group standardizes the rules
  that propel data across the web regardless
  of the format
• Improves the integration of data sources
  and the ability to draw new conclusions
• W3C said an RIF can trigger the
  integration and transformation of data from
  multiple sources.
• The functionality aims at giving data more
  meaning through the use of metadata and
  how metadata is formatted and how it is

To top