Skip to main content

nephased

Nephased provides a BERT-based classification pipeline for detecting Nepali text sentiment

Installation

From TestPyPI:

pip install nephased

Or you can use the Nephased(finetune of distilbert-base-nepali) from huggingface

Usage

Import Nephased module using the following command.

from nephased import Nephased

Initialize Nephased

clf = Nephased()
  • You can pass a single string:
>>> clf.predict("थुक्क पैसा मा बिकने हीजडा")
'PROFANITY_0'
  • or, a list of string:
>>> clf.predict(["राडिको छोरोको शासन धेर दिन टिक्दैन |", "सुरु मा चाहिँ तैले यो देश छोडनु पर्यो |", "एसको घरमा आगो लाहिदे ।"])
['PROFANITY_1', 'GENERAL', 'VIOLENCE']

About Output

Nephased can distinguish between 4 categories:

  • GENERAL : Instance without any profanity or violence.
  • PROFANITY_0 : Instance including rude, bad or slander which are not very harsh but offensive words used on day-to-day lives in Nepal.
  • PROFANITY_1 : Instance including swear or curse words which are very harsh
  • VIOLENCE : Instance including physical assualt or rape and pyromaniac act.

The guidelines for segragating such sentiments are on NepsaGuidelines

Metadata

Release files for nephased 0.0.34

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for nephased 0.0.34
File Size Uploaded
nephased-0.0.34.tar.gz 5.3 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for nephased 0.0.34
File Interpreter ABI Platform
nephased-0.0.34-py3-none-any.whl Python 3 none any Details

Total release size: 10.8 kB

Release files / nephased-0.0.34.tar.gz

Download URL nephased-0.0.34.tar.gz
Size 5.3 kB
Tags Source
SHA-256 checksum
How to use checksums
5217923cd53b36ff399ad3794df8fec29f8c5c62855c1127cac6da785953e613
BLAKE2b-256 checksum
How to use checksums
c8c534ecf17e17359c5655d920c39d73014347c39fd110e9fb85d8be0c78fd5b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.11.4

Release files / nephased-0.0.34-py3-none-any.whl

Download URL nephased-0.0.34-py3-none-any.whl
Size 5.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
2c6e8250d383337f6f8263ffa4bb27fac84a63ae8cee50ad23fdca77ff5a061b
BLAKE2b-256 checksum
How to use checksums
5e8504da0836d99dbda665555d6447ecb6a6c3044366f950548a1bcd3b9ddb3b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.11.4

Release history Release notifications | RSS feed

This release

0.0.34 This release

2 release files

0.0.33

2 release files

0.0.32

2 release files

0.0.3

2 release files

0.0.2

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page