Text Sentiment
Introduction
Text Sentiment allow you to predict the sentiment of text either data is POSITIVE
, NEGATIVE
, NEUTRAL
. You can use this
result to predict user reviews and many other task on you server side.
Currently we only support these languages by default
Arabic
, English
, French
, Hindi
, Spanish
, German
, italian
, Portuguese
Endpoint
Post
https://api.oyyi.xyz/v1/ml/text-sentimentContent-Type: application/json
Parameters
text Required
Pass the string text you want to analyze for sentiment.- Type:
string
- Type:
Example
Python
import requestsurl = $BASE_URL/ml/text-sentimentstoken = 'your_bearer_token_here'headers = {'Authorization': f'Bearer {token}'}data = { "text": 'i like the oyyi website and apis.'};response = requests.post(url,params=data, headers=headers)print(response.text)
Response
Default
{ "data": [ { "label": "positive", "score": 0.5482088327407837 } ],}
Table of Contents