Refactor IPC and DTO structures; remove unused code and streamline message handling
- Removed unused structs and methods from `response.rs`, `usage.rs`, and `client.rs`. - Simplified `Connection` handling in `conn.rs` to only support Unix sockets. - Updated `IpcServer` to exclusively use Unix sockets and removed TCP handling. - Cleaned up `editlog.rs` by removing loading and recent entry methods. - Refactored `memory.rs` to eliminate unused functions related to lesson promotion and retrospective creation. - Enhanced `search.rs` to support multiple search providers and improved error handling. - Updated chat view logic to simplify message display and improve user experience. - Removed deprecated modules and constants from various files to streamline the codebase.
This commit is contained in:
@@ -4,12 +4,10 @@ use super::spawn::AgentDefinition;
|
||||
pub const REVIEWER_ALLOWED: &[&str] = &["read", "grep", "glob", "recall", "remember"];
|
||||
|
||||
pub struct SubagentContext {
|
||||
pub definition: AgentDefinition,
|
||||
pub system_prompt: String,
|
||||
pub allowed_tools: Vec<String>,
|
||||
pub max_steps: usize,
|
||||
pub session_dir: PathBuf,
|
||||
pub origin: crate::app::state::types::Origin,
|
||||
}
|
||||
|
||||
pub fn build_subagent_context(def: AgentDefinition) -> SubagentContext {
|
||||
@@ -21,11 +19,9 @@ pub fn build_subagent_context(def: AgentDefinition) -> SubagentContext {
|
||||
}
|
||||
});
|
||||
SubagentContext {
|
||||
definition: def,
|
||||
system_prompt: String::new(),
|
||||
allowed_tools,
|
||||
max_steps: 25,
|
||||
session_dir: PathBuf::new(),
|
||||
origin: crate::app::state::types::Origin::SubAgent,
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user