Code Monkey home page Code Monkey logo

word-level-rnn-keras's Introduction

word-level-rnn

Word Level RNN for text generation using keras.

This is a project with a goal to make a Word Level Text generation using keras on Theano Framework. The code is based on the sample text generation character level code provided as a sample example at https://github.com/fchollet/keras/blob/master/examples/lstm_text_generation.py

#Requirements: Theano: https://github.com/Theano/Theano Keras: https://github.com/fchollet/keras

#Usage: To train a dataset, put the txt file inside the dataset directory, and run the script, additionally you can tweak the batchsize as per your machine's memory contraint

#Future Update: I'll add an option to have a choice between different RNN models

#Sample Testing: I tried training it on chapters of The Game of Thrones (individually, because of memory constraints), seems coherent, please try and give me feedback.

#Read This: Since the code is done at word level instead of character level, it needs more epochs than the character level text generation counter part, as well as much more memory because it has to be trained on thousands of words, (unlike character level code where it's only trained on 50-100 different characters (assuming ASCII).

Word level RNN text generation should in theory be more coherent then the Character level text generation at lesser amount of training. Suggestions and criticism are welcome to optimising and improve the code. thanks!

word-level-rnn-keras's People

Contributors

vlraik avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.