feat(ui): display agent name in message header

This commit is contained in:
2025-12-16 10:43:02 +08:00
parent a6c1e792fa
commit e698ec2a64
6 changed files with 72 additions and 6 deletions
+26
View File
@@ -0,0 +1,26 @@
/**
* Agent 工具函数
*/
/**
* Agent 显示名称映射
*/
export const AGENT_DISPLAY_NAMES: Record<string, string> = {
build: 'Build Agent',
plan: 'Plan Agent',
general: 'General Agent',
explore: 'Explore Agent',
'code-reviewer': 'Code Reviewer',
vision: 'Vision Agent',
summary: 'Summary Agent',
};
/**
* 获取 Agent 显示名称
* @param agentName Agent 名称(如 build、plan、explore 等)
* @returns 显示名称
*/
export function getAgentDisplayName(agentName?: string): string {
if (!agentName) return 'AI Assistant';
return AGENT_DISPLAY_NAMES[agentName] || agentName;
}