Parser now works with both txt and pdf files using the same regular expression