Added comments and some styling to synonym replacer