less random way of generating local ids