import tensorflow as tf

        self.graph = graph

        with self.graph.as_default():
            with tf.device('/cpu:0'):
                embedding = tf.get_variable(
                    'embedding', [vocab_size, hidden_size], dtype=tf.float32)
                inputs = tf.nn.embedding_lookup(embedding, input_.input_data)

            if is_training and config.keep_prob < 1:
                inputs = tf.nn.dropout(inputs, config.keep_prob)

            output, state = self._build_rnn_graph(inputs, config, is_training)

            softmax_w = tf.get_variable(
                'softmax_w', [hidden_size, vocab_size], dtype=tf.float32)
            softmax_b = tf.get_variable('softmax_b', [vocab_size], dtype=tf.float32)
            logits = tf.nn.xw_plus_b(output, softmax_w, softmax_b)
            logits = tf.reshape(logits, [self.batch_size, self.num_steps, vocab_size])
