stuart lamour’s sussex notes

Entries tagged as ‘json’

del.icio.us bug

May 23, 2008 · Leave a Comment

del.icio.us allows javascript calls which return the Javascript Object Notation (JSON) output of a users tags. The JSON format is a stripped bare XML for easy use by Javascript. Unlike the tag rolls JSON tag feeds contains no style information and can be skinned much more easily to the hosting site style.

The following output is all based on the sussex.skills delicious page.

The lists below use the browser default style.

Delicious also allows javascript calls which return the JSON output of a users bookmarked urls in the JSON format. 

You can also allows you to limit the bookmarks to particular tag. 

Or pick the union of two tags

Which may sometimes result in the empty set e.g.

all good!

But then we found a bug…

A Bug – Pattern matching and the JSON post feed….

You can filter the links that are loaded by tag. To only get bookmarks tagged with both ‘art’ and ‘history’:

http://del.icio.us/feeds/json/sussex.skills/art+history

 

The sussex.skills cloud contains many hyphenated term such as ‘data-collection’. 6 links are tagged ‘data-collection’.

An intersection of a set such as ‘data-collection’ and ‘analyisis’ which contains only 1 tagged link should produce a maximum of 1 result.

The code for this query would be

http://del.icio.us/feeds/json/sussex.skills/data-collection+analysis

For our dataset the expected intersection is none – the one url tagged as ‘analysis’ has not also been tagged ‘data-collection’.

The actual outcome is:

Supposition.

None of our test data is tagged ‘data’ so the result should be the empty set, and a search for ‘data’ delivers the empty set. However a search for the tags ‘data’ AND ‘data’ revealed the answer.

 

The Delicious search algorithm is doing partial pattern matching on any term on either side of the ‘+’ sign in the javascript arguments – a greedy search.

This renders it a little useless for our needs of displaying courses tagged with a specific match of skills :(

I wrote to delicious about a month ago now, but have heard nothing back so far. Writing a reminder now.

Anyone else found this or any ideas about a work around?  

Categories: pattern matching · skillclouds · tech
Tagged: , , ,