際際滷

際際滷Share a Scribd company logo
Web Service Semantic Annotation
SWAP Group - Dip. Informatica di Bari
Outline
      Standard per lannotazione semantica
        SAWSDL: Semantic Annotations for WSDL
        and XML Schema

        SA-REST: Semantic Annotations for REST

        Tabella comparativa

      Architettura
        Scenario duso

      Mockup
      Sviluppi futuri

2
Standard per lannotazione
semantica
Semantic Annotations for WSDL
4   and XML Schema [SAWSDL]
     Annotazione semantica di Web Service descritti tramite WSDL
     Insieme di attributi che estendono WSDL 2.0
     Collega concetti presenti in una qualsiasi ontologia ad elementi del
     documento WSDL
     Non impone luso di alcun linguaggio speci鍖co per la rappresentazione del
     modello semantico
     E ulteriormente estendibile
     W3C Recommendation dal 28 Agosto 2007
5
6
<wsdl:description
  targetNamespace="http://www.w3.org/2002/ws/sawsdl/spec/wsdl/order#"
  xmlns="http://www.w3.org/2002/ws/sawsdl/spec/wsdl/order#"
  xmlns:wsdl="http://www.w3.org/ns/wsdl"
  xmlns:xs="http://www.w3.org/2001/XMLSchema">

 <wsdl:types>
   <xs:schema targetNamespace="http://www.w3.org/2002/ws/sawsdl/spec/wsdl/order#"
     elementFormDefault="qualified">
     <xs:element name="OrderRequest">
       ...
     </xs:element>
     <xs:complexType name="item">
       ...
     </xs:complexType>
     <xs:element name="OrderResponse" type="confirmation" />
     <xs:simpleType name="confirmation">
       <xs:restriction base="xs:string">
         <xs:enumeration value="Confirmed" />
         <xs:enumeration value="Pending" />
         <xs:enumeration value="Rejected" />
       </xs:restriction>
     </xs:simpleType>
   </xs:schema>
 </wsdl:types>

  <wsdl:interface name="Order">
    <wsdl:operation name="order" pattern="http://www.w3.org/ns/wsdl/in-out">
      <wsdl:input element="OrderRequest" />
      <wsdl:output element="OrderResponse" />
    </wsdl:operation>
  </wsdl:interface>
</wsdl:description>




                                                                                    7
<wsdl:description
  targetNamespace="http://www.w3.org/2002/ws/sawsdl/spec/wsdl/order#"
  xmlns="http://www.w3.org/2002/ws/sawsdl/spec/wsdl/order#"
  xmlns:wsdl="http://www.w3.org/ns/wsdl"
  xmlns:xs="http://www.w3.org/2001/XMLSchema"
  xmlns:sawsdl="http://www.w3.org/ns/sawsdl">

  <wsdl:types>
    <xs:schema targetNamespace="http://www.w3.org/2002/ws/sawsdl/spec/wsdl/order#"
      elementFormDefault="qualified">
      <xs:element name="OrderRequest"
          sawsdl:modelReference="http://www.w3.org/2002/ws/sawsdl/spec/ontology/purchaseorder#OrderRequest"
          sawsdl:loweringSchemaMapping="http://www.w3.org/2002/ws/sawsdl/spec/mapping/RDFOnt2Request.xml">
        ...
      </xs:element>
      <xs:complexType name="item">
        ...
      </xs:complexType>
      <xs:element name="OrderResponse" type="confirmation" />
      <xs:simpleType name="confirmation"
          sawsdl:modelReference="http://www.w3.org/2002/ws/sawsdl/spec/ontology/
purchaseorder#OrderConfirmation">
        <xs:restriction base="xs:string">
          <xs:enumeration value="Confirmed" />
          <xs:enumeration value="Pending" />
          <xs:enumeration value="Rejected" />
        </xs:restriction>
      </xs:simpleType>
    </xs:schema>
  </wsdl:types>

  <wsdl:interface name="Order"
      sawsdl:modelReference="http://example.org/categorization/products/electronics">
    <wsdl:operation name="order" pattern="http://www.w3.org/ns/wsdl/in-out"
        sawsdl:modelReference="http://www.w3.org/2002/ws/sawsdl/spec/ontology/
purchaseorder#RequestPurchaseOrder">




                                                                                                              8
      <wsdl:input element="OrderRequest" />
      <wsdl:output element="OrderResponse" />
    </wsdl:operation>
  </wsdl:interface>
</wsdl:description>
9
10
Semantic Annotation for REST
11   [SA-REST]
      Automatizzare la fase di mediazione e composizione (mashup) di servizi
      RESTful
      Insieme di attributi che estendono (X)HTML (che non 竪 stato pensato per
      catturare le descrizioni di un servizio)
      Annota porzioni di codice (X)HTML che contengono descrizioni non machine-
      readable
      Utilizza RDFa, GRDDL o microformati (hCard, hCalendar, hResume)
      E ulteriormente estendibile
<html xmlns:sarest=http://lsdis.cs.uga.edu/SAREST#>
...
<p about= http://craigslist.org/search/>
    The logical input of this service is an
    <span property=sarest:input>
        http://lsdis.cs.uga.edu/ont.owl#Location_Query
    </span>
    object. The logical output of this service is a list of
    <span property=sarest:output>
            http://lsdis.cs.uga.edu/ont.owl#Location
    </span>
    objects. This service should be invoked using an
    <span property=sarest:action>HTTP GET</span>.
    <meta property=sarest:lifting content=http://craigslist.org/api/
    lifting.xsl/>
    <meta property=sarest:lowering content=http://craigslist.org/api/
    lowering.xsl/>
    <meta property=sarest:operation content= http://lsdis.cs.uga.edu/
    ont.owl#Location_Search/>
</p>
...


 ...
 The logical input of this service is an http://lsdis.cs.uga.edu/ont.owl#Location_Query object.
 The logical output of this service is a list of http://lsdis.cs.uga.edu/ont.owl#Location objects.



                                                                                                     12
 This service should be invoked using an HTTP GET.
 ...
13   Tabella comparativa
                                     SAWSDL                    SA-REST

                   Scopo        Annotazione semantica            Mashup

         Prima sottomissione       novembre 2005              agosto 2007

          Modello semantico     OWL, RDF, DAML+OIL         RDFa, Microformati

                    Stato       W3C Recommendation      08 W3C Activity incubator

           Pub. scienti鍖che 1           148                         5

                 Citazioni 2            106                         3



     1) Fonte: Faceted DBLP
     2) Fonte: Bibsonomy.org/
150
                                                            SAWSDL       SA-REST
                                      135
                                                                                   122
                                      120

                                      105
     Numero di articoli scientifici




                                      90

                                      75

                                      60

                                      45

                                      30

                                            12                   14
                                      15



14
                                                        2                    2                  1
                                       0
                                                 2007                 2008               2009
Architettura
User




                     Annotation Service




                        SAWSDL4J / WSDL4J



                                                   Pellet Reasoner
            UDDI4J




                                                                     META
                                                                            Ontology repository

     UDDI




                     Discovery Service


16
17   Scenario duso
                 Natural language            To approve/reject
                   descriptions            suggested annotations




      WSDL 鍖le   CODEArchitects              CODEArchitects        SAWSDL 鍖le
                                    META
                 Annotation Tool             Annotation Tool
Mockup
19
20
21
22

     Sviluppi futuri

       Associazioni semantiche anche per Precondizioni ed Effetti: maggior
       automazione nella fase di composizione
Dibattito

More Related Content

Semantic Web Service Annotation

  • 1. Web Service Semantic Annotation SWAP Group - Dip. Informatica di Bari
  • 2. Outline Standard per lannotazione semantica SAWSDL: Semantic Annotations for WSDL and XML Schema SA-REST: Semantic Annotations for REST Tabella comparativa Architettura Scenario duso Mockup Sviluppi futuri 2
  • 4. Semantic Annotations for WSDL 4 and XML Schema [SAWSDL] Annotazione semantica di Web Service descritti tramite WSDL Insieme di attributi che estendono WSDL 2.0 Collega concetti presenti in una qualsiasi ontologia ad elementi del documento WSDL Non impone luso di alcun linguaggio speci鍖co per la rappresentazione del modello semantico E ulteriormente estendibile W3C Recommendation dal 28 Agosto 2007
  • 5. 5
  • 6. 6
  • 7. <wsdl:description targetNamespace="http://www.w3.org/2002/ws/sawsdl/spec/wsdl/order#" xmlns="http://www.w3.org/2002/ws/sawsdl/spec/wsdl/order#" xmlns:wsdl="http://www.w3.org/ns/wsdl" xmlns:xs="http://www.w3.org/2001/XMLSchema"> <wsdl:types> <xs:schema targetNamespace="http://www.w3.org/2002/ws/sawsdl/spec/wsdl/order#" elementFormDefault="qualified"> <xs:element name="OrderRequest"> ... </xs:element> <xs:complexType name="item"> ... </xs:complexType> <xs:element name="OrderResponse" type="confirmation" /> <xs:simpleType name="confirmation"> <xs:restriction base="xs:string"> <xs:enumeration value="Confirmed" /> <xs:enumeration value="Pending" /> <xs:enumeration value="Rejected" /> </xs:restriction> </xs:simpleType> </xs:schema> </wsdl:types> <wsdl:interface name="Order"> <wsdl:operation name="order" pattern="http://www.w3.org/ns/wsdl/in-out"> <wsdl:input element="OrderRequest" /> <wsdl:output element="OrderResponse" /> </wsdl:operation> </wsdl:interface> </wsdl:description> 7
  • 8. <wsdl:description targetNamespace="http://www.w3.org/2002/ws/sawsdl/spec/wsdl/order#" xmlns="http://www.w3.org/2002/ws/sawsdl/spec/wsdl/order#" xmlns:wsdl="http://www.w3.org/ns/wsdl" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:sawsdl="http://www.w3.org/ns/sawsdl"> <wsdl:types> <xs:schema targetNamespace="http://www.w3.org/2002/ws/sawsdl/spec/wsdl/order#" elementFormDefault="qualified"> <xs:element name="OrderRequest" sawsdl:modelReference="http://www.w3.org/2002/ws/sawsdl/spec/ontology/purchaseorder#OrderRequest" sawsdl:loweringSchemaMapping="http://www.w3.org/2002/ws/sawsdl/spec/mapping/RDFOnt2Request.xml"> ... </xs:element> <xs:complexType name="item"> ... </xs:complexType> <xs:element name="OrderResponse" type="confirmation" /> <xs:simpleType name="confirmation" sawsdl:modelReference="http://www.w3.org/2002/ws/sawsdl/spec/ontology/ purchaseorder#OrderConfirmation"> <xs:restriction base="xs:string"> <xs:enumeration value="Confirmed" /> <xs:enumeration value="Pending" /> <xs:enumeration value="Rejected" /> </xs:restriction> </xs:simpleType> </xs:schema> </wsdl:types> <wsdl:interface name="Order" sawsdl:modelReference="http://example.org/categorization/products/electronics"> <wsdl:operation name="order" pattern="http://www.w3.org/ns/wsdl/in-out" sawsdl:modelReference="http://www.w3.org/2002/ws/sawsdl/spec/ontology/ purchaseorder#RequestPurchaseOrder"> 8 <wsdl:input element="OrderRequest" /> <wsdl:output element="OrderResponse" /> </wsdl:operation> </wsdl:interface> </wsdl:description>
  • 9. 9
  • 10. 10
  • 11. Semantic Annotation for REST 11 [SA-REST] Automatizzare la fase di mediazione e composizione (mashup) di servizi RESTful Insieme di attributi che estendono (X)HTML (che non 竪 stato pensato per catturare le descrizioni di un servizio) Annota porzioni di codice (X)HTML che contengono descrizioni non machine- readable Utilizza RDFa, GRDDL o microformati (hCard, hCalendar, hResume) E ulteriormente estendibile
  • 12. <html xmlns:sarest=http://lsdis.cs.uga.edu/SAREST#> ... <p about= http://craigslist.org/search/> The logical input of this service is an <span property=sarest:input> http://lsdis.cs.uga.edu/ont.owl#Location_Query </span> object. The logical output of this service is a list of <span property=sarest:output> http://lsdis.cs.uga.edu/ont.owl#Location </span> objects. This service should be invoked using an <span property=sarest:action>HTTP GET</span>. <meta property=sarest:lifting content=http://craigslist.org/api/ lifting.xsl/> <meta property=sarest:lowering content=http://craigslist.org/api/ lowering.xsl/> <meta property=sarest:operation content= http://lsdis.cs.uga.edu/ ont.owl#Location_Search/> </p> ... ... The logical input of this service is an http://lsdis.cs.uga.edu/ont.owl#Location_Query object. The logical output of this service is a list of http://lsdis.cs.uga.edu/ont.owl#Location objects. 12 This service should be invoked using an HTTP GET. ...
  • 13. 13 Tabella comparativa SAWSDL SA-REST Scopo Annotazione semantica Mashup Prima sottomissione novembre 2005 agosto 2007 Modello semantico OWL, RDF, DAML+OIL RDFa, Microformati Stato W3C Recommendation 08 W3C Activity incubator Pub. scienti鍖che 1 148 5 Citazioni 2 106 3 1) Fonte: Faceted DBLP 2) Fonte: Bibsonomy.org/
  • 14. 150 SAWSDL SA-REST 135 122 120 105 Numero di articoli scientifici 90 75 60 45 30 12 14 15 14 2 2 1 0 2007 2008 2009
  • 16. User Annotation Service SAWSDL4J / WSDL4J Pellet Reasoner UDDI4J META Ontology repository UDDI Discovery Service 16
  • 17. 17 Scenario duso Natural language To approve/reject descriptions suggested annotations WSDL 鍖le CODEArchitects CODEArchitects SAWSDL 鍖le META Annotation Tool Annotation Tool
  • 19. 19
  • 20. 20
  • 21. 21
  • 22. 22 Sviluppi futuri Associazioni semantiche anche per Precondizioni ed Effetti: maggior automazione nella fase di composizione

Editor's Notes

  1. L&amp;#x2019;idea di collegamento/binding/associazione tra documento WSDL e concetto dell&amp;#x2019;ontologia.
  2. Mashup = opportuna e lecita composizione di servizi per la costruzione di un&amp;#x2019;applicazione; La fase di mashup &amp;#xE8; attualmente manuale, malgrado tool con interfacce grafiche evolute.
  3. Alcuni degli articoli su SAWSDL riguardano progetti framework operativi come FUSION, MWSAF (di METEOR-S), IBM Annotation Editor (di IBM Semantic Tools for Web Services)
  4. Annotazione di input, output (req. funzionale) e categoria del servizio (req. non funzionale)