Graph query time inferencing


The documentation state that Graql is based perform query time inferencing. I wonder if it is based on query rewriting?
Indeed given that that technics has his limit when ontololgy becomes complex, i wonder what is the formal expressivity of Graql schema. I am thinking of rules, sub-typing and what not that is included.