Thing Description (TD) Serialization

Web of Things (WoT) Working Group

Thing Description (TD) Serialization

F2F Düsseldorf - July 2017

Daniel Peintner

Table of Contents

  1. TD Serialization Goals
  2. Candidates
  3. Evaluation / Comparison (Preliminary Results)

Goals

Identify suitable serialization formats for WoT Thing Description

What is important for WoT TD format

Possible Candidates

Text-based

  • JSON-LD
  • JSON
  • RDFa/XML
  • ???

Binary-based

  • EXI4JSON
  • CBOR
  • Smile
  • ???

Text-based - Current JSON-LD Example

{
  "@context": ["http://w3c.github.io/wot/w3c-wot-td-context.jsonld"],
  "@type": ["Thing"],
  "name": "MyTemperatureThing",
  "interaction": [{
      "@type": ["Property"],
      "name": "temperature",
      "outputData": { "type": "number" },
      "writable": false,
      "link": [{
        "href" : "coap://mytemp.example.com:5683/temp",
        "mediaType": "application/json"
        }]
  }]
}
			

Text-based - What is next
Compare acceptance of JSON-LD vs. JSON vs. RDF vs ???

TD Serialization test-bed

Measurements Osaka PlugFest

Measurements Düsseldorf PlugFest

Outlook
How can we improve even further

Optimized JSON-LD Example

{
  "@context": ["http://w3c.github.io/wot/w3c-wot-td-context.jsonld"],
  "@type": ["Thing"],
  "name": "MyTemperatureThing",
  "interaction": [{
      "@type": ["Property"],
      "name": "temperature",
      "outputData": { "type": "number" },
      "writable": false,
      "link": [{
        "href": "coap://mytemp.example.com:5683/temp",
        "mediaType": "application/json"
        }]
  }]
}
			

Measurements PlugFests

Any Questions?

Thanks for your attention!