summaryrefslogtreecommitdiffstats
path: root/src/config/mod.rs
diff options
context:
space:
mode:
authorsigoden <sigoden@gmail.com>2023-10-28 22:22:37 +0800
committersigoden <sigoden@gmail.com>2023-10-28 22:22:37 +0800
commit7f5bad64744e10b7e88751bd324fdf8e9a435920 (patch)
tree516ca4fd9878de2731d25884a12c7b7ea5e1d631 /src/config/mod.rs
parent2ab2e23bb0539a7fac0d990e3d7e08b7fade1030 (diff)
downloadaichat-7f5bad64744e10b7e88751bd324fdf8e9a435920.tar.gz
chore: improve code and doc
Diffstat (limited to 'src/config/mod.rs')
-rw-r--r--src/config/mod.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/config/mod.rs b/src/config/mod.rs
index 6e6251d..64a3299 100644
--- a/src/config/mod.rs
+++ b/src/config/mod.rs
@@ -60,7 +60,7 @@ pub struct Config {
pub auto_copy: bool,
/// REPL keybindings, possible values: emacs (default), vi
pub keybindings: Keybindings,
- /// Setup LLM platforms
+ /// Setup AIs
pub clients: Vec<ClientConfig>,
/// Predefined roles
#[serde(skip)]
@@ -571,7 +571,7 @@ impl Config {
fn compat_old_config(&mut self, config_path: &PathBuf) -> Result<()> {
let content = read_to_string(config_path)?;
let value: serde_json::Value = serde_yaml::from_str(&content)?;
- if value.get("client").is_some() {
+ if value.get("clients").is_some() {
return Ok(());
}
@@ -632,7 +632,7 @@ fn create_config_file(config_path: &Path) -> Result<()> {
exit(0);
}
- let client = Select::new("Select platform?", all_clients())
+ let client = Select::new("Select AI?", all_clients())
.prompt()
.map_err(|_| anyhow!("An error happened when selecting platform, try again later."))?;