[core/pyos refactor] Update comments, and start porting