diff --git a/src/api/apiType.ts b/src/api/apiType.ts index f1a0dacaf6973d05ab885bcf28eac4efe6777b1d..8fc4a640b5695a3deba6b2ab541525f0706ea686 100644 --- a/src/api/apiType.ts +++ b/src/api/apiType.ts @@ -23,8 +23,8 @@ export interface QueryKbRequest { created_time_order?: string; document_count_order?: string; name?: string; - page_number: number; - page_size: number; + page: number; + pageSize: number; [property: string]: any; } @@ -43,8 +43,8 @@ export interface DocListRequest { export interface DocRenameRequest { chunkSize?: number; docTypeId?: string; - docId: string; - docName: string; + docId?: string; + docName?: string; [property: string]: any; } diff --git a/src/api/dataSet.ts b/src/api/dataSet.ts index 64abfa11c8e2eecc1565a8222d7c40c115a333ab..d667da7ee91822cd36df53b97d14735234a198bc 100644 --- a/src/api/dataSet.ts +++ b/src/api/dataSet.ts @@ -1,4 +1,5 @@ import request from '@/utils/request'; +import qs from 'qs'; class dataSetAPI { // 获取数据集管理数据 @@ -6,7 +7,7 @@ class dataSetAPI { return request({ url: `/dataset/list`, method: 'post', - data: data, + data, }); } @@ -15,7 +16,7 @@ class dataSetAPI { return request({ url: `/dataset`, method: 'post', - data: data, + data, }); } @@ -46,7 +47,16 @@ class dataSetAPI { return request({ url: `/dataset/data`, method: 'post', - data: data, + data, + }); + } + /**更新数据集内的详情数据 */ + static updateDataSetInfo(params: { dataId: string }, data: { answer: string; question: string }) { + return request({ + url: `/dataset/data`, + method: 'put', + params, + data, }); } /**删除数据集内的问答数据 */ @@ -54,7 +64,7 @@ class dataSetAPI { return request({ url: `/dataset/data`, method: 'delete', - data: data, + data, }); } @@ -103,11 +113,18 @@ class dataSetAPI { } /** 导出数据集*/ - static exportDataSet(datasetIds: string[]) { + static saveDataSet(datasetIds: string[], options: any) { return request({ url: `/dataset/export`, method: 'post', - params: datasetIds, + params: { datasetIds }, + paramsSerializer: (params) => qs.stringify(params, { indices: false }), + onUploadProgress(e) { + const rate = Math.floor((e.loaded / (e.total as number)) * 100); + if (rate < 100) { + options.onProgress(rate); + } + }, }); } diff --git a/src/api/kfApp.ts b/src/api/kfApp.ts index 3bca04f5dc42142c358aa0ab504212906c1edfab..ed85159d1f48b6e7568dc8de06bdda2586de6bb7 100644 --- a/src/api/kfApp.ts +++ b/src/api/kfApp.ts @@ -20,15 +20,6 @@ class KfAppAPI { }); } - /** 是否启用文件*/ - static switchLibraryFile(data: { enabled: boolean; id: string }) { - return request({ - url: `/doc/switch`, - method: 'post', - data: data, - }); - } - /** 是否删除文件*/ static delLibraryFile(data: string[]) { return request({ diff --git a/src/styles/evaluate.scss b/src/styles/evaluate.scss index 56ae0e970fcd1ed08fc26b0c19a3d435fba13621..ff550386f6630242deace67f0f89e829d9cbc81f 100644 --- a/src/styles/evaluate.scss +++ b/src/styles/evaluate.scss @@ -18,7 +18,7 @@ justify-content: space-between; .search-input { - width: 300px; + width: 356px; font-size: 12px; } @@ -239,8 +239,26 @@ } } } -.el-select__popper .el-select-dropdown__list{ +.el-select__popper .el-select-dropdown__list{ + background-color: white; + .el-select-dropdown__item{ + display: flex; + align-items: center; + gap: 4px; + & span{ + max-width: 330px; + overflow: hidden; + text-overflow: ellipsis; + white-space: nowrap; + } + } .is-hovering{ + background-color: rgb(122,165,225); + } + .is-selected{ background-color: rgb(99,149,253); + span{ + color: white !important; + } } } \ No newline at end of file diff --git a/src/styles/knowledgeFile.scss b/src/styles/knowledgeFile.scss index ab718c377f468f21b9a1fd7b49085167c20f6e82..55de34d9a3b35f032034d1b9eab135e7f0375e50 100644 --- a/src/styles/knowledgeFile.scss +++ b/src/styles/knowledgeFile.scss @@ -119,6 +119,7 @@ } .kf-container-table-ops-right{ width: 356px; + font-size: 12px; } } @@ -353,7 +354,6 @@ .el-select-dropdown__item.is-hovering { color: #fff; - background: #07f !important; width: 399px; } @@ -573,7 +573,6 @@ .el-select-dropdown__item.is-hovering { color: #fff !important; - background: #07f; width: 319px; } } diff --git a/src/styles/knowledgeForm.scss b/src/styles/knowledgeForm.scss index 1af3e3142f847d31e6089827afa71ba571f0a67d..f6da94333e7b46c87c146ab1ff5cc0d86c762726 100644 --- a/src/styles/knowledgeForm.scss +++ b/src/styles/knowledgeForm.scss @@ -31,7 +31,6 @@ box-sizing: border-box; width: 100% !important; background: #fefefe !important; - border: 1px solid #07f !important; .el-select-dropdown { width: 100% !important; @@ -113,7 +112,6 @@ .el-select-dropdown__item.is-hovering { color: #fff !important; - background: #07f; } .el-form-item__content { @@ -234,7 +232,6 @@ .el-select-dropdown__item.is-hovering { color: #fff; - background: #07f !important; } } @@ -279,7 +276,6 @@ .el-select-dropdown__item.is-hovering { color: #fff !important; - background: #07f; width: 319px; } diff --git a/src/styles/reset.scss b/src/styles/reset.scss index 343469a0afca43aa8ffc73ffe3608ec71d5adf6a..193d35414b2e47be5c415c96cfaadfc70a084ecb 100644 --- a/src/styles/reset.scss +++ b/src/styles/reset.scss @@ -377,6 +377,12 @@ div:focus { .caret-wrapper { margin-left: 0 !important; transform: translateX(-3px); + .sort-up-active{ + border-bottom-color:var(--el-color-primary) !important ; + } + .sort-down-active{ + border-top-color:var(--el-color-primary) !important ; + } } .removeIsTrans { diff --git a/src/styles/uploadProgress.scss b/src/styles/uploadProgress.scss index f0edf1a4864dd297cce80398d01bad65a3f65100..48c66491bb4bff841a73a9da13c0df7a82d69bf9 100644 --- a/src/styles/uploadProgress.scss +++ b/src/styles/uploadProgress.scss @@ -2,7 +2,7 @@ position: fixed; right: 48px; bottom: 48px; - z-index: 9999; + z-index: 9; width: 400px; overflow: hidden; background-color: var(--o-bg-color-base); diff --git a/src/views/dataSet/craeteEvaluate.vue b/src/views/dataSet/craeteEvaluate.vue index 22756969670a418636eb895be08a67462a714101..63e8ce5c6798a6895081128d2931dc4266d7eea8 100644 --- a/src/views/dataSet/craeteEvaluate.vue +++ b/src/views/dataSet/craeteEvaluate.vue @@ -6,6 +6,7 @@ width="544" v-if="props.dialogEvaluateVisible" @close="handleCancelVisible" + align-center > @@ -21,6 +22,10 @@ + () const formLabelWidth = '100px'; const parserMethodOptions = ref([]) -const llmOptions = ref([ - { - label: 'deepSeek', - value: 'deepSeek', - icon:'src/assets/images/file_size.svg' - } -]) +const llmOptions = ref>([]); const form = reactive({ name: '', @@ -106,6 +109,9 @@ const rules = reactive({ method: [ { required: true, message: t('model.pleasePlace'), trigger: 'change' }, ], + topk: [ + { required: true, message: t('model.pleasePlace'), trigger: 'change' }, + ], }) const handleSubmit = async (formEl: FormInstance | undefined) => { @@ -147,4 +153,4 @@ onMounted(() => { }) }) - + \ No newline at end of file diff --git a/src/views/dataSet/index.vue b/src/views/dataSet/index.vue index d02fdea715e817401ea2fd0a68a839e4f4ae9ff7..74dfd3da006d748b3300d82d9737a7c8d5de9ab6 100644 --- a/src/views/dataSet/index.vue +++ b/src/views/dataSet/index.vue @@ -1,7 +1,8 @@