Commit 58e92a77 by 陈宥希

initial

parents
.DS_Store
node_modules
/dist
# local env files
.env.local
.env.*.local
# Log files
npm-debug.log*
yarn-debug.log*
yarn-error.log*
pnpm-debug.log*
# Editor directories and files
.idea
.vscode
*.suo
*.ntvs*
*.njsproj
*.sln
*.sw?
# demo
## Project setup
```
npm install
```
### Compiles and hot-reloads for development
```
npm run serve
```
### Compiles and minifies for production
```
npm run build
```
### Customize configuration
See [Configuration Reference](https://cli.vuejs.org/config/).
module.exports = {
presets: [
'@vue/cli-plugin-babel/preset'
]
}
{
"compilerOptions": {
"target": "es5",
"module": "esnext",
"baseUrl": "./",
"moduleResolution": "node",
"paths": {
"@/*": [
"src/*"
]
},
"lib": [
"esnext",
"dom",
"dom.iterable",
"scripthost"
]
}
}
This source diff could not be displayed because it is too large. You can view the blob instead.
{
"name": "demo",
"version": "0.1.0",
"private": true,
"scripts": {
"serve": "vue-cli-service serve",
"build": "vue-cli-service build"
},
"dependencies": {
"axios": "^1.4.0",
"core-js": "^3.32.1",
"element-plus": "^2.3.9",
"vue": "^3.3.4",
"vue-router": "^4.2.4"
},
"devDependencies": {
"@vue/cli-plugin-babel": "~5.0.0",
"@vue/cli-plugin-router": "~5.0.0",
"@vue/cli-service": "~5.0.0",
"less": "^4.2.0",
"less-loader": "^8.0.0"
},
"browserslist": [
"> 1%",
"last 2 versions",
"not dead",
"not ie 11"
]
}
<!DOCTYPE html>
<html lang="">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width,initial-scale=1.0">
<title>话术审核</title>
</head>
<body>
<noscript>
<strong>We're sorry but <%= htmlWebpackPlugin.options.title %> doesn't work properly without JavaScript enabled.
Please enable it to continue.</strong>
</noscript>
<div id="app"></div>
<!-- built files will be auto injected -->
</body>
</html>
<template>
<router-view/>
</template>
<style lang="less">
#app {
font-family: Avenir, Helvetica, Arial, sans-serif;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
text-align: center;
color: #2c3e50;
width: 100%;
height: 100%;
}
</style>
/**
* Eric Meyer's Reset CSS v2.0 (http://meyerweb.com/eric/tools/css/reset/)
* http://cssreset.com
*/
html,
body,
div,
span,
applet,
object,
iframe,
h1,
h2,
h3,
h4,
h5,
h6,
p,
blockquote,
pre,
a,
abbr,
acronym,
address,
big,
cite,
code,
del,
dfn,
em,
img,
ins,
kbd,
q,
s,
samp,
small,
strike,
strong,
sub,
sup,
tt,
var,
b,
u,
i,
center,
dl,
dt,
dd,
ol,
ul,
li,
fieldset,
form,
label,
legend,
table,
caption,
tbody,
tfoot,
thead,
tr,
th,
td,
article,
aside,
canvas,
details,
embed,
figure,
figcaption,
footer,
header,
hgroup,
menu,
nav,
output,
ruby,
section,
summary,
time,
mark,
audio,
video {
margin: 0;
padding: 0;
border: 0;
font-size: 100%;
font: inherit;
font-weight: normal;
vertical-align: baseline;
box-sizing: border-box;
}
/* HTML5 display-role reset for older browsers */
article,
aside,
details,
figcaption,
figure,
footer,
header,
hgroup,
menu,
nav,
section {
display: block;
}
ol,
ul,
li {
list-style: none;
}
blockquote,
q {
quotes: none;
}
blockquote:before,
blockquote:after,
q:before,
q:after {
content: '';
content: none;
}
table {
border-collapse: collapse;
border-spacing: 0;
}
/* custom */
a {
color: #7e8c8d;
text-decoration: none;
-webkit-backface-visibility: hidden;
}
::-webkit-scrollbar-track-piece {
background-color: rgba(0, 0, 0, 0.2);
-webkit-border-radius: 6px;
}
::-webkit-scrollbar-thumb:vertical {
height: 5px;
background-color: rgba(125, 125, 125, 0.7);
-webkit-border-radius: 6px;
}
::-webkit-scrollbar-thumb:horizontal {
width: 5px;
background-color: rgba(125, 125, 125, 0.7);
-webkit-border-radius: 6px;
}
html,
body {
width: 100%;
font-family: "Arial", "Microsoft YaHei", "黑体", "宋体", "微软雅黑", sans-serif;
min-height: 100%;
}
body {
line-height: 1;
-webkit-text-size-adjust: none;
-webkit-tap-highlight-color: rgba(0, 0, 0, 0);
}
/*清除浮动*/
.clearfix::before {
content: " ";
display: inline-block;
clear: both;
}
.clearfix {
*zoom: 1;
}
/*隐藏*/
.dn {
display: none;
}
div {
box-sizing: border-box;
}
/* 超小设备 (手机, 600px 以下屏幕设备) */
@media only screen and (max-width: 600px) {
html {
font-size: 12px;
}
}
/* 小设备 (平板电脑和大型手机,600 像素及以上) */
@media only screen and (min-width: 600px) {
html {
font-size: 15px;
}
}
/* 中型设备(平板电脑,768 像素及以上) */
@media only screen and (min-width: 768px) {
html {
font-size: 18px;
}
}
/* 大型设备(笔记本电脑/台式机,992 像素及以上) */
@media only screen and (min-width: 992px) {
html {
font-size: 24px;
}
}
/* 超大型设备(大型笔记本电脑和台式机,1200 像素及以上) */
@media only screen and (min-width: 1200px) {
html {
font-size: 37.5px;
}
}
.tableHeaders > .cell {
font-size: .45rem;
text-align: center !important;
}
\ No newline at end of file
/**
* 格式化时间
* @param {*} value 需要处理的时间
* @param {Boolean} str 時間戳格式化,默认为false
*/
export const formatDate = (value, str = false, chinese = false) => {
let date = new Date(value)
let y = date.getFullYear()
let MM = date.getMonth() + 1
MM = MM < 10 ? ('0' + MM) : MM
let d = date.getDate()
d = d < 10 ? ('0' + d) : d
let h = date.getHours()
h = h < 10 ? ('0' + h) : h
let m = date.getMinutes()
m = m < 10 ? ('0' + m) : m
let s = date.getSeconds()
s = s < 10 ? ('0' + s) : s
if (str) {
return y + '-' + MM + '-' + d
} else {
if (chinese) {
return y + '年' + MM + '月' + d + '日 ' + h + ':' + m + ':' + s
}
return y + '-' + MM + '-' + d + ' ' + h + ':' + m + ':' + s
}
}
\ No newline at end of file
<script setup>
import {onMounted, shallowReactive, ref} from 'vue';
defineProps({
value: Number
})
const emit = defineEmits(['handleAddCount']);
</script>
<template>
<h1>{{ value }}</h1>
<button @click="emit('handleAddCount')">点击+1</button>
</template>
\ No newline at end of file
import {createApp} from 'vue';
import App from './App.vue';
import router from './router';
import ElementPlus from 'element-plus';
import 'element-plus/dist/index.css';
import './assets/css/reset.css';
const app = createApp(App);
app.use(ElementPlus);
app.use(router);
app.mount('#app');
import axios from "axios";
import router from "@/router/index.js";
import {ElMessage} from "element-plus";
/**重置message,防止重复点击重复弹出message弹框 */
let messageInstance = null;
const resetMessage = (options) => {
if (messageInstance) {
messageInstance.close();
}
messageInstance = ElMessage(options);
};
['error', 'success', 'info', 'warning'].forEach(type => {
resetMessage[type] = options => {
if (typeof options === 'string') {
options = {
message: options
}
}
options.type = type;
return resetMessage(options);
}
});
export const Message = resetMessage;
// 请求超时时间
axios.defaults.timeout = 10000;
// post请求头
axios.defaults.headers.post['Content-Type'] = 'application/x-www-form-urlencoded;charset=UTF-8';
// 请求拦截器
axios.interceptors.request.use(
config => {
// 每次发送请求之前判断是否存在token,如果存在,则统一在http请求的header都加上token,不用每次请求都手动添加了
// 即使本地存在token,也有可能token是过期的,所以在响应拦截器中要对返回状态进行判断
const mid = window.localStorage.getItem('token');
const token = mid ? mid : '';
const str = "Basic " + btoa(mid + ":" + "s00pers3cret");
token && (config.headers.Authorization = str);
// console.log(config.url)
// const chatBot = config.url.includes('/api/cc/chat/single/bot');
// if (chatBot) {
// axios.defaults.headers.post['Content-Type'] = 'application/json;charset=utf-8';
// }
// 对用户状态进行判断、记录登录、注册的时间
// if(config.url === "/ploteditor/login" || config.url === "/ploteditor/registered"){
// window.localStorage.setItem('oldTime',new Date().getTime())
// }else{
// const newTime = new Date().getTime()
// const oldTime = window.localStorage.getItem('oldTime')
// if(newTime - oldTime > 120000){
// Message({
// message: '登录过期,请重新登录',
// duration: 1000,
// forbidClick: true
// });
// setTimeout(() => {
// router.replace({
// path: "/",
// });
// }, 500);
// return Promise.error(error);
// }else{
// window.localStorage.setItem('oldTime',newTime)
// }
// }
return config;
},
error => {
return Promise.error(error);
}
);
// 响应拦截器
axios.interceptors.response.use(
response => {
// 如果返回的状态码为200,说明接口请求成功,可以正常拿到数据。否则的话抛出错误
// console.log(response);
if (response.status === 200) {
if (response.data.code !== 1) {
if (response.data.code === 20007) {
return Promise.resolve(response);
} else {
return Promise.resolve(response);
}
}
return Promise.resolve(response);
} else {
return Promise.reject(response);
}
},
// 服务器状态码不是200的情况
error => {
if (error.response.status) {
switch (error.response.status) {
case 401:
break;
case 403:
break;
case 404:
break;
default:
}
return Promise.reject(error.response);
}
}
);
/**
* get方法,对应get请求
* @param {String} url [请求的url地址]
*/
export function get(url) {
return new Promise((resolve, reject) => {
axios.get(url)
.then(res => {
resolve(res.data);
}).catch(err => {
reject(err.data);
});
});
}
/**
* post方法,对应post请求 默认Content-Type为JSON
* @param {String} url [请求的url地址]
* @param {Object} params [请求时携带的参数]
*/
export function post(url, params) {
return new Promise((resolve, reject) => {
axios.post(url, params, {headers: {'Content-Type': 'application/json'}})
.then(res => {
resolve(res.data);
}).catch(err => {
reject(err.data);
});
});
}
/**
* put方法,对应put请求
* @param {String} url [请求的url地址]
* @param {Object} params [请求时携带的参数]
*/
export function put(url, params) {
return new Promise((resolve, reject) => {
axios.put(url, params, {headers: {'Content-Type': 'application/json'}})
.then(res => {
resolve(res.data);
}).catch(err => {
reject(err.data);
});
});
}
/**
* delete方法,对应delete请求
* @param {String} url [请求的url地址]
*/
export function handleDel(url, params) {
return new Promise((resolve, reject) => {
axios.delete(url)
.then(res => {
resolve(res.data);
}).catch(err => {
reject(err.data);
});
});
}
\ No newline at end of file
// export const baseUrl = 'https://tongyong-pre.jiaoyou365.com';
// export const baseUrl = 'https://tongyong.jiaoyou365.com';
// export const baseUrl = 'http://localhost:47001';
export const baseUrl = 'http://tx-gz18.heyqiwu.cn';
// TODO 不使用https;前端,baseUrl需为远程地址,打包时记得修改
// GET https://localhost:47001/api/audit/getAuditData?searchText=&auditStatus=&pageSize=10&pageNum=1&sortMethod=
// net::ERR_SSL_PROTOCOL_ERROR
\ No newline at end of file
import {get, put, post} from './axios.js';
import {baseUrl} from './baseUrl.js';
import {handleError} from "vue";
// import {post} from "axios";
/**
* 查询数据 查询参数以URL参数形式
* @param {*} param
*/
export const getData = (param) => {
// Test
console.log(param);
try {
return get(baseUrl + '/api/audit/getAuditData?' + param);
} catch (e) {
console.log(e);
return {msg: "failed"};
}
}
export const postForKnownBots = () => {
return post(baseUrl + '/api/pregen/getKnownBots', null);
}
/**
* 修改状态 查询参数在请求体中
* @param {*} param 修改后的话语-回答数据
*/
export const putAuditData = (param) => {
return put(baseUrl + '/api/audit/putAuditData', param);
}
/**
* 删除回答 查询参数在请求体中
* @param {*} param 修改后的话语-回答数据
*/
export const postDeleteData = (param) => {
return post(baseUrl + '/api/audit/deleteReply', param);
}
/**
* 重新生成回答 查询参数在请求体中
*/
export const postGenerateOneData = (param) => {
return post(baseUrl + '/api/pregen/generateOne', param);
}
\ No newline at end of file
import {createRouter, createWebHashHistory, createWebHistory} from 'vue-router'
import IndexView from '../views/IndexView.vue'
const routes = [
{
path: '/', // '/index',
name: 'IndexView',
component: IndexView
}
]
const router = createRouter({
history: createWebHashHistory(), // “/#/”
routes: routes // 可简写为 routes
})
export default router
<script setup xmlns="http://www.w3.org/1999/html">
import {onBeforeMount, ref} from 'vue';
import {getData, postDeleteData, postForKnownBots, postGenerateOneData, putAuditData} from '../request/index.js';
// ref() 函数接受一个初始值作为参数,并返回一个包含 .value 属性的对象。这个对象是一个响应式引用,任何对 .value 的修改都会触发视图的重新渲染。
/**
* 搜索文本输入框 v-model
*/
const searchInput = ref(''); // String
/**
* 审核状态 v-model
*/
const statusComboBox = ref(null); // Short
const statusOptions = [
{value: 0, label: '未审核'},
{value: 1, label: '审核通过'},
{value: 2, label: '审核不通过'}
];
/**
* 排序状态 v-model
*/
const sortComboBox = ref('');
const sortOptions = [
{value: '', label: '无'},
{value: 'asc', label: '升序'},
{value: 'desc', label: '降序'}
];
/**
* 所属Bot v-model
*/
const ofBotComboBox = ref(''); // String
let knownBotsList = ref([]); // select from intention
/**
* 所用模型 v-model
*/
const ofModelComboBox = ref(''); // String
const supportedModelList = [
"讯飞星火",
"MiniMax",
"文心一言"
];
/**
* refreshData() 查询到的数据
*/
let dialogData = ref({
// 当前页面号
pageNum: 1,
// 当前页面大小
pageSize: 10,
// 当前数据总条数
total: 0,
pages: undefined,
records: []
});
/**
* 当查询条件、审核状态、页面号等变更时,重新查询数据,在页面上体现更改
*/
async function refreshData() {
// Test
console.log("refreshData() called");
const param = `searchText=${searchInput.value}`
+ `&auditStatus=${statusComboBox.value}`
+ `&pageSize=${dialogData.value.pageSize}`
+ `&pageNum=${dialogData.value.pageNum}`
+ `&sortMethod=${sortComboBox.value}`
+ `&ofBot=${ofBotComboBox.value}`
+ `&ofModel=${ofModelComboBox.value}`
try {
const {data} = await getData(param);
// Test
console.log("getData() called");
// auditStatus -> statusName
for (let i = 0; i < data.records.length; i++) {
if (data.records[i].auditStatus === 0) {
data.records[i].statusName = '未审核';
} else if (data.records[i].auditStatus === 1) {
data.records[i].statusName = '通过';
} else if (data.records[i].auditStatus === 2) {
data.records[i].statusName = '不通过';
}
// data.records[i].createTime = formatDate(data.records[i].gmtCreate);
// data.records[i].updateTime = formatDate(data.records[i].gmtModified);
}
dialogData.value = data;
} catch (e) {
console.log(e);
}
}
async function getKnownBots() {
// Test
console.log("getKnownBots() called");
try {
knownBotsList.value = await postForKnownBots();
} catch (e) {
console.log("getKnownBots() failed,error: ", e);
}
}
/**
* 初始化 - 刷新页面数据、查询已知bot列表
*/
onBeforeMount(async () => {
await refreshData();
await getKnownBots();
});
/**
* 查询/重置 按钮点击事件
*/
function handleQueryData(value) {
if (value) { // 点击的是查询按钮
refreshData();
} else { // 点击的是重置按钮
searchInput.value = '';
statusComboBox.value = '';
sortComboBox.value = '';
}
}
/**
* 审核通过/不通过 按钮点击事件
* @param value 需向后端传递{optId, auditStatus}
* @param type param.auditStatus = type ? 1 : 2; // 通过/不通过
*/
async function handleAudit(value, type) {
const param = { // AuditDataDAO
optId: value.optId,
auditStatus: value.auditStatus
}
param.auditStatus = type ? 1 : 2; // 通过/不通过
const res = await putAuditData(param);
if (res.code === 1) {
// Test
console.log("putAuditData() success");
await refreshData();
} else {
console.log("putAuditData() failed");
}
}
/**
* 重新生成 按钮点击事件
* @param row 需向后端传递{userWords, optId, roleId, fromModel}
*/
async function handleRegenerate(row) {
const generateOneParam = { // AuditDataDAO
userWords: row.userWords,
optId: row.optId,
roleId: row.roleId,
fromModel: row.fromModel // 每句回答仍用原有的模型进行生成
};
const res = await postGenerateOneData(generateOneParam);
if (res.code === 1) {
// Test
console.log("handleRegenerate() success");
await refreshData();
} else {
console.log("handleRegenerate() failed");
}
}
/**
* 提交人工修改 按钮点击事件
* @param scope 需向后端传递{optId, auditStatus}
*/
async function handleManualModify(scope) {
const manualModifyParam = { // AuditDataDAO
optId: scope.row.optId,
auditStatus: 1, // 人工修改的回复默认通过
reply: document.getElementById('replyInput' + scope.$index).value
};
console.log(manualModifyParam);
// console.log("scope.row.$index: ", scope.row.$index); // undefined
const res = await putAuditData(manualModifyParam);
if (res.code === 1) {
// Test
console.log("handleRegenerate() success");
await refreshData();
} else {
console.log("handleRegenerate() failed");
}
}
/**
* 删除回答 按钮点击事件
* @param row 需向后端传递{optId}
*/
async function handleDelete(row) {
const handleParam = { // AuditDataDAO
optId: row.optId
};
console.log(handleParam);
const res = await postDeleteData(handleParam);
if (res.code === 1) {
// Test
console.log("handleDelete() success");
await refreshData();
} else {
console.log("handleDelete() failed");
}
}
/**
* 分页器 页面大小改变事件
*/
const handlePageSizeChange = (val) => {
dialogData.value.pageSize = val;
refreshData();
}
/**
* 分页器 当前页面改变事件
*/
const handleCurrentPageChange = (val) => {
dialogData.value.pageNum = val;
refreshData();
}
</script>
<template>
<!-- 查询条件 -->
<div class="queryCriteria">
<el-row>
<el-col :span="7">
<span>按角色ID和意图ID排序:</span>
<el-select v-model="sortComboBox" placeholder="请选择" clearable>
<el-option v-for="item in sortOptions" :key="item.value" :label="item.label" :value="item.value">
</el-option>
</el-select>
</el-col>
<el-col :span="6">
<span>搜索:</span>
<el-input v-model="searchInput" style="width: 7.5rem;" placeholder="用户话语、角色名、意图id"/>
</el-col>
<el-col :span="6">
<span>审核状态:</span>
<el-select v-model="statusComboBox" placeholder="请选择" clearable>
<el-option v-for="item in statusOptions" :key="item.value" :label="item.label" :value="item.value">
</el-option>
</el-select>
</el-col>
<el-col :span="5">
<el-button @click="handleQueryData(false)">重置</el-button>
<el-button type="primary" @click="handleQueryData(true)">查询</el-button>
</el-col>
<el-col :span="8">
<span>所属模版Bot:</span>
<el-select v-model="ofBotComboBox" placeholder="请选择" clearable>
<el-option v-for="item in knownBotsList" :key="item" :label="item" :value="item">
</el-option>
</el-select>
</el-col>
<el-col :span="8">
<span>所用生成模型:</span>
<el-select v-model="ofModelComboBox" placeholder="请选择" clearable>
<el-option v-for="item in supportedModelList" :key="item" :label="item" :value="item">
</el-option>
</el-select>
</el-col>
</el-row>
</div>
<!-- 数据渲染 -->
<div class="container">
<p>审核记录</p>
<div class="content">
<el-table :data="dialogData.records" border stripe style="width: 100%" header-cell-class-name="tableHeaders">
<!-- 根据el-table-column的prop属性值来查找提供给el-table :data的列表中每个元素的属性 -->
<el-table-column prop="optId" label="回复ID" width="60" align="center"></el-table-column>
<el-table-column prop="intentionId" label="意图ID" width="60" align="center"></el-table-column>
<el-table-column prop="roleId" label="角色ID" width="60" align="center"></el-table-column>
<el-table-column prop="roleName" label="角色名" width="80" align="center"></el-table-column>
<el-table-column prop="userWords" label="用户话语" width="270" align="center"></el-table-column>
<el-table-column prop="reply" label="模型回复" align="center" width="340">
<template #default="scope">
<div style="display: flex;align-items: center;justify-content: center;">
<input type="text" :id="'replyInput' + scope.$index" :value="scope.row.reply"
style="width: 100%; height: 100%; margin: 0; padding: 0;">
</div> <!-- statusName 在 refreshData 中设定 -->
</template>
</el-table-column>
<el-table-column prop="fromModel" label="所用模型" width="60" align="center"></el-table-column>
<el-table-column label="审核状态" width="100" align="center"> <!-- prop: auditStatus -->
<template #default="scope">
<div style="display: flex;align-items: center;justify-content: center;">
<el-tag :type="(scope.row.auditStatus === 0) ? 'info' : ((scope.row.auditStatus === 1) ? 'success' : 'danger')">
{{scope.row.statusName}}
</el-tag>
</div> <!-- statusName 在 refreshData 中设定 -->
</template>
</el-table-column>
<el-table-column label="操作"> <!-- width="380" -->
<template #default="scope">
<div style="display: flex;align-items: center;justify-content: center;">
<el-button type="success" @click="handleAudit(scope.row, true)">通过</el-button>
<el-button type="danger" @click="handleAudit(scope.row, false)">不通过</el-button>
<el-button type="primary" @click="handleManualModify(scope)">提交人工修改</el-button> <!-- 自动通过 -->
<el-button type="primary" @click="handleRegenerate(scope.row)">重新生成</el-button>
<el-button type="danger" @click="handleDelete(scope.row)">删除</el-button>
</div>
</template>
</el-table-column>
</el-table>
</div>
</div>
<!-- 分页 -->
<div class="pagination">
<el-pagination style="justify-content: center;" v-model:current-page="dialogData.pageNum"
v-model:page-size="dialogData.pageSize" :page-sizes="[10, 20, 50]" :background="true"
layout="sizes, prev, pager, next, jumper" :total="dialogData.total"
@size-change="handlePageSizeChange"
@current-change="handleCurrentPageChange"/>
</div>
</template>
<style scoped lang="less">
.queryCriteria {
margin: 1rem auto 0;
padding: 0 1rem;
> div {
font-size: .4rem;
text-align: left;
line-height: 1rem;
height: 1rem;
}
}
.container {
margin: 1rem auto 0;
padding: 0 .5rem;
> p {
color: #acacac;
font-size: .7rem;
text-align: left;
}
> .content {
line-height: 1rem;
color: #696969;
font-size: .6rem;
margin-top: .2rem;
border: 1px solid #9e9e9e;
> .list {
color: #000;
line-height: .8rem;
font-size: .5rem;
}
}
}
.pagination {
margin: 1rem auto;
}
</style>
\ No newline at end of file
const { defineConfig } = require('@vue/cli-service');
module.exports = defineConfig({
transpileDependencies: true,
publicPath:'./',
devServer: {
//代理axios
// proxy: 'http://localhost:9000',
//vue自己启动的端口
port: 47002
}
});
// const proxy = require('http-proxy-middleware');
// // 服务器会将任何未知请求 (没有匹配到静态文件的请求) 代理到http://localhost:9000上
# 对话模型及审核
# 对话模型及审核
**测试环境URL**: https://tongyong-pre.jiaoyou365.com
**生产环境URL**: https://tongyong.jiaoyou365.com
##查询
**METHOD**: GET
**path**: /api/chat/audit/info
## 公共请求实例
```json
curl --location 'https://******/api/chat/audit/info?searchText=null&auditStatus=null&pageSize=1&pageNum=10'
```
## 公共响应实例
```json
{
"code": 1,
"msg": "成功",
"data": {
"pages": 19,
"pageNum": 10,
"pageSize": 1,
"total": 19,
"records": [
{
"id": 10,
"workName": "机器男友",
"plotInfo": "【罗伯特是个高度拟人化的机器人,罗伯特的设定是你的温柔体贴的男友,在你起床的时候】【罗伯特对你说:】你起床了,昨晚睡得怎么样?【你回复罗伯特:】好累呀【罗伯特要说服你去散步,以罗伯特的口吻简短回复这句话】",
"answer": "你现在感觉如何?要不要去散步?",
"modelChannel": "minimax",
"auditStatus": 1, // 0未审核,1审核通过,2审核不通过
"gmtCreate": "2023-04-11T12:23:01.700+00:00",
"gmtModified": "2023-04-11T12:23:01.700+00:00"
},
{ ... }
]
}
}
```
##修改
**METHOD**: PUT
**path**: /api/chat/audit/info
## 公共请求实例
```json
curl --location --request PUT 'https://127.0.0.1:48088/api/chat/audit/info' \
--header 'Content-Type: application/json' \
--data '{
"answer":"散步是一种很好的恢复精力的方式。让我们去呼吸新鲜空气,享受户外的美好吧!",
"auditStatus":1,
"id":1,
"plotInfo":"【罗伯特是个高度拟人化的机器人,罗伯特的设定是你的温柔体贴的男友,在你起床的时候】【罗伯特对你说:】你起床了,昨晚睡得怎么样?【你回复罗伯特:】好累呀【罗伯特要说服你去散步,以罗伯特的口吻简短回复这句话】",
"workName":"机器男友"
}'
```
## 公共响应实例
```json
{
"code": 1,
"msg": "成功",
"data": {
"pages": 19,
"pageNum": 10,
"pageSize": 1,
"total": 19,
"records": [
{
"id": 10,
"workName": "机器男友",
"plotInfo": "【罗伯特是个高度拟人化的机器人,罗伯特的设定是你的温柔体贴的男友,在你起床的时候】【罗伯特对你说:】你起床了,昨晚睡得怎么样?【你回复罗伯特:】好累呀【罗伯特要说服你去散步,以罗伯特的口吻简短回复这句话】",
"answer": "你现在感觉如何?要不要去散步?",
"modelChannel": "minimax",
"auditStatus": 1,
"gmtCreate": "2023-04-11T12:23:01.700+00:00",
"gmtModified": "2023-04-11T12:23:01.700+00:00"
},
{ ... }
]
}
}
```
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment