Refactor run.py/overload.py to seperate out client logic