Giter Site home page Giter Site logo

pkarpovich / helpdesk-guru Goto Github PK

View Code? Open in Web Editor NEW
0.0 3.0 1.0 751 KB

An intelligent Telegram bot powered by Golang, designed to help answer user queries by interacting with a Python-based GPT service. The bot utilizes information from parsed user documents to provide accurate responses

License: MIT License

Go 19.80% Python 67.64% Dockerfile 11.24% Makefile 1.32%
gpt-4 openai parse-documents telegram-bot

helpdesk-guru's Introduction

Helpdesk Guru

Helpdesk-Guru is an intelligent Telegram bot powered by Golang, designed to help answer user queries by interacting with a Python-based GPT service. The bot utilizes information from parsed user documents to provide accurate responses, and includes user query rate-limiting and conversation reset features for enhanced usability. Docker Compose is used for effortless setup and deployment.

Features

  • Responds to user messages with generated text from GPT.
  • Rate limit for user queries to prevent spamming.
  • Clear command to erase previous queries and responses.

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes.

Prerequisites

  • Docker & Docker Compose
  • A Telegram Bot Token (you can obtain this by creating a bot on Telegram)
  • OpenAI API Key

Environment Variable

The project uses the following environment variables:

  • TELEGRAM_BOT_TOKEN - Your telegram bot token.
  • OPENAI_API_KEY - Your OpenAI API key.
  • OPENAI_MODEL - The model to use with OpenAI.
  • PERSIST_DIRECTORY - The directory for persisting data.

Create a .env file in the project root directory and add your environment variables:

TELEGRAM_BOT_TOKEN=YOUR_TELEGRAM_BOT_TOKEN
OPENAI_API_KEY=YOUR_OPENAI_API_KEY
OPENAI_MODEL=YOUR_OPENAI_MODEL
PERSIST_DIRECTORY=YOUR_PERSIST_DIRECTORY

Running the Bot and GPT Service with Docker Compose

You can run the entire system using Docker Compose:

docker-compose up --build

This will build the Docker images if they do not exist and start the services, namely, the telegram bot and the GPT service.

Usage

Once started, you can interact with the bot on Telegram. You can use the following commands:

  • /start: The bot will respond with a welcome message.
  • /clear: The bot will clear its memory of previous queries and responses.
  • For any other text, the bot will interact with the GPT service to generate a meaningful response.

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

License

This project is licensed under the MIT License - see the LICENSE file for details.

helpdesk-guru's People

Contributors

pkarpovich avatar

Watchers

 avatar  avatar  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.