adding logging infrastructure, new extraction routines and a lot of cleanup