diff --git a/frontend/src/components/Step2EnvSetup.vue b/frontend/src/components/Step2EnvSetup.vue index 0bb0a36..c2ede93 100644 --- a/frontend/src/components/Step2EnvSetup.vue +++ b/frontend/src/components/Step2EnvSetup.vue @@ -60,31 +60,20 @@

从知识图谱读取实体,使用 LLM 为每个实体生成详细的 Agent 人设与行为配置

- - -
-
-
-
-
- {{ currentStage }} - {{ progressMessage }} -
-
{{ profiles.length }} - Agent 人设 -
-
- {{ entityTypes.length }} - 实体类型 + 当前Agent数
{{ expectedTotal || '-' }} - 预期总数 + 预期Agent总数 +
+
+ {{ totalTopicsCount }} + 现实种子当前关联话题数
@@ -104,10 +93,23 @@ @click="selectProfile(profile)" >
- {{ profile.user_name || profile.username || `Agent ${idx}` }} - {{ profile.entity_type || 'Unknown' }} + {{ profile.realname || 'Unknown' }} + @{{ profile.username || `agent_${idx}` }} +
+
+ {{ profile.profession || '未知职业' }} +
+

{{ profile.bio || '暂无简介' }}

+
+ {{ topic }} + + +{{ profile.interested_topics.length - 4 }} +
-

{{ truncateBio(profile.bio || profile.description || '暂无简介') }}

@@ -298,6 +300,13 @@ const displayProfiles = computed(() => { return profiles.value.slice(0, 6) }) +// 计算所有人设的关联话题总数 +const totalTopicsCount = computed(() => { + return profiles.value.reduce((sum, p) => { + return sum + (p.interested_topics?.length || 0) + }, 0) +}) + // Methods const addLog = (msg) => { emit('add-log', msg) @@ -672,82 +681,34 @@ onUnmounted(() => { font-size: 12px; } -/* Progress Section */ -.progress-section { - margin: 16px 0; -} - -.progress-bar { - height: 6px; - background: #E5E5E5; - border-radius: 3px; - overflow: hidden; - margin-bottom: 12px; -} - -.progress-fill { - height: 100%; - background: linear-gradient(90deg, #FF5722, #FF9800); - border-radius: 3px; - transition: width 0.3s ease; -} - -.progress-info { - display: flex; - justify-content: space-between; - align-items: center; -} - -.progress-stage { - font-family: 'JetBrains Mono', monospace; - font-size: 11px; - font-weight: 600; - color: #FF5722; - text-transform: uppercase; -} - -.progress-detail { - font-size: 12px; - color: #666; - max-width: 60%; - text-align: right; - white-space: nowrap; - overflow: hidden; - text-overflow: ellipsis; -} - /* Stats Grid */ .stats-grid { display: grid; - grid-template-columns: repeat(3, 1fr); - gap: 8px; - margin-top: 16px; + grid-template-columns: 1fr 1fr 1fr; + gap: 12px; + background: #F9F9F9; + padding: 16px; + border-radius: 6px; } .stat-card { - background: #FAFAFA; - border: 1px solid #E5E5E5; - border-radius: 6px; - padding: 12px 8px; text-align: center; - min-width: 0; } .stat-value { display: block; - font-family: 'JetBrains Mono', monospace; - font-size: 18px; + font-size: 20px; font-weight: 700; - color: #333; - overflow: hidden; - text-overflow: ellipsis; + color: #000; + font-family: 'JetBrains Mono', monospace; } .stat-label { - display: block; - font-size: 11px; + font-size: 9px; color: #999; + text-transform: uppercase; margin-top: 4px; + display: block; } /* Profiles Preview */ @@ -781,11 +742,11 @@ onUnmounted(() => { } .profiles-list { - display: grid; - grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); + display: flex; + flex-direction: column; gap: 12px; - max-height: 240px; - overflow: hidden; + max-height: 400px; + overflow-y: auto; transition: max-height 0.3s ease; } @@ -797,7 +758,7 @@ onUnmounted(() => { background: #FAFAFA; border: 1px solid #E5E5E5; border-radius: 6px; - padding: 12px; + padding: 14px; cursor: pointer; transition: all 0.2s ease; } @@ -809,31 +770,64 @@ onUnmounted(() => { .profile-header { display: flex; - justify-content: space-between; - align-items: center; + align-items: baseline; + gap: 8px; + margin-bottom: 6px; +} + +.profile-realname { + font-size: 14px; + font-weight: 700; + color: #000; +} + +.profile-username { + font-family: 'JetBrains Mono', monospace; + font-size: 11px; + color: #999; +} + +.profile-meta { margin-bottom: 8px; } -.profile-name { - font-size: 13px; - font-weight: 600; - color: #333; -} - -.profile-type { - font-family: 'JetBrains Mono', monospace; - font-size: 10px; - background: #E3F2FD; - color: #1565C0; - padding: 2px 6px; +.profile-profession { + font-size: 11px; + color: #666; + background: #F0F0F0; + padding: 2px 8px; border-radius: 3px; } .profile-bio { font-size: 12px; - color: #666; - line-height: 1.5; - margin: 0; + color: #444; + line-height: 1.6; + margin: 0 0 10px 0; + display: -webkit-box; + -webkit-line-clamp: 3; + -webkit-box-orient: vertical; + overflow: hidden; +} + +.profile-topics { + display: flex; + flex-wrap: wrap; + gap: 6px; +} + +.topic-tag { + font-size: 10px; + color: #1565C0; + background: #E3F2FD; + padding: 2px 8px; + border-radius: 10px; +} + +.topic-more { + font-size: 10px; + color: #999; + padding: 2px 6px; } /* Config Preview */