diff --git a/crates/agent_ui/src/acp/completion_provider.rs b/crates/agent_ui/src/acp/completion_provider.rs index 3641e00bea3ccc8c10145fc33ae51d2afcc010d8..f0b0644f8e68d3908074dc9fc98a1eb4d91c16a4 100644 --- a/crates/agent_ui/src/acp/completion_provider.rs +++ b/crates/agent_ui/src/acp/completion_provider.rs @@ -1220,6 +1220,14 @@ mod tests { assert_eq!(SlashCommandCompletion::try_parse("Lorem/", 0), None); assert_eq!(SlashCommandCompletion::try_parse("/ ", 0), None); + + // Slash commands should not consume @ symbols that could be mention triggers + assert_eq!(SlashCommandCompletion::try_parse("/init @", 0), None); + + assert_eq!(SlashCommandCompletion::try_parse("/help @file", 0), None); + + // @ with whitespace before it should also not be consumed + assert_eq!(SlashCommandCompletion::try_parse("/command @", 0), None); } #[test]