Skip to content
This repository was archived by the owner on Mar 30, 2023. It is now read-only.

Commit b95b9ae

Browse files
committed
Added analyzer for username, cashtag and mention
1 parent 27d5c9d commit b95b9ae

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

twint/__version__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
VERSION = (2, 1, 4)
1+
VERSION = (2, 1, 5)
22

33
__version__ = '.'.join(map(str, VERSION))

twint/storage/elasticsearch.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -65,9 +65,9 @@ def createIndex(config, instance, **scope):
6565
"location": {"type": "keyword"},
6666
"tweet": {"type": "text"},
6767
"hashtags": {"type": "keyword", "normalizer": "hashtag_normalizer"},
68-
"cashtags": {"type": "keyword"},
68+
"cashtags": {"type": "keyword", "normalizer": "hashtag_normalizer"},
6969
"user_id_str": {"type": "keyword"},
70-
"username": {"type": "keyword"},
70+
"username": {"type": "keyword", "normalizer": "hashtag_normalizer"},
7171
"name": {"type": "text"},
7272
"profile_image_url": {"type": "text"},
7373
"day": {"type": "integer"},
@@ -86,7 +86,7 @@ def createIndex(config, instance, **scope):
8686
"geo_tweet": {"type": "geo_point"},
8787
"photos": {"type": "text"},
8888
"user_rt_id": {"type": "keyword"},
89-
"mentions": {"type": "keyword"},
89+
"mentions": {"type": "keyword", "normalizer": "hashtag_normalizer"},
9090
"source": {"type": "keyword"},
9191
"user_rt": {"type": "keyword"},
9292
"retweet_id": {"type": "keyword"},

0 commit comments

Comments
 (0)