Google Talk IM bot to search the AADL catalog
It's very rough right now, and I will only have it running when I'm there to watch it. But you should be able to connect to
superpatronbot@gmail.com
using a Google Talk or Jabber or iChat or Adium client, and use the command
/aadl anatomy of a murder
to do a keyword search over the Ann Arbor District Library's catalog of all media. To narrow it down you can do
/aadl anatomy of a murder dvd
/aadl anatomy of a murder sound recording
You'll get results formatted back nicely, thanks to the library catalog's use of RSS to generate search results. The search results will be copied to the channel, so that anyone else listening in can see what you are searching for.
This is a "social library search" tool, which would be weird for a library to foist on unsuspecting patrons for privacy reasons, but really very handy to have for a group of people.
It's a chat channel, and at any point along the way you can talk to anyone else on that channel just by typing your message.
The code is relatively rudimentary in many respects at this point, and it's running on my laptop so it's only up when I'm actually there. Bits of it are in active development, and as a part of that it might change in unpredictable ways or not work at all.
If you type
/help
you'll get back a list of commands which includes details from a few more libraries, including e.g.
/swan chicago mls libraries - SWAN catalog - see discussion
/mirlyn university of michigan libraries - MIRLYN catalog
/emich eastern michigan university libraries
Some build notes.
The whole thing is written in python. The bot is based on Perry Lorier's confbot.py, which speaks Jabber to the Google Talk servers. That in turn has been adapted and refactored by Brian Kerr and the Unicorn Collective to be a bit more flexible.
The AADL command I added based on code and libraries adapted from Jose Nazario's duckytool package. An initial proof of concept implementation was about 12 lines of new code.
Adding a new library is variously easy or difficult depending on whether your library system has a programmer-friendly way to display search results. At worst, I return a link to the search results, so that you can click through to the right search page. At best (for AADL) I return the search results as individual items so you can click through to a particular hit.
The command set is subject to change at any time! And remember, it's only up when I'm around, so this is by no means a production service.
Inspired by the MakeBOT. But I ran it on Google rather than AIM because Google's Jabber interface is a documented, standardized protocol.
Technorati Tags: googletalk, jabber, bot, aadl, library, elginpelican
ok, some evolution.
a few libraries disappeared, because we redid the code. never mind, they will be easy to add back in.
Brian Kerr took over the codebase, cleaned it up quite a bit, and is using it for a student project at the U of Michigan School of Information.
We found a Z39.50 gateway, which let us add in a search for the U of Michigan catalogs. Z39.50 is awful. It returns MARC records. MARC is pretty awful, too.
More poking around led to SRU, a new retreival protocol for library records. SRU is better in that it's all HTTP and XML based, and in that it uses Dublin Core as one possible output format so you don't have to know MARC to make sense of it. I haven't dug into it very much yet, but there seem to be some warts in the design, in that you really never get permalinks to catalog records, just relative records in a search stream.
The bot is only up when my iBook is on the net. It's sometimes slow to respond, in part because my iBook travels with me to places where the network isn't fast, and in part because Z39.50 does not make for fast searches. Oh, and the Jabber bot we are using slows down the more people who use it.
Progress.
Posted by:Edward Vielmetti | 18 January 2006 at 11:37 PM
Clarification: it's not a student project, but I am a student. :) There's a group of us who are doing fun things not for $ not for credit, but doing them while at SI. (If you think that sounds like a recipe for disaster, you're probably right.)
Posted by:Brian | 19 January 2006 at 04:22 AM
I don't know if you're aware of that, but ISBNdb.com is a project that actually cross indexes data from various libraries Z39.50 sources. There is a free XML API to get to the data as well. Email me if you have any questions..
Posted by:Andrew | 24 January 2006 at 02:33 PM