Giter VIP home page Giter VIP logo

little-t's Introduction

Overview ๐Ÿ“‹

Little_t is designed to copy a user's writing style by collecting a user's previous tweets and then responding to the requested user a sentence similar to that of the target. This process is explained below.

  • Unfortunately with recent Twitter Premium API Deprecation changes made in April of 2023 this project no longer has a sustainable way to be continued due to the 100$ fee to continue to utlize the Account Activity API which this project relied upon. Perhaps this change will be reverted in the future or another alternative solution can be found, but until then this is the last version of the project.

๐Ÿฃ Check out his old tweets: https://twitter.com/little_t_bot ๐Ÿฃ

How It Works โ”

1. Webook Subscription to Twitter's Web API via AWS Lambda Deploy of a HTTP Flask API.

  • Setup callback and webhook urls for Twitter to send real time tweet activity
  • Subscribe to Little_t_bot's account to get real time POST request information from Twitter (Tweets, Direct Messages, Mentions, Likes, etc...)
  • Parse payload information to know when a user requests for little_t to copy someone.

2. Call to Twitter's Web API with a given twitter handle (@username) to collect the following peices of information:

  • Twitter ID
  • Current User Name
  • User's Previous Timeline Tweets (up to 3200 recent tweets excluding retweets and comments)

2. Use a MongoDB Cluster to organize the the searched data into two collections:

  • One Collection called UserAccounts to store the user's Twitter ID, username, and a UTC timestamp of when that user was last requested.
  • The other Collection called TweetDumps to dump the Twitter ID of the poster, Tweet ID, and text content of the post. There is a single call to the timeline endpoint to check to see if any new tweets of the Twitter ID have been posted to avoid making upwards of 3200 redundant endpoint calls.

3. Parse and clean tweets to make a sensible and usable Text Corpus

  • lowercase all text
  • remove punctiation
  • remove non-words (\n, \t, emjoi's...etc)
  • tokenization of text

4. Plug the newly made Text Corpus into a Markov Chains algorithm to generate a NLP Model for generating new sentences.

little-t's People

Contributors

mccune1224 avatar

Watchers

 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.