Voice Controlled Discord Music Bot in discord.js v14

Overview

Voice Controlled Discord Bot

This repository is for the 5th Hackathon of Documatic. With that Project I am aiming to place #1 and win 50€

Banner

About

It is a voice controlled Discord Bot, means you (mainly) do not use prefix / Slash Commands, no! You will be using your VOICE.

Ofc. you somehow need to parse that audio, for that I am using https://wit.ai which is a free speech-to-text ai, which you need to train! That means it might sometimes not return what you say... but I tested it over 19 months on another Project, and there it works 100% everytime, even multilangual now..

It is a Music Bot, as other interactions are not that optimal, like kick / ban, you can't control that with voice 100% sure...

Check out the Show-off and Tutorial Video

image

System-Requirements

  • Idle Load: 17mb Ram
  • High Load: 25-30mb Ram
  • Highest Memory Load with HEAPS for 2 Days runtime: 97mb Ram
  • JS-Engine: nodejs v16.10 or later
  • RUST (cmake): latest
  • FFMPEG: npm i ffmpeg-static ffmpeg & apt-get install -y ffmpeg
Recommended-CPU Recommended-RAM
1 CORE 250mb Ram

Example Usage

image

How to use the Bot? | Check the Video

  1. Join the testing Server - Prefix: v! / self-host it!
  2. Join a Discord Voice-Channel, in a Server, where the Bot is in!
  3. Type in a Text-Channel v!control or @Bot control a. Now it'll only listen and be controlable by YOU
  4. Speak your COMMANDS and add a KEYWORD in beforehand. a. Examples: i. bot play shape of you ii. bot play thunder iii. bot play despacito iv. bot nightcore =Audio-Filter v. bot skip vi. bot stop
  5. Tipps to get understood more often! a. Make sure to talk in a normal speed and loudness, do not scream or errape b. Also Make sure to Reduce background noices, speak clear and fluently to be "recogniced" by the bot pretty well!

Self-Hosting

  1. Download the repo | Click-here
    • or: git clone https://github.com/Tomato6966/voice-controlled-discord-bot
  2. Rename example.env to .env and fill out the variables (get wit.ai Server Access Token from wit.ai)
  3. yarn install / npm install (make sure you have rust & nodejs on your system)
  4. Type node index.js / npm start

Want to add more music commands?

Take a look at my Light-Music-Bot Project, which is similar to this one (for the music system) https://github.com/Tomato6966/light-music-bot

Resources used (modules & credits)

  • node-fetch@2 for api Calls
  • discord.js@latest as my Discord-Bot-Wrapper
  • @discordjs/voice, @discordjs/opus, discord-ytdl-core, ytdl-core, youtube-sr, ffmpeg, libsodium-wrappers for the Music System (Its similar to my light-music-bot)
  • ffmpeg, prism-media, node-crc for parsing / Piping / Transforming Audio Streams, -Buffers and -Files.
  • dotenv for allowing to use .env ENVIRONMENT Variables

Explanation and show off Video

VoiceBot.mp4

ToDo

  • (28/07/2022 20:17) Change Message Responses from the voice-command, to VOICE-RESPONSES (Bot speaks it)
    • Announce Songs: "Now playing XYZ"
    • also for Skip: "Skipping the current Track"
  • (27/07/2022 18:23) Make the structure better, and fix all bugs
  • (27/07/2022 18:23) Add all to a .env file, and create an example.env file
  • (27/07/2022 18:23) Adjust the Settings
  • (27/07/2022 18:23) Make it multi langual without any modules
  • (27/07/2022 18:23) Try to make it even faster ;)
You might also like...

A mobile app for playing music on Resonate, an open source music streaming co-op.

stream2own Play fair. Website | Twitter | Contributing | Developer Guide 🎵 Resonate Stream App A mobile app for playing music on Resonate, an open so

Dec 28, 2022

A decentralized Music Ownership System developed on Truffle Suite and React Bootstrap to allow Music artists to upload their content to the blockchain, that can be streamed by users

A decentralized Music Ownership System developed on Truffle Suite and React Bootstrap to allow Music artists to upload their content to the blockchain, that can be streamed by users

A decentralized Music Ownership System developed on Truffle Suite and React Bootstrap to allow Music artists to upload their content to the blockchain, that can be streamed by users.

Sep 5, 2022

A quick-start template for Discord.js v14 in TypeScript that contains handling for commands, events, and interactions!

Typescript-Discord.js-v14-Template A quick-start template for Discord.js v14 in Typescript that contains handling for commands, events, and interactio

Dec 28, 2022

This is a template for a ticket system using Discord.js v14.

This is a template for a ticket system using Discord.js v14.

Ticket System Template (Discord.js v14) This is a template for a ticket system using Discord.js v14. Contact Features Ticket - Transcripts, 2 Step Tic

Dec 21, 2022

Discord.js V14 Slash-Command and Context-Menu Handler. Most efficient and advanced Handler out there!

Base discord.js v14 Command Handler Written by Tomato6966 Made for Deezcord Features ✔ Slash Commands ✔ Sub-Slash Commands ✔ Group-Sub-Slash Commands

Dec 21, 2022

Alisa botunun altyapı dosyaları (discord.js v14.6.0 ile uyumlu)

Botu başlatmadan önce ./ayarlar.json dosyasına gidip doldurulması gereken alanları lütfen doldurunuz yoksa bot çalışmaz! Botun kodlarında herhangi bir

Dec 15, 2022

Discord-Bot - You can use the discord bot codes that are updated in every video of the codes I use in the discord bot making series that I have published on my youtube channel.

Discord-Bot You can use the discord bot codes that are updated in every video of the codes I use in the discord bot making series that I have publishe

Jan 3, 2023

Link your position on a mcbe server to a discord voice. The sound changes according to the distance to the nearest players.

DiscordLink Link your position on a mcbe server to a discord voice. The sound changes according to the distance to the nearest players. Credits - No I

May 28, 2022

⚡ Discord bot with economy, gambling, music, fun, moderation features based on discord.js v12

⚡ Discord bot with economy, gambling, music, fun, moderation features based on discord.js v12

Crucian Crucian is my discord bot with simple structure based on discord.js Click Here to invite Crucian to your server Author Crucian © Apoo Authored

Jul 26, 2021
Comments
  • Little Confused

    Little Confused

    So I followed the steps below self-hosting and all that works. But when I do v!control and then bot comes in and tells you to say bot play shape of you I do and it records my voice in console but throws out an error I'm not sure how to solve

    Here is the error: image

    opened by iGetUploaded 4
Owner
Tomato6966
I am Tomato, around about 18, and a very good Discord Bot Developer, Dm me on Discord: Tomato#6966, to get one yourself!
Tomato6966
Advanced Music Bot It is an advance type of discord music bot which plays high quality of music with spotify

Advanced Music Bot It is an advance type of discord music bot which plays high quality of music with spotify, apple music support . You can save your songs and play it. It also has DJ mode system.

Diwas Atreya 65 Dec 25, 2022
About Discord bot draft that does not contain ready-made commands, compatible with discord.js v14. Create your own discord bot with this command handler.

discordJS-V14 About Discord bot draft that does not contain ready-made commands, compatible with discord.js v14. Create your own discord bot with this

Umut Bayraktar 36 Dec 28, 2022
discord.js v14 müzik botu && Emirhan Saraç discord bot altyapı 2022

Discord.js v14 Müzik Botu ?? Özellikler Müzik Müzik Filtreleri MessageButton Kolay Kullanım ?? Desteklenen Servisler Youtube SoundCloud Spotify ?? Des

codemirhan 18 Dec 20, 2022
Um bot discord usando Discord.js v14 (slash commands)

ANTES DE TUDO LEMBRE-SE: COPIAR CÓDIGOS NÃO É PROGRAMAR! USE APENAS PARA FINS EDUCATIVOS E QUE APRENDA COM ESSE REPOSITÓRIO!!! Descrição Fiz esse repo

Yurii 8 Dec 20, 2022
I’m a very useful music bot that can make you play a music with a simple command! I have a lot of good commands that you can have a better experience playing your favorites songs!

I’m a very useful music bot that can make you play a music with a simple command! I have a lot of good commands that you can have a better experience playing your favorites songs!

Hugo Kishi 2 Aug 16, 2022
A multipurpose bot, a clan bot, a all in one bot. The one bot u need for ur server originally made as Milrato discord Bot and by Tomato6966.

Public Bot and Support Server! Invite the Public Version of this Bot so you don't need to host it by yourself or join my Discord server to get a custo

Tomato6966 472 Dec 25, 2022
An simple package to create an Activity in Discord Voice Channel using Discord.js

discordjs-activity An simple package to create an Activity in Discord Voice Channel using Discord.js ?? | Installation npm install discordjs-activity

Sudhan 55 Nov 15, 2022
🤖 NODE.TS - Play a welcome sound every time someone joins the voice channel, meme bot. (Olha ele ae)

welcome2voice-bot ?? NODE.TS - Play a welcome sound every time someone joins the voice channel. ?? INVITE-ME ?? Installation Clone project git clone g

Bruno Silva 5 Feb 23, 2022
Telegram voice recognition bot

Node.js bot for telegram messenger based on Microsoft Azure Speech Service and Node.js Telegram Bot API

Dmitry 4 Mar 9, 2022
Music-Player - Music player application built with HTML, CSS and vanilla JavaScript

Music-Player Music player application built with HTML, CSS and vanilla JavaScrip

Karthik Umashankar 1 Feb 10, 2022