wujingjing
2025-01-06 b9fa2c53e0fb86718d976ee825102e43f3825a26
src/api/ai/chat.ts
@@ -1,4 +1,4 @@
import request from '/@/utils/request';
import request, { ExtraConfig } from '/@/utils/request';
export interface RecordSetValues {
   names: string[];
   values: Array<Array<any>>;
@@ -37,7 +37,16 @@
   });
};
export const reportHistoryProblem = async (params, req: any = request) => {
   return req({
      url: 'history/report_history_problem',
      method: 'POST',
      data: params,
      headers: {
         'Content-Type': 'application/x-www-form-urlencoded',
      },
   });
};
/**
 * @summary 设置历史对话状态(未设置:NULL,顶1,踩0
 */
@@ -79,4 +88,57 @@
         'Content-Type': 'application/x-www-form-urlencoded',
      },
   });
};
};
/**
 * 曲线查询
 * @param params
 * @param req
 * @returns
 */
export const curveQuery = (params, req: any = request) => {
   return req({
      url: 'chat/chat_supervisor_json',
      method: 'POST',
      data: params,
      headers: {
         'Content-Type': 'application/x-www-form-urlencoded',
      },
   });
};
/**
 * @description 查询对话日志列表
 * @param {FormData} params
 **/
export const getChatHistoryListByPost = (
   params,
   extraData: ExtraConfig = {}
) =>
   request({
      url: `/admin/chat/get_chat_history_list`,
      method: 'post',
      params: {},
      data: params,
      ...extraData,
   });
/**
 * @description 查询对话日志回答
 * @param {FormData} params
 **/
export const getChatHistoryAnswerByPost = (
   params,
   extraData: ExtraConfig = {}
) =>
   request({
      url: `/admin/chat/get_chat_history_answer`,
      method: 'post',
      params: {},
      data: params,
      ...extraData,
   });