Per-plugin toggle for exposing CLI commands to agents (plugin-commands skill curation) - #2739
Open
swairshah wants to merge 1 commit into
Open
Per-plugin toggle for exposing CLI commands to agents (plugin-commands skill curation)#2739swairshah wants to merge 1 commit into
swairshah wants to merge 1 commit into
Conversation
…ds skill Users can now curate which plugins advertise their bb CLI commands to agents. A new agent_cli_exposed column (default on) is read when the server generates the plugin-commands skill; a hidden plugin's commands keep working but are omitted from the skill, so agents never see them. - bb plugin agent-cli <id> [on|off] shows or sets the toggle from the CLI - POST /api/v1/plugins/:id/agent-cli sets it over HTTP; the SDK exposes plugins.setAgentCliExposed and InstalledPlugin.agentCliExposed - The plugin detail page gets an Agent access section with a switch, shown when the plugin registers a CLI command - Reinstalls and updates preserve the user's choice
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
Every plugin that registers a CLI shows up in the server-generated
plugin-commandsskill, so agents see all plugin commands. As the plugin count grows this becomes noise: not every plugin's commands are useful to agents, and today the only way to hide them is disabling the plugin entirely.Change
Adds a per-plugin agent CLI exposure toggle (default: exposed, preserving current behavior). A hidden plugin keeps a fully working CLI — its commands are just omitted from the generated
plugin-commandsskill, so agents never discover them.plugins.agent_cli_exposedboolean column (migration0110_plugin_agent_cli_exposed), preserved across reinstalls/updates and state-snapshot rollbacks.cliContributions()filters hidden plugins before writing the skill;PluginService.setAgentCliExposed()re-syncs the skill and broadcastsplugins-changed. New routePOST /api/v1/plugins/:id/agent-cliwith{ exposed: boolean }.bb plugin agent-cli <id> [on|off]shows or sets the toggle;bb plugin listmarks hidden commands with "(hidden from agents)".plugins.setAgentCliExposed();InstalledPlugin.agentCliExposed(schema defaulttrue, so older servers parse fine).Tests
drop agent_cli_exposedhelper, mirroring the existing pattern.turbo run typecheck(80 tasks) passes; db/sdk/cli/server plugin suites and app plugin component tests pass. The only failing test locally isinstall-machine-script.test.ts, which also fails on a cleanmaincheckout (environment-dependent).