Character generator RNN using Tensorflow

Hi all,

I have been working on a character generator using LSTM in Tensorflow. This is the code that I am using. The code seems to be working but it is not giving me the expected random characters based on the input I provide to it. Can someone look at my code and give me any pointers. I am a noob to Tensorflow and RNN. Any inputs will be appreciated.

Thanks.