microsoft / vscode

Visual Studio Code
https://code.visualstudio.com
MIT License
161.63k stars 28.4k forks source link

Handle conflicts between agent names #205776

Closed connor4312 closed 4 months ago

connor4312 commented 5 months ago

Testing #205609

For my little experiment I'm making a Home Assistant chat agent, which I would address as @home, but I could imagine people who write similar assistants for Google Home, Apple Homekit, etc. would probably also use that alias. (For this practical use case, it's also common for people to use multiple smart home clouds to some extent and coordinate them with Home Assistant.) So the next obvious step was making the name configurable, but that would conflict with the obvious implementation of having a static contribution point that identifies agents by their name, once better activation is supported (https://github.com/microsoft/vscode/issues/205631).

Maybe VS Code should support aliases and allow them to be mapped per-extension including in activation -- so I could alias hass, ghome, homekit and have them all work.

roblourens commented 5 months ago

That's a possibility, we also would be able to support participants with the same name from multiple extensions. The API is in place to differentiate them, although it's not really implemented, and in theory we can support different invocations of the same @ from the chat input, similar to how #file works, as long as you pick the participant from the suggest widget. I think it's undecided how we want to do it though

connor4312 commented 5 months ago

The API is in place to differentiate them, although it's not really implemented

I considered that as well, but with activation events that might get tricky

roblourens commented 4 months ago

This was implemented elsewhere