Skip to content
This repository has been archived by the owner. It is now read-only.
Web Of Things Thing Ontology
Branch: cocktail_dev
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.
legacy to be refactored


Within this repository we store all the necessary to start with a Web Of Things implementation.

1. WoT Ontology

The file called wot_ontology.owl contains the ontology we use to represent things. The Classes are

  1. Thing
  2. InteractionPattern (Action, Event, Property)
  3. DataSchema
  4. FieldSchema

And some others that are going to be described in a paper soon.

2. Cocktail python3 framework

Requiring Sepy, you can use the framework to create applications. First you have to run a SEPA instance, then just read up the documentation of the framework.

You should not need to know SPARQL to use Cocktail. However, for very special needs, in the package there are all the basic SPARQL that the framework uses, from which you can take inspiration, and then apply sepy to perform your queries.

$ python3 build
$ python3 sdist
$ sudo python3 \[install|develop\]

3. Tests

For now, tests are available only to check ontology consistency.

$ python3 test

4. Examples


To have an example on how to make a WebThing, have a look to the following files.

  2. tools/
  3. tools/ and in the tests of the cocktail package. Notice that (1) is also useful to see what happens when you start using the tool. (2) is a nice runnable script to observe a specific event notifications.
Available tools and experiments

While tools/ and tools/ are useful to learn how to program with Cocktail, they are also invokable from the python command line. Please refer to their -h argument to see how to invoke them.

There is also tools/ A typical experiment with consists in 0. Run the SEPA

  1. open a terminal, and run
$ cd tools
$ python3 ../
  1. Open another terminal, and run
$ python3
  1. call discover
  2. call events
  3. choose
  4. see that tools/ is called from
  5. again from, call discover
  6. call actions
  7. choose an action available
  8. see that tools/ is called from and that it prompts you for some input, if the action needs it.
  9. enjoy


Feel free to get in touch, if you have any question or suggestions

You can’t perform that action at this time.