telegram-voice-chatgpt-bot
Voice ChatGPT telegram bot
About: 1
Telegram bot for voice communication with ChatGPT. The user sends a voice or text message to the bot and receives a text or voice message in response from ChatGPT. It is written in JavaScript and uses NodeJS.
Features: 2
- The ability to choose a service for converting voice to text: using
OpenAI API
orYandexSpeechKit API
- Converting
.mp3 to text
: usingOpenAI API
. - Converting
.ogg to text
: usingYandexSpeechKit API
- Converting
.ogg to .mp3
: usingfluent-ffmpeg
. - The user can choose how best to get an answer: by
text
, byvoice
, or all together. - To convert text to voice message: using
YandexSpeechKit API
orGoogle
- ChatGPT remembers the context
- Whitelist of users who have access to the bot.
- Collecting simple statistics that includes the total number of requests, the number of voice requests, the number of text requests, the total number of words in all requests.
- The ability for users to see their statistics.
- Voice messages and text history chat are not saved on the server if the corresponding option is enabled
- The database is not used, all statistics and data are stored in
.json
format.
:warning: If the bot work with a large audience, it is better to use a database.
Installation: 3
$ git clone https://github.com/Hashmann/telegram-voice-chatgpt-bot.git
$ cd server
- Edit
.env.production
.env.development
and set your telegram bot token and OpenAI key. - Edit
whitelist.user.json
and add the usernames to the whitelist.
$ npm install
:warning: Do not delete directories:
audio
andlog
Usage: 4
Development
$ npm run start:dev
Production
$ npm run start
Dependencies: 5
Development
- Nodemon ^2.0.20
Production
- Dotenv (npm) ^16.0.3
Developer:
License:
Footnotes
Описание
Telegram bot for voice communication with ChatGPT.
Языки
JavaScript