class_docstr: A format that stores positions and per-position boost information
  in each posting.
  
  Supports: frequency, weight, positions, position_boosts.
class_docstr_tok: ["A","format","that","stores","positions","and","per-position","boost","information","in","each","posting",".","Supports",":","frequency",",","weight",",","positions",",","position_boosts","."]
code: def encode(self, poses):
      codes = []
      base = 0
      summedboost = 0
      for pos, boost in poses:
          summedboost += boost
          codes.append((pos - base, boost))
          base = pos
      return (
          pack_uint(len(poses))
          + pack_float(summedboost)
          + dumps(codes, 2)
      )
  
imports: from collections import defaultdict
  from whoosh.analysis import unstopped, entoken
  from whoosh.compat import iteritems, dumps, loads, b
  from whoosh.system import emptybytes
  from whoosh.system import _INT_SIZE, _FLOAT_SIZE
  from whoosh.system import pack_uint, unpack_uint, pack_float, unpack_float
label_desc: Use image node_id 2 for calling the PositionBoosts obj's underlying member method code with example usage: obj.encode(poses) and returns: unknown