grammatical structure analysis