Identifying the author's purpose in a text