improve the input helper