Build Bots That Talk Like Humans – Speech Synthesis UBot Studio

Today we’re diving into the new speech synthesis commands in UBot Studio Enterprise Edition.

We have integrated Eleven Labs, which is, at the time of writing, generally considered to be the highest quality speech synthesis ever created. Let’s find out if it lives up to the hype!

To start, I used some random inspirational text generated by chat GPT. After hitting ‘generate’, the synthesized speech was impressively human-like. If I didn’t know better, it would be pretty hard to differentiate it from a real human voice.

Now, let’s get into the nitty-gritty of how to use this feature in UBot Studio.

After opening UBot Studio and navigating to the public bot bank, select ‘speech synthesis’. Start with the ‘connect to speech synthesis’ command and enter your API key (you can find this on the 11 Labs website under your profile).

Once connected, we can start playing around with the various commands.

The ‘start playing speech’ command allows you to input text and listen to the synthesized speech. To ensure the script doesn’t continue playing while speaking, don’t forget to include the ‘wait for speech’ command.

You may notice a slight lag between hitting run and the start of the speech. However, the second time you hit run, the speech begins instantly. This is because the system generates the audio and saves it to the hard drive. If you play the same bit of speech again, it simply plays the already saved file.

If you want to regenerate the audio file each time, you can set the ‘refresh’ parameter to true. This means each time you run the command, the speech will sound slightly different as it generates a new file.

If you want to generate the files without playing them immediately, use the ‘generate speech’ command. This is particularly useful if you have a large amount of text to generate and want to play it in real time later.

You can also save the audio to a file using the ‘save to speech file’ command. Lastly, the ‘voice’ parameter allows you to select from a dropdown of default 11 Labs voices or manually enter the name of any voice set up in your account.

The new generation of speech synthesis in UBot Studio Enterprise Edition is a significant leap forward. It offers computer voices that sound strikingly like real people. So go ahead, explore and enjoy this new feature.

See you next time!

Here’s the code:

connect to speech synthesis("your eleven labs key")
start playing speech("Imagine a world where you\'re not bound by the limitations of time and manual labor. A world where you can automate repetitive tasks, freeing up your time to focus on what truly matters. That\'s the world Ubot Studio opens up for you. It\'s a world where efficiency meets creativity, where technology serves humanity, and where the only limit is your imagination.","Rachel","False")
wait for speech

Building An AI Bot That Can Write and Draw Comics

Let the language of wit become universal, for laughter transcends borders

Get UBot Studio Enterprise Here!

Hey there, botmasters! Today, we’re once again pushing the envelope of what’s possible with cutting edge generative AI. In particular, we’ll be creating a bot that generates single panel comics using ChatGPT and Stable Diffusion! So, let’s embark on yet another artistic adventure, and bring laughter and joy to our followers as we explore the vast potential of AI-generated humor.

First things first, let’s use ui console view to open our console to log the comic creations of our AI.

We will also connect to dreambooth using our API key.

Now, let’s set up some crucial paths for our images. We’ll set the #image path and the #comic path for where they’ll be generated.

We’re also going to set a #context to help our AI understand its role as a comic creator.

Time to create the chat GPT agent! We’ll name it “ComicGPT” and feed it the #context we’ve set:

Now, we can ask ComicGPT to provide us with a hilarious scene description! We’ll take its response and set it as the #scene variable:

And we’ll log the scene to the console using the log command:

Next, we’ll request the caption for the comic and set it as the #caption variable:

Don’t forget to log the caption, so we can see what our AI has in store for us:

Here comes the fun part – generating the image! We’ll use the generate dreambooth image command, passing in our #image path and #scene:

Then we can take a look at the generated image with log image command:

Now, we need to create some space for the caption by using pad image on our initial image:

Again, we’ll use log image to see the modified image.

Alright, it’s time to fit our funny text onto the image! We’ll do this using the fit text to image command:

And, of course, we’ll use log image to admire our AI’s masterpiece.

And there you have it, intrepid Bot masters! Our UBot Studio script is now fully equipped to generate ingenious comics. With each delightful comic, we not only showcase the astounding capabilities of artificial intelligence but also bring smiles to countless faces. So, let’s celebrate our accomplishment and revel in the boundless possibilities of AI-driven creativity. Here’s to transforming the world, one laughter-filled comic at a time!

Get UBot Studio Enterprise Here!
ui console view
config openai("YOUR_API_KEY")
connect to dreambooth("YOUR_API_KEY")
set(#image path,"C:\\Documents\\UBot Studio\\Workspace\\image.png","Local")
set(#comic path,"C:\\Documents\\UBot Studio\\Workspace\\comic.png","Local")
set(#context,"you are comicGPT, an ai that conceptualizes and writes single-panel comics. given a topic, you\'ll first describe the scene that\'s happening in the comic, and then provide a caption. Your description will be given to an image generator like dall-e, so make the scene description as visually simple as possible. I want to emphasize again that the scene should be simple. the most important thing is that the comic is funny, insightful, profound, or otherwise emotionally evocative.","Local")
create chat gpt agent("ComicGPT",#context,"gpt-4")
set(#scene,$chat gpt response("Give me just the scene description for a single-panel comic. Make it really funny.","ComicGPT"),"Local")
log(#scene)
set(#caption,$chat gpt response("Give me just the caption for the comic. Make it really funny.","ComicGPT"),"Local")
log(#caption)
generate dreambooth image(#image path,#scene,"Stable Diffusion XL Beta v2.2.2",512,384)
log image(#image path,50)
pad image(#image path,#comic path,0,0,100,0,"white")
log image(#comic path,50)
fit text to image(#image path,#caption,#comic path,"top",90,392,20,20,20,"Comic Neue","black","False","black",50,"True")
log image(#comic path,50)

Use Your Installed Chrome in UBot Studio Version 6.7.17

We are thrilled to announce that UBot Studio’s new version is now available, and it comes with a major update – we have switched to using your installed version of Chrome, instead of the internal UBot Studio browser.

So, what does this mean for you? Let’s dive into the details!

Benefits of Using Installed Chrome

The Installed Chrome browser option is now functional, and there are numerous benefits to using it:

  • Always use the latest version of Chrome
  • Compatible with the latest web standards
  • You can now log into your Google account, including GMail and YouTube (this was previously blocked with the internal browser)
  • Cookies and Cache persist between sessions
  • You can use the extensions!
  • You can use web3 websites!

Log Images in the Console View

In addition to the Chrome update, we have also added a new feature – log images. You can now add images into the console view, making it easier to track and review your bot’s progress when working with images.

How to Get It

If you have UBot Studio already installed, and you’re subscribed to updates or to Enterprise Edition, simply update when prompted the next time you open UBot Studio.

If you’re not subscribed to either our Update Subscription or Enterprise Edition, subscribe to Enterprise edition here:

How to Switch to the Installed Chrome Browser

Switching to the Installed Chrome browser is easy:

  1. From the main screen in UBot Studio, click the Tools menu, and select Options.
  2. Under General Options, click the drop-down labeled “Browser.”
  3. Select “Installed Chrome.”
  4. Click OK.
  5. Restart UBot Studio.

Conclusion

We are excited to bring you this major update, and we hope it will make your bot-building experience even better. If you have any questions or feedback, please don’t hesitate to contact us. Happy botting!

UBot Studio Unleashes AI Power for Irresistible YouTube Titles and Descriptions!

Unite your passion with AI technology, and together you will weave a tapestry of captivating content, touching the hearts of your audience and igniting a spark that transcends the boundaries of human creativity.

AI is improving at a pace that leaves my head spinning, and bots are getting smarter and smarter. Today, we’re going to harness the power of cutting edge AI technology and teach a bot how to manage your YouTube channel. This tutorial will guide you through the process of connecting to YouTube, and using the impressive capabilities of ChatGPT, the latest in AI driven language models, to generate captivating titles and descriptions for your videos. By integrating these advanced features into your YouTube strategy, you’ll save considerable time and effort while elevating your content and enhancing audience engagement. Alright, let’s get into it.

First, let’s start by setting up the ui console view . This command creates a simple console interface for our script. To do this, find the ui console view command in the toolbox and drag it into the script window.

Next, we need to configure the OpenAI api with the config openai command.

After that, we need to establish a connection to YouTube.

As a parameter, provide the path to your “client secrets” file. This file comes from the Google Developer Console. I’ll explain how to do all this in another tutorial.

Now, let’s retrieve your YouTube videos. Drag the set command into the script window and create a list called %videos.

Use the $get my videos function to fetch the videos and store them in the list.

The fun part begins! We’ll loop through the top 10 videos and generate new clickbait titles and descriptions for them. To do this, drag the loop command from the toolbox and set its parameter to 10.

Inside the loop, we’ll first get the video ID of the current video and set it to a variable.

Create a variable called #current video id and use the $next list item function to fetch the next video ID from the list %videos .

Now, we’ll create a ChatGPT agent to help us generate new titles and descriptions. Drag the create chat gpt agent command into the script window and provide three parameters: the agent’s default name “ChatGPT” is fine, we’ll set its purpose, and the GPT model will be “gpt-4”.

Next, we need to fetch the transcript of the current video. Use the set command to create a variable called #transcript and the $get youtube transcript function to obtain the transcript for the video ID.

Time to generate a clickbait title! Use the set command again to create a variable called #new title. Then, call the $chat gpt response function and provide the transcript as part of the input.

Now, let’s change the YouTube video title to the newly generated one. Drag the change youtube video title command and provide two parameters: #current video id and #new title.

To keep track of the changes, we’ll use the log command with a message that includes both the video ID and the new title.

Similarly, we’ll generate a new description for the video using the set command to create a variable called #new description.

Call the $chat gpt response function again and this time we’ll ask it to create a description from the transcript.

Now, it’s time to update the YouTube video description. Drag the change youtube video description command into the script window and provide two parameters: #current video id and #new description .

Once again, use the log command to keep track of the changes, but this time include the new description in the message.

And there you have it! With these steps, your YouTube videos will now feature compelling titles and descriptions, meticulously crafted by advanced AI, that captivate your audience and elevate your content’s appeal. Embrace the power of smart botting to unlock your channel’s potential and enjoy the benefits of this cutting-edge technology. 

Here’s the code! Remember to change the path to the client_secret.json file after downloading it from the Google Developer Console. Also replace the openai api key.

ui console view
config openai("YOUR_API_KEY")
connect to youtube("C:\secrets\client_secret.json")
set list(%videos,$get my videos(),"Local")
loop(10) {
    set(#current video id,$next list item(%videos),"Local")
    create chat gpt agent("ChatGPT","Your purpose is to look at a youtube transcript and generate either a video title or description based on the transcript.","gpt-4")
    set(#transcript,$get youtube transcript(#current video id),"Local")
    set(#new title,$chat gpt response("based on the following transcript, what would be the perfect clickbait title of this video? keep it short, less than 100 characters. here's the transcript:     {#transcript}","ChatGPT"),"Local")
    change youtube video title(#current video id, #new title)
    log("title for video    {#current video id}   changed to    {#new title} ")
    set(#new description,$chat gpt response("based on the following transcript, what would be the perfect description of this video?     {#transcript} ","ChatGPT"),"Local")
    change youtube video description(#current video id, #new description)
    log("title for video    {#current video id}   changed to    {#new title} ")
}

AI-Powered Fully Automated Blogging in UBot Studio

Look, I have to be honest. This stuff is just getting crazy. With this new AI tech that’s out there, one person can do the work of 10. UBot Studio harnesses all that power, and today I’m gonna show you an example. We’re going to build a bot that writes 10 high quality blogs, and posts them to our blog.

We’ll start out by dragging the ui console view command. This command will change the UBot browser into a console interface, where we can see the output of our bot’s actions.

Next, we’ll drag the config openai command. This will allow us to interact with the advanced artificial intelligence systems from openai. We’ll need to provide our Private Key, which we can get from OpenAI.

Now, we’ll use the connect to wordpress command to connect to our WordPress site. We’ll need to provide our WordPress site URL, username, and Application password.

Now let’s generate some article titles. We’ll drag the set list command, and name it %titles. For the value, we’re going to define a function.

So let’s drag over our define command. we’ll set the name to “get article titles” and we’ll set it to be a function. In our function, we’ll set a variable named #prompt. For the value, we’ll enter “List 10 article titles about UBot Studio

Next, we’ll set the #response variable. For the value, we’ll use the $gpt response function. This function will call the AI engine generate a response.

The response is in the form of a long string, so we need to convert it into a list of titles. To do that, we’ll drag the set list command and set the name to %titles. For the value, we’ll use the $list from text function.

And finally, we’ll drag the return command to output our %titles list, and then we should be good to use our shiny new function.

Alright, back to our main script. Now we can drag our function and set our variable.

With our list, we can use the with each command to iterate through. We’ll use the #title variable to store the current title. For each title, we’ll use the set command to set a variable. We’ll name it #article, and for the value, we’ll need to define another function.

Once again, we’ll drag over a define command. We’ll name it “generate article” and make it a Function. This function is going to have one parameter called #title.

This will be a simple function. Let’s drag over a set command to set the #prompt variable. This variable will store the text of the article prompt. For the value, we’ll use the string “Write an article that has the following title: ” and pass in our #title variable.

Next, we’ll drag over the set command again, and set the #article variable. For the value, we’ll drag over the $gpt response function. This function will generate an article based on our title.

Let’s finish our function with a return command, and set it to the #article variable.

Now we can drag over our $generate article function. We’ll pass in #title as our prompt.

Finally, we can use our title and article to create a post on our blog. We’ll set it to private, so that we can edit it before going live.

And while we’re at it, let’s log our title and article to the console.

Let’s give this a run and see what it looks like. Hey, not bad at all. Note that the point of this isn’t just to fill up the internet with a bunch of low quality articles. The point is to save you time. If I were to really use these, I would go in and edit each article by hand, making sure it says what I want it to. But that’s a lot faster than writing all of these from scratch. Using a tool like this could literally save hours out of your day, giving you more time to do other stuff, which ultimately translates to a business advantage, and a more satisfying life in general. So go have some fun with this, and rocket your business into the new generation of AI assisted growth and success!

ui console view
config openai("YOUR API KEY")
connect to wordpress("YOUR WEBSITE URL","YOUR USERNAME","YOUR APPLICATION PASSWORD")
set list(%titles,$get article titles(),"Local")
with each(%titles,#title) {
    set(#article,$generate article(#title),"Local")
    create wordpress post(#title,#article,"draft","post",#post id)
    log(#article)
}
define $get article titles {
    set(#prompt,"List 10 article titles about UBot Studio in JSON format","Local")
    set(#response,$gpt response(#prompt,""),"Local")
    set list(%titles,$list from text(#response,$new line),"Local")
    return(%titles)
}
define $generate article(#title) {
    set(#prompt,"Write an article that has the following title: {#title}","Local")
    set(#article,$gpt response(#prompt,""),"Local")
    return(#article)
}