Speechace
  • Introduction
    • Overview
    • Use-Cases
  • Getting Started
    • Pre-requisites
      • API Features
      • Getting the API Key
      • API Regions and endpoints
      • API Limits
    • API Samples
    • Supported Languages
    • API Versioning
    • Authentication
    • Try the Speechace API
    • Error Handling
      • Common Errors
      • Retry Strategies
  • Solutions
    • Speaking Practice for Language Learning
    • Automated Language Assessment with AI
    • Voice AI for Early Literacy
    • Test Prep for Standardized tests
      • PTE Speaking Questions
      • IELTS Speaking Questions
      • TOEFL Speaking Questions
      • CEFR Speaking Questions
      • TOEIC Speaking Questions
    • Speaking Practice in Spanish and French
  • Features
    • Introduction
    • Scripted activities
      • Pronunciation Scoring
        • Word and Sentence pronunciation
        • Multiple choice
        • Custom pronunciations
        • Phoneme list
      • Fluency scoring
        • Passage scoring
      • Lexical stress and intonation
    • Spontaneous activities
      • Open-ended scoring
        • Language scoring
        • Relevance scoring
        • Language detection
      • Task achievement scoring
        • Describe Image
        • Re-tell Lecture
        • Answer Question
  • API Reference
    • Postman API reference
    • Score Text/Pronunciation
      • Handling overall scores
      • Handling word scores
      • Handling phoneme and syllable scores
    • Score Text/Multiple choice
      • Handling multiple choice response
    • Score Text/Markup Language
      • Handling Markup Response
    • Score Text/Stress & Intonation
      • Handing stress and intonation response
    • Score Text/Phoneme list
      • Handling phoneme list response
    • Score Text/Fluency
      • Handling fluency response
      • Fidelity detection
    • Score Text/Validate Text
    • Score Speech/Open-ended
      • Handling language scores
      • Per metric feedback
        • Grammar metrics
        • Vocabulary metrics
        • Coherence metrics
    • Score Speech/Relevance
      • Handling relevance response
    • Score Speech/Language Detection
    • Score Task/Task Achievement
  • Guides on common topics
    • Intepreting quality score
    • Interpreting overall scores
      • Pronunciation Bands
      • Fluency Bands
      • Vocabulary Bands
      • Grammar Bands
      • Coherence Bands
    • Scoring rubrics
    • Interpreting fidelity class
    • Phonetic notation
      • US English (en-us)
      • UK English (en-gb)
      • French (fr-fr, fr-ca)
      • Spanish (es-es, es-mx)
    • Getting word timestamps in audio
    • Automatic handling of unknown words
    • Phoneme to letter mapping
    • Markup Language
  • Other Resources
    • Requesting Support
    • Rate Limiting
    • Data Retention
    • FAQs
    • Appendices
Powered by GitBook
On this page
  1. API Reference

Score Text/Multiple choice

PreviousHandling phoneme and syllable scoresNextHandling multiple choice response

Last updated 1 month ago

Run in Postman:

In this example, we will match the test-taker's utterance to the closest option provided in the Multiple Choice Question and evaluate the pronunciation of the spoken word or sentence. For instance, if the multiple-choice options are:

  • Apple

  • Banana

  • Orange

The test-taker’s response will be scored based on how closely it matches one of these options, and the pronunciation of the spoken word or sentence will be assessed for accuracy.

The request parameters which you can see in the cURL below are the same as in . Note that the options {Apple, Banana and Orange} are specified in the text field and are separated by newline characters (or \n).

curl --location -g 'https://api.speechace.co/api/scoring/text/v9/json?key={{speechacekey}}&dialect=en-us' \
--form 'text="\"apple
orange
banana\""'
--form 'user_audio_file=@"orang_16k.wav"'

In the above cURL, the audio file is matched to the closest choice, which is "Orange." Therefore, the response evaluates the pronunciation of the word "Orange":

{
  "status": "success",
  "quota_remaining": -1,
  "text_score": {
    "text": "orange",
    "word_score_list": [
      {
        "word": "orange",
        "quality_score": 77,
        "phone_score_list": [
          {
            "phone": "ao",
            "stress_level": 1,
            "extent": [
              79,
              87
            ],
            "quality_score": 99.625,
            "stress_score": 100,
            "sound_most_like": "ao"
          },
          {
            "phone": "r",
            "stress_level": null,
            "extent": [
              87,
              96
            ],
            "quality_score": 96,
            "sound_most_like": "r"
          },
          {
            "phone": "ih",
            "stress_level": 0,
            "extent": [
              96,
              105
            ],
            "quality_score": 60.33333333333334,
            "stress_score": 100,
            "sound_most_like": "ah"
          },
          {
            "phone": "n",
            "stress_level": null,
            "extent": [
              105,
              117
            ],
            "quality_score": 65.08333333333334,
            "sound_most_like": "ng"
          },
          {
            "phone": "jh",
            "stress_level": null,
            "extent": [
              117,
              129
            ],
            "quality_score": 61.5,
            "sound_most_like": "g",
            "child_phones": [
              {
                "extent": [
                  117,
                  126
                ],
                "quality_score": 70.33333333333333,
                "sound_most_like": "k"
              },
              {
                "extent": [
                  126,
                  129
                ],
                "quality_score": 35,
                "sound_most_like": "ng"
              }
            ]
          }
        ],
        "syllable_score_list": [
          {
            "phone_count": 2,
            "stress_level": 1,
            "letters": "or",
            "quality_score": 98,
            "stress_score": 100,
            "extent": [
              79,
              96
            ]
          },
          {
            "phone_count": 3,
            "stress_level": 0,
            "letters": "ange",
            "quality_score": 62,
            "stress_score": 100,
            "extent": [
              96,
              129
            ]
          }
        ]
      }
    ],
    "speechace_score": {
      "pronunciation": 77
    }
  },
  "version": "9.0"
}
Score a Multiple Choice Text
Score Text/Pronunciation