add pattern filtering to match entities
resolve the models through a controller filters instead