https://github.com/megane42/twitch_translation_bot
A twitch bot who can translate twitch chat.
https://github.com/megane42/twitch_translation_bot
bot translation twitch
Last synced: 7 days ago
JSON representation
A twitch bot who can translate twitch chat.
- Host: GitHub
- URL: https://github.com/megane42/twitch_translation_bot
- Owner: megane42
- License: mit
- Created: 2020-11-07T13:16:05.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2020-12-13T10:55:14.000Z (over 5 years ago)
- Last Synced: 2025-05-28T20:06:12.386Z (about 1 year ago)
- Topics: bot, translation, twitch
- Language: Ruby
- Homepage:
- Size: 17.6 KB
- Stars: 1
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
# Twitch Translation Bot

## Features
- Realtime Twitch chat translation from...
- any language to `TARGET_LANGUAGE`
- but `TARGET_LANGUAGE` to `FALLBACK_LANGUAGE`
## Requirements
- Twitch account for bot
- OAuth token of above bot account
- Sign in to twitch as bot account
- Access https://twitchapps.com/tmi/
- Connect
- API key for Google Cloud Translation API
- See https://translatepress.com/docs/automatic-translation/generate-google-api-key/
## Usage
- Run following ruby script
```ruby
require "bundler/inline"
gemfile do
source "https://rubygems.org"
gem "twitch_translation_bot", git: "https://github.com/megane42/twitch_translation_bot"
end
require "twitch_translation_bot"
ENV["CHANNEL_NAME"] = "megane42" # Chatroom name (= twitch user name) where you want to translate
ENV["BOT_NAME"] = "megane42bot" # Bot account name
ENV["BOT_ACCESS_TOKEN"] = "oauth:*******" # Oauth token of bot account
ENV["TARGET_LANGUAGE"] = "ja" # ISO 639-1 codes
ENV["FALLBACK_LANGUAGE"] = "es" # ISO 639-1 codes
ENV["TRANSLATE_KEY"] = "*************" # API key for google cloud translation API
TwitchTranslationBot::Bot.new.run
```
## License
- [MIT](https://opensource.org/licenses/MIT)