明国三年一场雨

明国三年一场雨

热爱技术分享
telegram
email

Telegram integrates ChatGPT-4, Telegram is Open AI artificial intelligence, building artificial intelligence chatbots based on ChatGPT and Telegram, experiencing the powerful features of ChatGPT, currently the best solution Telegram integrates ChatGPT-4, Telegram is Open AI artificial intelligence, building artificial intelligence chatbots based on ChatGPT and Telegram, experiencing the powerful features of ChatGPT, currently the best solution

Installation Preparation: a VPS, Telegram API, OpenAI API key

Open Source Project Address: https://github.com/karfly/chatgpt_telegram_bot

  1. SSH Connection Tool Fianlshell Download Link: https://www.hostbuf.com/t/988.html

  2. Obtain Telegram API and OpenAI API key

Details at api.telegram.org

  1. Download and Install the Open Source Project
    __
    Install git
apt install git

Clone the open source project

git clone https://github.com/karfly/chatgpt_telegram_bot.git

Navigate to the file directory

cd /root/chatgpt_telegram_bot

Change file names

mv config/config.example.yml config/config.yml
mv config/config.example.env config/config.env

Double-click to open the config.yml file, and add the Telegram API and OpenAI API keys prepared earlier

  1. Install Docker and Docker Compose

Install Docker

apt update
apt install curl
curl -fsSL get.docker.com -o get-docker.sh
sh get-docker.sh

Docker management

systemctl start docker # Start container
systemctl enable docker # Start on boot
systemctl status docker # Check status
docker --version # Check Docker version

Install Docker Compose

apt-get install docker-compose

Restart the server

reboot

Navigate to the file directory again

cd /root/chatgpt_telegram_bot

Execute the installation

docker-compose --env-file config/config.env up --build
  1. Bot Usage Commands

/retry– Retry generating the last bot response
/new– Start a new conversation
/mode– Choose chat mode
/balance– Display balance
/help– Display help

Loading...
Ownership of this post data is guaranteed by blockchain and smart contracts to the creator alone.