First commit of typing refactor for James