# 剧情编辑前后端文档
@[TOC](文章目录)
## 公共请求头 :Authorization:token(登录后返回) # 1.测试环境部署地址 ## 1.1后端部署 - 服务器:gz26 - 服务器部署地址:/home/jiaoyou/projects_dev/plotEditor - 前端部署地址:/var/www/html/dramaeditor # 一、登录注册 ## 1.1登录 ### 请求参数 1. 请求方式 Request Method: POST Path: /ploteditor/login 2. 请求头:无 3. 请求参数 参数名 | 参数类型 | 描述 | 必须 -------- | ----- | ----- | ----- ueserName | String | 用户名 | Y passWord | String | 用户密码 | Y 4. 请求体示例 ```json { "username":"guoke", "password":"123456" } ``` ### 响应参数 - 响应参数data说明 参数名 | 参数类型 | 描述 | 必须 -------- | ----- | ----- | ----- duration | Long | token有效时间 | Y username | String | 用户名 | Y token | String | 登录验证token | Y authority | String | 用户权限等级 | Y - 响应参数示例 ```json { "code": 1, "msg": "成功", "data": { "authority": 1, "duration": 100, "username": "guoke", "token": "eyJhbGciOiJIUzI1NiJ9.eyJpYXQiOjE2MjU1NjYyNDQsImV4cCI6MTYyNTU2NjI0NCwiYXV0aG9yaXR5IjoxLCJpZCI6MX0.9Zlq7ByxQ5b2TDqRw3EEZoQQcgMuwhASphlNy2sghOA" } } ``` ## 1.2获取验证码 ### 请求参数 1. 请求方式 Request Method: POST Path: /ploteditor/email 2. 请求头:无 3. 请求参数 参数名 | 参数类型 | 描述 | 必须 -------- | ----- | ----- | ----- email | String | 邮箱 | Y forgotPassword | Boolean | 发送验证码作用(true:忘记密码/false:注册) | Y 4. 请求体示例 ```json { "email":"1638049431@qq.com", "forgotPassword":true } ``` ### 响应参数 - 响应参数示例 ```json { "code": 1, "msg": "验证码已发送!!!", "data": null } } ``` ## 1.3注册 ### 请求参数 1. 请求方式 Request Method: POST Path: /ploteditor/registered 2. 请求头:无 3. 请求参数 参数名 | 参数类型 | 描述 | 必须 -------- | ----- | ----- | ----- ueserName | String | 用户名 | Y passWord | String | 用户密码 | Y email | String | 邮箱 | Y code | String | 验证码 | Y 4. 请求体示例 ```json { "username":"hjdtest", "password":"123456", "email":"1638049431@qq.com", "code":"090101" } ``` ### 响应参数 - 响应参数示例 ```json { "code": 1, "msg": "成功", "data": null } ``` ## 1.4忘记密码 ### 请求参数 1. 请求方式 Request Method: POST Path: /ploteditor/forgot 2. 请求头:无 3. 请求参数 参数名 | 参数类型 | 描述 | 必须 -------- | ----- | ----- | ----- ueserName | String | 用户名 | Y passWord | String | 用户设置的新密码 | Y email | String | 邮箱 | Y code | String | 验证码 | Y 4. 请求体示例 ```json { "username":"hjdtest", "password":"123456", "email":"1638049431@qq.com", "code":"090101" } ``` ### 响应参数 - 响应参数示例 ```json { "code": 1, "msg": "成功", "data": null } ``` # 二、作品页面 ## 2.1新增作品 ### 请求参数 1. 请求方式 Request Method: POST Path: /work/insert 2. 请求头:无 3. 请求参数 参数名 | 参数类型 | 描述 | 必须 -------- | ----- | ----- | ----- name | String | 新增作品名称 | Y 4. 请求体示例 ```json { "name":"第一个作品" } ``` ## 响应参数 参数名 | 参数类型 | 描述 | 必须 -------- | ----- | ----- | ----- id | Long | 作品id | Y name | String | 新增作品名称 | Y count | int | 作品字数 | Y ownerId | Long | 用户id | Y gmtCreate | data | 用户创建时间 | Y gmtModified | data | 用户修改时间 | Y - 响应参数示例 ```json { "code": 1, "msg": "成功", "data": null } ``` ## 2.2修改作品 ### 请求参数 1. 请求方式 Request Method: PUT Path: /work/update 2. 请求头:无 3. 请求参数 参数名 | 参数类型 | 描述 | 必须 -------- | ----- | ----- | ----- id | Long | 作品编号 | Y name | String | 修改后作品名 | Y count | int | 作品字数 | Y 4. 请求体示例 ```json { "id":123, "name":"修改第一个作品", "count":255 } ``` ## 响应参数 - 响应参数示例 ```json { "code":"1", "msg":"成功", "data":null } ``` ## 2.3查询作品 ### 请求参数 1. 请求方式 Request Method: GET Path: /work/inquiry 2. 请求头:无 3. 请求参数 参数名 | 参数类型 | 描述 | 必须 -------- | ----- | ----- | ----- name | String |作品名 | Y 4. 请求体示例 ``` curl --location --request GET 'http://localhost:48089/work/inquiry?name=%E7%AC%AC%E4%B8%80%E4%B8%AA%E4%BD%9C%E5%93%81' ``` ## 响应参数 - 响应参数data说明 参数名 | 参数类型 | 描述 | 必须 -------- | ----- | ----- | ----- id | Long | 作品id | Y name | String | 作品名称 | Y count | int | 作品字数 | Y ownerId | Long | 用户id | Y gmtCreate | data | 用户创建时间 | Y gmtModified | data | 用户修改时间 | Y - 响应参数示例 ```json { "code": 1, "msg": "成功", "data": { "id": 7, "name": "第三个作品", "count": 0, "ownerId": 123, "gmtCreate": "2021-07-05T08:19:12.000+00:00", "gmtModified": "2021-07-05T08:19:12.000+00:00" } } ``` ## 2.4删除作品 ### 请求参数 1. 请求方式 Request Method: DELETE Path: /work/delete 2. 请求头:无 3. 请求参数 参数名 | 参数类型 | 描述 | 必须 -------- | ----- | ----- | ----- id | int | 作品id | Y 4. 请求体示例 ``` curl --location --request DELETE 'http://localhost:48089/work/delete?id=8' ``` ## 响应参数 - 响应参数示例 ```json { "code":"1", "msg":"成功", "data":null } ``` ## 2.5跳转剧情列表页面 ### 请求参数 1. 请求方式 Request Method: GET Path: /plotpoint/insertAll 2. 请求头:无 3. 请求参数 参数名 | 参数类型 | 描述 | 必须 -------- | ----- | ----- | ----- id | int | 作品id | Y 4. 请求体示例 ``` curl --location --request GET 'http://localhost:48089/plotpoint/insertAll?Id=1' ``` ## 响应参数 - 响应参数data说明 参数名 | 参数类型 | 描述 | 必须 -------- | ----- | ----- | ----- id | Long | 剧情点id | Y number | String | 剧情点编号 | Y texts | List | 剧情点所有NPC的话术 | Y npcName | String | NPC名称 | Y content | String | NPC话术 | Y projectId | int | Long | Y ownerId | int | Long | Y branchs | List | 该剧情点分支 | Y previous | List | 上一步剧情信息 | Y merge | Boolean | true:合并剧情/false:未合并 | Y uncondition | Boolean | true:开启任意跳转/false:关闭任意跳转 | Y complete | Boolean | true:剧情点已完善/false:未完善 | Y wordCount | int | 剧情点字数 | Y branchCount | int | 剧情点分支数量 | Y - 响应参数示例 ```json { "code": 1, "msg": "成功", "data": [ { "id": 10, "number": "1-1", "texts": [ { "npcName": "长老修改三", "content": "" } ], "branchs": null, "projectId": 1, "ownerId": 1, "previous": null, "merge": false, "uncondition": false, "complete": false, "wordCount": 0, "branchCount": 0 } ] } ``` ## 2.6查询所有作品列表 ### 请求参数 1. 请求方式 Request Method: GET Path: /work/inquiryAll 2. 请求头:无 3. 请求参数 参数名 | 参数类型 | 描述 | 必须 -------- | ----- | ----- | ----- 4. 请求体示例 ``` curl --location --request GET 'http://localhost:48089/work/inquiryAll' ``` ## 响应参数 - 响应参数data说明 参数名 | 参数类型 | 描述 | 必须 -------- | ----- | ----- | ----- id | int | 作品id | Y name | String | 作品名称 | Y count | int | 作品字数 | Y - 响应参数示例 ```json { "code":"1", "msg":"成功", "data":[ { "code":1, "msg":"成功", "data":{ "id":2, "name":"第二个作品", "count":12323, "ownerId":123, "gmtCreate":"2021-07-03T07:02:11.000+00:00", "gmtModified":"2021-07-03T07:02:11.000+00:00" } } ... ] } ``` ## 2.7下载文件 ### 请求参数 1. 请求方式 Request Method: GET Path: /work/getJson 2. 请求头:无 3. 请求参数 参数名 | 参数类型 | 描述 | 必须 -------- | ----- | ----- | ----- id | int | 作品id | Y 4. 请求体示例 ``` curl --location --request GET 'http://localhost:48089/work/getJson?id=1' ``` ## 响应参数 - 响应参数data说明 参数名 | 参数类型 | 描述 | 必须 -------- | ----- | ----- | ----- filePath | String | 文件下载路径 | Y - 响应参数示例 ```json { "code":"1", "msg":"成功", "data":{ "filePath":"http://hw-gz26.heyqiwu.cn/downloads/求婚剧情二--140--2021-07-14--15-07-439.json" } } ``` ## 2.8上传文件 ### 请求参数 1. 请求方式 Request Method: post Path: /work/setJson 2. 请求头:无 3. 请求参数 参数名 | 参数类型 | 描述 | 必须 -------- | ----- | ----- | ----- multipartFile | .json文件 | 文件 | Y id | String | 作品id | Y 4. 请求体示例 ``` curl --location --request post 'http://localhost:48089/work/setJson?id=1' 上传的文件 ``` ## 响应参数 - 响应参数示例 ```json { "code":"1", "msg":"成功", "data":null } ``` # 三、评论页面 ## 2.1新增评论 ### 请求参数 1. 请求方式 Request Method: POST Path: /comment/insert 2. 请求头:无 3. 请求参数 参数名 | 参数类型 | 描述 | 必须 -------- | ----- | ----- | ----- id | Long | 评论id(不传说明是用户评论,而不是回答别人的评论) | Y Content | String | 评论内容 | Y plotId | Long | 剧情点id,取得是剧情点列表或详情返回的plot_id | Y 4. 请求体示例 ```json { "id":1, "Content": "好啊", "plotId": 126 } ``` ## 响应参数 - 响应参数示例 ```json { "code":"1", "msg":"成功", "data":null } ``` ## 2.2查询评论 ### 请求参数 1. 请求方式 Request Method: GET Path: /comment/inquiry 2. 请求头:无 3. 请求参数 参数名 | 参数类型 | 描述 | 必须 -------- | ----- | ----- | ----- plotId | Long | 剧情点id,取得是剧情点列表或详情返回的plot_id | Y 4. 请求体示例 ``` curl --location --request GET 'http://localhost:48089/comment/inquiry?plotId=1' ``` ## 响应参数 - 响应参数data说明 参数名 | 参数类型 | 描述 | 必须 -------- | ----- | ----- | ----- id | Long | 评论id | Y commentator | String | 评论人 | Y respondent | String | 被评论人 | Y content | String | 评论内容 | Y parentId | Long | 所属评论id | Y plotId | Long | 剧情点id | Y userDelete | Boolean | 用户是否可以删除(true:可以删除/false:不可以) | Y subComments | List | 评论下的对话 | Y gmtCreate | String | 评论时间 | Y - 响应参数示例 ```json { "code": 1, "msg": "成功", "data": [ { "id": 1, "commentator": "hgd", "respondent": null, "parentId": 0, "plotId": 126, "userDelete": true, "subComments": [ { "id": 1, "commentator": "hgd", "respondent": null, "parentId": 0, "plotId": 126, "userDelete": true, "subComments": null, "gmtCreate": null, "content": "好啊" } ], "gmtCreate": null, "content": "好啊" } ] } ``` ## 2.3删除评论 ### 请求参数 1. 请求方式 Request Method: DELETE Path: /comment/delete 2. 请求头:无 3. 请求参数 参数名 | 参数类型 | 描述 | 必须 -------- | ----- | ----- | ----- id | Long | 评论id | Y 4. 请求体示例 ```json curl --location --request DELETE 'http://localhost:48089/comment/delete?Id=7' ``` ## 响应参数 - 响应参数示例 ```json { "code":"1", "msg":"成功", "data":null } ``` # 四、剧情点页面 ## 2.1新增剧情点 ### 请求参数 1. 请求方式 Request Method: POST Path: /plotpoint/insert 2. 请求头:无 3. 请求参数 参数名 | 参数类型 | 描述 | 必须 -------- | ----- | ----- | ----- branchs | List | 该剧情点分支 | Y number | String | 剧情点编号 | Y texts | List | 剧情点所有NPC的话术 | Y npcName | String | NPC名称 | Y content | String | NPC话术 | Y projectId | Long | 作品id | Y branchNumber | String | 分支编号 | Y userSpeech | String | 用户话术 | Y merge | Boolean | true:合并剧情/false:未合并 | Y uncondition | Boolean | true:开启任意跳转/false:关闭任意跳转 | Y 4. 请求体示例 ```json { "number": "1-2", "texts":[ { "npcName":"长老", "content":"欢迎来到游戏世界" } ], "branchs":[ { "name":"分支1", "userSpeech":"你好是的我知道你好啊", "nextPlotNum":"1-2" }, { "name":"分支2", "examples":"你好是的我知道你好啊", "nextPlotNum":"1-3" } ], "projectId": 1, "merge": true, "uncondition": true } ``` ## 响应参数 - 响应参数示例 ```json { "code":"1", "msg":"成功", "data":null } ``` ## 2.2搜索剧情点 ### 请求参数 1. 请求方式 Request Method: GET Path: /plotpoint/inquiry 2. 请求头:无 3. 请求参数 参数名 | 参数类型 | 描述 | 必须 -------- | ----- | ----- | ----- plotText | String | 剧情点编号 | Y projectId | int | 作品id | Y 4. 请求体示例 ``` curl --location --request GET 'http://localhost:48089/plotpoint/inquiry?plotText=1-1&projectId=1' ``` ## 响应参数 - 响应参数data说明 参数名 | 参数类型 | 描述 | 必须 -------- | ----- | ----- | ----- id | Long | 剧情点id | Y number | String | 剧情点编号 | Y texts | List | 剧情点所有NPC的话术 | Y npcName | String | NPC名称 | Y content | String | NPC话术 | Y projectId | int | Long | Y ownerId | int | Long | Y branchs | List | 该剧情点分支 | Y previous | List | 上一步剧情信息 | Y merge | Boolean | true:合并剧情/false:未合并 | Y uncondition | Boolean | true:开启任意跳转/false:关闭任意跳转 | Y complete | Boolean | true:剧情点已完善/false:未完善 | Y wordCount | int | 剧情点字数 | Y branchCount | int | 剧情点分支数量 | Y - 响应参数示例 ```json { "code": 1, "msg": "成功", "data": [ { "id": 10, "number": "1-1", "texts": [ { "npcName": "长老修改三", "content": "" } ], "branchs": null, "projectId": 1, "ownerId": 1, "previous": null, "merge": false, "uncondition": false, "complete": false, "wordCount": 0, "branchCount": 0 } ] } ``` ## 2.3删除剧情点 ### 请求参数 1. 请求方式 Request Method: DELETE Path: /plotpoint/delete 2. 请求头:无 3. 请求参数 参数名 | 参数类型 | 描述 | 必须 -------- | ----- | ----- | ----- id | Long | 剧情点id | Y projectId | Long | 作品id | Y 4. 请求体示例 ```json curl --location --request DELETE 'http://localhost:48089/plotpoint/delete?Id=7&projectId=1' ``` ## 响应参数 - 响应参数示例 ```json { "code":"1", "msg":"成功", "data":null } ``` ## 2.4查询剧情点详情 ### 请求参数 1. 请求方式 Request Method: GET Path: /plotpoint/detail 2. 请求头:无 3. 请求参数 参数名 | 参数类型 | 描述 | 必须 -------- | ----- | ----- | ----- id | Long | 剧情点id | Y 4. 请求体示例 ``` curl --location --request GET 'http://localhost:48089/plotpoint/detail?number=1-1&projectId=10' ``` ## 响应参数 - 响应参数data说明 参数名 | 参数类型 | 描述 | 必须 -------- | ----- | ----- | ----- nextPlotNum | String | 分支编号 | Y name | String | 分支名称 | Y userSpeech | String | 用户话术 | Y id | Long | 剧情点id | Y number | String | 剧情点编号 | Y texts | List | 剧情点所有NPC的话术 | Y npcName | String | NPC名称 | Y content | String | NPC话术 | Y projectId | int | Long | Y ownerId | int | Long | Y branchs | List | 该剧情点分支 | Y previous | List | 上一步剧情信息 | Y merge | Boolean | true:合并剧情/false:未合并 | Y uncondition | Boolean | true:开启任意跳转/false:关闭任意跳转 | Y complete | Boolean | true:剧情点已完善/false:未完善 | Y wordCount | int | 剧情点字数 | Y branchCount | int | 剧情点分支数量 | Y reply | String | 上一步剧情分支内容 | Y commentId | Long | 剧情点复制id | Y - 响应参数示例 ```json { "code": 1, "msg": "成功", "data": { "id": 12, "number": "1-3", "texts": [ { "npcName": "长老", "content": "欢迎来到游戏世界" } ], "branchs": [ { "name": "分支1", "userSpeech": "你好是的啊", "nextPlotNum": "1-2" }, { "name": "分支2", "userSpeech": null, "nextPlotNum": "1-3" } ], "projectId": 1, "ownerId": 1, "previous": [ { "num": "1-3", "reply": "" }, { "num": "1-1", "reply": "你好是的我知道你好啊+" } ], "merge": true, "uncondition": true, "complete": false, "wordCount": 15, "branchCount": 2, "commentId": 2 } } ``` ## 2.5修改剧情点信息 ### 请求参数 1. 请求方式 Request Method: PUT Path: /plotpoint/updata 2. 请求头:无 3. 请求参数 参数名 | 参数类型 | 描述 | 必须 -------- | ----- | ----- | ----- id | int | 剧情点id | Y branchs | List | 该剧情点分支 | Y number | String | 剧情点编号 | Y texts | List | 剧情点所有NPC的话术 | Y npcName | String | NPC名称 | Y content | String | NPC话术 | Y projectId | Long | 作品id | Y branchNumber | String | 分支编号 | Y userSpeech | String | 用户话术 | Y number | String | 剧情点编号 | Y unmodified | String | 未修改前的剧情点编号 | Y merge | Boolean | true:合并剧情/false:未合并 | Y uncondition | Boolean | true:开启任意跳转/false:关闭任意跳转 | Y 4. 请求体示例 ```json { "id":1 "number": "1-1", "texts":[ { "npcName":"长老", "content":"欢迎来到游戏世界" } ], "branchs":[ { "name":"分支1", "userSpeech":"你好是的我知道你好啊", "nextPlotNum":"1-2" }, { "name":"分支2", "examples":"你好是的我知道你好啊", "nextPlotNum":"1-3" } ], "projectId": 1, "unmodified":"1-1", "merge": true, "uncondition": true } ``` ## 响应参数 - 响应参数示例 ```json { "code":"1", "msg":"成功", "data":null } ``` ## 2.6更新剧情点列表 ### 请求参数 1. 请求方式 Request Method: PUT Path: /plotpoint/detect 2. 请求头:无 3. 请求参数 参数名 | 参数类型 | 描述 | 必须 -------- | ----- | ----- | ----- id | int | 作品id | Y 4. 请求体示例 ```json { "id":1 } ``` ## 响应参数 - 响应参数示例 ```json { "code":"1", "msg":"成功", "data":null } ``` ## 2.7根据作品id查询所有角色 ### 请求参数 1. 请求方式 Request Method: GET Path: /plotpoint/getAllRoles 2. 请求头:无 3. 请求参数 | 参数名 | 参数类型 | 描述 | 必须 | | --------- | -------- | ------------ | ---- | | projectId | Long | 作品id | Y | | pageNum | Integer | 页码 | F | | pageSize | Integer | 显示多少条数 | F | 4.请求体示例 ``` localhost:48089/plotpoint/getAllRoles?projectId=149 ``` ## 响应参数 - 响应参数data说明 | 参数名 | 参数类型 | 描述 | 必须 | | ---------- | --------- | -------------------- | ---- | | id | Long | 角色ID | F | | workId | Long | 作品id | Y | | roleName | String | 角色名称 | Y | | speakStyle | String | 说话风格,播报的风格 | Y | | intonation | int | 音调 | Y | | speech | int | 语速 | Y | | volume | int | 音量 | Y | | updateTime | Timestamp | 更新时间 | F | - 响应参数示例 ``` { "code": 1, "msg": "成功", "data": { "records": [ { "id": 33, "workId": 149, "roleName": "旁白", "speakStyle": "滕志梅(客服女声)", "intonation": 50, "speech": 0, "volume": 50, "updateTime": "2021-08-17T07:41:05.000+00:00" }, { "id": 34, "workId": 149, "roleName": "分支1", "speakStyle": "滕志梅(客服女声)", "intonation": 50, "speech": 0, "volume": 50, "updateTime": "2021-08-17T07:41:05.000+00:00" }, { "id": 35, "workId": 149, "roleName": "分支2", "speakStyle": "滕志梅(客服女声)", "intonation": 50, "speech": 0, "volume": 50, "updateTime": "2021-08-17T07:41:05.000+00:00" } ], "total": 3, "size": 5, "current": 1, "orders": [], "hitCount": false, "searchCount": true, "pages": 1 } } ``` ## 2.8修改角色信息 ### 请求参数 请求方式 Request Method: PUT Path: /plotpoint/updateByStyle 请求头:无 请求参数 | 参数名 | 参数类型 | 描述 | 必须 | | ---------- | -------- | -------- | ---- | | workId | Long | 作品id | Y | | speakStyle | String | 说话风格 | Y | | intonation | int | 音调 | Y | | speech | int | 语速 | Y | | volume | int | 音量 | Y | | roleName | String | 角色名称 | Y | 4.请求体示例 ``` localhost:48089/plotpoint/updateByStyle?workId=89&speakStyle=滕志梅(11111服女声)&intonation=10&speech=90&volume=10&roleName=分支7 ``` - 响应参数示例 ``` { "code": 1, "msg": "更新成功!", "data": null } ``` ## 2.9搜索意图 1. 请求方式 Request Method: POST Path: /plotpoint/intention 2. 请求参数 | 参数名 | 参数类型 | 描述 | 必须 | | ------ | -------- | ---------- | ----------- | | sents | String | 意图搜索名 | Y请求体示例 | 3. 请求体示例 ``` { "sents":"愿意陪伴,没兴趣陪伴你,看看我" } ``` 4.响应参数示例 ``` { "code": 1, "msg": "成功", "data": [ { "intentName": "同意陪", "branchs": [ { "branchName": "不陪我", "examples": "陪伴我\n陪我", "auxiliaryPriority": "10", "semanticTriples": [ { "semanticRelationName": "ruleb0dob0whatb0vn", "valueRange": "[项目词组陪伴动词]:visitor" } ] }, { "branchName": "同意陪", "examples": "同意陪\n答应陪伴", "auxiliaryPriority": "10", "semanticTriples": [ { "semanticRelationName": "ruleb0dob0whatb0vv", "valueRange": "[项目词组同意动词]:[项目词组陪伴动词]" } ] }, { "branchName": "当然陪", "examples": "当然陪\n一定陪伴", "auxiliaryPriority": "10", "semanticTriples": [ { "semanticRelationName": "ruleb0dob0whatb0adv", "valueRange": "[项目词组当然肯定副词]:[项目词组陪伴动词]" } ] }, { "branchName": "愿意陪", "examples": "愿意陪伴\n想陪", "auxiliaryPriority": "10", "semanticTriples": [ { "semanticRelationName": "ruleb0dob0whatb0vv", "valueRange": "[项目词组同意意愿动词]:[项目词组陪伴动词]" } ] }, { "branchName": "继续", "examples": null, "auxiliaryPriority": "10", "semanticTriples": [ { "semanticRelationName": "ruleb0certainb0answer", "valueRange": "继续" } ] }, { "branchName": "陪一下", "examples": "先陪\n就陪伴", "auxiliaryPriority": "10", "semanticTriples": [ { "semanticRelationName": "ruleb0dob0whatb0adv", "valueRange": "一下:[项目词组陪伴动词]+就:[项目词组陪伴动词]+先:[项目词组陪伴动词]" } ] }, { "branchName": "陪他们", "examples": "陪他们\n陪她", "auxiliaryPriority": "10", "semanticTriples": [ { "semanticRelationName": "ruleb0dob0whatb0vn", "valueRange": "[项目词组陪伴动词]:[项目词组第三人称词组]" } ] }, { "branchName": "陪你", "examples": "陪伴你\n陪你", "auxiliaryPriority": "10", "semanticTriples": [ { "semanticRelationName": "ruleb0dob0whatb0vn", "valueRange": "[项目词组陪伴动词]:bot" } ] }, { "branchName": "陪动作", "examples": "陪打球\n陪伴游泳", "auxiliaryPriority": "10", "semanticTriples": [ { "semanticRelationName": "ruleb0dob0whatb0vv", "valueRange": "[项目词组陪伴动词]:[项目词组动作类词组]" } ] }, { "branchName": "陪吧", "examples": "陪吧\n陪伴", "auxiliaryPriority": "9", "semanticTriples": [ { "semanticRelationName": "ruleb0certainb0answer", "valueRange": "[项目词组陪伴动词]" } ] } ], "phrases": [ { "phraseName": "项目词组同意动词", "pos": null, "words": "希望+同意+期待+保证+答应+订交+许诺+允诺+容许+承诺+赞助+附和+认可+允许+接受+应承+批准+答允+赞成+许可+应允+和议+订定+制定+应许+愿望+协议+乐意+准许+认同+愿意+支持+赞同+愿", "highPerformance": false, "wordSet": null, "ableEdit": false }, { "phraseName": "项目词组同意意愿动词", "pos": null, "words": "计划+要+想要+希望+打算+选+准备+选择+想+需要+乐意+应该+会+可以+愿意+考虑+愿", "highPerformance": false, "wordSet": null, "ableEdit": false }, { "phraseName": "项目词组动作类词组", "pos": null, "words": "带走+失踪+锻炼+使用+说+etc+游泳+批评+打球+逃走", "highPerformance": false, "wordSet": null, "ableEdit": true }, { "phraseName": "项目词组陪伴动词", "pos": null, "words": "陪同+伴随+陪陪+陪伴+陪+随同", "highPerformance": false, "wordSet": null, "ableEdit": false }, { "phraseName": "项目词组第三人称词组", "pos": null, "words": "它们俩+它们+他们俩+它+他+她们+她+他俩+她俩+它俩+他们+她们俩", "highPerformance": false, "wordSet": null, "ableEdit": false }, { "phraseName": "项目词组当然肯定副词", "pos": null, "words": "仍然+依旧+一定+依然+绝对+肯定+当然+必须+应该+必然+必定+照旧", "highPerformance": false, "wordSet": null, "ableEdit": false } ], "wsces": [ { "o": "bot", "s": "陪", "customWord": "和你在一起,和你一起,同你一起,跟你一起,同你一起,我和你在一起,我和你一起,我同你一起,我跟你一起,我同你一起", "semanticRelationName": "ruleb0dob0whatb0vn" }, { "o": "陪", "s": "吧", "customWord": "[项目词组陪伴动词]", "semanticRelationName": "ruleb0certainb0answer" } ] }, { "intentName": "同意看", "branchs": [ { "branchName": "去看", "examples": "去看看\n过去看", "auxiliaryPriority": "10", "semanticTriples": [ { "semanticRelationName": "ruleb0dob0whatb0vv", "valueRange": "[项目词组去的动词]:[项目词组看动词]" } ] }, { "branchName": "同意看", "examples": "同意看\n答应看", "auxiliaryPriority": "10", "semanticTriples": [ { "semanticRelationName": "ruleb0dob0whatb0vv", "valueRange": "[项目词组同意动词]:[项目词组看动词]" } ] }, { "branchName": "想看", "examples": "愿意看\n想看", "auxiliaryPriority": "10", "semanticTriples": [ { "semanticRelationName": "ruleb0dob0whatb0vv", "valueRange": "[项目词组同意意愿动词]:[项目词组看动词]" } ] }, { "branchName": "我看", "examples": "我看看\n我瞧瞧", "auxiliaryPriority": "10", "semanticTriples": [ { "semanticRelationName": "ruleb0dob0whatb0nv", "valueRange": "visitor:[项目词组看动词]" } ] }, { "branchName": "看一下", "examples": "看一下\n就看看", "auxiliaryPriority": "10", "semanticTriples": [ { "semanticRelationName": "ruleb0dob0whatb0adv", "valueRange": "一下:[项目词组看动词]+就:[项目词组看动词]+先:[项目词组看动词]" } ] }, { "branchName": "看他们", "examples": "看他们\n看她", "auxiliaryPriority": "10", "semanticTriples": [ { "semanticRelationName": "ruleb0dob0whatb0vn", "valueRange": "[项目词组看动词]:[项目词组第三人称词组]" } ] }, { "branchName": "看你", "examples": "看你\n看看你", "auxiliaryPriority": "10", "semanticTriples": [ { "semanticRelationName": "ruleb0dob0whatb0vn", "valueRange": "[项目词组看动词]:bot" } ] }, { "branchName": "看吧", "examples": "看吧\n看看", "auxiliaryPriority": "9", "semanticTriples": [ { "semanticRelationName": "ruleb0certainb0answer", "valueRange": "[项目词组看动词]" } ] }, { "branchName": "看吧吗", "examples": "看吗\n看看吗", "auxiliaryPriority": "9", "semanticTriples": [ { "semanticRelationName": "ruleb0askb0answer", "valueRange": "[项目词组看动词]" } ] }, { "branchName": "看我", "examples": "看我\n看看我", "auxiliaryPriority": "10", "semanticTriples": [ { "semanticRelationName": "ruleb0dob0whatb0vn", "valueRange": "[项目词组看动词]:visitor" } ] }, { "branchName": "继续", "examples": null, "auxiliaryPriority": "10", "semanticTriples": [ { "semanticRelationName": "ruleb0certainb0answer", "valueRange": "继续" } ] } ], "phrases": [ { "phraseName": "项目词组同意动词", "pos": null, "words": "希望+同意+期待+保证+答应+订交+许诺+允诺+容许+承诺+赞助+附和+认可+允许+接受+应承+批准+答允+赞成+许可+应允+和议+订定+制定+应许+愿望+协议+乐意+准许+认同+愿意+支持+赞同+愿", "highPerformance": false, "wordSet": null, "ableEdit": false }, { "phraseName": "项目词组同意意愿动词", "pos": null, "words": "计划+要+想要+希望+打算+选+准备+选择+想+需要+乐意+应该+会+可以+愿意+考虑+愿", "highPerformance": false, "wordSet": null, "ableEdit": false }, { "phraseName": "项目词组看动词", "pos": null, "words": "瞄+搜查+瞅+观望+搜索+查看查看+看+查看+瞅一眼+望见+看到+找找+观察+搜搜+瞄瞄+观看+看见+望+搜+查+看看看+瞧+查查+看看+瞧瞧+瞅瞅+观察观察+查找+瞧见+侦查+观看观看+找", "highPerformance": false, "wordSet": null, "ableEdit": false }, { "phraseName": "项目词组第三人称词组", "pos": null, "words": "它们俩+它们+他们俩+它+他+她们+她+他俩+她俩+它俩+他们+她们俩", "highPerformance": false, "wordSet": null, "ableEdit": false }, { "phraseName": "项目词组去的动词", "pos": null, "words": "光临+移动+逃+到达+参与+逃离+上+出去+溜溜+走走+转转+参加+逛+溜+逃到+出发+登陆+抵达+赶路+离开+跑路+到+挪动+启程+去+逃跑+开始+走着+过去+逃命+行+行动+逃避+跑+进去+走到+溜走+逃走+跟+莅临+驾到+来临+驾临+来+来到+转+逃亡+过来+走+走近+逛逛+走进+出+进入+进来", "highPerformance": false, "wordSet": null, "ableEdit": false } ], "wsces": [ { "o": "看", "s": "吧", "customWord": "[项目词组看动词]", "semanticRelationName": "ruleb0certainb0answer" } ] } ] } ``` ## 3.0剧本生成 1. 请求方式 Request Method: POST Path: localhost:48089/plotpoint/plotBeing 2.请求头:无 3.请求参数 | 参数名 | 参数类型 | 描述 | 必须 | | ------ | -------- | ------------------ | ---- | | workId | Long | 作品id | Y | | number | String | 开始生成剧情点编号 | Y | 4.请求体示例 ``` { "workId":295, "number":"1-1" } ``` 5.响应体示例 ``` SUCCESS: { "code": 1, "msg": "成功", "data": null } FAILTURE: { "code": 60003, "msg": "该接口禁止访问", "data": null } { "code": 50002, "msg": "作品数据缺失!", "data": null } ``` ## 3.1剧情生成百分比 1. 请求方式 Request Method: POST Path: localhost:48089/plotpoint/percent 2.请求头:无 3.请求参数 | 参数名 | 参数类型 | 描述 | 必须 | | ------ | -------- | ------ | ---- | | workId | Long | 作品id | Y | 4.请求体示例 ``` { "workId":295 } ``` 5.响应体示例 ``` SUCCESS: { "code": 1, "msg": "成功", "data": { "status": 1, // 生成完成状态-> 1: 成功, 0: 生成中 "progress": 100 // 进度,100表示完成 } } { "code": 1, "msg": "成功", "data": { "status": 0, // 生成完成状态-> 1: 成功, 0: 生成中 "progress": 90 // 进度,100表示完成 } } FAILTURE: { "code": 50002, "msg": "不存在脚本,请先生成!", "data": null } ```