Skip to main content

Sentiment Analysis Tool

Project description

Swarmauri Logo

PyPI - Downloads PyPI - Python Version PyPI - License PyPI - Version


Sentiment Analysis Tool

A tool for analyzing the sentiment of text using Hugging Face's transformers library. This tool provides simple sentiment analysis capabilities, classifying text as POSITIVE, NEGATIVE, or NEUTRAL.

Installation

pip install swarmauri_tool_sentimentanalysis

Usage

Here's a basic example of how to use the Sentiment Analysis Tool:

from swarmauri.tools.SentimentAnalysisTool import SentimentAnalysisTool

# Initialize the tool
tool = SentimentAnalysisTool()

# Analyze sentiment
result = tool("I love this product!")
print(result)  # {'sentiment': 'POSITIVE'}

# Another example
result = tool("This product is okay.")
print(result)  # {'sentiment': 'NEUTRAL'}

Want to help?

If you want to contribute to swarmauri-sdk, read up on our guidelines for contributing that will help you get started.

Project details


Release history Release notifications | RSS feed

Download files

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

Source Distribution

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

File details

Details for the file swarmauri_tool_sentimentanalysis-0.6.1.dev16.tar.gz.

File metadata

File hashes

Hashes for swarmauri_tool_sentimentanalysis-0.6.1.dev16.tar.gz
Algorithm Hash digest
SHA256 c9f48119f838f15b6bf1f4722384cf51002c0fbc3db0353a3d86dd542dea78d3
MD5 cfe9ba2e97a3998e0f2e9d927178d12c
BLAKE2b-256 1dad5260d1a2bd75fcd0af2407dd75ac9bc2ea538b87bac894d112b31b39dddd

See more details on using hashes here.

File details

Details for the file swarmauri_tool_sentimentanalysis-0.6.1.dev16-py3-none-any.whl.

File metadata

File hashes

Hashes for swarmauri_tool_sentimentanalysis-0.6.1.dev16-py3-none-any.whl
Algorithm Hash digest
SHA256 9b28b69e373f22aa8e39aa8d3847a0d886637eee452c85beabbfe83b7d0eebf7
MD5 15db16e2358c0600e6bac6682df8de85
BLAKE2b-256 4bfe3e342b38bf93a494fca1efe3d36d05e871efc57083523520fe75c3eb22fd

See more details on using hashes here.

Supported by

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