added regex for output parsing