- From: Peter Mika <pmika@yahoo-inc.com>
- Date: Mon, 03 May 2010 13:16:49 +0200
- To: Goix Laurent Walter <laurentwalter.goix@telecomitalia.it>
- CC: Fabien Gandon <Fabien.Gandon@sophia.inria.fr>, Ian Jacobi <jacobi@csail.mit.edu>, Ivan Herman <ivan@w3.org>, David Recordon <recordond@gmail.com>, Dan Brickley <danbri@danbri.org>, "public-xg-socialweb@w3.org" <public-xg-socialweb@w3.org>, Tim Berners-Lee <timbl@w3.org>, Marie-Claire Forgue <mcf@w3.org>, Murray Maloney <murray@muzmo.com>, Richard Cyganiak <richard@cyganiak.de>, Raphaël Troncy <raphael.troncy@eurecom.fr>, Bernard Vatant <bernard.vatant@mondeca.com>, Toby A Inkster <tai@g5n.co.uk>, public-grddl-wg <public-grddl-wg@w3.org>, Venezia Claudio <claudio.venezia@telecomitalia.it>
Hi Walter, I would not go as far as converting phone numbers to URIs. This would basically require a complete parser in XSLT to convert from all possible expressions of phone numbers to a normalized form. Such a parser is difficult to write even in code, and would certainly fail for a number of cases. Even email address can be tricky... if the email is only used for display, users are not required to enter a correct email address. At which point they will put in things like "pmika (at) yahoo-inc (dot) com", which is great for display, but parsing an email out of it is hard (in fact, it's meant to be hard...) Unfortunately, something that was designed to be a string, is best kept as a string. Cheers, Peter Goix Laurent Walter wrote: > Hi Fabien, all, > > Thanks for putting this together and moving towards "real" RDF! > > Regarding emails and phone/fax numbers, do you think it would be useful to maximize the use of 'resources' instead of text literals thus referring to URIs ('mailto:' and 'tel:') that could optimize linking and cross referencing? > From the OG structure it seems URIs are not required for these fields, which basically allow any string, although it could be recommended to prefix them as URIs. Independently your transformer could anyway try to express them as URIs/resources. > > Regarding the country-name info i understand we are recycling the vcard spec and a lightweight string mechanism, that could however limit interop. Any hint to use ISO 3166-1-alpha-2 country codes (e.g. from DC terms) to be more consistent? The question here still applies both to OG and the XSLT... > > Cheers, > Walter > PS: we should acknowledge Air France for its support in building the Semantic Web :-) > > -----Original Message----- > From: Fabien Gandon [mailto:Fabien.Gandon@sophia.inria.fr] > Sent: lunedì 3 maggio 2010 12.08 > To: Ian Jacobi; Peter Mika; Ivan Herman; David Recordon; Dan Brickley; public-xg-socialweb@w3.org; Tim Berners-Lee; Marie-Claire Forgue; Murray Maloney; Richard Cyganiak; Raphaël Troncy; Bernard Vatant; Toby A Inkster; public-grddl-wg; Goix Laurent Walter > Subject: XSLT mapping rules and GRDDL profile for Facebook Open Graph Protocol > > Hello everyone, > > Courtesy of Air France I had some time to hack a first XSLT transformation that extracts RDF from an XHTML page using the Open Graph protocol. > > I released this alpha version as an open source freeware GRDDL profile: > http://ns.inria.fr/grddl/ogp/ > > If you want to declare that a document contains Open Graph Protocol data and always uses the latest profile, add this profile to the head of your > XHTML: > <head profile="http://ns.inria.fr/grddl/ogp/"> > > Tests are being done as I write this and feedback is welcome. > > > The current version takes an XHTML file containing OGP markup as input e.g. > > <html xmlns:og="http://opengraphprotocol.org/schema/"> > <head> > <base href="http://www.inria.fr/sophia/index.html" /> <title>INRIA Sophia Antipolis</title> <meta property="og:title" content="INRIA Sophia Antipolis" /> <meta property="og:type" content="non profit" /> <meta property="og:url" content="http://www.inria.fr/sophia/" /> <meta property="og:image" > content="http://www-sop.inria.fr/oasis/FMCO/2008/ur_sophia.jpg" /> <meta property="og:description" content="INRIA's Sophia Antipolis - Méditerranée research centre was set up in 1983 at the heart of one of the most important scientific parks in Europe. Today it has premises in Sophia Antipolis, Marseille and Montpellier, and now in Italy, bringing together almost 500 staff - including nearly 400 scientists - divided in about 40 research teams."/> <meta property="og:site_name" content="INRIA - French National Institute for Research in Computer Science and Control " /> <meta property="og:latitude" content="43.6161" /> <meta property="og:longitude" content="7.0678" /> <meta property="og:street-address" content="2004 rt des Lucioles" /> <meta property="og:locality" content="Sophia Antipolis" /> <meta property="og:region" content="French Riviera" /> <meta property="og:postal-code" content="06902" /> <meta property="og:country-name" content="France" /> <meta property="og:email" content="Fabien.Gandon@inria.fr" /> <meta property="og:phone_number" content="+33492387788" /> <meta property="og:fax_number" content="+33492387783" /> <meta property="og:upc" content="HRV1230OPHJ" /> <meta property="og:isbn" content="1234567890123" /> </head> </html> > > > From this it provides an RDF version with both the extracted OGB triples and some mappings to several ontologies e.g. (result for the XHTML above): > > <rdf:RDF xmlns:owl="http://www.w3.org/2002/07/owl#" > xmlns:good="http://purl.org/goodrelations/v1#" > xmlns:foaf="http://xmlns.com/foaf/0.1/" > xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" > xmlns:h="http://www.w3.org/1999/xhtml" > xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#" > xmlns:biblio="http://purl.org/ontology/bibo/" > xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" > xmlns:sioc="http://rdfs.org/sioc/ns#" > xmlns:og="http://opengraphprotocol.org/schema/" > xmlns:dc="http://purl.org/dc/elements/1.1/" > xmlns:vcard="http://www.w3.org/2006/vcard/ns#" > xml:base="http://opengraphprotocol.org/schema/"> > > <!--Processing metadata property="title" content="INRIA Sophia Antipolis"--> <rdf:Description rdf:about="http://www.inria.fr/sophia/index.html#objectN65541"> > <rdfs:label>INRIA Sophia Antipolis</rdfs:label> <dc:title>INRIA Sophia Antipolis</dc:title> </rdf:Description> <rdf:Description rdf:about="http://www.inria.fr/sophia/index.html"> > <og:title>INRIA Sophia Antipolis</og:title> </rdf:Description> > > <!--Processing metadata property="type" content="non profit"--> <rdf:Description rdf:about="http://www.inria.fr/sophia/index.html#objectN65541"> > <rdf:type rdf:resource="http://opengraphprotocol.org/schema/Non_profit"/> > </rdf:Description> > <rdf:Description rdf:about="http://www.inria.fr/sophia/index.html"> > <og:type>non profit</og:type> > </rdf:Description> > > <!--Processing metadata property="url" > content="http://www.inria.fr/sophia/"--> > <rdf:Description > rdf:about="http://www.inria.fr/sophia/index.html#objectN65541"> > <foaf:homepage rdf:resource="http://www.inria.fr/sophia/"/> > <rdf:seeAlso rdf:resource="http://www.inria.fr/sophia/"/> > </rdf:Description> > <sioc:Document rdf:about="http://www.inria.fr/sophia/"> > <sioc:about > rdf:resource="http://www.inria.fr/sophia/index.html#objectN65541"/> > </sioc:Document> > <rdf:Description rdf:about="http://www.inria.fr/sophia/index.html"> > <og:url>http://www.inria.fr/sophia/</og:url> > </rdf:Description> > > <!--Processing metadata property="image" > content="http://www-sop.inria.fr/oasis/FMCO/2008/ur_sophia.jpg"--> > <rdf:Description > rdf:about="http://www.inria.fr/sophia/index.html#objectN65541"> > <foaf:depiction > rdf:resource="http://www-sop.inria.fr/oasis/FMCO/2008/ur_sophia.jpg"/> > </rdf:Description> > <rdf:Description rdf:about="http://www.inria.fr/sophia/index.html"> > <og:image>http://www-sop.inria.fr/oasis/FMCO/2008/ur_sophia.jpg</og:image> > </rdf:Description> > > <!--Processing metadata property="description" content="INRIA's Sophia Antipolis - Méditerranée research centre was set up in 1983 at the heart of one of the most important scientific parks in Europe. Today it has premises in Sophia Antipolis, Marseille and Montpellier, and now in Italy, bringing together almost 500 staff - including nearly 400 scientists - divided in about 40 research teams."--> <rdf:Description rdf:about="http://www.inria.fr/sophia/index.html#objectN65541"> > <rdfs:comment>INRIA's Sophia Antipolis - Méditerranée research centre was set up in 1983 at the heart of one of the most important scientific parks in Europe. Today it has premises in Sophia Antipolis, Marseille and Montpellier, and now in Italy, bringing together almost 500 staff - including nearly 400 scientists - divided in about 40 research teams.</rdfs:comment> <dc:description>INRIA's Sophia Antipolis - Méditerranée research centre was set up in 1983 at the heart of one of the most important scientific parks in Europe. Today it has premises in Sophia Antipolis, Marseille and Montpellier, and now in Italy, bringing together almost 500 staff - including nearly 400 scientists - divided in about 40 research teams.</dc:description> </rdf:Description> <rdf:Description rdf:about="http://www.inria.fr/sophia/index.html"> > <og:description>INRIA's Sophia Antipolis - Méditerranée research centre was set up in 1983 at the heart of one of the most important scientific parks in Europe. Today it has premises in Sophia Antipolis, Marseille and Montpellier, and now in Italy, bringing together almost 500 staff - including nearly 400 scientists - divided in about 40 research teams.</og:description> </rdf:Description> > > <!--Processing metadata property="site_name" content="INRIA - French National Institute for Research in Computer Science and Control "--> <sioc:Site rdf:about="http://www.inria.fr/"> <rdfs:label>INRIA - French National Institute for Research in Computer Science and Control </rdfs:label> <dc:title>INRIA - French National Institute for Research in Computer Science and Control </dc:title> <sioc:space_of> <sioc:Container> <sioc:container_of> <sioc:Document rdf:about="http://www.inria.fr/sophia/index.html"> > <sioc:about > rdf:resource="http://www.inria.fr/sophia/index.html#objectN65541"/> > </sioc:Document> > </sioc:container_of> > </sioc:Container> > </sioc:space_of> > </sioc:Site> > <rdf:Description rdf:about="http://www.inria.fr/sophia/index.html"> > <og:site_name>INRIA - French National Institute for Research in Computer Science and Control </og:site_name> </rdf:Description> > > <!--Processing metadata property="latitude" content="43.6161"--> <rdf:Description rdf:about="http://www.inria.fr/sophia/index.html#objectN65541"> > <geo:lat>43.6161</geo:lat> > </rdf:Description> > <rdf:Description rdf:about="http://www.inria.fr/sophia/index.html"> > <og:latitude>43.6161</og:latitude> > </rdf:Description> > > <!--Processing metadata property="longitude" content="7.0678"--> <rdf:Description rdf:about="http://www.inria.fr/sophia/index.html#objectN65541"> > <geo:long>7.0678</geo:long> > </rdf:Description> > <rdf:Description rdf:about="http://www.inria.fr/sophia/index.html"> > <og:longitude>7.0678</og:longitude> > </rdf:Description> > > <!--Processing metadata property="street-address" content="2004 rt des Lucioles"--> <vcard:VCard rdf:about="http://www.inria.fr/sophia/index.html#objectN65541"> > <vcard:adr> > <vcard:Address > rdf:about="http://www.inria.fr/sophia/index.html#addressN65541"> > <vcard:street-address>2004 rt des Lucioles</vcard:street-address> </vcard:Address> </vcard:adr> </vcard:VCard> <rdf:Description rdf:about="http://www.inria.fr/sophia/index.html"> > <og:street-address>2004 rt des Lucioles</og:street-address> </rdf:Description> > > <!--Processing metadata property="locality" content="Sophia Antipolis"--> <vcard:VCard rdf:about="http://www.inria.fr/sophia/index.html#objectN65541"> > <vcard:adr> > <vcard:Address > rdf:about="http://www.inria.fr/sophia/index.html#addressN65541"> > <vcard:locality>Sophia Antipolis</vcard:locality> </vcard:Address> </vcard:adr> </vcard:VCard> <rdf:Description rdf:about="http://www.inria.fr/sophia/index.html"> > <og:locality>Sophia Antipolis</og:locality> </rdf:Description> > > <!--Processing metadata property="region" content="French Riviera"--> <vcard:VCard rdf:about="http://www.inria.fr/sophia/index.html#objectN65541"> > <vcard:adr> > <vcard:Address > rdf:about="http://www.inria.fr/sophia/index.html#addressN65541"> > <vcard:region>French Riviera</vcard:region> </vcard:Address> </vcard:adr> </vcard:VCard> <rdf:Description rdf:about="http://www.inria.fr/sophia/index.html"> > <og:region>French Riviera</og:region> > </rdf:Description> > > <!--Processing metadata property="postal-code" content="06902"--> <vcard:VCard rdf:about="http://www.inria.fr/sophia/index.html#objectN65541"> > <vcard:adr> > <vcard:Address > rdf:about="http://www.inria.fr/sophia/index.html#addressN65541"> > <vcard:postal-code>06902</vcard:postal-code> > </vcard:Address> > </vcard:adr> > </vcard:VCard> > <rdf:Description rdf:about="http://www.inria.fr/sophia/index.html"> > <og:postal-code>06902</og:postal-code> > </rdf:Description> > > <!--Processing metadata property="country-name" content="France"--> <vcard:VCard rdf:about="http://www.inria.fr/sophia/index.html#objectN65541"> > <vcard:adr> > <vcard:Address > rdf:about="http://www.inria.fr/sophia/index.html#addressN65541"> > <vcard:country-name>France</vcard:country-name> > </vcard:Address> > </vcard:adr> > </vcard:VCard> > <rdf:Description rdf:about="http://www.inria.fr/sophia/index.html"> > <og:country-name>France</og:country-name> > </rdf:Description> > > <!--Processing metadata property="email" content="Fabien.Gandon@inria.fr"--> > <rdf:Description > rdf:about="http://www.inria.fr/sophia/index.html#objectN65541"> > <foaf:mbox rdf:resource="mailto:Fabien.Gandon@inria.fr"/> > <vcard:email>Fabien.Gandon@inria.fr</vcard:email> > </rdf:Description> > <rdf:Description rdf:about="http://www.inria.fr/sophia/index.html"> > <og:email>Fabien.Gandon@inria.fr</og:email> > </rdf:Description> > > <!--Processing metadata property="phone_number" content="+33492387788"--> <rdf:Description rdf:about="http://www.inria.fr/sophia/index.html#objectN65541"> > <vcard:tel>+33492387788</vcard:tel> > <foaf:phone>+33492387788</foaf:phone> > </rdf:Description> > <rdf:Description rdf:about="http://www.inria.fr/sophia/index.html"> > <og:phone_number>+33492387788</og:phone_number> > </rdf:Description> > > <!--Processing metadata property="fax_number" content="+33492387783"--> <rdf:Description rdf:about="http://www.inria.fr/sophia/index.html#objectN65541"> > <vcard:tel>+33492387783</vcard:tel> > <foaf:phone>+33492387783</foaf:phone> > </rdf:Description> > <rdf:Description rdf:about="http://www.inria.fr/sophia/index.html"> > <og:fax_number>+33492387783</og:fax_number> > </rdf:Description> > > <!--Processing metadata property="upc" content="HRV1230OPHJ"--> <rdf:Description rdf:about="http://www.inria.fr/sophia/index.html#objectN65541"> > <good:hasEAN_UCC-13>0HRV1230OPHJ</good:hasEAN_UCC-13> > </rdf:Description> > <rdf:Description rdf:about="http://www.inria.fr/sophia/index.html"> > <og:upc>HRV1230OPHJ</og:upc> > </rdf:Description> > > <!--Processing metadata property="isbn" content="1234567890123"--> <rdf:Description rdf:about="http://www.inria.fr/sophia/index.html#objectN65541"> > <biblio:isbn>1234567890123</biblio:isbn> > </rdf:Description> > <rdf:Description rdf:about="http://www.inria.fr/sophia/index.html"> > <og:isbn>1234567890123</og:isbn> > </rdf:Description> > > </rdf:RDF> > > (Pffeeww !) > > Cheers, > > -- > fabien, inria, http://fabien.info > > > Questo messaggio e i suoi allegati sono indirizzati esclusivamente alle persone indicate. La diffusione, copia o qualsiasi altra azione derivante dalla conoscenza di queste informazioni sono rigorosamente vietate. Qualora abbiate ricevuto questo documento per errore siete cortesemente pregati di darne immediata comunicazione al mittente e di provvedere alla sua distruzione, Grazie. > > This e-mail and any attachments is confidential and may contain privileged information intended for the addressee(s) only. Dissemination, copying, printing or use by anybody else is unauthorised. If you are not the intended recipient, please delete this message and any attachments and advise the sender by return e-mail, Thanks. > >
Received on Monday, 3 May 2010 11:18:56 UTC