added categorical pulling of states
added routing for pulling current state