revise interface to make it simpler to use