improve filtering/sanitization of keywords