Skip to main content

A lexicon-based sentiment analysis for Spanish.

Project description

CI new dev push

CD approved PR dev to master

SentiLeak

This is a lexicon-based sentiment analysis package for Python.

For now, it only supports Spanish but it will be extended to support other languages like English, Portuguese, Catalan or French.

Installation

SentiLeak can be installed with pip:

pip install SentiLeak

Usage

To use this package, it is only necessary to import SentiLeak class and call the method compute_sentiment.

This is an example of usage:

>>> from sentileak import SentiLeak
>>> sent_analysis = SentiLeak()
>>> text = "La decisión del árbitro fue muy perjudicial para el equipo local. El partido estaba empatado para ambos equipos. Al final, el portero hizo una gran intervención que salvó a su equipo."
>>> sent_analysis.compute_sentiment(text)
{
	'per_sentence_sentiment': [{
		'position': 0,
		'text': 'La decisión del árbitro fue muy perjudicial para el equipo local.',
		'score': -3.0
	}, {
		'position': 1,
		'text': 'El partido estaba empatado para ambos equipos.',
		'score': 0.0
	}, {
		'position': 2,
		'text': 'Al final, el portero hizo una gran intervención que salvó a su equipo.',
		'score': 3.0
	}],
	'global_sentiment': 0.0
}

Contributor

The main (and the only) contributor is FernanOrtega

This project has also the support of Opileak

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

SentiLeak-0.1.4.tar.gz (16.8 kB view details)

Uploaded Source

Built Distribution

SentiLeak-0.1.4-py3-none-any.whl (19.5 kB view details)

Uploaded Python 3

File details

Details for the file SentiLeak-0.1.4.tar.gz.

File metadata

  • Download URL: SentiLeak-0.1.4.tar.gz
  • Upload date:
  • Size: 16.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.7.14

File hashes

Hashes for SentiLeak-0.1.4.tar.gz
Algorithm Hash digest
SHA256 965c4859a37894e1580ec9505a4f991d9088a95fd454ce7fd73b55f79d82c18e
MD5 9ee1dc2b6f7f5fbf68ef470d6f7c89f4
BLAKE2b-256 59607f7098137d925ecc94f30895acaef8b73fe9909df0933f632e3ff0b17f1f

See more details on using hashes here.

File details

Details for the file SentiLeak-0.1.4-py3-none-any.whl.

File metadata

  • Download URL: SentiLeak-0.1.4-py3-none-any.whl
  • Upload date:
  • Size: 19.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.7.14

File hashes

Hashes for SentiLeak-0.1.4-py3-none-any.whl
Algorithm Hash digest
SHA256 80dabdd1e9383cdad6f4d5aaf58ed8785d5e9532aacfc273fe2e73848a1fb214
MD5 16e9d2b1271a43e6204eecf0f4ab0b73
BLAKE2b-256 249e96e22498d8ec3c3b4279a733831f369c2976af634dfd779b9b31d11067a7

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page