Git Product home page Git Product logo

keywordsentimentserverless's Introduction

KeywordSentimentServerless

An AWS Lambda application that scrapes social media websites for keywords, performs sentiment analysis using Amazon Comprehend on the text containing the keywords, and uploads the data to Amazon Elasticsearch Service.

Definitions

Campaign: A collection of campaign name, keywords, subreddits to search, and social media websites to search.

Architecture

Lambda Functions:

  • processCampaignTableStream: triggers scrapeReddit
  • processPostsTableStream: parses the Posts table stream, analyzing posts
  • scrapeReddit: queries reddit using PRAW, then filters posts by Campaign parameters
  • searchElastic: given a query, searches Elasticsearch

DynamoDB Tables:

  • Campaigns
  • Posts

Elasticsearch indices:

  • posts

A DynamoDB Stream is enabled on the Campaigns and Posts tables. Posting to those tables triggers the AWS Lambda functions processCampaignTableStream and processPostsTableStream, respectively. processCampaignTableStream triggers Lambda function scrapeReddit which sends posts matching parameters specified by the Campaign to the Posts table. Then those posts are streamed to processPostsTableStream where they are analyzed by Amazon Comprehend and indexed into Amazon Elasticsearch.

Future Possibilities

Now that the posts are indexed into Elasticsearch, Temporal tracking of negative posts and data analysis & visualization of posts are useful applications for 1) brands interested in sentiment surrounding their products and services and 2) studies relating to the sentiment around controversial topics. Tracking a post's setiment through time can be implemented by adding a "retrieved on" attribute to the post data and by creating a CloudWatch rule that periodically queries and analyzes each post's text (i.e. comments, retweets) in the Elasticsearch index.

Furthermore, Twitter search can be integrated into the application.

keywordsentimentserverless's People

Contributors

felixglush avatar

Stargazers

 avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.