- 引入AgentTeamOrchestrator支持多agent协同任务执行 - 增加第三方swarms库依赖并配置git协议替换以改善包管理 - 扩展DelegationManager支持团队任务调度和进度跟踪 - 实现中文bigram分词算法提升中文任务检索准确性 - 调整A2AClient和DelegationManager超时时间从30秒增至600秒 - 优化AgentRunResult状态判断逻辑增加有意义摘要检测 - 修改Dockerfile配置npm仓库镜像地址和git协议映射 - 更新CLI命令行接口支持网关端口配置传递 - 调整提供者超时配置机制增强请求稳定性 - 移除过时的support_group字段简化agent描述符结构 - 增强错误处理和进度事件报告机制改进用户体验
59 lines
1.7 KiB
TypeScript
59 lines
1.7 KiB
TypeScript
'use client';
|
|
|
|
import Link from 'next/link';
|
|
import { usePathname } from 'next/navigation';
|
|
import { Building2, Clock3 } from 'lucide-react';
|
|
|
|
import { pickAppText } from '@/lib/i18n/core';
|
|
import { useAppI18n } from '@/lib/i18n/provider';
|
|
import { cn } from '@/lib/utils';
|
|
|
|
const TASK_MANAGEMENT_TABS = [
|
|
{
|
|
label: 'Office',
|
|
href: '/office',
|
|
icon: Building2,
|
|
match: (pathname: string) => pathname === '/office' || pathname.startsWith('/office/'),
|
|
},
|
|
{
|
|
label: 'Scheduled tasks',
|
|
href: '/cron',
|
|
icon: Clock3,
|
|
match: (pathname: string) => pathname === '/cron' || pathname.startsWith('/cron/'),
|
|
},
|
|
] as const;
|
|
|
|
export function TaskManagementTabs() {
|
|
const { locale } = useAppI18n();
|
|
const pathname = usePathname();
|
|
|
|
return (
|
|
<div className="rounded-2xl border border-border/70 bg-muted/20 p-1">
|
|
<div className="flex flex-wrap gap-1">
|
|
{TASK_MANAGEMENT_TABS.map((tab) => {
|
|
const isActive = tab.match(pathname);
|
|
const Icon = tab.icon;
|
|
|
|
return (
|
|
<Link
|
|
key={tab.href}
|
|
href={tab.href}
|
|
className={cn(
|
|
'inline-flex items-center gap-2 rounded-xl px-4 py-2 text-sm font-medium transition-colors',
|
|
isActive
|
|
? 'bg-background text-foreground shadow-sm'
|
|
: 'text-muted-foreground hover:bg-background/70 hover:text-foreground'
|
|
)}
|
|
>
|
|
<Icon className="h-4 w-4" />
|
|
{tab.href === '/cron'
|
|
? pickAppText(locale, '定时任务', 'Scheduled tasks')
|
|
: pickAppText(locale, '办公室', 'Office')}
|
|
</Link>
|
|
);
|
|
})}
|
|
</div>
|
|
</div>
|
|
);
|
|
}
|