Build an advanced Text-to-Voice AI converter yourself in just 3 minutes

Share it with your senior IT friends and colleagues
Reading Time: 3 minutes

Hello and welcome to Build AI tool yourself

In this article, we will learn how to build an AI-based advanced text-to-voice converter yourself.

It can not only just translate text into voice but also add emotions to the voice. The following textures can be added to the voice

  • Laughter
  • Sigh
  • Gasp
  • Clearing throat
  • hesitation
  • and others

This is what we will be doing.



मानवता की पहचान गुणों से होती है.. ना कि ऊंचे सिंहासन पर बैठने से…

महल के उच्च शिखर पर बैठने के बावजूद… कौवे का गरुड़ होना असंभव है।



AI based advanced text to voice converter tool

We will be using the Bark model from the GitHub repository –

And we will be using the Google Colab notebook for the quick demo –

You do not need to install anything for running the above notebook. So, follow the instructions and it will be done.

Let’s begin!

Access the code notebook from here –

To use it, download and then upload it to your Google Drive and open it as a Google Colab file.

Step 1 – Open the Google Colab notebook

You do not need to install anything for running the above notebook. So, just follow the instructions and it will be done.

Step 2 – Run the first cell to install the AI model – Bark

Bark is the model that converts Text to Voice of our choice.

Once it is done, it will show that the model is successfully installed

Step 3 – Import the necessary libraries

Step 4 – Give your text and convert it into voice

You could add your text as well or try running other cells to check the output.

Bark AI model

Bark supports 100 voiceovers in 13 Languages – English, German, Spanish, French, Hindi, Italian, Japanese, Korean, Polish, Portuguese, Turkish, Russian and Chinese

Let’s play around a little

Choosing another Voice Over artist

Here is the Bark Speaker Library –

Have changed the VO from speaker_1 to speaker_8

Choosing another Language

We can also change the language and Bark automatically detects the language

Let’s change it to Hindi. We also need to change the speaker else the Voice would be in Hindi but wth different accent.

Adding Emotions to the Voice

Bark supports the following elements

  • [laughter]
  • [laughs]
  • [sighs]
  • [music]
  • [gasps]
  • [clears throat]
  •  or ... for hesitations
  •  for song lyrics
  • CAPITALIZATION for emphasis of a word
  • [MAN] and [WOMAN] to bias Bark toward male and female speakers, respectively

Let’s add [clears throat] to our previous text and see how does it work

Play more with this Text to Audio AI tool.

  • Add your text
  • Select another speaker
  • Or select another language

This was very simple. Right?  In case of any difficulty, write to me – nt(at)aimletc(dot)com

Thanks for choosing to read it completely. I can try to simplify any AI concept for you.

In case you want me to simplify any AI topic, please let me know on LinkedIn –

Here is how I learned AI as a non-technical person in 4 months for free.

Let’s learn to build a basic AI/ML model in 4 minutes (Part 1)

Share it with your senior IT friends and colleagues
Nikhilesh Tayal
Nikhilesh Tayal
Articles: 51