Coder Social home page Coder Social logo

carlosandres12 / doc2vec_user_comments Goto Github PK

View Code? Open in Web Editor NEW

This project forked from smokincaterpillar/doc2vec_user_comments

0.0 2.0 0.0 1.24 MB

I analysed online user comments on articles by German news publishers SPON, ZEIT, and Focus

Jupyter Notebook 100.00%

doc2vec_user_comments's Introduction

Analysis of user comments with gensim Doc2Vec

Doc2Vec is a nice neural network framework for text analysis. The machine learning technique computes so called document and word embeddings, i.e. vector representations of documents and words. These representations can be used to uncover semantic relations. For instance, Doc2Vec may learn that the word "King" is similar to "Queen" but less so to "Database".

I used the Doc2Vec framework to analyze user comments on German online news articles from SPON, ZEIT, and Focus and uncovered some interesting relations among the data. Furthermore, I fed the resulting Doc2Vec document embeddings as inputs to a supervised machine learning classifier. Accordingly, given a particular comment, can we determine from which news site it originated? Are there patterns among user comments? Can we identify stereotypical comments for different news sites?

You can find a Jupyter Notebook abut the Doc2Vec and ML models in this repository. I trained several models and plaid with the model parameters a bit. Some of the outcomes in this particular notebook might be slightly different from the results in the talk given below, but overall the different models were very robust regarding changes in parameter settings. The results were very similar for very different settings (like doc2vec dimensionality, window size, etc.). The individual best prototypes may vary across models, but the overall political tone of the prototypical comments, especially the racists tendency for Focus user comments, was always and strongly present in all models!

Unfortunately, I cannot provide the raw scraped user comment data (yet), because I am lacking permissions by the publishers.

I gave a presentation about this project at the PyData conference. The slides can be found in this repository and you may watch the talk on YouTube.

doc2vec_user_comments's People

Watchers

 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.