plan to cleanup the fd generation code