added ability to control number of builds queried