Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

Building SADI Services Tutorial - SIB Workshop, Geneva, December 2015

694 views

Published on

The primary slide deck for the SADI tutorial. We explain the motivation, simple SADI services, more complex SADI services, and then do a detailed walk-through of building a service, including the Perl service code and examples of service invocation at the command line, and using the SHARE client. You will want to look at the sample data/queries in this slide deck: http://www.slideshare.net/markmoby/sample-data-and-other-ur-ls-55737183 and the example service code in this slide deck: http://www.slideshare.net/markmoby/example-code-for-the-sadi-bmi-calculator-web-service?related=1

Published in: Internet
  • Be the first to comment

Building SADI Services Tutorial - SIB Workshop, Geneva, December 2015

  1. 1. Beyond the Triplestore http://tiny.cc/SADI_Tutorial Slides, copy/paste code, and example data are all in this Google folder All content licensed CC-BY Mark D. Wilkinson, CBGP-UPM, Madrid markw@illuminae.com
  2. 2. Contact me anytime! markw@illuminae.com I’m the SADI “Helpdesk” :-)
  3. 3. First: Why SADI? Then: Examples of SADI simple Linked Data Followed by: Examples of SADI with “deep semantics” Finally: How to build it yourself!
  4. 4. Semantic Web Technologies
  5. 5. Semantic Web Technologies ?
  6. 6. Semantic Web Technologies ?TO ME: If you are using RDF or even OWL, without reasoning, then you are ‘doing’ Linked Data. When you start using a reasoner (or reasoning of some type) you are ‘doing’ Semantic Web
  7. 7. Semantic Web Technologies ?I will be showing how SADI can be used both as a straightforward Linked Data resource, and/or as a Semantic Web resource.
  8. 8. Semantic Web Technologies ?Key Message: You do not have to “get” OWL to use SADI effectively
  9. 9. The Web
  10. 10. The Semantic Web causally related to
  11. 11. In My Opinion, this is the critical bit! causally related to The link is explicitly labeled! ???
  12. 12. http://semanticscience.org/resource/SIO_000243 SIO_000243: <owl:ObjectProperty rdf:about="&resource;SIO_000243"> <rdfs:label xml: lang="en"> is causally related with</rdfs:label> <rdf:type rdf:resource="&owl;SymmetricProperty"/> <rdf:type rdf:resource="&owl;TransitiveProperty"/> <dc:description xml:lang="en"> A transitive, symmetric, temporal relation in which one entity is causally related with another non-identical entity. </dc:description> <rdfs:subPropertyOf rdf:resource="&resource;SIO_000322"/> </owl:ObjectProperty> causally related with
  13. 13. A lot of important information cannot be represented on the Semantic Web For example, all of the data that results from analytical algorithms and statistical analyses
  14. 14. Varying estimates put the size of the Deep Web between 500 and 800 times larger than the surface Web
  15. 15. On the WWW “automation” of access to Deep Web data happens through “Web Services”
  16. 16. There are many suggestions for how to bring the Deep Web into the Semantic Web using Semantic Web Services (SWS)
  17. 17. There are many suggestions for how to bring the Deep Web into the Semantic Web using Semantic Web Services (SWS) Describe input data Describe output data Describe how the system manipulates the data Describe how the world changes as a result
  18. 18. There are many suggestions for how to bring the Deep Web into the Semantic Web using Semantic Web Services (SWS) Describe input data Describe output data Describe how the system manipulates the data Describe how the world changes as a result None, so far, has proven to be wildly successful (in my opinion)
  19. 19. There are many suggestions for how to bring the Deep Web into the Semantic Web using Semantic Web Services (SWS) Describe input data Describe output data Describe how the system manipulates the data Describe how the world changes as a result None, so far, has proven to be wildly successful (in my opinion) …because describing what a Service does is HARD!
  20. 20. Lord, Phillip, et al. The Semantic Web–ISWC 2004 (2004): 350-364.
  21. 21. Lord, Phillip, et al. The Semantic Web–ISWC 2004 (2004): 350-364.
  22. 22. Lord, Phillip, et al. The Semantic Web–ISWC 2004 (2004): 350-364.
  23. 23. Scientific Web Services are DIFFERENT! They’re simpler! So perhaps we can solve the Semantic Web Service problem as it pertains to this (important!) domain
  24. 24. With respect to the Semantic Web What is missing from this list? Describe input data Describe output data Describe how the system manipulates the data Describe how the world changes as a result
  25. 25. http://semanticscience.org/resource/SIO_000243 causally related with
  26. 26. http://semanticscience.org/resource/SIO_000243 The Semantic Web gets its power from relationships causally related with
  27. 27. Relationships are not on this list… and that seemed to me to be a huge oversight! Describe input data Describe output data Describe how the system manipulates the data Describe how the world changes as a result
  28. 28. http://semanticscience.org/resource/SIO_000243 In 2008 I published a set of design-patterns for scientific Semantic Web Services that focuses on the biological relationship that the Service “exposes” causally related with
  29. 29. AACTCTTCGTAGTG... BLAST Web Service
  30. 30. AACTCTTCGTAGTG... BLAST sequenceX has_seq_string
  31. 31. AACTCTTCGTAGTG... BLAST has homology to Terminal Flower type gene species A. thal. sequenceX has_seq_string AACTCTTCGTAGTG... sequenceX has_seq_string
  32. 32. AACTCTTCGTAGTG... BLAST has homology to Terminal Flower type gene species A. thal. SADI requires you to explicitly declare as part of your analytical output, the biological relationship between the input and the output that your algorithm “exposed”. sequenceX has_seq_string AACTCTTCGTAGTG... sequenceX has_seq_string
  33. 33. If SADI produces Linked Data, can we interact with it like any other Linked Data resource?
  34. 34. “Semantic Health And Research Environment” SPARQL + SADI + Workflows + OWL Reasoning
  35. 35. The SHARE registry indexes all of the input/output/relationship triples that can be generated by all known SADI services SHARE is then able to discover Services that will generate the data that it needs to answer the SPARQL query
  36. 36. What is the phenotype of every allele of the Antirrhinum majus DEFICIENS gene SELECT ?allele ?image ?desc WHERE { locus:DEF genetics:hasVariant ?allele . ?allele info:visualizedByImage ?image . ?image info:hasDescription ?desc }
  37. 37. What is the phenotype of every allele of the Antirrhinum majus DEFICIENS gene SELECT ?allele ?image ?desc WHERE { locus:DEF genetics:hasVariant ?allele . ?allele info:visualizedByImage ?image . ?image info:hasDescription ?desc } Note that there is no “FROM” clause! We don’t tell it where it should get the information, The machine has to figure that out by itself...
  38. 38. What is the phenotype of every allele of the Antirrhinum majus DEFICIENS gene SELECT ?allele ?image ?desc WHERE { locus:DEF genetics:hasVariant ?allele . ?allele info:visualizedByImage ?image . ?image info:hasDescription ?desc } Starting data: the locus “DEF” (Deficiens) (the “bound” variable in the query)
  39. 39. What is the phenotype of every allele of the Antirrhinum majus DEFICIENS gene SELECT ?allele ?image ?desc WHERE { locus:DEF genetics:hasVariant ?allele . ?allele info:visualizedByImage ?image . ?image info:hasDescription ?desc } Query: A series of relationships v.v. DEF
  40. 40. Enter that query into SHARE
  41. 41. Click “Submit”...
  42. 42. ...and in a few seconds you get your answer. Based on the relationships in your query, SHARE queried its registry to automatically discover SADI Services capable of generating those triples
  43. 43. This is Linked Data, like any other…
  44. 44. What pathways does UniProt protein P47989 belong to? PREFIX pred: <http://sadiframework.org/ontologies/predicates.owl#> PREFIX ont: <http://ontology.dumontierlab.com/> PREFIX uniprot: <http://lsrn.org/UniProt:> SELECT ?gene ?pathway WHERE { uniprot:P47989 pred:isEncodedBy ?gene . ?gene ont:isParticipantIn ?pathway . }
  45. 45. What pathways does UniProt protein P47989 belong to? PREFIX pred: <http://sadiframework.org/ontologies/predicates.owl#> PREFIX ont: <http://ontology.dumontierlab.com/> PREFIX uniprot: <http://lsrn.org/UniProt:> SELECT ?gene ?pathway WHERE { uniprot:P47989 pred:isEncodedBy ?gene . ?gene ont:isParticipantIn ?pathway . }
  46. 46. What pathways does UniProt protein P47989 belong to? PREFIX pred: <http://sadiframework.org/ontologies/predicates.owl#> PREFIX ont: <http://ontology.dumontierlab.com/> PREFIX uniprot: <http://lsrn.org/UniProt:> SELECT ?gene ?pathway WHERE { uniprot:P47989 pred:isEncodedBy ?gene . ?gene ont:isParticipantIn ?pathway . } Note again that there is no “From” clause… I have not told SHARE where to look for the answer, I am simply asking my question
  47. 47. Enter that query into SHARE
  48. 48. Two different providers of gene information (KEGG & NCBI); were found & accessed Two different providers of pathway information (KEGG and GO); were found & accessed
  49. 49. Again, the results are all links to the original data
  50. 50. These were examples where SADI/SHARE was used for “simple” Linked Data exploration What does it look like when we start pushing Semantics? Please be assured - you DO NOT have to understand this next piece in order to use SADI. This is just “the icing on the cake” “c'est la cerise sur le gâteau” “la guinda del pastel” “die Krönung des Ganzen”
  51. 51. Show me the latest Blood Urea Nitrogen and Creatinine levels of patients who appear to be rejecting their transplants PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> PREFIX patient: <http://sadiframework.org/ontologies/patients.owl#> PREFIX l: <http://sadiframework.org/ontologies/predicates.owl#> SELECT ?patient ?bun ?creat FROM <http://sadiframework.org/ontologies/patients.rdf> WHERE { ?patient rdf:type patient:LikelyRejecter . ?patient l:latestBUN ?bun . ?patient l:latestCreatinine ?creat . }
  52. 52. Show me the latest Blood Urea Nitrogen (BUN) and Creatinine levels of patients who appear to be rejecting their transplants PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> PREFIX patient: <http://sadiframework.org/ontologies/patients.owl#> PREFIX l: <http://sadiframework.org/ontologies/predicates.owl#> SELECT ?patient ?bun ?creat FROM <http://sadiframework.org/ontologies/patients.rdf> WHERE { ?patient rdf:type patient:LikelyRejecter . ?patient l:latestBUN ?bun . ?patient l:latestCreatinine ?creat . }
  53. 53. Likely Rejecter: A patient who has creatinine levels that are increasing over time - - Mark D Wilkinson’s definition
  54. 54. Likely Rejecter: …but there is no “likely rejecter” column or table in our database… only blood chemistry measurements at various time-points
  55. 55. Likely Rejecter: So the data required to answer this question DOESN’T EXIST!
  56. 56. My definition of a Likely Rejecter is encoded in a machine-readable document written in the OWL Ontology language Basically: “the regression line over creatinine measurements should have an increasing slope”
  57. 57. Our ontology refers to other ontologies (possibly published by other people) to learn about what the properties of “regression models” are e.g. that regression models have slopes and intercepts and that slopes and intercepts have decimal values
  58. 58. ?
  59. 59. Enter that query into SHARE
  60. 60. Based on the Class definition SHARE decides that it needs to do a Linear Regression analysis on the blood creatinine measurements
  61. 61. ?
  62. 62. The conversation between SHARE and the registry reveals the use of “Deep Semantics” Q: Is there a SADI service that will consume instances of Patient and give me instances of LikelyRejector A: No Q: Okay... LikelyRejectors need a regression model of increasing slope over their BloodCreatinine, so... Is there a SADI service that will consume BloodCreatinine over time and give me its linear regression model? A: No Q: Okay... Blood Creatinine over time is a subclass of data of type X/Y coordinate, so is there a service that consumes X/Y data and returns its regression model? A: Yes → here’s the Service URL.
  63. 63. The SHARE system utilizes DL Reasoning over SADI interface definitions to discover analytical services that do linear regression analysis → sends the data to be analyzed
  64. 64. This happens iteratively (e.g. SHARE also has to examine the slope of the regression line using another service, find the “latest” in a series of time measurements, etc.) There is reasoning after every Service invocation (i.e. after every clause in the query) Once it is able to find instances (OWL Individuals) of the LikelyRejector class, it continues with the rest of the query
  65. 65. VOILA!
  66. 66. The way SHARE “interprets” data varies depending on the context of the query (i.e. which ontologies it reads – Mine? Yours?) and on what part of the query it is trying to answer at any given moment (which ontological concept is relevant to that clause)
  67. 67. Example? Blood Creatinine measurements were not dictated to be Blood Creatinine measurements
  68. 68. Example? The data had the ‘qualities/properties’ that allowed one machine to interpret that they were Blood Creatinine measurements (e.g. to determine which patients were rejecting)
  69. 69. Example? But the data also had the ‘qualities/properties’ that allowed another machine to interpret them as Simple X/Y coordinate data (e.g. the Linear Regression calculation tool)
  70. 70. Benefit of Deep Semantics Data is amenable to constant re-interpretation
  71. 71. http://www.flickr.com/people/faernworks/
  72. 72. We will examine SADI mainly as a source of Linked Data We will not spend much time thinking about the Semantics of our services or their interfaces
  73. 73. 2 Contents 1. Introduction to Semantic Web Services 2. Introduction to SADI services 3. SADI service ontologies 4. SADI service generator 5. SADI and SAWSDL 6. SADI clients
  74. 74. 2.1.3 Motivation for SADI ▪▪ simple “perfection is finally attained not when there is no longer anything to add, but when there is no longer anything to take away” ▪▪ powerful “everything should be as simple as it can be, but not simpler” ▪▪ flexible “SADI: there’s nothing to it”
  75. 75. 2.2 Introduction to SADI Services 2. Introduction to SADI Services 1. What is a SADI service? 2. Why use SADI services? 3. Requirements for SADI compliance 4. Calling a SADI service 5. Advanced SADI features 6. The SADI registry
  76. 76. 2.2.1 What is a SADI service? ● SADI services ○ use simple HTTP operations ■ (no project-specific protocol) ○ consume and produce RDF data ■ (no project-specific message scaffolding) ○ use OWL to describe service interface (use existing ontologies and especially existing properties)
  77. 77. 2.2.1 What is a SADI service? ● input is an RDF graph ○ rooted at a particular node ○ described by an OWL class ● output is an RDF graph ○ rooted at the same node ○ described by another OWL class
  78. 78. 2.2.1 What is a SADI service? ● explicit relationship between input and output ○ transparent service operation semantics ● machine-understandable description of the service interface ○ easy service discovery and integration
  79. 79. 2.2.2 Why use SADI services? Input height weight SADI Service Output BMI ID Name Height Weight Age 24601 7474505B 6 Jean Valjean Jake Blues — ... 1.8m 1.73m 1.88m ... 84kg 101kg 75kg ... 45 31 39 ... Client BMI
  80. 80. 2.2.2 Why use SADI services? Input height weight SADI Service Output BMI ID Name Height Weight Age 24601 7474505B 6 Jean Valjean Jake Blues — ... 1.8m 1.73m 1.88m ... 84kg 101kg 75kg ... 45 31 39 ... Client BMI #24601 1.8m 84kg height weight
  81. 81. 2.2.2 Why use SADI services? Input height weight SADI Service Output BMI ID Name Height Weight Age 24601 7474505B 6 Jean Valjean Jake Blues — ... 1.8m 1.73m 1.88m ... 84kg 101kg 75kg ... 45 31 39 ... Client BMI #24601 25.9 BMI 25.9
  82. 82. 2.2.2 Why use SADI services? @prefix rdf: @prefix rdfs: @prefix xsd: @prefix mged: @prefix foaf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> . <http://www.w3.org/2000/01/rdf-schema#> . <http://www.w3.org/2001/XMLSchema#> . <http://mged.sourceforge.net/ontologies/MGEDOntology.owl#> . <http://xmlns.com/foaf/0.1/> . <http://sadiframework.org/examples/bmi-input.rdf#patient24601> bmi:BMI "25.9"^^xsd:double ; foaf:name "Jean Valjean"^^xsd:string ; mged:has_height [ a mged:Measurement ; mged:has_units mged:m ; mged: has_value "1.8"^^xsd:double ] ; mged:has_mass [ a mged:Measurement ; mged:has_units mged:kg ; mged: has_value "84"^^xsd:double ] . Client 24601 1.8m 84kg height weight BMI 25.9
  83. 83. 2.2.2 Why use SADI services? sadi: <http://sadiframework.org/ontologies/predicates.owl#> sadi: <http: //sadiframework.org/ontologies/predicates.owl#> dumontier: <http://ontology.dumontierlab.com/> kegg: <http://lsrn.org/KEGG_PATHWAY:> ?gene ?protein ?seq PREFIX PREFIX PREFIX SELECT WHERE { kegg:hsa00232 dumontier:hasParticipant ?gene . ?gene sadi:encodes ?protein . ?protein sadi:hasSequence ?seq } Service Service Servic e Similar to “Federated Queries”… but are actually Web Service Workflows
  84. 84. 2.2.3 Requirements for SADI compliance ● Identified by an HTTP URL ○ used to identify the service ■ (service URI) ○ used to invoke the service ■ (service URL) http://sadiframework.org/examples/hello
  85. 85. 2.2.3 Requirements for SADI compliance •Responds to HTTP GET with service interface def. •RDF document •Service definition instance identified by service URI •(see §2.3.1 for specifics) •Indicates input OWL class and output OWL class • (among other things) http://sadiframework.org/examples/hello
  86. 86. http://sadiframework.org/examples/hello input OWL class is http://sadiframework.org/examples/hello.owl#NamedIndividual output OWL class is http://sadiframework.org/examples/hello.owl#GreetedIndividual 2.2.3 Requirements for SADI compliance
  87. 87. 2.2.3 Requirements for SADI compliance ● Responds to HTTP POST by invoking service ○ input is an RDF document ■ contains input OWL class instances ○ output is an RDF document ■ contains output OWL class instances ● one for each input instance ● Input/output instance share same URI http://sadiframework.org/examples/hello
  88. 88. http://sadiframework.org/examples/hello input: @prefix hello: <http://sadiframework.org/examples/hello.owl#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . <http://sadiframework.org/examples/hello-input.rdf#1> a hello:NamedIndividual ; foaf:name "Guy Incognito" . output: @prefix hello: <http://sadiframework.org/examples/hello.owl#> . <http://sadiframework.org/examples/hello-input.rdf#1> a hello:GreetedIndividual ; hello:greeting "Hello, Guy Incognito!" . 2.2.3 Requirements for SADI compliance
  89. 89. 2.2.3 Requirements for SADI compliance ● Indicates error with appropriate HTTP status ○ usually 500 Internal Service Error ○ may return RDF describing the error
  90. 90. 2.2.4 Calling a SADI service 1. Client sends POST request to service URL ● POST body is an RDF document ○ contains input OWL class instances ○ input serialization specified in Content-type HTTP header application/rdf+xml text/rdf+n3 ○ output serialization requested in Accept HTTP header
  91. 91. POST /examples/hello HTTP/1.1 Host: sadiframework.org Content-type: text/rdf+n3 Accept: text/rdf+n3 @prefix hello: <http://sadiframework.org/examples/hello.owl#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . <http://sadiframework.org/examples/hello-input.rdf#1> a hello:NamedIndividual ; foaf:name "Guy Incognito" . 2.2.4 Calling a SADI service
  92. 92. POST /examples/hello HTTP/1.1 Host: sadiframework.org Content-type: text/rdf+n3 Accept: text/rdf+n3 @prefix hello: <http://sadiframework.org/examples/hello.owl#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . <http://sadiframework.org/examples/hello-input.rdf#1> a hello:NamedIndividual ; foaf:name "Guy Incognito" . 2.2.4 Calling a SADI service Note that there is NO special message structure! This is not like SOAP!
  93. 93. 2.2.4 Calling a SADI service 2. Service responds with output ● response body is an RDF document ○ contains output OWL class instances ● serialization specified in ○ Content-type HTTP header application/rdf+xml text/rdf+n3
  94. 94. HTTP/1.1 200 OK Content-type: text/rdf+n3 @prefix hello: <http://sadiframework.org/examples/hello.owl#> . <http://sadiframework.org/examples/hello-input.rdf#1> a hello:GreetedIndividual ; hello:greeting "Hello, Guy Incognito!" . 2.2.4 Calling a SADI service
  95. 95. 2.2.5 Advanced SADI features 5. Advanced SADI features a. Asynchronous SADI services b. Parameterized SADI services
  96. 96. 2.2.5.a Asynchronous SADI services ● Problem ○ HTTP timeout if a service takes too long to respond ● Solution ○ service returns stub immediately; client polls for complete response
  97. 97. 2.2.5.a Asynchronous SADI services 1. Client sends POST request to service URL ● POST body is an RDF document ○ contains input OWL class instances ● input serialization specified in Content-type HTTP header application/rdf+xml text/rdf+n3 ● output serialization requested in Accept HTTP header (Exactly the same as before….)
  98. 98. POST /examples/hello HTTP/1.1 Host: sadiframework.org Content-type: text/rdf+n3 Accept: text/rdf+n3 @prefix hello: <http://sadiframework.org/examples/hello.owl#> . @prefix foaf: <http://xmlns.com/foaf/0.1/> . <http://sadiframework.org/examples/hello-input.rdf#1> a hello:NamedIndividual ; foaf:name "Guy Incognito" . 2.2.5.a Asynchronous SADI services
  99. 99. 2.2.5.a Asynchronous SADI services 2. Service responds with stub ● HTTP response code is: 202 Accepted but incomplete ● response body is an RDF document contains output OWL class instances composed of rdfs: isDefinedBy statements ● serialization specified in: Content-type HTTP header application/rdf+xml, text/rdf+n3, etc
  100. 100. HTTP/1.1 202 Accepted Content-type: text/rdf+n3 @prefix hello: <http://sadiframework.org/examples/hello.owl#> . @prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> . <http://sadiframework.org/examples/hello-input.rdf#1> a hello:GreetedIndividual ; rdfs:isDefinedBy <http://sadiframework.org/examples/hello?poll=1> . 2.2.5.a Asynchronous SADI services
  101. 101. 2.2.5.a Asynchronous SADI services 3. Client fetches asynchronous data ● fetch the object URL of each rdfs:isDefinedBy statement GET /examples/hello?poll=1 HTTP/1.1 Host: sadiframework.org
  102. 102. 2.2.5.a Asynchronous SADI services 4. Until output is ready ● service sends an HTTP 302 redirect Retry-after HTTP header suggests how long the client should wait (in seconds) HTTP/1.1 302 Moved Temporarily Retry-After: 30 Location: http://sadiframework.org/examples/hello?poll=1
  103. 103. 2.2.5.a Asynchronous SADI services 5. Client follows redirect ● after waiting as suggested by Retry-after HTTP header GET /examples/hello?poll=1 HTTP/1.1 Host: sadiframework.org
  104. 104. 2.2.5.a Asynchronous SADI services 6. When output is ready ● response body is an RDF document should be combined with original response HTTP/1.1 200 OK Content-type: text/rdf+n3 @prefix hello: <http://sadiframework.org/examples/hello.owl#> . <http://sadiframework.org/examples/hello-input.rdf#1> a hello:GreetedIndividual ; hello:greeting "Hello, Guy Incognito!" .
  105. 105. 2.2.6 The SADI registry ● clients need to find SADI services ○ ideally just search the Web for instances of the SADI service description class ■ current technology isn’t quite there ● use the SADI registry ○ SPARQL endpoint, Java and REST APIs ○ anyone can register a service ○ services are indexed by the properties they attach
  106. 106. 2.2.6 The SADI registry SADI registry http://sadiframework.org/registry/ SPARQL endpoint http://sadiframework.org/registry/sparql REST API http://sadiframework.org/registry/api/
  107. 107. 2.3.2 Input and output OWL classes 2. Input and output OWL classes a. Input OWL classes b. Output OWL classes
  108. 108. 2.3.2 Input and output OWL classes 2. Input and output OWL classes a. Input OWL classes b. Output OWL classes Remember the OWL2 presentation yesterday by Frédéric Bestian… The dangers of OWL reasoning!
  109. 109. 2.3.2 Input and output OWL classes 2. Input and output OWL classes a. Input OWL classes b. Output OWL classes Human equivalent to (leg minimum cardinality 2) → you not human if you lose a leg
  110. 110. 2.3.2 Input and output OWL classes 2. Input and output OWL classes a. Input OWL classes b. Output OWL classes Do SADI Services suffer this problem?
  111. 111. 2.3.2 Input and output OWL classes 2. Input and output OWL classes a. Input OWL classes b. Output OWL classes Do SADI Services suffer this problem? NO! We are not trying to “understand” the world!
  112. 112. 2.3.2 Input and output OWL classes 2. Input and output OWL classes a. Input OWL classes b. Output OWL classes Do SADI Services suffer this problem? NO! We are only trying to discover acceptable input
  113. 113. 2.3.2 Input and output OWL classes 2. Input and output OWL classes a. Input OWL classes b. Output OWL classes If my analysis requires that you have 2 legs and you have only one leg... YOU ARE NOT A CANDIDATE FOR MY ANALYSIS. PERIOD.
  114. 114. 2.3.2 Input and output OWL classes 2. Input and output OWL classes a. Input OWL classes b. Output OWL classes If my analysis requires that you have 2 legs and you have only one leg... ...my service isn’t interested in whether or not you are human… it only wants your legs!
  115. 115. 2.4.1 Exercise Create a SADI service that takes height and weight as input and attaches BMI.
  116. 116. SADI Services in Perl The Perl module in CPAN is: SADI::Simple Example Service Code: https://docs.google.com/document/d/1HrFNxG2-eZhiaCaBjNLcAtHPY_-MLCw9BwFmnw4BHKQ/edit?usp=sharing Example Data and other information: https://docs.google.com/document/d/1DdWux6w3RzMGexFHf9roRuJnCiDaxWJScECK4POg6RQ/edit?usp=sharing

×