diff options
Diffstat (limited to 'src/repl/mod.rs')
| -rw-r--r-- | src/repl/mod.rs | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/src/repl/mod.rs b/src/repl/mod.rs index 8c68f78..13e147b 100644 --- a/src/repl/mod.rs +++ b/src/repl/mod.rs @@ -31,7 +31,7 @@ lazy_static::lazy_static! { const MENU_NAME: &str = "completion_menu"; lazy_static::lazy_static! { - static ref REPL_COMMANDS: [ReplCommand; 30] = [ + static ref REPL_COMMANDS: [ReplCommand; 31] = [ ReplCommand::new(".help", "Show this help message", AssertState::pass()), ReplCommand::new(".info", "View system info", AssertState::pass()), ReplCommand::new(".model", "Change the current LLM", AssertState::pass()), @@ -148,6 +148,7 @@ lazy_static::lazy_static! { AssertState::pass() ), ReplCommand::new(".set", "Adjust settings", AssertState::pass()), + ReplCommand::new(".delete", "Delete roles/sessions/RAGs/agents-config", AssertState::pass()), ReplCommand::new(".copy", "Copy the last response", AssertState::pass()), ReplCommand::new(".exit", "Exit the REPL", AssertState::pass()), ]; @@ -392,6 +393,14 @@ impl Repl { println!("Usage: .set <key> <value>...") } }, + ".delete" => match args { + Some(args) => { + Config::delete(&self.config, args)?; + } + _ => { + println!("Usage: .delete [roles|sessions|rags|agents-config]") + } + }, ".copy" => { let config = self.config.read(); self.copy(config.last_reply()) |
