[Cloud Computing Tencent Cloud] WeChat Mini Program integrate Tencent Cloud Smart Oral Evaluation-English (SOE-E)

Smart Oral Evaluation-English (SOE-E)

Tencent Cloud Smart Oral Evaluation-English (SOE-E) is a voice evaluation product launched by Tencent Cloud. In the past, oral English practice had to rely on professional teachers to perform subjective assessment after listening, so the cost was high and the learning time was difficult to guarantee. Tencent Cloud launched an English voice evaluation product for this scenario, supporting voice evaluation covering all ages from children to adults, supporting multiple modes such as words (words), sentences, and supporting pronunciation accuracy (GOP), fluency, completeness, and stress Accuracy and other omni-directional scoring mechanism, and the similarity of experts’ scoring is more than 95%.

Features

  • Coverage for all ages

    It supports English voice evaluation and scoring covering all age groups from children to adults, and provides personalized and differentiated evaluation ability support for children.

  • Multi-dimensional scoring

    Supports multiple voice evaluation modes such as words, sentences, paragraphs, and free speaking, and supports all-round scoring mechanisms such as pronunciation accuracy, fluency, and completeness.

  • Not an expert, better than an expert

    The scoring results of the voice evaluation of Zhiling Speaking Evaluation are more than 95% fit with the expert scoring, which can be widely used in the oral English teaching business.

Mini Program plug-in

The Smart Oral Evaluation-English (SOE-E) Mini Program plug-in Mini Program plug-in encapsulates the recording function of the Mini Program and the calls of Wisdom Speaking Evaluation API, allowing developers to access the voice evaluation capabilities through simple configuration, eliminating the need for complicated voice fragmentation and authentication logic. Focus on business development.

Prerequites

Usages

Import Plug-in code

Log in to the Mini Program Plug-in Center - https://mp.weixin.qq.com/wxopen/plugindevdoc?appid=wxe5a00a1780c8eb95&token=486467026&lang=zh_CN to add the plug-in.

Introduce the following code in app.json:

1
2
3
4
5
6
7
8
// app.json

"plugins": {
"myPlugin": {
"version": "1.1.1",
"provider": "wxe5a00a1780c8eb95"
}
}

Import plug-in code.

1
let plugin = requirePlugin("myPlugin");

Initialization

Option 1 (recommended): Obtain authorization credentials from the backend to the applet plug-in, and the applet plug-in obtains the authorization credentials to initiate a request. During the formal deployment, please add a layer of permission check of your own website on the backend:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
let plugin = requirePlugin("myPlugin");
let manager = plugin.getSoeRecorderManager({
getAuthorization: function (callback) {
wx.request({
url: 'https://example.com/server/getAuthorization',
method: 'POST',
data: {},
success: data => {
callback({
timestamp: data.result.timestamp,
authorization: data.result.authorization
})
}
});
}
});

Option 2: The authorization certificate is obtained through the applet cloud function, and the applet plug-in gets the authorization certificate to initiate a request. The applet cloud has its own permission check, and no additional permission check is required:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
let plugin = requirePlugin("myPlugin");
let manager = plugin.getSoeRecorderManager({
getAuthorization: function (callback) {
wx.cloud.callFunction({
name: 'getAuthorization',
data: {},
success: data => {
callback({
timestamp: data.result.timestamp,
authorization: data.result.authorization
})
}
})
}
});

Option 3: The applet uses a fixed key to calculate the authorization certificate. This format is suitable for front-end debugging. If you use this format, please avoid revealing the key.

1
2
3
4
5
let plugin = requirePlugin("myPlugin");
let manager = plugin.getSoeRecorderManager({
secretId: yourSecretId,
secretKey: yourSecretKey
});

Record, stop and get evaluation result:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
// start record
manager.start({
content: 'about'
})

// stop record
manager.stop()

// Or use local voice data(Base64)
/**
* 支持将音频数据作为参数进行测评,仅支持base64格式
* @param {
* content: 'about', // 测评文本
* audioBase64: '//uQBAAAA', // 测评音频base64格式
* ...options // option中其他非必传参数
* }
*/
manager.uploadLocalFile({
content: 'about',
audioBase64: '//uQBAAAA'
});

Get evaluation result callback:

1
2
3
4
manager.onSuccess((res) => {
//打印识别结果
console.log(res)
});

Other callback methods:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
// start callback
manager.onStart((res) => {
console.log("成功开始录音识别", res)
});

// stop callback
manager.onStop((res) => {
console.log("录音已停止", res)
});

// error callback
manager.onError((res) => {
// print log
console.log(res)
})

References

[1] 智聆口语评测(英文)_英语口语评测_英语语音评测 - 腾讯云 - https://cloud.tencent.com/product/soe-e

[2] 智聆口语评测 - 文档中心 - 腾讯云 - https://cloud.tencent.com/document/product/884](https://cloud.tencent.com/document/product/884)

[3] 智聆口语评测 小程序插件 - SDK 文档 - 文档中心 - 腾讯云 - https://cloud.tencent.com/document/product/884/33984

[4] 智聆口语评测 发音数据传输接口附带初始化过程(常用实践) - API 文档 - 文档中心 - 腾讯云 - https://cloud.tencent.com/document/product/884/32605

[5] Tencent/iHearing: 微信智聆口语测评小程序是针对口语练习场景开发的测评类小程序,通过智聆口语评测插件提供了句子和单词发音准确度等功能。 - https://github.com/Tencent/iHearing

[6] 智聆口语评测 | 小程序插件 | 微信公众平台 - https://mp.weixin.qq.com/wxopen/plugindevdoc?appid=wx63d6102e26f0a3f8&token=1947236119&lang=zh_CN

[7] WeChat Developer Tools - https://developers.weixin.qq.com/miniprogram/en/dev/devtools/download.html

[8] Tencent Cloud - https://intl.cloud.tencent.com/