My first pipe

Whilst the US are asleep and Yahoo Pipes is up, I’ve been having a quick play.

My initial idea was to utilise the machine tags feature of flickr to create a pipe which would work with photos tagged by members of the Hursley photo club. Members who post to flickr have used machine tags to tag photos taken on our recent trip to Winchester. The following tags are in use:

So the idea was to have a number of inputs which would allow you to then utilise the machine tags to find pictures that matched. To begin with I started with location and member. Not overly exciting, but a start.

Getting the input is easy, just use a couple of text inputs, then a string concatenation to turn them into the machine tags, which in turn was wired to another string concatenation to create the search string e.g. “hurlabphoto:member=aspender hurlabphoto:location=winchester”. I then fed this into the flickr source module. However whilst it appeared to handle a single machine tag ok, it didn’t return results if two were present. Instead, I used the URLBuilder and Fetch modules to create a valid flickr feed request (using the API reference documentation to get it right) which worked.

What this gave me was a feed containing the photos which matched both the location and member. Unfortunately this is where things started to get disappointing. Firstly, it would be nice to be able to use wildcards with the machine tags, but they are only supported when using the full blown flickr APIs. So you have to input both a member and a location. Additionally there are not any facilities for validating/checking inputs so you cannot even check for null/empty and not include that input as a result. What’s more, it would be nice to be able to provide a list/drop down style of input. For example it would be awesome to be able to do a wildcard search on a machine tag such as hurlabphoto:member and then take all the values to populate a drop down to present to the user.

One way I tried to get around this problem was to initially retrieve all photos tagged with hurlabphoto then attempt to successively filter on the tags returned for each photo using the inputs. In the results returned by flickr, the tags are contained as such:


<category term="hurlabphoto" scheme="http://www.flickr.com/photos/tags/" />
<category term="hurlabphoto:location=winchester" scheme="http://www.flickr.com/photos/tags/" />
<category term="hurlabphoto:date=20070127" scheme="http://www.flickr.com/photos/tags/" />
<category term="hurlabphoto:member=aspender" scheme="http://www.flickr.com/photos/tags/" />
<category term="hurlabphoto:subject=candid" scheme="http://www.flickr.com/photos/tags/" />

The filter node recognises the term attribute, but unfortunately doesn’t seem to successfully return results when you filter against it with a machine tag such as hurlabphoto:member=aspender.

So, the net result is that I’ve created a pipe which simply removes the need to insert the full machine tag and which also sorts the results. Not very useful. Most of this is down to the current limitations of machine tag searching by anything other than the full API, something which will hopefully be relaxed over time. When/if it does, then the combination of flickr and pipes will be very powerful indeed.

So, finally, if you want to have a play with the pipe and maybe play around with taking a clone of it, you will find it here. FYI, valid values for the inputs are:

location: winchester
member: aspender, currie, calanais, Fragments of eternity, Liam O’Neill

Leave a Reply