Refactor convert_plg to handle entities, download remote assets