Formating ISBNs
I found out there are strict rules for formatting ISBNs.
There are Implementations in C, Emacs elisp, php and check-digit checking perl.
There are also articles about the structure and country prefixes. Finally there is the official Handbook.
I have ported the implementation from bibclean over to Python done some pythonisations to speed it up and added a check sum validation routine inspired by the perl version.
Download isbn.py.