Semantic TYPO3Develop Extensions with Semantic Web in MindJochen Rau @ T3CON11SFJune 11, 2011
(c) by Benjamin Nowack, Attribution 3.0 Unported (CC BY 3.0)
Concepts           (c) by Benjamin Nowack, Attribution 3.0 Unported (CC BY 3.0)
Implementations   (c) by Benjamin Nowack, Attribution 3.0 Unported (CC BY 3.0)
http://commons.wikimedia.org/wiki/File:Z%C3%BCrich_-_Seefeld_-_Heureka_IMG_1757.JPG
No Rocket Science
Lets make some assertions about meJochens is a Person.Jochens age is 40.Jochens name is Jochen Rau.Jochen likes TYPO3 and ...
Lets make some assertions about meJochens is a Person.Jochens age is 40.Jochens name is Jochen Rau.Jochen likes TYPO3 and ...
Lets make some assertions about meJochens is a Person.Jochens age is 40.Jochens name is Jochen Rau.Jochen likes TYPO3 and ...
Lets make some assertions about me                                  Jochen                   40                           ...
Lets make some assertions about me                                  Jochen                   40                           ...
Lets make some assertions about me                                  Jochen                   40                           ...
Unique Names for Resources                Jochen                  knows                          Sebastian                ...
Unique Names for Resources                            <http://typoplanet.de/resource/Jochen>                          <htt...
Unique Names for Resources              <http://typoplanet.de/resource/Jochen>            <http://xmlns.com/foaf/0.1/knows...
Turtle Serialization of an RDF Graph<http://example.com/JR>	   <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://x...
Turtle Serialization of an RDF Graph@prefix   ex: <http://example.org/> .@prefix   dbp: <http://dbpedia.org/resource/> .@p...
Turtle Syntactic sugar@prefix   ex: <http://example.org/> .@prefix   dbp: <http://dbpedia.org/resource/> .@prefix   nyt: <...
Turtle And even more syntactic sugar@prefix   ex: <http://example.org/> .@prefix   dbp: <http://dbpedia.org/resource/> .@p...
RDF at a Glance Simple, ubiquitous way of modeling data Main concepts    Triples of subject, predicate, and object    Uniq...
Description Logic and Rules OWL and RIF What? Why?   Knowledge is spread all over the system:   Domain model, database sch...
Description Logic and Rules OWL and RIF                     Knublauch, Holger. KBeans Specification: Semantic Transparency ...
RDF in HTMLThree di erent standards to markup your HTML code   Microformats   Microdata (part of HTML5 spec)   RDFa ("RDF ...
RDF in HTML RDFa<div>   <p>     Alice Birpemswick   </p>   <p>     Email: <a href="mailto:alice@example.com">alice@example...
RDF in HTML RDFa<div prefix="foaf: http://xmlns.com/foaf/0.1/" about="http://example.com/resource/alice"typeof="Person">  ...
RDF in HTML RDFa<div prefix="foaf: http://xmlns.com/foaf/0.1/" about="http://example.com/resource/alice"typeof="Person">  ...
RDF in HTML RDFa<div prefix="foaf: http://xmlns.com/foaf/0.1/" about="http://example.com/alice#me" rel="knows">   <ul>    ...
RDF in HTML RDFa<div prefix="foaf: http://xmlns.com/foaf/0.1/" about="http://example.com/alice#me" rel="knows">   <ul>    ...
RDF in HTML GoodRelations Vocabulary
RDF in HTML Enable RDFa in TYPO3# Set the doctype and add common namespacesconfig.doctype = xhtml+rdfa_10config.namespaces...
Demo
EXT:semantic SPARQL Client
Linked Data Cloud
Linked Data Cloud
Querying a Graph SPARQLW3C RecommendationGraph pattern matchingSimilar to SQL and Turtle
Querying a Graph Filter, Functions, Ordering ...
Querying a Graph Custom Functions
Querying a Graph Property Paths
Querying a Graph Property Paths and Inference
Querying a Graph Subqueries
EXT:semantic SPARQL Query Administration Default namespaces (RDFa default pro le) Syntax highlighting Code indentation   C...
EXT:semantic SPARQL Query Administration Default namespaces (RDFa default pro le) Syntax highlighting Code indentation Fro...
EXT:semantic Custom Content Elements Default layouts and custom HTML template code Support for pagination (dynamic query r...
EXT:semantic Custom Content Elements     Frontend                 Backend
EXT:semantic Custom Content Elements Query results variables are bound to the template variables and are used as labels in...
Demo
Developer    Query Object Modelclass Tx_BlogExample_Domain_Repository_PostRepository extends Tx_Extbase_Persistence_Reposi...
Semantic TYPO3 Current Projects SPARQL Client (EXT:semantic, Jochen Rau) RDF/RDFa support (Sebastian Kurfürst, masters the...
Semantic TYPO3 RoadmapImprove usability of SPARQL ClientTransform Domain Models into RDF(a)Transform OWL Ontologies into P...
Semantic TYPO3 Vision
Semantic TYPO3 Vision
Semantic TYPO3 Vision
Demo
Thanks! Twitter @jocrau Email jochen.rau@typoplanet.de Blog http://blog.typoplanet.de Talk Lunch
Semantic TYPO3
Semantic TYPO3
Semantic TYPO3
Semantic TYPO3
Semantic TYPO3
Semantic TYPO3
Upcoming SlideShare
Loading in...5
×

Semantic TYPO3

5,329

Published on

Develop for TYPO3 with Semantic Web in mind.

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

No Downloads
Views
Total Views
5,329
On Slideshare
0
From Embeds
0
Number of Embeds
0
Actions
Shares
0
Downloads
37
Comments
0
Likes
3
Embeds 0
No embeds

No notes for slide

Semantic TYPO3

  1. 1. Semantic TYPO3Develop Extensions with Semantic Web in MindJochen Rau @ T3CON11SFJune 11, 2011
  2. 2. (c) by Benjamin Nowack, Attribution 3.0 Unported (CC BY 3.0)
  3. 3. Concepts (c) by Benjamin Nowack, Attribution 3.0 Unported (CC BY 3.0)
  4. 4. Implementations (c) by Benjamin Nowack, Attribution 3.0 Unported (CC BY 3.0)
  5. 5. http://commons.wikimedia.org/wiki/File:Z%C3%BCrich_-_Seefeld_-_Heureka_IMG_1757.JPG
  6. 6. No Rocket Science
  7. 7. Lets make some assertions about meJochens is a Person.Jochens age is 40.Jochens name is Jochen Rau.Jochen likes TYPO3 and Wine.Jochen lives in Massachusetts.
  8. 8. Lets make some assertions about meJochens is a Person.Jochens age is 40.Jochens name is Jochen Rau.Jochen likes TYPO3 and Wine.Jochen lives in Massachusetts. Subject Predicate Object
  9. 9. Lets make some assertions about meJochens is a Person.Jochens age is 40.Jochens name is Jochen Rau.Jochen likes TYPO3 and Wine.Jochen lives in Massachusetts. Subject Predicate Object Triple
  10. 10. Lets make some assertions about me Jochen 40 age name Jochen Rau is a likes TYPO3 likes lives inJochens is a Person. PersonJochens age is 40. Wine MassachusettsJochens name is Jochen Rau.Jochen likes TYPO3 and Wine.Jochen lives in Massachusetts.
  11. 11. Lets make some assertions about me Jochen 40 age name Jochen Rau is a likes TYPO3 likes lives inJochens is a Person. PersonJochens age is 40. Wine MassachusettsJochens name is Jochen Rau.Jochen likes TYPO3 and Wine. TYPO3Jochen lives in Massachusetts. license GNU General Public License description platform TYPO3 is a free and open source content management system as well as a Model–view– controller (MVC) Web PHP Application Development framework written in PHP.
  12. 12. Lets make some assertions about me Jochen 40 age name Jochen Rau is a likes TYPO3 likes GNU General license lives in Public LicenseJochens is a Person. Person descriptionJochens age is 40. Wine MassachusettsJochens name is Jochen Rau. platform TYPO3 is a free and open source contentJochen likes TYPO3 and Wine. management system asJochen lives in Massachusetts. well as a Model–view– controller (MVC) Web PHP Application Development framework written in PHP.
  13. 13. Unique Names for Resources Jochen knows Sebastian likes Paris
  14. 14. Unique Names for Resources <http://typoplanet.de/resource/Jochen> <http://xmlns.com/foaf/0.1/knows> <http://sebastian.kurfuerst.eu/> <http://xmlns.com/foaf/0.1/likes> <http://en.wikipedia.org/wiki/Paris_(2008_film)><http://typoplanet.de/resource/Jochen><http://typoplanet.de/resource/hg132k4jhjh1234t><urn:uuid:67ecc3bd-07e2-44f4-a788-597bf9949f0c><tel:+1-617-555-7332><mailto:jochen.rau@typoplanet.de>
  15. 15. Unique Names for Resources <http://typoplanet.de/resource/Jochen> <http://xmlns.com/foaf/0.1/knows> <http://sebastian.kurfuerst.eu/> <http://sebastian.kurfuerst.eu/> <http://xmlns.com/foaf/0.1/likes> <http://en.wikipedia.org/wiki/Paris_(2008_film)>
  16. 16. Turtle Serialization of an RDF Graph<http://example.com/JR> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://xmlns.com/foaf/0.1/Person> .<http://example.com/JR> <http://xmlns.com/foaf/0.1/age> "40" .<http://example.com/JR> <http://xmlns.com/foaf/0.1/name> "Jochen Rau" .<http://example.com/JR> <http://xmlns.com/foaf/0.1/interest> <http://dbpedia.org/resource/TYPO3> .<http://example.com/JR> <http://xmlns.com/foaf/0.1/interest> <http://dbpedia.org/resource/Wine> .<http://example.com/JR> <http://example.com/livesIn> <http://data.nytimes.com/Massachusetts> .
  17. 17. Turtle Serialization of an RDF Graph@prefix ex: <http://example.org/> .@prefix dbp: <http://dbpedia.org/resource/> .@prefix nyt: <http://data.nytimes.com/> .@prefix foaf: <http://xmlns.com/foaf/0.1/> .ex:JR a foaf:Person .ex:JR foaf:age "40" .ex:JR foaf:name "Jochen Rau" .ex:JR foaf:interest dbp:TYPO3 .ex:JR foaf:interest dbp:Wine .ex:JR ex:livesIn nyt:Massachusetts .
  18. 18. Turtle Syntactic sugar@prefix ex: <http://example.org/> .@prefix dbp: <http://dbpedia.org/resource/> .@prefix nyt: <http://data.nytimes.com/> .@prefix foaf: <http://xmlns.com/foaf/0.1/> .ex:JR a foaf:Person ; ex:age "40" ; ex:name "Jochen Rau" ; ex:likes dbp:TYPO3 ; ex:likes dbp:Wine ; ex:livesIn nyt:Massachusetts .
  19. 19. Turtle And even more syntactic sugar@prefix ex: <http://example.org/> .@prefix dbp: <http://dbpedia.org/resource/> .@prefix nyt: <http://data.nytimes.com/> .@prefix foaf: <http://xmlns.com/foaf/0.1/> .ex:JR a foaf:Person ; ex:age "40" ; ex:name "Jochen Rau" ; ex:likes dbp:TYPO3 , dbp:Wine ; ex:livesIn nyt:Massachusetts .
  20. 20. RDF at a Glance Simple, ubiquitous way of modeling data Main concepts Triples of subject, predicate, and object Unique names for resources Objects can also be literal values (with data type or language) Performant data stores (e.g. Virtuoso, AllegroGraph, BigOWLIM) Existing frameworks with rich APIs (e.g. JENA, Sesame, Erfurt) Billions of triples as Open Data available (e.g. Wikipedia, MusicBrainz) Many di erent serialization formats (e.g. RDF/XML, Turtle, N3) Makes data migration much easier
  21. 21. Description Logic and Rules OWL and RIF What? Why? Knowledge is spread all over the system: Domain model, database scheme, TS con gurartion, FlexForm, TCA, documentation, Templates ... In di erent Formats: SQL, TypoScript, XML, PHP, HTML ... Using inconsistent terminology: "Template" in TYPO3? So, what to do? data and metadata in the same data structure (RDF) use well de ned languages to describe (meta)data (OWL RIF)
  22. 22. Description Logic and Rules OWL and RIF Knublauch, Holger. KBeans Specification: Semantic Transparency for Components and Domain Models. Technical Report FAW-TR-01001, FAW Ulm, 2001.
  23. 23. RDF in HTMLThree di erent standards to markup your HTML code Microformats Microdata (part of HTML5 spec) RDFa ("RDF for attributes", W3C Recommendation)A subset of RDFMakes web pages machine readable by your favorite search engine
  24. 24. RDF in HTML RDFa<div> <p> Alice Birpemswick </p> <p> Email: <a href="mailto:alice@example.com">alice@example.com</a> </p> <p> Phone: <a href="tel:+1-617-555-7332">+1 617.555.7332</a> </p></div>
  25. 25. RDF in HTML RDFa<div prefix="foaf: http://xmlns.com/foaf/0.1/" about="http://example.com/resource/alice"typeof="Person"> <p property="foaf:name"> Alice Birpemswick </p> <p> Email: <a rel="foaf:mbox" href="mailto:alice@example.com">alice@example.com</a> </p> <p> Phone: <a rel="foaf:phone" href="tel:+1-617-555-7332">+1 617.555.7332</a> </p></div>
  26. 26. RDF in HTML RDFa<div prefix="foaf: http://xmlns.com/foaf/0.1/" about="http://example.com/resource/alice"typeof="Person"> <p property="foaf:name"> Alice Birpemswick </p> <p> Email: <a rel="foaf:mbox" href="mailto:alice@example.com">alice@example.com</a> </p> <p> Phone: <a rel="foaf:phone" href="tel:+1-617-555-7332">+1 617.555.7332</a> </p></div> http://example.com/resource/alice
  27. 27. RDF in HTML RDFa<div prefix="foaf: http://xmlns.com/foaf/0.1/" about="http://example.com/alice#me" rel="knows"> <ul> <li typeof="Person"> <a rel="foaf:homepage" href="http://example.com/bob" property="foaf:name">Bob</a> </li> <li typeof="Person" > <a rel="foaf:homepage" href="http://example.com/eve" property="foaf:name">Eve</a> </li> <li typeof="Person" > <a rel="foaf:homepage" href="http://example.com/manu" property="foaf:name">Manu</a> </li> </ul></div>
  28. 28. RDF in HTML RDFa<div prefix="foaf: http://xmlns.com/foaf/0.1/" about="http://example.com/alice#me" rel="knows"> <ul> <li typeof="Person"> <a rel="foaf:homepage" href="http://example.com/bob" property="foaf:name">Bob</a> </li> <li typeof="Person" > <a rel="foaf:homepage" href="http://example.com/eve" property="foaf:name">Eve</a> </li> <li typeof="Person" > <a rel="foaf:homepage" href="http://example.com/manu" property="foaf:name">Manu</a> </li> </ul></div>
  29. 29. RDF in HTML GoodRelations Vocabulary
  30. 30. RDF in HTML Enable RDFa in TYPO3# Set the doctype and add common namespacesconfig.doctype = xhtml+rdfa_10config.namespaces { xml = http://www.w3.org/XML/1998/namespace xmlns = http://www.w3.org/2000/xmlns/ xsd = http://www.w3.org/2001/XMLSchema# xhv = http://www.w3.org/1999/xhtml/vocab# rdfa = http://www.w3.org/ns/rdfa# rdf = http://www.w3.org/1999/02/22-rdf-syntax-ns# rdfs = http://www.w3.org/2000/01/rdf-schema# owl = http://www.w3.org/2002/07/owl# rif = http://www.w3.org/2007/rif#[...] dbo = http://dbpedia.org/ontology/ foaf = http://xmlns.com/foaf/0.1/ geo = http://www.w3.org/2003/01/geo/wgs84_pos# gr = http://purl.org/goodrelations/v1# cal = http://www.w3.org/2002/12/cal/ical# og = http://ogp.me/ns# v = http://rdf.data-vocabulary.org/# bibo = http://purl.org/ontology/bibo/}
  31. 31. Demo
  32. 32. EXT:semantic SPARQL Client
  33. 33. Linked Data Cloud
  34. 34. Linked Data Cloud
  35. 35. Querying a Graph SPARQLW3C RecommendationGraph pattern matchingSimilar to SQL and Turtle
  36. 36. Querying a Graph Filter, Functions, Ordering ...
  37. 37. Querying a Graph Custom Functions
  38. 38. Querying a Graph Property Paths
  39. 39. Querying a Graph Property Paths and Inference
  40. 40. Querying a Graph Subqueries
  41. 41. EXT:semantic SPARQL Query Administration Default namespaces (RDFa default pro le) Syntax highlighting Code indentation Content Manager
  42. 42. EXT:semantic SPARQL Query Administration Default namespaces (RDFa default pro le) Syntax highlighting Code indentation Frontend and backend Content Manager
  43. 43. EXT:semantic Custom Content Elements Default layouts and custom HTML template code Support for pagination (dynamic query re-writing)
  44. 44. EXT:semantic Custom Content Elements Frontend Backend
  45. 45. EXT:semantic Custom Content Elements Query results variables are bound to the template variables and are used as labels in a human readable form
  46. 46. Demo
  47. 47. Developer Query Object Modelclass Tx_BlogExample_Domain_Repository_PostRepository extends Tx_Extbase_Persistence_Repository { public function findByTagAndBlog($tag, Tx_BlogExample_Domain_Model_Blog $blog, $limit = 20) { $query = $this->createQuery(); return $query->matching( $query->logicalAnd( $query->equals(blog, $blog), $query->equals(tags.name, $tag) ) ) ->setOrderings(array(date => Tx_Extbase_Persistence_QueryInterface::ORDER_DESCENDING)) ->setLimit((integer)$limit) ->execute(); } public function findNext(Tx_BlogExample_Domain_Model_Post $post) { $query = $this->createQuery(); $posts = $query->matching($query->greaterThan(date, $post->getDate())) ->setOrderings(array(date => Tx_Extbase_Persistence_QueryInterface::ORDER_DESCENDING)) ->execute(); return $posts->getFirst(); }}
  48. 48. Semantic TYPO3 Current Projects SPARQL Client (EXT:semantic, Jochen Rau) RDF/RDFa support (Sebastian Kurfürst, masters thesis) CMS ontology (Andreas Wolf, GSoC) Taxonomy and Categories (EXT:taxonomy, Fabien Udriot) Semantic persistence backend (EXT:semantic, Thomas Maroschik) Globally unique identi ers in v4 (EXT:identity, Thomas Maroschik) Tagging support for Editors (v4: RTE plugin, v5: Aloha)
  49. 49. Semantic TYPO3 RoadmapImprove usability of SPARQL ClientTransform Domain Models into RDF(a)Transform OWL Ontologies into PHP Code and MetadataExtbase Query Object Model -> SPARQL Query
  50. 50. Semantic TYPO3 Vision
  51. 51. Semantic TYPO3 Vision
  52. 52. Semantic TYPO3 Vision
  53. 53. Demo
  54. 54. Thanks! Twitter @jocrau Email jochen.rau@typoplanet.de Blog http://blog.typoplanet.de Talk Lunch
  1. A particular slide catching your eye?

    Clipping is a handy way to collect important slides you want to go back to later.

×