feat(task):优化任务执行与智能体展示功能
- 更新action.svg图标样式- 重构AgentRepo组件,优化智能体列表展示逻辑 - 改进ExecutePlan组件,支持object类型节点渲染 - 完善TaskResult组件,增加执行计划存储与清理机制 - 调整TaskSyllabus组件,优化卡片激活状态样式 - 在Task组件中添加搜索建议功能 - 更新主题配色变量和全局样式- 替换ElInput为ElAutocomplete组件 - 清理无用的jsplumb连接代码- 优化组件间通信与状态管理
This commit is contained in:
@@ -4,6 +4,7 @@ import { v4 as uuidv4 } from 'uuid'
|
||||
|
||||
import { store } from '../index'
|
||||
import { useStorage } from '@vueuse/core'
|
||||
import type { IExecuteRawResponse } from '@/api'
|
||||
|
||||
|
||||
export interface Agent {
|
||||
@@ -81,6 +82,20 @@ export const useAgentsStore = defineStore('counter', () => {
|
||||
}
|
||||
}
|
||||
|
||||
// 执行完任务的结果
|
||||
const executePlan = ref<IExecuteRawResponse[]>([])
|
||||
function setExecutePlan(plan: IExecuteRawResponse[]) {
|
||||
executePlan.value = plan
|
||||
}
|
||||
|
||||
function resetAgent() {
|
||||
agentRawPlan.value = {
|
||||
loading: false,
|
||||
}
|
||||
currentTask.value = undefined
|
||||
executePlan.value = []
|
||||
}
|
||||
|
||||
|
||||
return {
|
||||
agents,
|
||||
@@ -90,7 +105,10 @@ export const useAgentsStore = defineStore('counter', () => {
|
||||
currentTask,
|
||||
setCurrentTask,
|
||||
agentRawPlan,
|
||||
setAgentRawPlan
|
||||
setAgentRawPlan,
|
||||
executePlan,
|
||||
setExecutePlan,
|
||||
resetAgent,
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
Reference in New Issue
Block a user