Giter Club home page Giter Club logo

shapiro's Introduction

shapiro

Lexicon based sentiment analysis.

Overview

Shapiro provides building blocks for sentiment analysis. The current implementation is a improved variant of code examples from a talk about Introduction to sentiment analysis with spaCy I gave at the EuroPython 2018 conference.

Shapiro's goals are:

  • provide functions for common preprocessing tasks like replacing synonyms and unifying emojis/smiley codes
  • provide means to read a sentiment lexicon and match tokens with it
  • provide ways to model domain independent sentiment specific parts of Latin based languages (like negators and intensifiers)
  • provide means to assign sentiment information to idioms
  • (long term) provide ways to model a grammar for more advanced sentiment analysis similar to the one described Bing Liu (2015) "Sentiment Analysis: Mining Opinions, Sentiments, and Emotions".

Currently it provides basic support for:

  • Users can provide lexicons (in CSV format) to assign topics and ratings to sentiment words
  • Negators, intensifiers and diminishers (and combinations of them). Currently there is support for English and German. Adding more languages based on Latin should be possible.
  • Lemmatization, part of speech tagging and basic language modelling by using spaCy.

This is a work in progress and features might be added and changed as seem fit. So the API is a moving target.

Getting started

To use shapiro, you need Python and spaCy. The easiest way to get it is:

  1. Download and install anaconda from https://www.anaconda.com/download/
  2. Install spaCy:

    conda install -c conda-forge spacy
  3. Install Tox:

    conda install -c conda-forge tox
  4. Download the language models you need. For example to get English and German run:

    python -m spacy download en
    python -m spacy download de

For more information on installing spaCy visit https://spacy.io/usage/. For details on available free language models visit https://spacy.io/usage/models.

shapiro's People

Contributors

alexmach77 avatar bnelo12 avatar charlesdong1991 avatar roskakori avatar wlongxiang avatar

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.