RocketChat / hubot-natural

Natural Language Processing Chatbot for RocketChat
https://open.rocket.chat/channel/hubot-natural
MIT License
145 stars 44 forks source link

Refactoring bot index #31

Closed MatheusFaria closed 6 years ago

MatheusFaria commented 6 years ago

In this PR the bot/index file was refactored. The behaviors related to machine learning were extracted to the bot/brain file. The behaviors related to actions (respond, error, configure) were extracted to the bot/action_handler file.

Besides these changes, the code style was fixed following the coffeelint standard style sheet.

Since we changed a lot of code from one file to others, we didn't change the methods' logic, to facilitate the reviewing process. Others architectural changes where thought and could be discussed for future changes, they are:

diegodorgam commented 6 years ago

Awesome contribution! I'll merge it now. thks @MatheusFaria