mirror of
https://github.com/labring/FastGPT.git
synced 2025-07-21 03:35:36 +00:00
fix 4.9.6 (#4631)
* fix debug quote list * delete next text node match * fix extract default boolean value * export latest 100 chat items * fix quote item ui * doc * fix doc
This commit is contained in:
@@ -21,4 +21,8 @@ weight: 793
|
||||
2. 使用记录仪表盘,无法获取指定成员的使用统计。
|
||||
3. 仪表盘接口,因未考虑时区问题,统计异常。
|
||||
4. LLM 模型测试接口,无法测试未启用的 LLM。同时修复,模型测试接口会把模型自定义请求地址去除问题。
|
||||
5. 导出对话记录,限制单条对话记录消息上限 1000 组,避免导出失败。
|
||||
6. 工作流变量下一段文本仍是工作流变量,不触发渲染。
|
||||
7. 调试知识库检索模块,提示无权操作知识库。
|
||||
8. 文本内容提取节点,默认值赋值逻辑。
|
||||
|
||||
|
@@ -103,7 +103,7 @@ export async function dispatchContentExtract(props: Props): Promise<Response> {
|
||||
|
||||
// auto fill required fields
|
||||
extractKeys.forEach((item) => {
|
||||
if (item.required && !arg[item.key]) {
|
||||
if (item.required && arg[item.key] === undefined) {
|
||||
arg[item.key] = item.defaultValue || '';
|
||||
}
|
||||
});
|
||||
|
@@ -102,12 +102,6 @@ export function registerLexicalTextEntity<T extends TextNode | VariableLabelNode
|
||||
return;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
const nextMatch = getMatch(nextText);
|
||||
|
||||
if (nextMatch !== null && nextMatch.start === 0) {
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
if (match === null) {
|
||||
|
@@ -86,7 +86,7 @@
|
||||
"llm_use_vision_tip": "After clicking on the model selection, you can see whether the model supports image recognition and the ability to control whether to start image recognition. \nAfter starting image recognition, the model will read the image content in the file link, and if the user question is less than 500 words, it will automatically parse the image in the user question.",
|
||||
"logs_chat_user": "user",
|
||||
"logs_empty": "No logs yet~",
|
||||
"logs_export_confirm_tip": "There are a total of {{total}} dialogue records, confirm the export?",
|
||||
"logs_export_confirm_tip": "There are currently {{total}} conversation records, and each conversation can export up to 100 latest messages. \nConfirm export?",
|
||||
"logs_export_title": "Time, source, user, contact, title, total number of messages, user good feedback, user bad feedback, custom feedback, labeled answers, conversation details",
|
||||
"logs_message_total": "Total Messages",
|
||||
"logs_source": "source",
|
||||
|
@@ -90,7 +90,7 @@
|
||||
"llm_use_vision_tip": "点击模型选择后,可以看到模型是否支持图片识别以及控制是否启动图片识别的能力。启动图片识别后,模型会读取文件链接里图片内容,并且如果用户问题少于 500 字,会自动解析用户问题中的图片。",
|
||||
"logs_chat_user": "使用者",
|
||||
"logs_empty": "还没有日志噢~",
|
||||
"logs_export_confirm_tip": "当前共 {{total}} 条对话记录,确认导出?",
|
||||
"logs_export_confirm_tip": "当前共有 {{total}} 条对话记录,每条对话最多可导出最新 100 条消息。确认导出?",
|
||||
"logs_export_title": "时间,来源,使用者,联系方式,标题,消息总数,用户赞同反馈,用户反对反馈,自定义反馈,标注答案,对话详情",
|
||||
"logs_message_total": "消息总数",
|
||||
"logs_source": "来源",
|
||||
|
@@ -86,7 +86,7 @@
|
||||
"llm_use_vision_tip": "點選模型選擇後,可以看到模型是否支援圖片辨識以及控制是否啟用圖片辨識的功能。啟用圖片辨識後,模型會讀取檔案連結中的圖片內容,並且如果使用者問題少於 500 字,會自動解析使用者問題中的圖片。",
|
||||
"logs_chat_user": "使用者",
|
||||
"logs_empty": "還沒有紀錄喔~",
|
||||
"logs_export_confirm_tip": "目前共 {{total}} 條對話記錄,確認匯出?",
|
||||
"logs_export_confirm_tip": "當前共有 {{total}} 條對話記錄,每條對話最多可導出最新 100 條消息。\n確認導出?",
|
||||
"logs_export_title": "時間,來源,使用者,聯絡方式,標題,訊息總數,使用者贊同回饋,使用者反對回饋,自定義回饋,標註答案,對話詳細資訊",
|
||||
"logs_message_total": "訊息總數",
|
||||
"logs_source": "來源",
|
||||
|
@@ -44,27 +44,30 @@ const QuoteList = React.memo(function QuoteList({
|
||||
}),
|
||||
{
|
||||
refreshDeps: [rawSearch, RawSourceBoxProps.chatId],
|
||||
manual: false
|
||||
manual: !chatItemDataId
|
||||
}
|
||||
);
|
||||
|
||||
const formatedDataList = useMemo(() => {
|
||||
return rawSearch
|
||||
.map((item) => {
|
||||
const currentFilterItem = quoteList?.find((res) => res._id === item.id);
|
||||
|
||||
const processedData = rawSearch.map((item) => {
|
||||
if (chatItemDataId && quoteList) {
|
||||
const currentFilterItem = quoteList.find((res) => res._id === item.id);
|
||||
return {
|
||||
...item,
|
||||
q: currentFilterItem?.q || '',
|
||||
a: currentFilterItem?.a || ''
|
||||
};
|
||||
})
|
||||
.sort((a, b) => {
|
||||
const aScore = formatScore(a.score);
|
||||
const bScore = formatScore(b.score);
|
||||
return (bScore.primaryScore?.value || 0) - (aScore.primaryScore?.value || 0);
|
||||
});
|
||||
}, [quoteList, rawSearch]);
|
||||
}
|
||||
|
||||
return item;
|
||||
});
|
||||
|
||||
return processedData.sort((a, b) => {
|
||||
const aScore = formatScore(a.score);
|
||||
const bScore = formatScore(b.score);
|
||||
return (bScore.primaryScore?.value || 0) - (aScore.primaryScore?.value || 0);
|
||||
});
|
||||
}, [rawSearch, quoteList, chatItemDataId]);
|
||||
|
||||
return (
|
||||
<>
|
||||
|
@@ -64,13 +64,15 @@ const QuoteItem = ({
|
||||
fontSize={'10px'}
|
||||
h={'full'}
|
||||
alignItems={'center'}
|
||||
mr={1}
|
||||
flexShrink={0}
|
||||
>
|
||||
{index + 1}
|
||||
</Flex>
|
||||
<Flex px={1.5}>
|
||||
<MyIcon name={icon as any} mr={1} flexShrink={0} w={'12px'} />
|
||||
<Box
|
||||
className="textEllipsis3"
|
||||
className={'textEllipsis'}
|
||||
wordBreak={'break-all'}
|
||||
flex={'1 0 0'}
|
||||
fontSize={'mini'}
|
||||
@@ -81,7 +83,7 @@ const QuoteItem = ({
|
||||
</Flex>
|
||||
</Box>
|
||||
{score && !isDeleted && (
|
||||
<Box className="hover-data" visibility={'hidden'}>
|
||||
<Box className="hover-data" visibility={'hidden'} flexShrink={0}>
|
||||
<ScoreTag {...score} />
|
||||
</Box>
|
||||
)}
|
||||
|
@@ -67,7 +67,6 @@ async function handler(req: ApiRequestProps<ExportChatLogsBody, {}>, res: NextAp
|
||||
}
|
||||
}
|
||||
]);
|
||||
console.log(teamMemberWithContact);
|
||||
|
||||
const where = {
|
||||
teamId: new Types.ObjectId(teamId),
|
||||
@@ -161,7 +160,7 @@ async function handler(req: ApiRequestProps<ExportChatLogsBody, {}>, res: NextAp
|
||||
},
|
||||
chatDetails: {
|
||||
$map: {
|
||||
input: '$chatitems',
|
||||
input: { $slice: ['$chatitems', -1000] },
|
||||
as: 'item',
|
||||
in: {
|
||||
id: '$$item._id',
|
||||
|
Reference in New Issue
Block a user