import tensorflow as tf

            extended_vsize = vsize
            if self.max_phrase_size is not None:
                extended_vsize += self.max_phrase_size
                extra_zeros = tf.zeros((batch_size, self.max_phrase_size))
                vocab_dist = tf.concat(values=[vocab_dist, extra_zeros], axis=1) # [batch_size, extended_vsize]
                if self.options.add_first_word_prob_for_phrase: # add prob of the first word to each phrase
