https://github.com/drsmile444/tensorflow-ml-bot-example
🤖 Telegram Bot example using Machine Learning and Tensorflow
https://github.com/drsmile444/tensorflow-ml-bot-example
example telegram telegram-bot tensorflow tutorial
Last synced: 11 months ago
JSON representation
🤖 Telegram Bot example using Machine Learning and Tensorflow
- Host: GitHub
- URL: https://github.com/drsmile444/tensorflow-ml-bot-example
- Owner: DrSmile444
- Created: 2022-08-27T07:47:52.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2023-02-04T11:17:22.000Z (almost 3 years ago)
- Last Synced: 2025-01-12T13:27:25.727Z (about 1 year ago)
- Topics: example, telegram, telegram-bot, tensorflow, tutorial
- Language: TypeScript
- Homepage:
- Size: 550 KB
- Stars: 1
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Tensorflow Machine Learning Telegram Bot Example
## Description
This repo contains an example of using tensorflow model
together with Telegram Bots to analyze messages from users.
## Requirements
You need to have [node.js v16+](https://nodejs.org/en/) installed.
[Here is the instruction how to install it.](https://www.pluralsight.com/guides/getting-started-with-nodejs)
Here is the way you can check your node version by using any shell:
```shell
> node -v
v16.13.0
```
## Install
1. Clone the repository:
```shell
git clone git@github.com:DrSmile444/tensorflow-ml-bot-example.git
```
2. Install `node_modules` modules:
```shell
npm install
```
3. [Get bot token from bot father.](https://sendpulse.com/knowledge-base/chatbot/telegram/create-telegram-chatbot)
4. Create a copy of `.env.example` and name it `.env`.
5. Insert bot token into `BOT_TOKEN` in `.env`.
## Run the bot
To run the bot, you need to execute the following command:
```shell
npm start
```
## Branches
This project contains several branches with different stages of the bot:
1. [main](https://github.com/DrSmile444/tensorflow-ml-bot-example/tree/main) - basic bot setup without tensorflow logic
1. [feature/tensorflow](https://github.com/DrSmile444/tensorflow-ml-bot-example/tree/feature/tensorflow) - complete bot setup with tensorflow
## Technical stack
1. [Node.js v16](https://nodejs.org/en/) - is a JavaScript runtime built on Chrome's V8 JavaScript engine.
2. [TypeScript](https://www.typescriptlang.org/) - is a strongly typed programming language that builds on JavaScript, giving you better tooling at any scale.
3. [Grammy](https://grammy.dev/) - makes creating Telegram bots so simple you already know how to do it.
4. [ESLint](https://eslint.org/) - statically analyzes your code to quickly find problems. It is built into most text editors and you can run ESLint as part of your continuous integration pipeline.
5. [Prettier](https://prettier.io/) - is an opinionated code formatter. It enforces a consistent style by parsing your code and re-printing it with its own rules that take the maximum line length into account, wrapping code when necessary.
## Code editors
Here you can find a suggested code editors list
### WebStorm (recommended)
[WebStorm](https://www.jetbrains.com/webstorm/) has [built-in ESLint plugin support](https://www.jetbrains.com/help/webstorm/eslint.html), so you need only enable it.
The course lectors will use this IDE.
### Visual Studio Code
VS Code includes built-in JavaScript IntelliSense, debugging, formatting, code navigation, refactorings, and many other advanced language features.
To enable ESLint, you need to install ESLint plugin.
This repo contains VS Code suggested plugins, so you can install them in several clicks.