🤯 LobeHub - Super-Agents on Your Team. Add super-agents to the chats your team already uses.They take on work by themselves and get better every week.
TypeScript agentagent-collaborationagent-harnessloop-engineeringmcppersonal-assistantproactive-agentskillssuper-agenttask-management
🌐 chore: translate non-English comments to English in store/task (#13561)
LobeHub Botb92ee0ade56d
diff --git a/packages/types/src/task/index.ts b/packages/types/src/task/index.tsindex c0ee51a58eb..19672e07dda 100644--- a/packages/types/src/task/index.ts+++ b/packages/types/src/task/index.ts@@ -82,7 +82,7 @@ export interface TaskDetailData {dependencies?: Array<{ dependsOn: string; type: string }>;description?: string | null;error?: string | null;- // heartbeat.interval: 周期执行间隔 | heartbeat.timeout+lastAt: watchdog 监控(检测卡死)+ // heartbeat.interval: periodic execution interval | heartbeat.timeout+lastAt: watchdog monitoring (detects stuck tasks)heartbeat?: {interval?: number | null;lastAt?: string | null;diff --git a/src/services/task.ts b/src/services/task.tsindex 7187a9e13f4..b9aa84d8520 100644--- a/src/services/task.ts+++ b/src/services/task.ts@@ -63,9 +63,9 @@ class TaskService {config?: Record<string, unknown>;context?: Record<string, unknown>;description?: string;- // heartbeatInterval: 周期执行间隔(秒),控制每隔多久自动执行一次 task+ // heartbeatInterval: periodic execution interval (seconds), controls how often the task auto-executesheartbeatInterval?: number;- // heartbeatTimeout: watchdog 超时阈值(秒),用于检测 running task 是否卡死+ // heartbeatTimeout: watchdog timeout threshold (seconds), used to detect if a running task is stuckheartbeatTimeout?: number | null;instruction?: string;name?: string;@@ -105,7 +105,7 @@ class TaskService {deleteTopic = async (topicId: string) => lambdaClient.task.deleteTopic.mutate({ topicId });- // 安全 merge config(不会覆盖 checkpoint/review 等其他 config 字段)+ // Safely merges config without overwriting other config fields such as checkpoint/reviewupdateConfig = async (id: string, config: Record<string, unknown>) =>lambdaClient.task.updateConfig.mutate({ config, id });diff --git a/src/store/task/selectors/detailSelectors.ts b/src/store/task/selectors/detailSelectors.tsindex 9fc03329711..9b9f50d389b 100644--- a/src/store/task/selectors/detailSelectors.ts+++ b/src/store/task/selectors/detailSelectors.ts@@ -24,7 +24,7 @@ const activeTaskDescription = (s: TaskStoreState) => activeTaskDetail(s)?.descriconst activeTaskAgentId = (s: TaskStoreState) => activeTaskDetail(s)?.agentId;-// TODO [LOBE-6634]: 等后端 getTaskDetail 返回 model/provider 后,改为读 detail.model / detail.provider+// TODO [LOBE-6634]: Once the backend getTaskDetail returns model/provider, read from detail.model / detail.provider insteadconst activeTaskModel = (s: TaskStoreState) =>activeTaskDetail(s)?.config?.model as string | undefined;@@ -37,7 +37,7 @@ const activeTaskDependencies = (s: TaskStoreState) => activeTaskDetail(s)?.depenconst activeTaskParent = (s: TaskStoreState) => activeTaskDetail(s)?.parent;-// 周期执行间隔(秒),0 或 undefined 表示未配置+// Periodic execution interval (seconds); 0 or undefined means not configuredconst activeTaskPeriodicInterval = (s: TaskStoreState) =>activeTaskDetail(s)?.heartbeat?.interval ?? 0;diff --git a/src/store/task/slices/config/action.ts b/src/store/task/slices/config/action.tsindex 481da278fe5..37c47b2eb8a 100644--- a/src/store/task/slices/config/action.ts+++ b/src/store/task/slices/config/action.ts@@ -80,7 +80,7 @@ export class TaskConfigSliceActionImpl {}};- // 通过 task.updateConfig 安全 merge model/provider 到 config,不会覆盖 checkpoint/review+ // Safely merges model/provider into config via task.updateConfig without overwriting checkpoint/reviewupdateTaskModelConfig = async (id: string,modelConfig: { model?: string; provider?: string },@@ -93,8 +93,8 @@ export class TaskConfigSliceActionImpl {}};- // 配置周期执行间隔(heartbeatInterval 字段,单位:秒,null 或 0 禁用)- // 后端周期执行逻辑待 LOBE-6587 就绪后自动生效,前端可先完成 UI 配置+ // Configures the periodic execution interval (heartbeatInterval field, in seconds; null or 0 disables it)+ // Backend periodic execution logic will take effect automatically once LOBE-6587 is ready; the frontend UI config can be completed in advanceupdatePeriodicInterval = async (id: string, interval: number | null): Promise<void> => {try {await taskService.update(id, { heartbeatInterval: interval ?? 0 });@@ -104,8 +104,8 @@ export class TaskConfigSliceActionImpl {}};- // TODO [LOBE-6587]: 定时任务(cron 模式)- // updateSchedule(id, { pattern, timezone }) — 后端 task.update schema 尚未暴露 schedulePattern/scheduleTimezone+ // TODO [LOBE-6587]: Scheduled tasks (cron mode)+ // updateSchedule(id, { pattern, timezone }) — backend task.update schema does not yet expose schedulePattern/scheduleTimezone}export type TaskConfigSliceAction = Pick<diff --git a/src/store/task/slices/detail/action.ts b/src/store/task/slices/detail/action.tsindex 70f4581ba05..3e698db7555 100644--- a/src/store/task/slices/detail/action.ts+++ b/src/store/task/slices/detail/action.ts@@ -9,11 +9,11 @@ import type { TaskStore } from '../../store';import type { TaskDetailDispatch } from './reducer';import { taskDetailReducer } from './reducer';-// config / heartbeatInterval / heartbeatTimeout 不在此处暴露:-// - model/provider 走 configSlice.updateTaskModelConfig-// - checkpoint 走 configSlice.updateCheckpoint-// - review 走 configSlice.updateReview-// - heartbeat 配置待 LOBE-6587 上游 infra 完成后新增专用 action+// config / heartbeatInterval / heartbeatTimeout are not exposed here:+// - model/provider goes through configSlice.updateTaskModelConfig+// - checkpoint goes through configSlice.updateCheckpoint+// - review goes through configSlice.updateReview+// - heartbeat config will get a dedicated action once the upstream infra in LOBE-6587 is completeexport interface TaskUpdatePayload {assigneeAgentId?: string | null;description?: string;