All Products
Search
Document Center

Activate Intelligent Speech Interaction

Last Updated: Oct 24, 2019

Procedure

  1. Go to the Alibaba Cloud official website to register an Alibaba Cloud account. If you already have an Alibaba Cloud account, go to the next step.

  2. On the Intelligent Speech Interaction product page, click Enable Now.

  3. On the page that appears, click Buy Now to purchase Intelligent Speech Interaction services. By default, a free trial is available. Currently, an Alibaba Cloud account can initiate a maximum of two concurrent service calls for free.

  4. On the Access Key Management page in the Alibaba Cloud console, create an AccessKey ID and AccessKey secret for your Alibaba Cloud account. Use the AccessKey ID and AccessKey secret to call Intelligent Speech Interaction services.

Note: The AccessKey ID and AccessKey secret you create in step 4 belong to your Alibaba Cloud account. The AccessKey has access to all services that have been activated, which is similar to the root user in Linux. For your account security, we recommend that you do not use the AccessKey. Instead, you can create a RAM user in the RAM console, and use the AccessKey of the RAM user to call Intelligent Speech Interaction services. For more information, see the following section.

Move the pointer over your avatar in the upper-right corner in the Alibaba Cloud console, and select RAM from the drop-down list. On the RAM page that appears, you can create and manage RAM users. For more information about RAM, see the RAM document.

RAM document

The procedure for creating a RAM user is as follows. For more information, see Create a RAM user.

  1. Log on to the RAM console.

  2. Choose Identities > Users > Create User.

  3. In the dialog box that appears, specify the logon name and display name. Set the other parameters as required. To create multiple RAM users at a time, click Add User.

  4. In the Access Mode section, select Programmatic Access. If you need to use the RAM user to log on to the console, select Console Password Logon as well.

  5. Click OK. On the page that appears, click Download CSV File to save the user information to your local host. The AccessKey ID and AccessKey secret of the RAM user are stored in the downloaded file. This is the only chance to view and download the AccessKey secret. For account security, the AccessKey secret cannot be viewed or downloaded again after you exit the page. If the AccessKey secret is lost, you must create a new AccessKey. The newly created AccessKey and the original AccessKey represent the same user identity. Different AccessKeys of a RAM user are equivalent in use.

  6. For more information about authorizing the created RAM user to call Intelligent Speech Interaction services, see the following section.

RAM user authorization

Formerly, Intelligent Speech Interaction was not integrated with Alibaba Cloud RAM. However, to meet customer needs, RAM users are allowed to access Intelligent Speech Interaction service resources under their Alibaba Cloud account by default. To further safeguard the security of accessing Intelligent Speech Interaction service resources, we have integrated Intelligent Speech Interaction with Alibaba Cloud RAM. Only authorized RAM users can access Intelligent Speech Interaction service resources under your Alibaba Cloud account. Even if you have been able to use a RAM user to access Intelligent Speech Interaction service resources, you must also authorize the RAM user. The procedure is as follows:

  1. Log on to the Alibaba Cloud console with your Alibaba Cloud account, and click Resource Access Management. You can also click here to go to the RAM console.

  2. Choose Permissions > Policies. On the page that appears, enter nls in the search box, and click the search icon to view the system policies predefined for users.

Policies

Policy name Note Description
AliyunNLSFullAccess Provides full access to Intelligent Speech Interaction. This policy allows users to access and operate all APIs and the console of Intelligent Speech Interaction.
AliyunNLSReadOnlyAccess Provides read-only access to Intelligent Speech Interaction. This policy allows users to have read-only access to all APIs and the console of Intelligent Speech Interaction.
AliyunNLSSpeechServiceAccess Provides access to Intelligent Speech Interaction services. This policy allows users to call and operate APIs related to Intelligent Speech Interaction services.
AliyunNLSSlpAccess Provides access to the customization platform of Intelligent Speech Interaction. This policy allows users to call and operate the hotword and language model APIs of the customization platform of Intelligent Speech Interaction.
  1. In addition to the predefined system policies, you can create a policy to grant more flexible and fine-grained permissions to your RAM users to call each API. (If you are using an earlier version of the RAM console, choose Create Authorization Policy > Blank Template.)Click Create Policy. In the dialog box that appears, enter the policy name and note, and select Script for Configuration Mode. For more information about permissions, see the API resource table at the end of this topic. Assume that you want to create a custom policy with read-only access to the console. You can set the policy name to CustomNLSPortalReadOnlyAccess and the note to Custom read-only console access policy. Then, you can configure the script as follows.
  1. {
  2. "Version": "1",
  3. "Statement": [
  4. {
  5. "Effect": "Allow",
  6. "Action": [
  7. "nls:Get*",
  8. "nls:List*",
  9. "nls:Verify*"
  10. ],
  11. "Resource": [
  12. "acs:nls:*:*:portal/*"
  13. ]
  14. }
  15. ]
  16. }

In the script:

  • The value of the Effect parameter is either Allow or Deny.
  • For more information about the Action and Resource parameters, see the API resource table at the end of this topic.

Create a custom policy

  1. Grant the configured policy to the RAM user who wants to access Intelligent Speech Interaction service resources. The procedure is as follows: Click Users in the left-side navigation pane to view the users that have been created. Find the target RAM user, and click Add Permissions in the Actions column.

Click Add Permissions

In the dialog box that appears, select System Policy or Custom Policy, and select policies to be granted to the RAM user. The selected policies are added to the Selected list on the right. Click the cross sign to remove a selected policy, or click Clear to remove all selected policies. Click OK. The authorization result appears.

Add Permissions

  1. Confirm that the RAM user authorization is successful. The procedure is as follows: Click Users in the left-side navigation pane. (If you are using an earlier version of the RAM console, choose User Management > Management > User Authorization Policy.)Click the RAM user configured in step 4. On the page that appears, click the Permissions tab to view the policies granted to the RAM user.

View the policies granted to the RAM user

API resource tableIntelligent Speech Interaction provides 25 API resources, as listed in the following table. You can customize policies based on these API resources.

API operation Action Resource
CreateAsrVocab nls:CreateAsrVocab acs:nls:$regionid:$accountid:slp/vocab/*
DeleteAsrVocab nls:DeleteAsrVocab acs:nls:$regionid:$accountid:slp/vocab/$vocabId
DeleteVocab nls:DeleteVocab acs:nls:$regionid:$accountid:slp/vocab/$vocabId
GetAsrVocab nls:GetAsrVocab acs:nls:$regionid:$accountid:slp/vocab/$vocabId
ListAsrVocab nls:ListAsrVocab acs:nls:$regionid:$accountid:slp/vocab/*
UpdateAsrVocab nls:UpdateAsrVocab acs:nls:$regionid:$accountid:slp/vocab/$vocabId
AddDataToAsrLmModel nls:AddDataToAsrLmModel acs:nls:$regionid:$accountid:slp/lm/data/*
acs:nls:$regionid:$accountid:slp/lm/model/$modelId
CreateAsrLmData nls:CreateAsrLmData acs:nls:$regionid:$accountid:slp/lm/data/*
CreateAsrLmModel nls:CreateAsrLmModel acs:nls:$regionid:$accountid:slp/lm/model/*
DeleteAsrLmData nls:DeleteAsrLmData acs:nls:$regionid:$accountid:slp/lm/data/$dataId
DeleteAsrLmModel nls:DeleteAsrLmModel acs:nls:$regionid:$accountid:slp/lm/model/$modolId
DeployAsrLmModel nls:DeployAsrLmModel acs:nls:$regionid:$accountid:slp/lm/model/$modolId
GetAsrLmData nls:GetAsrLmData acs:nls:$regionid:$accountid:slp/lm/data/$dataId
GetAsrLmModel nls:GetAsrLmModel acs:nls:$regionid:$accountid:slp/lm/model/$modolId
ListAsrLmData nls:ListAsrLmData acs:nls:$regionid:$accountid:slp/lm/data/*
ListAsrLmModel nls:ListAsrLmModel acs:nls:$regionid:$accountid:slp/lm/model/*
RemoveDataFromAsrLmModel nls:RemoveDataFromAsrLmModel acs:nls:$regionid:$accountid:slp/lm/data/$dataId
acs:nls:$regionid:$accountid:slp/lm/model/$modolId
StopTrainAsrLmModel nls:StopTrainAsrLmModel acs:nls:$regionid:$accountid:slp/lm/model/$modolId
TrainAsrLmModel nls:TrainAsrLmModel acs:nls:$regionid:$accountid:slp/lm/model/$modolId
UndeployAsrLmModel nls:UndeployAsrLmModel acs:nls:$regionid:$accountid:slp/lm/model/$modolId
UpdateAsrLmData nls:UpdateAsrLmData acs:nls:$regionid:$accountid:slp/lm/data/$dataId
UpdateAsrLmModel nls:UpdateAsrLmModel acs:nls:$regionid:$accountid:slp/lm/model/$modolId
GetTaskResult nls:GetTaskResult acs:nls:$regionid:$accountid:filetrans/$taskId
SubmitTask nls:SubmitTask acs:nls:$regionid:$accountid:filetrans/*
CreateToken nls:CreateToken acs:nls:$regionid:$accountid:meta/*

Next steps