cleanup & python integration