Arkadiusz Ryś пре 2 година
родитељ
комит
dedcbe76e1
1 измењених фајлова са 39 додато и 92 уклоњено
  1. 39 92
      README.rst

+ 39 - 92
README.rst

@@ -14,98 +14,7 @@ The translated prefixes can be extended:
    # Functions and services
    [[prefixes]]
    name = "dtf"
-   namespace = "https://ontology.rys.app/dt/function/"
-   # Generic
-   [[prefixes]]
-   name = "owl"
-   namespace = "http://www.w3.org/2002/07/owl#"
-   [[prefixes]]
-   name = "rdf"
-   namespace = "http://www.w3.org/1999/02/22-rdf-syntax-ns#"
-   [[prefixes]]
-   name = "xsd"
-   namespace = "http://www.w3.org/2001/XMLSchema#"
-   [[prefixes]]
-   name = "rdfs"
-   namespace = "http://www.w3.org/2000/01/rdf-schema#"
-   [[prefixes]]
-   name = "dc"
-   namespace = "http://purl.org/dc/elements/1.1/"
-   [[prefixes]]
-   name = "vim4"
-   namespace = "http://bipm.org/jcgm/vim4#"
-   [[prefixes]]
-   name = "swrl"
-   namespace = "http://www.w3.org/2003/11/swrl#"
-   # Digital Twin Design
-   ## Drivetrain
-   [[prefixes]]
-   name = "dart"
-   namespace = "http://ua.be/drivetrain/description/artifacts/artifacts#"
-   [[prefixes]]
-   name = "dftg"
-   namespace = "http://ua.be/drivetrain/description/ftg#"
-   ## SDO2L
-   [[prefixes]]
-   name = "acyclic"
-   namespace = "http://ua.be/sdo2l/vocabulary/base/acyclic#"
-   [[prefixes]]
-   name = "base"
-   namespace = "http://ua.be/sdo2l/vocabulary/base/base#"
-   [[prefixes]]
-   name = "file"
-   namespace = "http://ua.be/sdo2l/vocabulary/formalisms/file#"
-   [[prefixes]]
-   name = "ftg"
-   namespace = "http://ua.be/sdo2l/vocabulary/formalisms/ftg#"
-   [[prefixes]]
-   name = "traces"
-   namespace = "http://ua.be/sdo2l/vocabulary/formalisms/processtraces#"
-   [[prefixes]]
-   name = "shaclproperty"
-   namespace = "http://ua.be/sdo2l/vocabulary/formalisms/shaclproperty#"
-   [[prefixes]]
-   name = "system"
-   namespace = "http://ua.be/sdo2l/vocabulary/formalisms/system#"
-   [[prefixes]]
-   name = "violation"
-   namespace = "http://ua.be/sdo2l/vocabulary/formalisms/violation#"
-   [[prefixes]]
-   name = "code"
-   namespace = "http://ua.be/sdo2l/vocabulary/formalisms/code#"
-   [[prefixes]]
-   name = "component"
-   namespace = "http://ua.be/sdo2l/vocabulary/formalisms/component#"
-   [[prefixes]]
-   name = "csas"
-   namespace = "http://ua.be/sdo2l/vocabulary/formalisms/cs_as#"
-   [[prefixes]]
-   name = "dict"
-   namespace = "http://ua.be/sdo2l/vocabulary/formalisms/dict#"
-   [[prefixes]]
-   name = "drawio"
-   namespace = "http://ua.be/sdo2l/vocabulary/formalisms/drawio#"
-   [[prefixes]]
-   name = "object_diagram"
-   namespace = "http://ua.be/sdo2l/vocabulary/formalisms/object_diagram#"
-   [[prefixes]]
-   name = "pm"
-   namespace = "http://ua.be/sdo2l/vocabulary/formalisms/pm#"
-   [[prefixes]]
-   name = "requirement"
-   namespace = "http://ua.be/sdo2l/vocabulary/formalisms/requirement#"
-   [[prefixes]]
-   name = "richtext"
-   namespace = "http://ua.be/sdo2l/vocabulary/formalisms/richtext#"
-   [[prefixes]]
-   name = "script"
-   namespace = "http://ua.be/sdo2l/vocabulary/formalisms/script#"
-   [[prefixes]]
-   name = "tabular"
-   namespace = "http://ua.be/sdo2l/vocabulary/formalisms/tabular#"
-   [[prefixes]]
-   name = "text"
-   namespace = "http://ua.be/sdo2l/vocabulary/formalisms/text#"
+   ...
    [[prefixes]]
    name = "traceability_model"
    namespace = "http://ua.be/sdo2l/vocabulary/formalisms/traceability_model#"
@@ -200,6 +109,44 @@ At this point, you can execute the query by clicking the Query button.
 The list of corresponding individuals will now be visible in the Results panel.
 You can now use these results to further query the graph.
 
+Outlier detection workflow demo
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+To give a concrete example, we follow a workflow for figuring out outliers in a CSV file created during the `enactment process <https://msdl.uantwerpen.be/git/lucasalbertins/wee/wiki/Basic+Tutorial>`_.
+You start by opening the GUI.
+You can then double-check the settings, like the endpoint.
+If all settings are correct, you can proceed by choosing the `Outlier Function` in the `Query Palette`.
+
+The `Visual Query Editor` will now have the following `Query` pre-set for you.
+
+.. code-block:: sql
+
+   SELECT ?outlier ?outlier_relation ?outlier_value WHERE {
+     SERVICE <{{ service_endpoint }}> {
+       SELECT ?outlier ?outlier_relation ?outlier_value WHERE {
+         BIND(dtf:outlier("{{ outlier_file }}", "{{ outlier_column }}", "{{ outlier_artifact }}") AS ?outlier)
+       }
+     }
+   }
+
+You don't need to understand the SPARQL query itself. What you are likely interested in are the fields below the `Query`.
+
+- `http://127.0.0.1:8000/`
+- `rotation.csv`
+- `2`
+- `<http://ua.be/drivetrain/description/artifacts/artifacts#drivetrain-sensor-data-v1>`
+
+They are, in sequential order, the service, the file, the column, and the artifact URI.
+The first field, `http://127.0.0.1:8000/`, is the `URI to a (in this case local) service for outliers <https://msdl.uantwerpen.be/git/arys/spendpoint>`_ we provide.
+
+Once you're satisfied with the fields you filled in you can gently press the `Query` button.
+You should be greeted by a results resembling the following image.
+
+.. |results| image:: docs/results.png
+   :alt: Screenshot including the results of an outlier query
+   :width: 100%
+
+Congratulations! You have successfully performed outlier detection on the enactment artifact.
 
 Advanced usage
 --------------