Refactor subagent and workflow domain models; migrate access tiers and events to domain module
- Moved `AccessTier` and `SubagentEvent` enums to `zesdex_domain::subagent`. - Consolidated workflow-related types into `zesdex_domain::workflow`. - Updated references across the codebase to use the new domain models. - Refactored tool execution logic to utilize a new `ToolExecutor` trait. - Enhanced `AgentTurnService` to handle tool calls and events more effectively. - Adjusted API handlers and state management to align with new domain structure.
This commit is contained in:
@@ -14,10 +14,7 @@ use crate::tools::{arg_str, Tool, ToolCtx};
|
||||
use crate::workflow::engine::execution::execute_workflow;
|
||||
use crate::workflow::hive_mind::cycle::execute_cycle;
|
||||
use crate::workflow::hive_mind::synthesis::synthesize_consensus;
|
||||
use crate::workflow::hive_mind::types::{
|
||||
CognitiveCycle, NodeDirective, NodeOutput,
|
||||
};
|
||||
use crate::workflow::script::WorkflowScript;
|
||||
use zesdex_domain::workflow::{CognitiveCycle, NodeDirective, NodeOutput, WorkflowScript};
|
||||
|
||||
/// Execute a multi-step workflow defined in YAML.
|
||||
///
|
||||
@@ -49,7 +46,7 @@ impl Tool for WorkflowRun {
|
||||
#[instrument(skip(self, ctx, args))]
|
||||
fn run(&self, ctx: &ToolCtx, args: &Value) -> Result<String> {
|
||||
let yaml = arg_str(args, "workflow_yaml")?;
|
||||
let script = WorkflowScript::parse(&yaml)?;
|
||||
let script = crate::workflow::script::parse_workflow_script(&yaml)?;
|
||||
info!(
|
||||
"Workflow started: {} ({} phases)",
|
||||
script.name,
|
||||
|
||||
Reference in New Issue
Block a user