Refactor parser package