Updated the XML to corpus script to process a directory.