a parser for learning