under the hood regular expressions