clean up shorten.py