LPTHW - ex48 - Handling exceptions and unit testing
lword = string.lower(word)  


There is no need to import the string module for this, you can use:

lword = word.lower()


As for this:

elif int(lword):


Probably better as

elif lword.isdigit():


As for your exception handling

     except:                                                              
         action.append(('error', word))


You should almost never use a bare except. You should catch a specific exception, and put a minimal amount of code in the try block. In this case you could have done something like

try:
   actions.append( ('number', int(word) )
except ValueError:
   actions.append( ('error', word) )