Skip to content

Commit 8fc0902

Browse files
echobtfactorydroid
andauthored
fix(cortex-cli): add model alias resolution to ACP server command (#184)
Complete the model alias feature (PR #138) by adding support to the ACP server command. This ensures consistent model alias resolution (e.g., 'sonnet' -> 'anthropic/claude-sonnet-4-20250514') across all CLI entry points. This was the only missing piece from the 10 open CLI PRs, as all other features were already implemented in the current codebase: - PR #155: Tab completion setup on first run - PR #153: Valid JSONL with full event data - PR #151: Man page generation command - PR #138: Model alias shortcuts (now complete) - PR #137: Consistent provider casing - PR #135: --log-level flag - PR #134: Actual write permission check - PR #133: Binary location from PATH - PR #130: Searched paths in ripgrep debug - PR #129: Valid JSON output on errors Co-authored-by: Droid Agent <droid@factory.ai>
1 parent 416833a commit 8fc0902

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

cortex-cli/src/acp_cmd.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
66
use anyhow::Result;
77
use clap::Parser;
8+
use cortex_common::resolve_model_alias;
89
use std::net::SocketAddr;
910
use std::path::PathBuf;
1011

@@ -53,7 +54,8 @@ impl AcpCli {
5354
}
5455

5556
if let Some(model) = &self.model {
56-
config.model = model.clone();
57+
// Resolve model alias (e.g., "sonnet" -> "anthropic/claude-sonnet-4-20250514")
58+
config.model = resolve_model_alias(model).to_string();
5759
}
5860

5961
// Decide transport mode

0 commit comments

Comments
 (0)