finite state grammar