fix on modeler and substr_offset