Skip to content

A MarkerDAO Telegram Bot can reply to members of community with chatGPT API

Notifications You must be signed in to change notification settings

PublicAI01/markerdao-telegram-bot

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Telegram Bot

This telegram bot can reply message in telegram group when being @your_bot_name

Installation

pip3 install -r requirements.txt -i https://mirrors.aliyun.com/pypi/simple/

Usage

  • register a telegram bot using @BotFather and get the bot TOKEN, register a OpenAI API account and get the API key, then set the TOKEN and key in config.env

  • Please set telegram bot TOKEN, OpenAI API key and your telegram bot name in config.env in config dir before run the command as follows:

chmod +x ./bot.py && ./bot.py

OR

make run
  • Your bot on the server needs to be outside of GFW or enable proxy to access telegram bot API and OpenAI API

WATCHOUT: disable the privacy mode of your telegram bot and give a admin of group before join the group, if it does not work well, you need to remove the bot from your group and rejoin the group again.

  • You can set daily question limit per user in bot.env

Helpful reference

About

A MarkerDAO Telegram Bot can reply to members of community with chatGPT API

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published