Navigation

    CreatiCode Scratch Forum

    • Register
    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • CreatiCode

    Say Sentences with an AI Speaker

    2D Blocks
    1
    1
    283
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • info-creaticode
      CreatiCode last edited by admin

       

      Introduction

       

      You can easily make the computer “say” any word or sentence using the “say” block in the AI category! Even better, you can save what the computer says as a sound clip in the Sounds tab. That way, you can replay it whenever you want.

      This feature is super helpful for users who can’t read text on a screen, and it also makes talking with an app feel much more natural — like chatting with a real person!

       
       

      Block Syntax

       

      420131ee-a7cb-46bb-b4cc-a6b23b7f55d8-image.png

       
      Let’s take a closer look at each input in this block:

       
       

      Sentence

       

      You should usually put a full sentence or phrase inside the “say” block—not just individual words. This helps the AI figure out how to say the words naturally. Also, remember: each “say” block causes a small delay.

      Here’s what happens when you use two blocks for “Good” and “morning” separately:

      Your browser does not support the audio element.

       
      On the other hand, this is what you get when you use one block for both words:

      Your browser does not support the audio element.

       
       

      Speaker Language

       
      You can pick which language the AI speaker uses. The most common languages are listed at the top of the list:

      Tip:
      The same language can show up more than once because of different dialects (ways of speaking). For example, “Good afternoon” sounds different between English speakers in the USA and the UK:

      Your browser does not support the audio element.

      vs

      Your browser does not support the audio element.

      Normally, you want to match the sentence and the language.
      But sometimes you might want the same speaker to say things in two languages. Here’s an example where a Chinese AI speaker says both Chinese and English:

      Your browser does not support the audio element.

       
       

      Speaker Type

       
      Within the same language, you can pick what type of AI speaker to use:

      f31fe66b-5cb4-44e1-b909-c2148da675f1-image.png

       
      Important:
      Not every speaker type is available for every language.
      If the one you picked doesn’t work, you’ll see a warning message at the bottom of the code editor:

      a52a0814-ae0a-4944-beac-5312b0e0e187.gif

       
       

      Talking Speed

       
      You can change how fast the AI talks!

      • 100 = Normal speed
      • > 100 = Faster
      • < 100 = Slower

       

      Examples:

      • Normal (100):

      Your browser does not support the audio element.

      • Faster (200):

      Your browser does not support the audio element.

      • Slower (50):

      Your browser does not support the audio element.

       
       

      Pitch

      Pitch controls how high or low the voice sounds.

      • 100 = Normal pitch
      • Higher numbers = Squeakier
      • Lower numbers = Deeper

      Usually, it’s best to leave it at 100 unless you want a funny effect.

       
       

      Volume

      Volume controls how loud the AI speaks.

      • 100 = Normal loudness
      • Higher = Louder (shouting!)
      • Lower = Quieter (whispering)

      You can even change volume inside a sentence by using multiple blocks!

       
       

      Sound Clip Name

       
      If you type a name into the Sound Clip Name input, the sound will get saved into the Sounds tab.

      This is super useful if you want the computer to say the same thing many times. Instead of making the AI generate speech every time (which takes a little time), you can just play the sound clip instantly.

       
       

      Demo

       
      In this example, we make the AI say “How are you?” and store it in a sound clip called “greetings”. After that, we use the start sound block to play it:

      store.gif

      1 Reply Last reply Reply Quote 0
      • First post
        Last post