Your SlideShare is downloading. ×
0
Ruby on Rails and the Semantic Web
Ruby on Rails and the Semantic Web
Ruby on Rails and the Semantic Web
Ruby on Rails and the Semantic Web
Ruby on Rails and the Semantic Web
Ruby on Rails and the Semantic Web
Ruby on Rails and the Semantic Web
Ruby on Rails and the Semantic Web
Upcoming SlideShare
Loading in...5
×

Thanks for flagging this SlideShare!

Oops! An error has occurred.

×
Saving this for later? Get the SlideShare app to save on your phone or tablet. Read anywhere, anytime – even offline.
Text the download link to your phone
Standard text messaging rates apply

Ruby on Rails and the Semantic Web

1,696

Published on

Slides for lightning talk, providing short introduction to the Semantic Web, and outlining current initiatives to work with semantic web technologies within the Ruby on Rails framework.

Slides for lightning talk, providing short introduction to the Semantic Web, and outlining current initiatives to work with semantic web technologies within the Ruby on Rails framework.

Published in: Technology, Education
0 Comments
1 Like
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total Views
1,696
On Slideshare
0
From Embeds
0
Number of Embeds
1
Actions
Shares
0
Downloads
9
Comments
0
Likes
1
Embeds 0
No embeds

Report content
Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
No notes for slide

Transcript

  • 1. and the Semantic Web Ruby on Rails & & Nathalie Steinmetz (http://nathaliesteinmetz.net)
  • 2. Semantic Web? Wait, what’s that? I love Ruby on Rails I Ruby on Rails vs. Syntax vs. semantics of a sentence: On the Web: codefellows.org Syntax: HTML Semantics: none ?
  • 3. Semantic Web? So… 2001 Tim Berners-Lee A Web of data: “The Semantic Web provides a common framework that allows data to be shared and reused across application, enterprise, and community boundaries.”
  • 4. Two main goals: 1. Describe real world objects in a structured way 2. Integrate and combine data from different sources Semantic Web: RDF & vocabularies Main language: RDF Nathalie Ruby on Rails likes Subject Predicate Object Use existing vocabularies: FOAF <rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:ex="http://example.org/vocabulary#"> <ex:Nathalie> <ex:likes><ex:Ruby_on_Rails> </rdf:RDF>
  • 5. Semantic Web: in action How to markup web pages: Schema.org – recognized by Bing, Google, Yahoo and Yandex: RDFa: Embedding RDF into HTML JSON-LD: Lightweight Linked Data format based on JSON Microdata: Embedding machine-readable data into HTML <div> <h1>Avatar</h1> <span>Director: James Cameron (born August 16, 1954)</span> <span>Science fiction</span> <a href="../movies/avatar-theatrical-trailer.html">Trailer</a> </div> <div itemscope itemtype ="http://schema.org/Movie"> <h1 itemprop="name“ Avatar</h1> <div itemprop="director" itemscope itemtype="http://schema.org/Person"> Director: <span itemprop="name">James Cameron</span> (born <span itemprop="birthDate">August 16, 1954)</span> </div> <span itemprop="genre">Science fiction</span> <a href="../movies/avatar-theatrical-trailer.html" itemprop="trailer">Trailer</a> </div>
  • 6. Semantic Web: Linked Data Linked Open Data Cloud:Google, Microsoft, Facebook: Bing Snapshot Google Knowledge Graph Facebook Graph Search
  • 7. Semantic Web on Rails Ruby RDF Project: ruby-rdf.github.io Automated testing of HTML5 microdata: Contains numerous gems supporting Linked Data and Semantic Web programming: • gem ‘rdf’ • gem ‘rdf-rdfa’ • gem ‘rdf-microdata’ • gem ‘json-ld’ • rack middleware ‘rack-sparql’ • rack middleware ‘rack-sesame’ • gem linkeddata (combination of several gems) Ruby library for extracting HTML5 microdata: • gem ‘microdata’  Integration tests using test-unit test "the top level item is a schema.org/Person" do assert_equal ['http://schema.org/Person'], @items.first.type end test "the Person should have a name, url, and job title" do person = @items.first assert_equal ['Jason Ronallo'], person.properties['name'] assert_equal ['http://twitter.com/ronallo'], person.properties['url'] assert_equal ['Ass. Head of Digital Library Initiatives'], person.properties['jobTitle'] end
  • 8. Questions? More info at: Semantic Web: http://www.w3.org/standards/semanticweb/ RDF: http://www.w3.org/standards/techs/rdf#w3c_all RDFa: http://rdfa.info/ JSON-LD: http://json-ld.org/ RDF.rb: http://rdf.rubyforge.org/ Ruby RDF project: http://ruby-rdf.github.io/ HTML5 microdata test: http://jronallo.github.io/blog/automated-testing-of-html5-microdata-in-rails/

×