improve Li's terrible interface.