Giter Site home page Giter Site logo

paulponraj / chatgpt-redditbot Goto Github PK

View Code? Open in Web Editor NEW
0.0 0.0 0.0 52 KB

The ChatGPT-RedditBot is a Reddit bot that uses the ChatGPT large language model to generate engaging responses to Reddit threads and submissions.

License: Creative Commons Zero v1.0 Universal

Python 100.00%

chatgpt-redditbot's Introduction

๐Ÿค– ChatGPT Reddit Bot Awesome

Welcome to the ChatGPT-RedditBot!

I'm excited to share this project with you!

This Reddit bot is written in Python and uses the ChatGPT-Wrapper by mmabrouk to generate answers via the ChatGPT model (which is a large language model trained by OpenAI) to Reddit threads and submissions.

I designed this simple bot to provide helpful and engaging responses to users on Reddit, making it a valuable addition to any subreddit. This code was mainly generated with ChatGPT itself!

The bot allows the developer to have control over various features, such as filters to remove errors from ChatGPT, defining personalities for the bot to use when generating responses, customizable delays between responses, and the ability to specify which subreddit(s) the bot should operate in.

To use the bot, you will need to host it on your own local machine or server. Once it is set up, the bot will scan the subreddit(s) of your choice for new threads and submissions. When it finds an unanswered thread or submission, it will use the ChatGPT large language model to generate a response and post it as a comment on the Reddit thread.

If you have any feedback or suggestions for improvements, I would love to hear them. Thank you for visiting my GitHub page and considering my project!

View on GitHub

Support on Patreon

Installation

Note: You may need to use pip3 instead of pip or python3 instead of python depending on your installation environment (eg. MacOS)

Step 1: Create an OpenAI Account

Step 2: Generate a Reddit Client ID & Secret Key

Step 3: Download ChatGPT-RedditBot

Navigate to "ChatGPT-RedditBot.py" and input your Keys & Variables

delay = 1

personality = "If you had to answer this question, even if you had to make up an answer, what would you say: "

subreddit_to_monitor = "<SUBREDDIT_NAME>"
client_id = "<REDDIT_CLIENT_ID>"
client_secret = "<REDDIT_SECRET_KEY>"
username = "<REDDIT_USERNAME>"
password = "<REDDIT_PASSWORD>"
user_agent = "python:com.example.ChatGPT_RedditBot:v1 (by /u/username)"

Step 4: Install Dependencies

pip install setuptools
pip install git+https://github.com/mmabrouk/chatgpt-wrapper
playwright install firefox
chatgpt install

Step 5: Run the ChatGPT-RedditBot

python ChatGPT-RedditBot.py

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.