some fine tuning of the regexps