Pigsty – a Firefox extension for RDF galleries

A pigsty at the city farm in St Werburg's, Bristol
In preparation for sparqlcamp I spent far too much time playing with a Firefox extension to show RDF information about photos, which I’ve called pigsty party in hommage to the rather better piggy bank extension. I had a terrible time actually writing it – very slow indeed to develop, but the power of Firefox made it worthwhile, I think. Or, at least you can see some of the potential of it, though the result is a terrible old hack, borrowing heavily from the Sage RSS reader in particular.
The idea was to try and show how the results of Sparql queries (for example; they could just be ordinary RDF files) might be usefully displayed to the user in a way that really showed the advantages of RDF (assuming there are any 😉 I’ve been using Sage a lot and I like the way you can get images in the feeds via the html. I like Flickr (and flickrfox) a lot too but I’m certainly not going to try to put my 10000+ photos on their site.
A fair few people have being putting RDF data about images on their sites – especially depiction data, location data, dates and thumbnails. After a Guinness-fuelled meeting at the Foaf workshop in Galway last year, Morten Frederiksen, Greg Williams and I have more or less have the same kinds of information available in similar formats: scene is set for a distributed Flickr thingy. Tags are fashionable, so what the hell… 🙂
So some groundwork for something like that was the aim. Of course there are plenty of different ways of creating something like this – some sort of distributed query combining the results from several sources into one html page is another tack, and it looks as if we’ll try something like that out of Sparqling days too.
A Firefox extension is another way. The Pigsty Firefox extension finds gallery files in this format or this format linked from foaffiles which the extension finds using the foaf autodiscovery from html method. More detail is on the Pigsty homepage.
Having found the feeds you can view then with their images and metadata, and also filter the metadata for people, places, dates and tags. Some screenshots are available. Really, the feeds need to be latest photos from each source for it to be an interesting, updating dataset.
This is one to throw away, but I hope it makes some sort of sense. It’s fairly easy to extend – I’ve made some headway into displaying iCalendar RDF files but I’m having some issues with datatypes at the moment. I’d quite like to see what conferences and meetings my friends were going to and then save the events as iCalendar locally.
Many thanks to Jim Ley for providing updated versions of his javascript RDF parser on request. I think using the inbuilt RDF features of Firefox might also be an option, although I don’t know how up to date they are for the current RDF syntax.
The main issue I can see with Pigsty (apart from general usability issues) is that processing the RDF files rapidly gets too tiring for the application and you get ‘a script in this page is causing firefox to run slowly’.
Another interesting area for more work is to investigate how to use SKOS tags rather than dc:subject tags (dc:subject are just strings; SKOS tags have an associated uri and can have more structure). The really interesting stuff here is how to reuse tags from friends or events, but this occurs in the authoring area rather than display. We also need Creative Commons and authoring properties to make this stuff realy useful.
Comments welcome – mail me (libby@asemantics.com) – comments are switched off in the blog.

Images and calendars

I’ve been playing around with displaying my photos as a calendar, as I mostly use them to remember what I’ve been doing, so I thought it might be useful. I’ve used Masahide Kanzaki’s neato client-side XSLT and Javascript together with a hacked perl script – more info.
It seems to work pretty well (when it does work – in Mozilla-based browsers and Explorer). There are a couple of minor bugs. Once issue with using the clientside stuff is that you can’t link directly to a month – only a year. Also, because it’s XSLT and so document-based it’s going to be trickier to add in my actual calendar data and say, moblog image data.
I’m quite pleased with it though – an interesting different view on the pictures. Wish I’d had a better camera pre-2003 …

Cataloging pictures

Dan and Jim and a frisbee
I spent a happy couple of hours last night cataloguing photos to test my new javascript cataloging tool, and then realized this morning that there were sufficient bugs in my implementation that I had to rebuild the database. In particular the bnode id generation was screwed (but how did it ever work?) and then I realized I didn’t have a scutter implementation in my mini RDF implementation ‘tinkling’ (tiny Inkling). But now my foaf codepiction experiment implementation is more useful – you can see who annotated photos, as well as rough locations (and a map), people, wordnet things…and cataloging is pretty fast (although there’s a tendency to forget which fields you’ve added). But tinkling is still crufty as hell… Also the js thing is very crufty and doesn’t work in IE, only Moz.