bug fix for constant regular expression model building