added some flags, updated TODO