Skip to main content

aitelegrambot is a Telegram bot that uses the Ollama backend to run the LLM rationalAI (by default).

Project description

Introduction

aitelegrambot is a Telegram bot that uses the Ollama backend to run the LLM rationalAI(by default). This bot is designed to provide access to the full capabilities of Ollama through Telegram, allowing users to interact with LLMs in a convenient and interactive manner.

Running the bot.

Setting up Ollama

To run this bot you need to get setup Ollama seperately, please find the tutorial at Ollama's github repository.

Getting a Telegram bot token

To obtain a Telegram bot token, you can request it from BotFather, the official bot management bot.

Setup the bot.

  1. Make sure your python is up-to date
  2. Install pipx

    For Debian and it's derivatives

    apt install pipx
    

    For ArchLinux and it's derivatives

    pacman -S python-pipx
    

    For Gentoo

    sudo emerge --sync
    sudo emerge --ask --update --deep --newuse @world
    sudo emerge --ask dev-python/pip
    sudo pip install pipx
    
    And finally, do to make sure its packages are on the path run,
    pipx ensurepath
    
  3. Open your terminal, and install aitelegrambot by running
    pipx install aitelegrambot
    
  4. make a .env file With the following contents:
TELEGRAM_BOT_TOKEN=tokenhere
DEFAULT_MODEL=defaultmodelhere
OLLAMA_HOST=ollamahosthere

You may omit DEFAULT_MODEL and OLLAMA_HOST, if you are going to use the default settings (OLLAMA_HOST being localhost:11434 and DEFAULT_MODEL being tusharhero/rationalai).

  1. Run the bot.
aitelegrambot

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

aitelegrambot-0.2.0.tar.gz (18.1 kB view details)

Uploaded Source

Built Distribution

aitelegrambot-0.2.0-py2.py3-none-any.whl (17.7 kB view details)

Uploaded Python 2 Python 3

File details

Details for the file aitelegrambot-0.2.0.tar.gz.

File metadata

  • Download URL: aitelegrambot-0.2.0.tar.gz
  • Upload date:
  • Size: 18.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.10.7

File hashes

Hashes for aitelegrambot-0.2.0.tar.gz
Algorithm Hash digest
SHA256 3e1bb823f375a5a789fe580e964f6b2b2a97066d2ae2ad6ee8567b903c72ec89
MD5 6f3f0e2f85cf7f6f2af6c1dd81f907be
BLAKE2b-256 f06e91606ddcb7bb1cc904bea35d799f71832a54a6c1af3eb8e8df1e649a32eb

See more details on using hashes here.

File details

Details for the file aitelegrambot-0.2.0-py2.py3-none-any.whl.

File metadata

File hashes

Hashes for aitelegrambot-0.2.0-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 1898eb5a9adb41e6dc4cc9bbf767adbdb021c2e5d13752fb3369f6c187617ccb
MD5 b91d06c8e9569b4089e1bd76887f8efd
BLAKE2b-256 8a45765be09ee9adc3c4d9e0177a93d129690a3b650085cdf6f8dbf203f23bb1

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page