Moved all extracting functionality to separate modules