Add associated document ids in vertex distribution. FIXME: likelihood function.