Skip to main content

Multilingual Emotion Classification

Project description

Text Emotion

Introduction

Supported Languages

The following languages are supported by the finetuned xlm-roberta model:

  • English
  • French
  • Spanish
  • German
  • Italian

All other languages are translated to English using the EasyNMT library. If the language is not supported by EasyNMT, then it is not supported.

Installation

You can install emotion using:

$ pip install text-emotion

Usage

from text_emotion import Detector

detector = Detector(emotion_language="fr")

print(detector.detect("Hello, I am so happy!"))

XLM-Roberta

The underlying model is xlm-roberta-large. You can test it at:

https://huggingface.co/ma2za/xlm-roberta-emotion

References

Unsupervised Cross-lingual Representation Learning at Scale (Conneau et al., ACL 2020)

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

text_emotion-0.0.3.tar.gz (4.4 kB view details)

Uploaded Source

Built Distribution

text_emotion-0.0.3-py3-none-any.whl (4.4 kB view details)

Uploaded Python 3

File details

Details for the file text_emotion-0.0.3.tar.gz.

File metadata

  • Download URL: text_emotion-0.0.3.tar.gz
  • Upload date:
  • Size: 4.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.3.2 CPython/3.11.2 Linux/6.2.0-20-generic

File hashes

Hashes for text_emotion-0.0.3.tar.gz
Algorithm Hash digest
SHA256 2a242c311c3a951c5d68718555741eae9c1a36f2e43dd90feafeb0c23e1344eb
MD5 bd87633f5c1bbe254629f1c662f49102
BLAKE2b-256 3f511a5b53bb254b7b54b717a8002ab2ad2ee002e72b90fe2b217a7714cbea20

See more details on using hashes here.

File details

Details for the file text_emotion-0.0.3-py3-none-any.whl.

File metadata

  • Download URL: text_emotion-0.0.3-py3-none-any.whl
  • Upload date:
  • Size: 4.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.3.2 CPython/3.11.2 Linux/6.2.0-20-generic

File hashes

Hashes for text_emotion-0.0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 849e9ba23cf73d368abb7ee2f32a146b2fe4016a84cf1e57e33268d322797ec2
MD5 7eb2e15919654ec4f4afbcc2cebd7e7a
BLAKE2b-256 aebe1756d8fe1b1a8b677a876526e2146578ed82852b530b3515326ab858e8d5

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