Re: Can RDFa be used on XML: pharma information

2009-07-26 Thread Rick Jelliffe



Ivan Herman wrote:


I am sorry if I come into this thread very late. Additionally to what
Ralph just said, the RDFa distiller running on the W3C site:

http://www.w3.org/2007/08/pyRdfa/

should actually work with an arbitrary XML file, although only SVG is
'announced' there (which is probably my mistake). If there is a problem
then, well... it is my bug:-(


So do the RDFa attributes use a prefix or not? And which namespace uri? 
And is this in any spec?


That was the stumbling block the client didn't mind pioneering but they 
didn't want just to make things up on the fly.


Cheers
Rick Jelliffe



rdfs:sameAs ( was Re: Can RDFa be used on XML: pharma information)

2009-06-24 Thread Rick Jelliffe

Thanks for everyone  for their useful  help yesterday.

I am deferring the RDFa parts, and instead will concentrate on making 
page-level RDF descriptions that may be useful for data links for the 
outside world. (The HTML pages are now full of ids, hproduct 
microformats class, HTML rel, and dublin Core, which may be some use.)


So new plan is concentrate on simple RDF indexes on topical lines first. 
That seems rather less pioneering. Here is an example.


For the medicines, I am first making abstract LSIDs for all the WHO ATC 
codes in our system (no representation retrievable). Then there will be 
a atc.rdf document with items like the following:



 P01
 http://www.pbs.gov.au/html/consumer/search/results?atc-code=A01A#pbs-search-results"/>
 http://www.whocc.no/atcddd/indexdatabase/index.php?query=A01A"/>
 http://dbpedia.openlinksw.com:8890/page/ATC_code_A01A"/>



Now the foaf:isPrimaryTopicOf is fine.
And the rdfs:seeAlso is fine there.

But the foaf:page has me feckless and fretting.  It is the closest I can 
get for a semantic WHO URI. I really want to say "What that page is 
about is what this page is about", ie that topic belonging to the LSID I 
am using is an alias for the topic in that page. 

I am tempted to use rdfs:sameAs  but that seems to be used when the two 
pages are identical rather than two topics being the same.  (Actually, 
rdfs:sameAs gets used sometimes semantically and sometimes for pages.)


What is best practice here please?  I suppose I could also use 
foaf:isPrimaryTopicOf too: is it ettiquette to say that some external 
page is actually about a local identifier?


Cheers
Rick Jelliffe



Re: Can RDFa be used on XML: pharma information

2009-06-23 Thread Rick Jelliffe

Egon Willighagen wrote:


Namespace... to solve this, you could do instead:


 Canteen Cuisine


where the prefix xhtml would be bound to the namespace belonging to
XHTML+RDFa...
  

Waaa?

In XML namespaces, an attribute with no qualifier is in no namespace. 
Does the RDF community work things so that you can detach any attribute 
with non namespace and re-use it with its element's namespace/prefix?


Are you saying that  a generic RDFa  processor would actually be looking 
for xhtml:*/@property  and would not understand  */@property?   Or 
are you saying that a generic RDFa processor would  also accept  
*/@xshtml:property



Cheers
Rick Jelliffe




Re: Can RDFa be used on XML: pharma information

2009-06-23 Thread Rick Jelliffe

Egon Willighagen wrote:

The problem here is to define what attributes your XML will use to
define the RDFa hooks... what attributes will define a new subject,
the predicate, and how you define the object...

  
Yes, we lose the  html:base element and html:link, but why would we lose 
the predicates?   @rel and @rev would presumably be available on any 
element: couldn't it be used so that instead of


http://dbpedia.org/resource/Albert_Einstein";>
 Albert Einstein
 1879-03-14
 http://dbpedia.org/resource/Germany";>
   Federal Republic of Germany
 


I can have

http://dbpedia.org/resource/Albert_Einstein";>
 Albert Einstein
 1879-03-14
 http://dbpedia.org/resource/Germany";>
   Federal Republic of Germany
 


It seems to me that where-ever RDFa does not rely on HTML semantics, it 
"should" be free (there is no conceptual impediment) to use on XML: it 
can certainly determine whether an XML element has a legit XMLliteral or 
mixed or element content.



Because the XML is using a local namespace, it will be unrecognizable
for any client... however, given you define those attributes (or via
new elements), you should be able to embed this RDFa in the HTML more
easily too...
  

What is the necessary difference, for an RDFa engine, between


 Canteen Cuisine


and


 Canteen Cuisine


Cheers
Rick Jelliffe




Re: Can RDFa be used on XML: pharma information

2009-06-23 Thread Rick Jelliffe

I see that the 2008 draft
  http://www.w3.org/2006/07/SWD/RDFa/rdfa-overview
says
 "RDFa itself is intended to be a technique that allows for adding 
metadata to any (XML) markup document, including SMIL, RSS, SVG, MathML, 
etc. Note, however, that in the current state, RDFa is being defined 
only for the (X)HTML family of languages."


So I think I will go ahead and add some RDFa markup to the XML, so that 
there is some data on the web which might stimulate developers or inform 
them, and tell the client that we may need to change tack.


Cheers
Rick Jelliffe



Re: Can RDFa be used on XML: pharma information

2009-06-23 Thread Rick Jelliffe

Egon Willighagen wrote:

On Tue, Jun 23, 2009 at 11:49 AM, Rick Jelliffe wrote:
  

So there is still no convenient way to mark up existing XML as RDF?  It was
a showstopper 10 years ago but I kind of expected there would have been some
progresssigh



Define 'markup'... 
Markup = annotation.  Taking existing data and adding stuff to make it 
more useful, without disrupting existing uses of that data (and without 
creating the size/maintenance issues you get from duplication.) 

One of the rationales for this project is to make more effective use of 
bandwidth, which makes me lean against duplication somewhat, but it may 
indeed be the appropriate way.


Cheers, and thanks,
Rick Jelliffe



Re: Can RDFa be used on XML: pharma information

2009-06-23 Thread Rick Jelliffe

Dan Brickley wrote:

On 23/6/09 11:49, Rick Jelliffe wrote:

So there is still no convenient way to mark up existing XML as RDF?  It
was a showstopper 10 years ago but I kind of expected there would have
been some progresssigh


Well, since you didn't seem keen on converting all the XML to RDF I 
didn't point you at http://www.w3.org/TR/2007/REC-grddl-20070911/ ... 
but that's certainly one of the answers to "how to map XML into RDF" 
that we didn't have in 1999. Since you're an XSLT genius, maybe it 
wouldn't be horribly painful just to write a convertor XSLT and link 
that from the namespace doc of your XML files?

I quite like the idea of GRDDL actually. I'm looking at it tonight too.

Thanks!
Rick



Re: Can RDFa be used on XML: pharma information

2009-06-23 Thread Rick Jelliffe
So there is still no convenient way to mark up existing XML as RDF?  It 
was a showstopper 10 years ago but I kind of expected there would have 
been some progresssigh


(Like I said, it has different info from the HTML so adding RDFa to the 
HTML won't work; also the XML has existing customers so we don't want to 
alter that, though the idea of duplicating the XML data as RDF seems 
workable but a terrible hack; and we want to avoid having a new datafeed.)


Cheers
Rick Jelliffe



Can RDFa be used on XML: pharma information

2009-06-23 Thread Rick Jelliffe
I am working on improving the semweb markup on an Australian government 
Department of Health and Aging website, which has HTML and XML versions 
of the medicines allowed for prescription and the amount the government 
pays. It has various links to interesting documents, and we want to make 
it more semweb friendly.


Here are two example pages to give you the idea (they have different 
selections of data):


http://www.pbs.gov.au/html/consumer/search/results?term=Zyprexa%20Zydis&publication=GE

 
http://www.pbs.gov.au/xml/consumer/search/results?term=Zyprexa%20Zydis&publication=GE 



We are doing some general things like improving the microformats (DC and 
hproduct) in the HTML.


But the plan was to decorate the XML (which has extra information)  with 
the appropriate RDFa, which seems perfect. But now I see that the RDFa 
spec says that RDFa is designed for use on XHTML. We do no want to use 
it that way, we want to augment the XML.


So I was wondering if anyone here had any advice? I see the choices

1) Convert to old RDF or some other format and making this available 
too: but we really don't want to do this (an extra thing to maintain, 
more bandwidth, etc)


2) Just ploughing ahead and using RDFa on XML even if nothing can use 
it. (Would that be the case?)


3) Err, Something clever from people on this list.

Any ideas about what people do with RDF?

Cheers
Rick Jelliffe