feature: add data-evaluation

* feature: add evaluation task management function

* feature: add evaluation task detail page

* fix: delete duplicate definition for table t_model_config

* refactor: rename package synthesis to ratio

* refactor: add eval file table and  refactor related code

* fix: calling large models in parallel during evaluation
This commit is contained in:
hefanli
2025-12-04 09:23:54 +08:00
committed by GitHub
parent 265e284fb8
commit 1d19cd3a62
52 changed files with 2882 additions and 1244 deletions

View File

@@ -0,0 +1,42 @@
import React from 'react';
import { Button, message, Modal } from 'antd';
interface PreviewPromptModalProps {
previewVisible: boolean;
onCancel: () => void;
evaluationPrompt: string;
}
const PreviewPromptModal: React.FC<PreviewPromptModalProps> = ({ previewVisible, onCancel, evaluationPrompt }) => {
return (
<Modal
title="评估提示词预览"
open={previewVisible}
onCancel={onCancel}
footer={[
<Button key="copy" onClick={() => {
navigator.clipboard.writeText(evaluationPrompt).then();
message.success('已复制到剪贴板');
}}>
</Button>,
<Button key="close" type="primary" onClick={onCancel}>
</Button>
]}
width={800}
>
<div style={{
background: '#f5f5f5',
padding: '16px',
borderRadius: '4px',
whiteSpace: 'pre-wrap',
fontFamily: 'monospace'
}}>
{evaluationPrompt}
</div>
</Modal>
)
}
export default PreviewPromptModal;