Add support for syntactic classification.

Tests pending.
Why don't we use compiler in this case?