Giter Club home page Giter Club logo

lda2vec's Introduction

lda2vec: Tools for interpreting natural language

image

image

image

image

image

The lda2vec model tries to mix the best parts of word2vec and LDA into a single framework. word2vec captures powerful relationships between words, but the resulting vectors are largely uninterpretable and don't represent documents. LDA on the other hand is quite interpretable by humans, but doesn't model local word relationships like word2vec. We build a model that builds both word and document topics, makes them interpreable, makes topics over clients, times, and documents, and makes them supervised topics.

Resources

See this Jupyter Notebook for an example of an end-to-end demonstration.

See this slide deck or this youtube video for a presentation focused on the benefits of word2vec, LDA, and lda2vec.

See the API reference docs

About

image

Word2vec tries to model word-to-word relationships.

image

LDA models document-to-word relationships.

image

LDA yields topics over each document.

image

lda2vec yields topics not over just documents, but also regions.

image

lda2vec also yields topics over clients.

image

lda2vec the topics can be 'supervised' and forced to predict another target.

lda2vec also includes more contexts and features than LDA. LDA dictates that words are generated by a document vector; but we might have all kinds of 'side-information' that should influence our topics. For example, a single client comment is about a particular item ID, written at a particular time and in a particular region. In this case, lda2vec gives you topics over all items (separating jeans from shirts, for example) times (winter versus summer) regions (desert versus coastal) and clients (sporty vs professional attire).

Ultimately, the topics are interpreted using the excellent pyLDAvis library:

image

Requirements

Minimum requirements:

  • Python 2.7+
  • NumPy 1.10+
  • Chainer 1.5.1+
  • spaCy 0.99+

Requirements for some features:

  • CUDA support
  • Testing utilities: py.test

lda2vec's People

Contributors

cemoody avatar tingletech avatar cesarsalgado avatar matheusportela avatar intohole avatar

Watchers

Chris Cinelli avatar James Cloos 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.