IPTC News in JSON AGM 2013

670 views
615 views

Published on

Standardizing the representation of news in JSON

Published in: Technology
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
670
On SlideShare
0
From Embeds
0
Number of Embeds
1
Actions
Shares
0
Downloads
4
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

IPTC News in JSON AGM 2013

  1. 1. News in JSONStuart Myles * Associated Press * 25th June 2013http://www.flickr.com/photos/anirudhkoul/3536413126/
  2. 2. Remind Me: What is JSON?JSON = JavaScript Object Notation http://json.org/Name / value pairs: a fieldname in quotes, a colon, a value in quotes"givenname" : "Stuart"Objects: written inside curly braces, may contain multiple NVPs{"givenname" : "Stuart", "familyname" : "Myles"}Arrays: Written inside square braces, may contain multiple objects{"iptcdelegates": [{"givenname": "Dave", "familyname": "Compton"},{"givenname": "Stuart", "familyname": "Myles"},{"givenname": "Robert", "familyname": "Schmidt-Nia"}]}© 2013 IPTC (www.iptc.org) All rights reserved 2
  3. 3. Remind Me: Why News in JSON?Lightweight, easy to parse formatIncreasingly popular alternative to / replacement for XMLTwo principle use cases:data interchange (e.g. APIs) with more emphasis on partialrepresentationdata at rest (e.g. search engines like Elastic Search or MongoDB)Not simply translating from an existing XML standard into JSONDetermine how to represent key properties and structuresHand crafted, rather than mechanically translating from XML into JSONGoal: comprehensive standard, lightweight instance documents© 2013 IPTC (www.iptc.org) All rights reserved 3
  4. 4. News in JSON Activityhttp://www.flickr.com/photos/jondresner/5789254800/News In JSON Activityhttp://www.flickr.com/photos/jondresner/5789254800/
  5. 5. News in JSON Activityhttp://www.flickr.com/photos/jondresner/5789254800/News In JSON Activityhttp://www.flickr.com/photos/jondresner/5789254800/NINJANINJS
  6. 6. NINJS Overview© 2013 IPTC (www.iptc.org) All rights reserved 6
  7. 7. NINJS Data Model© 2013 IPTC (www.iptc.org) All rights reserved 7
  8. 8. NINJS Highlight #1Descriptive MetadataSame basic structurebut differing properties per type and preference"place" : [{"name" : "New York City","name@ru" : "Нью-Йорк","why" : "direct","how" : "extracted","rel" : "about","scheme" : "http://data.example.com/","code" : "N46020133052049607171"}],"subject" : [{"name": "Data-Mining & Database Marketing","rel" : "about"}]© 2013 IPTC (www.iptc.org) All rights reserved 8
  9. 9. NINJS Highlight #2Text MarkupA single object with a property per text markup type"body" : {"text": "It was a case for a digitalSherlock Holmes.","html": "<b>It was a case for a digitalSherlock Holmes.","iptc7901" : "It was a case for a digitalSherlock Holmes.u201d","nitf": "<p>It was a case for a digitalSherlock Holmes.</p>","xhtml": "<p>It was a case for a digitalSherlock Holmes.</p>"}© 2013 IPTC (www.iptc.org) All rights reserved 9
  10. 10. NINJS Highlight #3Associations and Representations• NINJS is a JSON representation of a news item• You can represent a complete item, with all properties– For instance in an internal CMS like MongoDB• Or you may want to convey key properties– For instance as an API response• The representationtype property indicates how complete• Associations are themselves NINJS documents– You may include complete or partial representations© 2013 IPTC (www.iptc.org) All rights reserved 10
  11. 11. JSON-LD• JSON for Linked Data• A W3C effort to add conventions to JSON documents tosupport Linked Data concepts, currently in last call• http://www.w3.org/TR/json-ld/• Do we want to adopt any of the JSON-LD conventionsfor NINJS?• Or would it create too much of a burden for clients?© 2013 IPTC (www.iptc.org) All rights reserved 11
  12. 12. NINJS Spec• Reference document– https://www.stypi.com/Td4K2niLwPJRbIM697EYTtEO• Working document– https://www.stypi.com/pZxwJ2pADLcb77Vw64gfn9HA• JSON Schema– http://json-schema.org/– Not entirely real but better than inventing our own– https://www.stypi.com/D7GbLXJUugfrLOlDezCr49jt• How strict?– Balance between flexibility and interoperability© 2013 IPTC (www.iptc.org) All rights reserved 12
  13. 13. News in JSON Road Map• Complete the initial draft• Review property names• Experiment with implementations• Create a NINJS 1.0 recommendation– Present it for a vote at the Washington, DC meeting– Consider an experimental phase• You can help by joining the News in JSON group– iptc-news-in-json-dev@yahoogroups.com© 2013 IPTC (www.iptc.org) All rights reserved 13
  14. 14. Date and Place of Next MeetingWashington, DC 21 - 23 October, 2013http://www.flickr.com/photos/pcscheid/4351707431/Merci et à bientôt!© 2013 IPTC (www.iptc.org) All rights reserved 14

×