Re: create HTML based on RDF?

On Fri, 2011-05-06 at 13:02 +0200, Frans Knibbe wrote:
> Hello,
> 
> I am continuing my efforts with publishing Linked Data. I am trying to 
> that step by step. I have now managed to publish data in static RDF 
> files. Also, I have managed to configure my web server to do 303 
> redirection, returning either a HTML file or the RDF file, depending on 
> the client request. I understand that it is good practice to offer a 
> HTML representation of the data if the client is unable to handle RDF.
> 
> I notice that it would be really helpful if I could automatically 
> generate HTML files based on the RDF files. That way I can focus on just 
> keeping the RDF file in good shape. After creating or editing an RDF 
> file I could run something that makes a HTML representation.
> 
> Is anyone aware of software that can be used to automatically export a 
> RDF file to a HTML file that looks nice in an internet browser? Or isn't 
> this a common problem? I have to admit that I might thinking in the 
> wrong way about this.
> 
> Regards,
> Frans


Hi Frans,

I think you have a number of possible solutions (which have been
mentioned in this thread) depending on how and which components you want
to use.

To help you make a decision, I have a few questions: What's your goal
for outputting an HTML page? Who is it for (you, developers, average
consumer..)? How do you want it consumed (single document view,
navigating through the dataset, part of a larger site..)?

You generally don't need to get into a templating system if the
consumers of the HTML are there only to get a quick view of the data. It
doesn't have to be pretty nor be integrated with a larger system.
General purpose tools like rapper, any23 [1], ARC2 can help you do that
with minimal work.

If you are interested in a templating framework, I'd like to suggest
Linked Data Pages [2] (built on top of Paget [3]). It can do content
negotiation; offer different RDF serializations; work with a SPARQL
endpoint; create unique SPARQL queries per HTTP URI request; HTML (RDFa)
templates; themes..

Needless to say a templating framework may be overkill for your needs
and be more complex to setup than integrating one of the general tools
into something you already have.

Once again, it all depends on how you want the HTML representation to be
consumed. If you want to focus on data management and architecting
information for your consumers, you should consider using an RDF store
and run SPARQL queries.

[1] http://any23.org/
[2] https://github.com/csarven/linked-data-pages
[3] http://code.google.com/p/paget/

-Sarven

Received on Monday, 9 May 2011 14:45:58 UTC