# sentiment-and-keyword

> Analyze strings based on sentiment and keyword strength using synonyms and related concepts

Latest version **1.0.9** (published 2021-05-19) · ISC license · 0 weekly downloads

## Install

```sh
npm install sentiment-and-keyword
pnpm add sentiment-and-keyword
yarn add sentiment-and-keyword
bun add sentiment-and-keyword
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.9 |
| Published | 2021-05-19 |
| First published | 2019-10-17 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 2 |
| Unpacked size | 7.7 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Ashley Sanders |
| Maintainers | ashmikeketchum |
| Keywords | sentiment, strings, analysis, keywords, thesaurus, synonyms |

## Links

- npm: https://www.npmjs.com/package/sentiment-and-keyword
- npm.io page: https://npm.io/package/sentiment-and-keyword

## Dependencies (2)

- [sentiment](https://npm.io/package/sentiment.md) ^5.0.2
- [thesaurus](https://npm.io/package/thesaurus.md) 0.0.1

## Alternatives

- [@mce/gif](https://npm.io/package/@mce/gif.md) — 2.6K weekly downloads
- [cleanse](https://npm.io/package/cleanse.md) — 173 weekly downloads
- [str](https://npm.io/package/str.md) — 127 weekly downloads
- [naming](https://npm.io/package/naming.md) — 95 weekly downloads
- [tap-telco-api](https://npm.io/package/tap-telco-api.md) — 19 weekly downloads

## Recent versions

- 1.0.9 (latest) — 2021-05-19
- 1.0.8 — 2019-10-17
- 1.0.7 — 2019-10-17
- 1.0.6 — 2019-10-17
- 1.0.5 — 2019-10-17
- 1.0.4 — 2019-10-17
- 1.0.3 — 2019-10-17
- 1.0.2 — 2019-10-17
- 1.0.1 — 2019-10-17
- 1.0.0 — 2019-10-17

## README

# [sentiment-and-keyword](https://www.npmjs.com/package/sentiment-and-keyword)

### Analyze strings based on sentiment and keyword strength using synonyms and related concepts.

See https://www.npmjs.com/package/sentiment-and-keyword

### Install

```npm i sentiment-and-keyword```

### Usage

```js
const sentkey = require('sentiment-and-keyword');

// Set your text to analyzed *required
let text = "The text you want to be analyzed";
// Set your keywords to be used for analysis *required
let keywords = ["Independent", "Honest", "Collaborative", "Brilliant", "Caring"];

sentkey.analyze(text,keywords,function(err,res){
    if(err){
        console.log(err);
        return
    } 
    console.log(res);
})

```

### Result parse

```json
{
  "text": "The text you want to be analyzed",
  "sentiment_score": 0,
  "sentiment_status": "Neutral",
  "sentiment_calculation":  [  
                              {"Independent": 0},
                              {"Honest": 0},
                              {"Collaborative": 0},
                              {"Brilliant": 0},
                              {"Caring": 0} 
                            ],
  "sentiment_comparative": "0",
  "strength_tracker": [ 
                        {"keyword": "Independent", "score": 0},
                        {"keyword": "Honest", "score": 0},
                        {"keyword": "Collaborative", "score": 0},
                        {"keyword": "Brilliant", "score": 0},
                        {"keyword": "Caring", "score": 0} 
                      ],
  "graph_data": [ 
                  [ 
                    "Keyword", 
                    "Percentage", 
                    { "role": "style" }
                  ],
                  ["keyword1", 0, "#color"],
                  ["keyword3", 0, "#color"],
                  ["keyword4", 0, "#color"],
                  ["keyword5", 0, "#color"],
                  ["keyword6", 0, "#color"],  
                ]
};

```

---
_Source: https://npm.io/package/sentiment-and-keyword · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
