Giter Site home page Giter Site logo

vocabacov's Introduction

Vocabacov

Telegram bot to enlarge your vocabulary.

Environment variables

Name Mandatory Default value Description
VOCABACOV_TOKEN yes Telegram bot token.
VOCABACOV_CHANNELS yes Comma delimited ids of telegram bot channels.
VOCABACOV_DEBUG no false Debug logging enabled/disabled.
VOCABACOV_TIMEOUT no 30 Request timeout to wait for an update.

Run

To run bot with telegram token YOUR_TELEGRAM_BOT_TOKEN, channel 36484 and mapping volume database file /db/vocabacov.db to you host's current directory:

touch $(pwd)/vocabacov.db

docker run -d \
--name vocabacov \
-e VOCABACOV_TOKEN=YOUR_TELEGRAM_BOT_TOKEN \
-e VOCABACOV_CHANNELS=36484 \
-v $(pwd)/vocabacov.db:/db/vocabacov.db \
ghcr.io/karlovskiy/vocabacov:latest

Telegram bot

To create telegram bot follow this guide.

Commands

Vocabacov bot accepts commands in the format

/lang
phrase
translation

where lang is ISO-3166 Alpha-2 code, phrase is one or more words and translation is a translation (could be also definition or description).

Examples:

/en 
hello world
say hi to the world

This bot saves submitted words in the sqlite3 database, and you can use sqlite3 to query phrases table.

$ sqlite3
SQLite version 3.38.2 2022-03-26 13:51:10
Enter ".help" for usage hints.
Connected to a transient in-memory database.
Use ".open FILENAME" to reopen on a persistent database.
sqlite> .open vocabacov.db
sqlite> select * from phrases;

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.