class_docstr: Helper for interpolation algirithm.
  New token is sample from model, ground_truth or reward according to lambdas
  
  Args:
      embedding: A callable that takes a vector tensor of `ids` (argmax ids),
          or the `params` argument for `embedding_lookup`. The returned tensor
          will be passed to the decoder input.
      start_tokens: `int32` vector shaped `[batch_size]`, the start tokens.
      end_token: `int32` scalar, the token that marks end of decoding.
      vocab: texar.Vocab, the vocabularies of training set
      reward_metric: 'bleu' or 'rouge', the metric of reward
      ground_truth: the ground truth in training set
      ground_truth_length: the length of ground truth sentences
      lambdas: 'float32' vector shapes [3], according to which
          decide the way of generate the next token in training
class_docstr_tok: ["Helper","for","interpolation","algirithm",".","New","token","is","sample","from","model",",","ground_truth","or","reward","according","to","lambdas","Args",":","embedding",":","A","callable","that","takes","a","vector","tensor","of","`","ids","`","(","argmax","ids",")",",","or","the","`","params","`","argument","for","`","embedding_lookup","`",".","The","returned","tensor","will","be","passed","to","the","decoder","input",".","start_tokens",":","`","int32","`","vector","shaped","`","[","batch_size","]","`",",","the","start","tokens",".","end_token",":","`","int32","`","scalar",",","the","token","that","marks","end","of","decoding",".","vocab",":","texar.Vocab",",","the","vocabularies","of","training","set","reward_metric",":","'bleu","'","or","'rouge","'",",","the","metric","of","reward","ground_truth",":","the","ground","truth","in","training","set","ground_truth_length",":","the","length","of","ground","truth","sentences","lambdas",":","'float32","'","vector","shapes","[","3","]",",","according","to","which","decide","the","way","of","generate","the","next","token","in","training"]
docstr: notice the special form of 'state'([decoded_ids, rnn_state])
docstr_tok: ["notice","the","special","form","of","'state","'","(","[","decoded_ids",",","rnn_state","]",")"]
code: def next_inputs(self, time, outputs, state, sample_ids, name=None):
      """
      notice the special form of 'state'([decoded_ids, rnn_state])
      """
      (
          finished,
          next_inputs,
          next_state,
      ) = SampleEmbeddingHelper.next_inputs(
          self, time, outputs, state[1], sample_ids, name
      )
  
      next_state = [
          tf.concat(
              [
                  state[0][:, :time],
                  tf.expand_dims(sample_ids, 1),
                  state[0][:, time + 1 :],
              ],
              axis=1,
          ),
          next_state,
      ]
      next_state[0] = tf.reshape(
          next_state[0], (tf.shape(sample_ids)[0], 60)
      )
  
      return finished, next_inputs, next_state
  
file_path: texar/examples/seq2seq_exposure_bias/interpolation_helper.py
imports: import tensorflow
  import numpy
  from tensorflow_probability import distributions
  from tensorflow.contrib.seq2seq import SampleEmbeddingHelper
  from texar.tf.evals.bleu import sentence_bleu
  from rouge import Rouge
label_desc: Use image node_id 3 for calling the InterpolationHelper obj's underlying member method code with example usage: obj.next_inputs(time, outputs, state, sample_ids, name) and returns: finished,  next_inputs,  next_state