Skip to content

Commit

Permalink
0.0.5 setup ready
Browse files Browse the repository at this point in the history
  • Loading branch information
n4ze3m committed Mar 11, 2022
1 parent c0b80ee commit 3d4cbcb
Show file tree
Hide file tree
Showing 3 changed files with 35 additions and 24 deletions.
14 changes: 14 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,23 @@
## 0.0.5

- adjust formatting
- use data class instead of Map
- expose Emoji for external use

By [@TheOneWithTheBraid](https://github.com/TheOneWithTheBraid) on [GitHub PR](https://github.com/buckthorndev/sentiment_dart/pull/1)

## 0.0.4

- new language added(german)

## 0.0.3

- big update

## 0.0.2

- pub points issue fixed

## 0.0.1

- Initial version with 3 languages
43 changes: 20 additions & 23 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,15 @@ import 'package:sentiment_dart/sentiment_dart.dart';
main() {
void main() {
final sentiment = Sentiment();
print(sentiment.analysis('i hate you piece of shit 💩'));
print(sentiment.analysis('i hate you piece of shit 💩',emoji: true));
print(Sentiment.analysis('i hate you piece of shit 💩'));
print(Sentiment.analysis('i hate you piece of shit 💩',emoji: true));
}
}
```
*output*

_output_

```output
{score: -7, comparative: -1.1666666666666667, words: [i, hate, you, piece, of, shit], good words: [], badword: [[hate, -3], [shit, -4]]}
Expand All @@ -26,24 +27,24 @@ main() {

### Other language

*example*
_example_

```dart
import 'package:sentiment_dart/sentiment_dart.dart';
main() {
void main() {
final sentiment = Sentiment();
print(sentiment.analysis('ti odio un pezzo di merda 💩',languageCode: 'it'));
print(sentiment.analysis('ti odio un pezzo di merda 💩',emoji: true,languageCode: 'it'));
print(Sentiment.analysis('ti odio un pezzo di merda 💩',languageCode: 'it'));
print(Sentiment.analysis('ti odio un pezzo di merda 💩',emoji: true,languageCode: 'it'));
}
}
```

*output*
_output_

```output
{score: -7, comparative: -1.1666666666666667, words: [ti, odio, un, pezzo, di, merda], good words: [], badword: [[odio, -3], [merda, -4]]}
Expand All @@ -53,21 +54,22 @@ main() {

### Custom language

*example*
_example_

```dart
import 'package:sentiment_dart/sentiment_dart.dart';
main() {
void main() {
final sentiment = Sentiment();
var customLang = {'i': 1, 'love': 1, 'dart': 5,'car':2};
print(sentiment.analysis('i love dart',customLang: customLang));
print(Sentiment.analysis('i love dart',customLang: customLang));
}
}
```
*output*

_output_

```output
{score: 7, comparative: 2.3333333333333335, words: [i, love, dart], good words: [[i, 1], [love, 1], [dart, 5]], badword: []}
Expand All @@ -83,24 +85,18 @@ AFINN is a list of words rated for valence with an integer between minus five (n
## Languages and code

| language | code |
| -- | -- |
| -------- | ---- |
| English | en |
| Italian | it |
| french | fr |
| german | de |

*As soon as possible, more languages will be available.*

## todo

- [ ] add more languages

- [ ] fix small bugs

## Contribution 🤓

Happy 😍 to recieve or provide contributions related to this package.

## Features and bugs 🐛
## Features and bugs 🐛

Please file feature requests and bugs at the [issue tracker][tracker].

Expand All @@ -110,4 +106,5 @@ Please file feature requests and bugs at the [issue tracker][tracker].

if you have any questions , feel free to wite us on

- [Twitter](https://twitter.com/buckthorndev)
- [Buckthorn Twitter](https://twitter.com/buckthorndev)
- [n4ze3m Twitter](https://twitter.com/n4ze3m)
2 changes: 1 addition & 1 deletion pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: sentiment_dart
description: Sentiment Dart is a dart module that uses the AFINN-165 wordlist to perform sentiment analysis on arbitrary blocks of text
version: 0.0.4
version: 0.0.5
homepage: https://github.com/buckthorndev/sentiment_dart

environment:
Expand Down

0 comments on commit 3d4cbcb

Please sign in to comment.