mirror of
https://github.com/explosion/spaCy.git
synced 2024-12-26 18:06:29 +03:00
Updated spaCy universe for spacytextblob (#10335)
* Updated spacytextblob in universe.json * Fixed json * Update website/meta/universe.json Co-authored-by: Sofie Van Landeghem <svlandeg@users.noreply.github.com> * Added spacy_version tag to spacytextblob Co-authored-by: Sofie Van Landeghem <svlandeg@users.noreply.github.com>
This commit is contained in:
parent
b16da378bb
commit
5f568f7e41
|
@ -227,11 +227,11 @@
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"id": "spacy-textblob",
|
"id": "spacy-textblob",
|
||||||
"title": "spaCyTextBlob",
|
"title": "spacytextblob",
|
||||||
"slogan": "Easy sentiment analysis for spaCy using TextBlob. Now supports spaCy 3.0!",
|
"slogan": "A TextBlob sentiment analysis pipeline component for spaCy.",
|
||||||
"thumb": "https://github.com/SamEdwardes/spaCyTextBlob/raw/main/website/static/img/logo-thumb-square-250x250.png",
|
"thumb": "https://github.com/SamEdwardes/spacytextblob/raw/main/docs/static/img/logo-thumb-square-250x250.png",
|
||||||
"description": "spaCyTextBlob is a pipeline component that enables sentiment analysis using the [TextBlob](https://github.com/sloria/TextBlob) library. It will add the additional extensions `._.polarity`, `._.subjectivity`, and `._.assessments` to `Doc`, `Span`, and `Token` objects. For spaCy 2 please use `pip install pip install spacytextblob==0.1.7`",
|
"description": "spacytextblob is a pipeline component that enables sentiment analysis using the [TextBlob](https://github.com/sloria/TextBlob) library. It will add the additional extension `._.blob` to `Doc`, `Span`, and `Token` objects.",
|
||||||
"github": "SamEdwardes/spaCyTextBlob",
|
"github": "SamEdwardes/spacytextblob",
|
||||||
"pip": "spacytextblob",
|
"pip": "spacytextblob",
|
||||||
"code_example": [
|
"code_example": [
|
||||||
"import spacy",
|
"import spacy",
|
||||||
|
@ -241,9 +241,10 @@
|
||||||
"nlp.add_pipe('spacytextblob')",
|
"nlp.add_pipe('spacytextblob')",
|
||||||
"text = 'I had a really horrible day. It was the worst day ever! But every now and then I have a really good day that makes me happy.'",
|
"text = 'I had a really horrible day. It was the worst day ever! But every now and then I have a really good day that makes me happy.'",
|
||||||
"doc = nlp(text)",
|
"doc = nlp(text)",
|
||||||
"doc._.polarity # Polarity: -0.125",
|
"doc._.blob.polarity # Polarity: -0.125",
|
||||||
"doc._.subjectivity # Sujectivity: 0.9",
|
"doc._.blob.subjectivity # Subjectivity: 0.9",
|
||||||
"doc._.assessments # Assessments: [(['really', 'horrible'], -1.0, 1.0, None), (['worst', '!'], -1.0, 1.0, None), (['really', 'good'], 0.7, 0.6000000000000001, None), (['happy'], 0.8, 1.0, None)]"
|
"doc._.blob.sentiment_assessments.assessments # Assessments: [(['really', 'horrible'], -1.0, 1.0, None), (['worst', '!'], -1.0, 1.0, None), (['really', 'good'], 0.7, 0.6000000000000001, None), (['happy'], 0.8, 1.0, None)]",
|
||||||
|
"doc._.blob.ngrams() # [WordList(['I', 'had', 'a']), WordList(['had', 'a', 'really']), WordList(['a', 'really', 'horrible']), WordList(['really', 'horrible', 'day']), WordList(['horrible', 'day', 'It']), WordList(['day', 'It', 'was']), WordList(['It', 'was', 'the']), WordList(['was', 'the', 'worst']), WordList(['the', 'worst', 'day']), WordList(['worst', 'day', 'ever']), WordList(['day', 'ever', 'But']), WordList(['ever', 'But', 'every']), WordList(['But', 'every', 'now']), WordList(['every', 'now', 'and']), WordList(['now', 'and', 'then']), WordList(['and', 'then', 'I']), WordList(['then', 'I', 'have']), WordList(['I', 'have', 'a']), WordList(['have', 'a', 'really']), WordList(['a', 'really', 'good']), WordList(['really', 'good', 'day']), WordList(['good', 'day', 'that']), WordList(['day', 'that', 'makes']), WordList(['that', 'makes', 'me']), WordList(['makes', 'me', 'happy'])]"
|
||||||
],
|
],
|
||||||
"code_language": "python",
|
"code_language": "python",
|
||||||
"url": "https://spacytextblob.netlify.app/",
|
"url": "https://spacytextblob.netlify.app/",
|
||||||
|
@ -254,7 +255,8 @@
|
||||||
"website": "https://samedwardes.com"
|
"website": "https://samedwardes.com"
|
||||||
},
|
},
|
||||||
"category": ["pipeline"],
|
"category": ["pipeline"],
|
||||||
"tags": ["sentiment", "textblob"]
|
"tags": ["sentiment", "textblob"],
|
||||||
|
"spacy_version": 3
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"id": "spacy-ray",
|
"id": "spacy-ray",
|
||||||
|
|
Loading…
Reference in New Issue
Block a user