major revisions, working four-part parser