同步基础练主要面向有标准答案的对话任务,虽然该模式允许用户和标准答案有一定的区别或偏差,但AI会相对严格的要求用户使用标准答案回复问题,
调试
您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。
授权信息
下表是API对应的授权信息,可以在RAM权限策略语句的Action元素中使用,用来给RAM用户或RAM角色授予调用此API的权限。具体说明如下:
- 操作:是指具体的权限点。
- 访问级别:是指每个操作的访问级别,取值为写入(Write)、读取(Read)或列出(List)。
- 资源类型:是指操作中支持授权的资源类型。具体说明如下:
- 对于必选的资源类型,用前面加 * 表示。
- 对于不支持资源级授权的操作,用
全部资源表示。
- 条件关键字:是指云产品自身定义的条件关键字。
- 关联操作:是指成功执行操作所需要的其他权限。操作者必须同时具备关联操作的权限,操作才能成功。
| 操作 | 访问级别 | 资源类型 | 条件关键字 | 关联操作 |
|---|---|---|---|---|
| aicontent:SyncPracticeTasksGenerate | create | *全部资源 * |
| 无 |
请求语法
POST /api/v1/aiteacher/syncPractice/generateTask HTTP/1.1
请求参数
| 名称 | 类型 | 必填 | 描述 | 示例值 |
|---|---|---|---|---|
| body | object | 否 | 请求 body 参数 | |
| userId | string | 是 | 用户 Id | 6440xxxxxxxxxx5fafc98c421 |
| grade | string | 是 | 年级 枚举值:
| 13 |
| textbook | string | 否 | 教材名 | 英语(基础模块)修订版 |
| topic | string | 是 | 对话主题 | talk about your dream job. |
| learningObject | string | 否 | 学习目标 | Understanding unique professions such as dog walkers, hotel test sleepers, and food tasters, including their job responsibilities and the benefits or challenges associated with each role. |
| textContent | string | 是 | 用于生成问题的参考文章 | Dog walker Dog walking, as a profession, originated in the US. Some may think that it's a perfect job, because dog walkers won't be imprisoned in an office. But it's actually manual labour. At their busiest, dog walkers may have more than ten dogs to take care of in a day. Hotel test sleeper A hotel test sleeper, as the name suggests, has to write expert reviews about the facilities, locations, prices, dining and other services of hotels, in order to provide evaluations and guides for travelers. Hotel test sleepers don't need to punch in for work and they get about ten thousand yuan as income every month. What a comfortable job! Food taster In ancient times, a food taster was a person who tasted foods (or drinks) to be served to someone else, to confirm that it was safe to eat. But now, those working as food tasters just get to taste various new foods and drinks aimed at specific regions across the world. They then give their opinions on these products to the companies and suggest improvements. |
| keySentences | array | 否 | 重点学习句子集合 | |
| string | 否 | 重点学习句子 | A hotel test sleeper, as the name suggests, has to write expert reviews about the facilities, locations, prices, dining, and other services of hotels. | |
| keyWords | array | 否 | 重点学习单词集合 | |
| string | 否 | 重点学习单词 | responsibility |
返回参数
示例
正常返回示例
JSON格式
{
"requestId": "xxxx-xxxx-xxxx-xxxxxxxx\n",
"success": true,
"errCode": "UNKNOWN_ERROR\n",
"errMessage": "未知错误\n",
"httpStatusCode": 200,
"data": {
"taskType": "textbook_question_answering",
"taskContent": [
{
"assistant": "Why might some people think dog walking is a great job?\n",
"user": "They think it's great because they won't be stuck in an office.\n"
}
]
}
}错误码
访问错误中心查看更多错误码。
变更历史
| 变更时间 | 变更内容概要 | 操作 |
|---|
暂无变更历史
