您现在访问的是微软AZURE全球版技术文档网站,若需要访问由世纪互联运营的MICROSOFT AZURE中国区技术文档网站,请访问 https://docs.azure.cn.

免费试用语音服务Try Speech Services for free

以简单、经济的方式开始使用语音服务。Getting started with the Speech Services is easy and affordable. 可利用 30 天免费试用了解此服务的功能并确定它能否满足应用程序需求。A 30-day free trial lets you discover what the service can do and decide whether it's right for your application's needs.

如果需要更长时间,请注册 Microsoft Azure 帐户,其中附带 200 美元的服务额度,可用于支付长达 30 天的付费语音服务订阅。If you need more time, sign up for a Microsoft Azure account—it comes with $200 in service credit that you can apply toward a paid Speech Services subscription for up to 30 days.

最后,语音服务提供适合用于开发应用程序的免费、低容量层。Finally, the Speech Services offers a free, low-volume tier that's suitable for developing applications. 服务额度到期后,仍可以保留此免费订阅。You can keep this free subscription even after your service credit expires.

免费试用Free trial

利用 30 天免费试用版,可在有限时间内访问标准定价层。The 30-day free trial gives you access to the standard pricing tier for a limited time.

若要注册 30 天免费试用版,请执行下列步骤:To sign up for a 30-day free trial:

  1. 转到试用认知服务Go to Try Cognitive Services.

  2. 选择“语音 API”选项卡。Select the Speech APIs tab.

    “语音服务”选项卡

  3. 在“语音服务”下,选择“获取 API 密钥”按钮。Under Speech Services, select the Get API Key button.

    API 密钥

  4. 同意条款,然后从下拉菜单选择区域设置。Agree to the terms and select your locale from the drop-down menu.

    同意条款

  5. 使用 Microsoft、Facebook、LinkedIn 或 GitHub 帐户登录。Sign in by using your Microsoft, Facebook, LinkedIn, or GitHub account.

    可以在 Microsoft 帐户门户中注册免费的 Microsoft 帐户。You can sign up for a free Microsoft account at the Microsoft account portal. 若要开始,请单击“Microsoft 登录”,然后,当系统要求登录时,请单击“创建帐户”。To get started, click Sign in with Microsoft and then, when asked to sign in, click Create one. 按步骤创建并验证新的 Microsoft 帐户。Follow the steps to create and verify your new Microsoft account.

登录到“试用认知服务”后,免费试用开始。After you sign in to Try Cognitive Services, your free trial begins. 显示的网页中将列出你当前具有其试用订阅的所有 Azure 认知服务服务。The displayed webpage lists all the Azure Cognitive Services services for which you currently have trial subscriptions. “语音服务”旁将列出两个订阅密钥。Two subscription keys are listed beside Speech Services. 可以在应用程序中使用任一密钥。You can use either key in your applications.

备注

所有免费试用订阅均位于美国西部区域。All free trial subscriptions are in the West US region. 发出请求时,请确保使用 westus 终结点。When you make requests, be sure to use the westus endpoint.

新 Azure 帐户New Azure account

新 Azure 帐户将收到使用时间长达 30 天的 200 美元服务额度。New Azure accounts receive a $200 service credit that is available for up to 30 days. 可使用此额度深入探索语音服务或者开始应用程序开发。You can use this credit to further explore the Speech Services or to begin application development.

若要注册新的 Azure 帐户,请转到 Azure 注册页,单击“免费开始”,然后使用 Microsoft 帐户创建新的 Azure 帐户。To sign up for a new Azure account, go to the Azure sign-up page, click Start Free, and create a new Azure account using your Microsoft account.

可以在 Microsoft 帐户门户中注册免费的 Microsoft 帐户。You can sign up for a free Microsoft account at the Microsoft account portal. 若要开始,请单击“Microsoft 登录”,然后,当系统要求登录时,请单击“创建帐户”。To get started, click Sign in with Microsoft and then, when asked to sign in, click Create one. 按步骤创建并验证新的 Microsoft 帐户。Follow the steps to create and verify your new Microsoft account.

创建 Azure 帐户后,请按照下一部分的步骤开始订阅语音服务。After creating your Azure account, follow the steps in the next section to start a subscription to the Speech Services.

在 Azure 中创建语音资源Create a Speech resource in Azure

若要将语音服务资源(免费层或付费层)添加到 Azure 帐户,请执行以下操作:To add a Speech Services resource (free or paid tier) to your Azure account:

  1. 使用 Microsoft 帐户登录 Azure 门户Sign in to the Azure portal using your Microsoft account.

  2. 选择门户左上角的“创建资源”。Select Create a resource at the top left of the portal.

    创建资源

  3. 在“新建”窗口中,搜索“语音”。In the New window, search for speech.

  4. 在搜索结果中,选择“语音”。In the search results, select Speech.

    选择语音

  5. 在“语音”下,选择“创建”按钮。Under Speech, select the Create button.

    选择“创建”按钮

  6. 在“创建”下输入:Under Create, enter:

    • 新资源的名称。A name for the new resource. 名称有助于区分同一服务的多个订阅。The name helps you distinguish among multiple subscriptions to the same service.

    • 选择新资源关联的 Azure 订阅,以确定计费方式。Choose the Azure subscription that the new resource is associated with to determine how the fees are billed.

    • 选择将使用资源的区域。Choose the region where the resource will be used. 目前在东亚、欧洲北部和美国西部区域提供语音服务。Currently, the Speech Services is available in East Asia, North Europe, and West US regions.

    • 选择免费或付费定价层。Choose either a free or paid pricing tier. 单击“查看全部定价详细信息”,获取每个层的定价和用量配额的完整信息。Click View full pricing details for complete information about pricing and usage quotas for each tier.

    • 为此“语音”订阅创建新的资源组或将订阅分配到现有资源组。Create a new resource group for this Speech subscription or assign the subscription to an existing resource group. 资源组有助于使多种 Azure 订阅保持有序状态。Resource groups help you keep your various Azure subscriptions organized.

    • 为了以后可便捷访问订阅,请选中“固定到仪表板”复选框。For convenient access to your subscription in the future, select the Pin to dashboard check box.

    • 选择“创建”。Select Create.

      选择“创建”按钮

      创建和部署新语音资源需要一些时间。It takes a moment to create and deploy your new Speech resource. 选择“快速入门”,查看新资源的信息。Select Quickstart to see information about your new resource.

      “快速启动”面板

  7. 在“快速入门”下,单击步骤 1 中的“密钥”链接,以显示订阅密钥。Under Quickstart, click the Keys link under step 1 to display your subscription keys. 每个订阅有两个密钥;可在应用程序中使用任意一个密钥。Each subscription has two keys; you can use either key in your application. 选择每个密钥旁的按钮,可将其复制到剪贴板以粘贴到代码中。Select the button next to each key to copy it to the clipboard for pasting into your code.

备注

可在一个或多个区域中创建数量不受限的标准层订阅。You can create an unlimited number of standard-tier subscriptions in one or multiple regions. 但是,只能创建一个免费层订阅。However, you can create only one free-tier subscription. 在免费层上进行的模型部署如果连续 7 天处于未使用状态,则会被系统自动停用。Model deployments on the free tier that remain unused for 7 days will be decomissioned automatically.

切换到新订阅Switch to a new subscription

若要从一个订阅切换到另一个订阅(例如,在免费试用过期或发布应用程序的情况下进行切换),请将代码中的区域和订阅密钥替换为新 Azure 资源的区域和订阅密钥。To switch from one subscription to another, for example when your free trial expires or when you publish your application, replace the region and subscription key in your code with the region and subscription key of the new Azure resource.

备注

免费试用密钥在美国西部 (westus) 区域创建。Free trial keys are created in the West US (westus) region. 通过 Azure 仪表板创建的订阅可以位于某个其他的区域,具体取决于你的选择。A subscription created via the Azure dashboard may be in some other region if you so choose.

  • 如果应用程序使用语音 SDK,请在创建语音配置时提供区域代码,例如 westusIf your application uses a Speech SDK, you provide the region code, such as westus, when creating a speech configuration.
  • 如果应用程序使用某个语音服务的 REST API,则区域是你在发出请求时使用的终结点 URI 的一部分。If your application uses one of the Speech Services's REST APIs, the region is part of the endpoint URI you use when making requests.

为某个区域创建的密钥仅在该区域有效。Keys created for a region are valid only in that region. 尝试在其他区域使用此类密钥会导致身份验证错误。Attempting to use them with other regions will result in authentication errors.

后续步骤Next steps

完成我们的 10 分钟快速入门之一,或查看我们的 SDK 示例:Complete one of our 10-minute quickstarts or check out our SDK samples: