Added a more accurate query token weight calculation formula.