Added reading directory and applying pdf conversion