I took part on the second day of Boston Mashathon, and above a great talk with Lee Cornelison from the library of MIT Lincoln Laboratory, to whom I can show the eXtensible Catalog Drupal Toolkit in action, I was able to create two new Drupal modules for the toolkit. Both modules have double interfaces: they implement a new Drupal Toolkit hook, 'hook_xc_display_full' with which other modules can enhance the content of the full record display (now, at the and of the day it doesn't seem to be a good name, I guess I will change it), and for modules other than XC Drupal Toolkit there are another public funtions available.
My old and favorite idea is, that the books have theirs "social connections" with other books. They have a lots of common attributes: their authors, contributors, publishers and subjects should use and links between books. The hierarchial classification systems are theoretically the eminent examples, since they enrich the connection types: the introduce the parent-child connection, while normal subject headings shows only "siblings". Unfortunatelly, the most popular hierarchical classification systems based on artificial notations (numbers, and punctuation marks), which is good for international usage on one side, but on the other side without the dictionary, the user can not understand the notation. And the user is without a dictionary. I don't know the copyright status of Dewey Decimal Classification System, but that of the Universal Decimal Classidication is a horror. The copyright owner (the UDC Consortium) does not allows the electronic publication, and usage in library systems. Please correct me if this situation has been changed, and there is a freely available online UDC edition (not just mere samples). Anyway: back to Dewey. The good news - to shame of me I haven't known it a week before - OCLC created an initiative to make the meaning of Dewey numbers available as web service at http://dewey.info. You can use HTML and RDF formats, there are language variants for about 10 languages. At the time of writing only the first 3 numbers of any Dewey numbers are searchable, but I hope, that they will enriche it in the future.
The calling of web service is quite straightforward. The URL scheme is
http://dewey.info/class/[Dewey number]/about.[two letter language code].rdf
Our aim is quite simple: resolve the meaning of a number - though of course there are other things to develop in the future. The meaning is tagged with <skos:prefLabel> element in the RDF response, so what we had to do is extract the content of that element. I chosed to use regex for this simple task, though it could have been done with an XML handler as well, like SimpleXML, what I use in the other module. For reducing the number of HTTP request I applied a simple caching mechanism: the Drupal variables (variable_get() and variable_set()).
When a request happens, the module start to call this translator function with numbers from the top of hierarchy downwards. In both Dewey, and UDC the hierarchy is simple (let's forget not the composite notations): 813's topmost element is 8 (Literature), then 81 on the second level (American literature in English), and finaly 851 in the thrid level (American fiction in English). If the length of Dewey number is greater than 3, we do not try to translate the larger parts. The xc_dewey_get($dewey_number) returns either an array like this:
8 => "Literature",
81 => "American literature in English"
851 => "American fiction in English"
or like this:
8 => "Literature",
81 => "American literature in English",
851 => "American fiction in English",
"851.2" => "851.2"
The xc_dewey_xc_display_full() function, which is implementation of hook_xc_display_full($xc_record) return a string wrapped into an array, which looks like this:
Literature > American literature in English > American fiction in English
where each text is a link, which launch a query. This way you can easily find all literature in the catalog.
On this image it is clear, how the hierarchial structure could give more context to the non-hierarchical subject headings.
The titles of journals are always changing. Even theirs ISSN numbers. There might be different formats (print, CD-ROM, online, microform). OCLC's xISSN service try to find this type of history of each journals. You can find more details here: http://www.oclc.org/xissn/default.htm. The module I wrote (XC xISSN) requests this service with an ISSN number, and send you back the the details of the given journal's history. It uses the PHP response format (which returns a PHP program code string), but change it a little. First it returns an array instead of string. Second, for making iteration more easily, I modified the array as this:
'preceding' => // the array of titles
'this' => // the array of titles
'succeeding' => // the array of titles
I enhanced the titles with two more properties based on form: shortform, and longform. This gives the user a human readable label to the form, which actualy an ONIX code. The values are:
'JB' => array('short' => t('Print version'), 'long' => t('Printed serial')),
'JC' => array('short' => t('CD-ROM version'), 'long' => t('Serial distributed electronically by carrier')),
'JD' => array('short' => t('Online version'), 'long' => t('Electronic serial distributed online')),
'MA' => array('short' => t('Microform version'), 'long' => t('Microform')),
All labels come from the OCLC's xISSN site, but I applied the t() function, to make them translatable.
The hook_xc_display_full() implementation creates a themed display. I add one feature here: the module checks the Solr index whether the ISSN number is avaivalable, and so, it display the number as query link, which brings the user to the search result page.
Both modules are available inside the eXtensible Catalog Drupal Toolkit (http://drupal.org/project/xc). Of course there are a lots of places for improvement, but this was not a bad start at all.
I owe a great thank to all organizers. It was a great event in a great place! Thank you!
eXtensible Catalog Organization
kirunews (at) gmail.com
The OCLC Developer Network supports the use of OCLC Web Services—a set of tools and APIs that expose data and services for WorldCat and our member libraries and partner institutions or companies. learn more »
© 2010 OCLC Domestic and international trademarks and/or service marks of OCLC Online Computer Library Center, Inc. and its affiliates