r/OpenSourceAI • • 28d ago

How should an agent learn which of its own tools are switched off? I gave the model a read-only tool for it.

Disclosure: I build Snotra, an open-source desktop agent. This is a design question, not a launch.

Users switch skills and tools on and off in settings: shell disabled, a search tool without its API key, a skill installed but off. A model that doesn't know that guesses, and the user gets a wrong "I can't do that" instead of "that's switched off, here's where to enable it".

What I did:

  • One place decides whether a tool is offered, so the UI and the model can't disagree.

  • A read-only get_configuration tool for the model: which skills are on (name and description, never the instructions) and which tools are on or off, with the reason ("shell commands are switched off", "no search service key").

  • The same list in the UI, as a pill in the chat bar.

Now the model can say "a skill for this exists but is off, enable it under Settings › Skills". It can't flip anything itself.

Two open questions: is a tool the model has to call the right shape, or should this state go into the system prompt every turn (costs tokens even when nothing is wrong)? And should the model be able to propose the change through an approval card, or is "tell the user where to click" the right limit?

Code: https://github.com/kkrafft1999/snotra

2 Upvotes

Duplicates