feat(data-management): 添加数据集相似度推荐功能

- 在DatasetApplicationService中实现getSimilarDatasets方法,支持基于标签匹配的相似数据集推荐
- 新增normalizeSimilarLimit、normalizeTagNames、countSharedTags等辅助方法用于相似度计算
- 在DatasetRepository接口及其实现类中添加findSimilarByTags方法,支持数据库层面的标签匹配查询
- 在DatasetController中暴露/similar REST API端点,支持按需获取相似数据集
- 在前端Overview组件中展示相似数据集表格,包含名称、标签、类型、文件数和更新时间等信息
- 在DatasetDetail页面集成相似数据集获取逻辑,限制默认返回数量为4条
- 移除KnowledgeItem中的冗余title字段,统一使用其他标识信息
- 优化知识管理相关组件中的标题显示逻辑,移除硬编码标题值
This commit is contained in:
2026-01-30 11:43:44 +08:00
parent c51cd2b6e4
commit c221666e67
12 changed files with 481 additions and 98 deletions

View File

@@ -92,7 +92,6 @@ export type KnowledgeSetView = {
export type KnowledgeItemView = {
id: string;
setId: string;
title: string;
content: string;
contentType: KnowledgeContentType;
status: KnowledgeStatusMeta | null;
@@ -140,7 +139,6 @@ export function mapKnowledgeItem(data: KnowledgeItem): KnowledgeItemView {
return {
id: data.id,
setId: data.setId,
title: data.title,
content: data.content,
contentType: data.contentType,
status: knowledgeStatusMap[data.status] ?? null,