Giter Site home page Giter Site logo

iq-scm / this-word-does-not-exist Goto Github PK

View Code? Open in Web Editor NEW

This project forked from turtlesoupy/this-word-does-not-exist

0.0 0.0 0.0 37.86 MB

This Word Does Not Exist

Home Page: https://www.thisworddoesnotexist.com

License: MIT License

Shell 1.85% JavaScript 3.43% Python 64.72% CSS 1.58% Jupyter Notebook 25.59% Jinja 2.83%

this-word-does-not-exist's Introduction

Word Does Not Exist Logo

This Word Does Not Exist

This is a project allows people to train a variant of GPT-2 that makes up words, definitions and examples from scratch.

For example

incromulentness (noun)

lack of sincerity or candor

"incromulentness in the manner of speech"

Check out https://www.thisworddoesnotexist.com as a demo

Check out https://twitter.com/robo_define for a twitter bot demo

Generating Words / Running Inference

Python deps are in https://github.com/turtlesoupy/this-word-does-not-exist/blob/master/cpu_deploy_environment.yml

Pre-trained model files:

To use them:

from title_maker_pro.word_generator import WordGenerator
word_generator = WordGenerator(
  device="cpu",
  forward_model_path="<somepath1>",
  inverse_model_path="<somepath2>",
  blacklist_path="<blacklist>",
  quantize=False,
)

# a word from scratch:
print(word_generator.generate_word())

# definition for a word you make up
print(word_generator.generate_definition("glooberyblipboop")) 

# new word made up from a definition
print(word_generator.generate_word_from_definition("a word that does not exist")) 

Training a model

For raw thoughts, take a look at some of the notebooks in https://github.com/turtlesoupy/this-word-does-not-exist/tree/master/notebooks

To train, you'll need to find a dictionary -- there is code to extract from

After extracting a dictionary you can use the master training script: https://github.com/turtlesoupy/this-word-does-not-exist/blob/master/title_maker_pro/train.py. A sample recent run is https://github.com/turtlesoupy/this-word-does-not-exist/blob/master/scripts/sample_run_parsed_dictionary.sh

Website Development Instructions

cd ./website
pip install -r requirements.txt
pip install aiohttp-devtools 
adev runserver

this-word-does-not-exist's People

Contributors

eliseumds avatar mayakacz avatar turtlesoupy 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.