<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>bot | rael.io</title><link>https://rael.io/tags/bot/</link><atom:link href="https://rael.io/tags/bot/index.xml" rel="self" type="application/rss+xml"/><description>bot</description><generator>Source Themes Academic (https://sourcethemes.com/academic/)</generator><language>en-us</language><copyright>Fork me on [GitHub](https://github.com/raelga/rael.io)</copyright><lastBuildDate>Sun, 09 Jul 2017 11:23:56 +0200</lastBuildDate><image><url>https://rael.io/img/photos/emma-hello-card.jpg</url><title>bot</title><link>https://rael.io/tags/bot/</link></image><item><title>tgfwdbot</title><link>https://rael.io/project/tgfwdbot/</link><pubDate>Sun, 09 Jul 2017 11:23:56 +0200</pubDate><guid>https://rael.io/project/tgfwdbot/</guid><description>
&lt;p&gt;&lt;a href=&#34;https://travis-ci.org/raelga/tgfwdbot&#34; target=&#34;_blank&#34;&gt;&lt;img src=&#34;https://travis-ci.org/raelga/tgfwdbot.svg?branch=master&#34; alt=&#34;Build Status&#34; /&gt;&lt;/a&gt;
&lt;a href=&#34;https://goreportcard.com/report/github.com/raelga/tgfwdbot&#34; target=&#34;_blank&#34;&gt;&lt;img src=&#34;https://goreportcard.com/badge/github.com/raelga/tgfwdbot&#34; alt=&#34;Go Report&#34; /&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Bot to forward messages between supergroups and private chats, to allow talking in Telegram supergroups when banned.&lt;/p&gt;
&lt;h2 id=&#34;why&#34;&gt;Why&lt;/h2&gt;
&lt;p&gt;Sometimes, due to trolls reporters, users can be banned from any Telegram supergroup, not only the one where reported.
With this bot, users will be able to participate in specific groups through the bot.&lt;/p&gt;
&lt;p&gt;This bot can be added to the group, identified by &lt;code&gt;TELEGRAM_GROUP_ID&lt;/code&gt;, and will:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Forward any message from the Group to the private conversation with the banned user&lt;/li&gt;
&lt;li&gt;Forward any message from the private conversation with the banned user to the Group&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;The admins of the groups where the bot is a member will decide if the allows the banned users to participate or not.&lt;/p&gt;
&lt;h2 id=&#34;disclaimer&#34;&gt;Disclaimer&lt;/h2&gt;
&lt;p&gt;&lt;strong&gt;This bot is not intended to be a tool for spammers and malicious users to bypass Telegram bans.&lt;/strong&gt;
The purpose is to allow users to interact in the groups with the authorization of the group admins when globally banned from supergroups due to troll reportings.&lt;/p&gt;
&lt;h2 id=&#34;notes&#34;&gt;Notes&lt;/h2&gt;
&lt;p&gt;Gopher art from &lt;a href=&#34;https://github.com/ashleymcnamara/gophers&#34; target=&#34;_blank&#34;&gt;ashleymcnamara/gophers&lt;/a&gt;.&lt;/p&gt;</description></item><item><title>PyBot</title><link>https://rael.io/project/pybot/</link><pubDate>Thu, 02 Mar 2017 11:23:56 +0200</pubDate><guid>https://rael.io/project/pybot/</guid><description>
&lt;p&gt;&lt;a href=&#34;https://circleci.com/gh/raelga/pybot/tree/master&#34; target=&#34;_blank&#34;&gt;&lt;img src=&#34;https://circleci.com/gh/raelga/pybot/tree/master.svg?style=svg&#34; alt=&#34;CircleCI&#34; /&gt;&lt;/a&gt;&lt;/p&gt;
&lt;h1 id=&#34;pybot&#34;&gt;pybot&lt;/h1&gt;
&lt;p&gt;Wrapper for &lt;a href=&#34;https://github.com/python-telegram-bot/python-telegram-bot&#34; target=&#34;_blank&#34;&gt;python-telegram-bot&lt;/a&gt; to allow dynamic plug-in architecture, an attempt to make python-telegram-bot more hubottish.&lt;/p&gt;
&lt;h3 id=&#34;execution-flow&#34;&gt;Execution flow&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;&lt;p&gt;&lt;code&gt;bin/pybot&lt;/code&gt; starts the bot with the selected adapter and using the configuration options defined in &lt;code&gt;conf/pybot.conf&lt;/code&gt; or the command-line arguments.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;The selected adapter receives the message and sends it to the &lt;code&gt;brain.py&lt;/code&gt;.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;The &lt;code&gt;brain.py&lt;/code&gt; loads in runtime all the &lt;code&gt;.py&lt;/code&gt; files in the &lt;code&gt;./memory&lt;/code&gt; folder each time and try to execute a defined method, for example &lt;code&gt;hear(message.text)&lt;/code&gt;.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Each module in &lt;code&gt;./memory&lt;/code&gt; with that method returns a response, the &lt;code&gt;brain.py&lt;/code&gt; sends it to the &lt;code&gt;pybot.py&lt;/code&gt; and it sends the response back to the chat.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;
&lt;ul&gt;
&lt;li&gt;As the methods are dynamically loaded, you can edit and add the files in &lt;code&gt;./memory&lt;/code&gt; without need to restart &lt;code&gt;pybot.py&lt;/code&gt;, and they will be reloaded on the next message. Overkill but funny.&lt;/li&gt;
&lt;/ul&gt;
&lt;h3 id=&#34;makefile-targets&#34;&gt;Makefile targets&lt;/h3&gt;
&lt;pre&gt;&lt;code class=&#34;language-Makefile&#34;&gt;usage: Show this help
setup-venv: Setup virtualenv
lint: Run code linter to check code style
telegram: Run pybot with the telegram adapter
docker-build: Build the docker image for running pybot
docker-telegram: Run with telegram adapter in the docker container
docker-lint: Run pep8 in the docker container
docker-clean: Remove the docker image
&lt;/code&gt;&lt;/pre&gt;
&lt;h3 id=&#34;execution-example&#34;&gt;Execution example&lt;/h3&gt;
&lt;pre&gt;&lt;code class=&#34;language-bash&#34;&gt;make docker-telegram
&lt;/code&gt;&lt;/pre&gt;
&lt;pre&gt;&lt;code&gt;docker run -it --rm --name pybot -v /Users/rael/Code/python/pybot:/usr/src/pybot -w /usr/src/pybot &#39;pybot&#39; bin/pybot telegram
Starting pybot using conf token file. CTRL-C to quit.
2017-04-17 07:35:54,392 - pybot.interfaces.telegram - INFO - Bot raelbot up and ready!
2017-04-17 07:36:39,371 - pybot.brain - INFO - 116133952, Hello world!, 53693428, 2017-04-17 07:36:39,&amp;quot;53693428&amp;quot;;
&lt;/code&gt;&lt;/pre&gt;
&lt;h3 id=&#34;contributing&#34;&gt;Contributing&lt;/h3&gt;
&lt;p&gt;Contributions of all sizes are welcome.&lt;/p&gt;
&lt;h3 id=&#34;attributions&#34;&gt;Attributions&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;Header image from &lt;a href=&#34;https://python-telegram-bot.org&#34; target=&#34;_blank&#34;&gt;python-telegram-bot.org&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;h3 id=&#34;license&#34;&gt;License&lt;/h3&gt;
&lt;p&gt;You may copy, distribute and modify the software provided that modifications are described and licensed for free under &lt;code&gt;GNU General Public License v3.0&lt;/code&gt;. Derivatives works (including modifications or anything statically linked to the library) can only be redistributed under LGPL-3, but applications that use the library don&amp;rsquo;t have to be.&lt;/p&gt;</description></item><item><title>Hubot Raelbot</title><link>https://rael.io/project/hubot-raelbot/</link><pubDate>Sun, 16 Aug 2015 11:23:56 +0200</pubDate><guid>https://rael.io/project/hubot-raelbot/</guid><description>
&lt;p&gt;&lt;strong&gt;raelbot&lt;/strong&gt; is a chat bot built on the Hubot framework.&lt;/p&gt;
&lt;h3 id=&#34;running-raelbot-locally&#34;&gt;Running raelbot Locally&lt;/h3&gt;
&lt;p&gt;You can test your hubot by running the following, however some plugins will not
behave as expected unless the &lt;a href=&#34;#configuration&#34;&gt;environment variables&lt;/a&gt; they rely
upon have been set.&lt;/p&gt;
&lt;p&gt;You can start raelbot locally by running:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;% bin/hubot
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;You&amp;rsquo;ll see some start up output and a prompt:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;[Sat Feb 28 2015 12:38:27 GMT+0000 (GMT)] INFO Using default redis on localhost:6379
raelbot&amp;gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Then you can interact with raelbot by typing &lt;code&gt;raelbot help&lt;/code&gt;.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;raelbot&amp;gt; raelbot help
raelbot help - Displays all of the help commands that raelbot knows about.
...
&lt;/code&gt;&lt;/pre&gt;
&lt;h2 id=&#34;persistence&#34;&gt;Persistence&lt;/h2&gt;
&lt;p&gt;If you are going to use the &lt;code&gt;hubot-redis-brain&lt;/code&gt; package (strongly suggested),
you will need to add the Redis to Go addon on Heroku which requires a verified
account or you can create an account at &lt;a href=&#34;https://redistogo.com/&#34; target=&#34;_blank&#34;&gt;Redis to Go&lt;/a&gt; and manually
set the &lt;code&gt;REDISTOGO_URL&lt;/code&gt; variable.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;% heroku config:add REDISTOGO_URL=&amp;quot;...&amp;quot;
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;If you don&amp;rsquo;t need any persistence feel free to remove the &lt;code&gt;hubot-redis-brain&lt;/code&gt;
from &lt;code&gt;external-scripts.json&lt;/code&gt; and you don&amp;rsquo;t need to worry about redis at all.&lt;/p&gt;
&lt;h2 id=&#34;adapters&#34;&gt;Adapters&lt;/h2&gt;
&lt;p&gt;Adapters are the interface to the service you want your hubot to run on, such
as Campfire or IRC. There are a number of third party adapters that the
community have contributed. Check &lt;a href=&#34;https://github.com/github/hubot/blob/master/docs/adapters.md&#34; target=&#34;_blank&#34;&gt;Hubot Adapters&lt;/a&gt; for the
available ones.&lt;/p&gt;
&lt;p&gt;If you would like to run a non-Campfire or shell adapter you will need to add
the adapter package as a dependency to the &lt;code&gt;package.json&lt;/code&gt; file in the
&lt;code&gt;dependencies&lt;/code&gt; section.&lt;/p&gt;
&lt;p&gt;Once you&amp;rsquo;ve added the dependency with &lt;code&gt;npm install --save&lt;/code&gt; to install it you
can then run hubot with the adapter.&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;% bin/hubot -a &amp;lt;adapter&amp;gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Where &lt;code&gt;&amp;lt;adapter&amp;gt;&lt;/code&gt; is the name of your adapter without the &lt;code&gt;hubot-&lt;/code&gt; prefix.&lt;/p&gt;
&lt;h3 id=&#34;deploying-to-unix-or-windows&#34;&gt;Deploying to UNIX or Windows&lt;/h3&gt;
&lt;p&gt;If you would like to deploy to either a UNIX operating system or Windows.
Please check out the &lt;a href=&#34;https://github.com/github/hubot/blob/master/docs/deploying/unix.md&#34; target=&#34;_blank&#34;&gt;deploying hubot onto UNIX&lt;/a&gt; and &lt;a href=&#34;https://github.com/github/hubot/blob/master/docs/deploying/unix.md&#34; target=&#34;_blank&#34;&gt;deploying
hubot onto Windows&lt;/a&gt; wiki pages.&lt;/p&gt;</description></item></channel></rss>