update regex patterns