-
Notifications
You must be signed in to change notification settings - Fork 17
Add config settings for generating shortcut tools #8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
dvcrn
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Rebase latest main, add tests
Co-authored-by: dvcrn <[email protected]>
Co-authored-by: dvcrn <[email protected]>
|
Rebased latest main branch which has test setup. Need to add tests |
Co-authored-by: dvcrn <[email protected]>
Added comprehensive tests for the new configuration options in commit 5a67bdd. The tests cover:
All tests are passing and the build is successful. Warning Firewall rules blocked me from connecting to one or more addressesI tried to connect to the following addresses, but was blocked by firewall rules:
If you need me to access, download, or install something from one of these locations, you can either:
|
This PR adds two new environment variable configuration options to control shortcut tool generation behavior:
New Configuration Options
GENERATE_SHORTCUT_TOOLS(default:true)Controls whether dynamic shortcut tools are generated for each available shortcut. When set to
false, only the base tools (list_shortcuts,open_shortcut,run_shortcut) will be available.INJECT_SHORTCUT_LIST(default:false)When set to
true, injects the list of available shortcuts with their identifiers into therun_shortcuttool description to help the LLM understand which shortcuts are available.Usage Example
{ "mcpServers": { "siri-shortcuts": { "command": "npx", "args": ["mcp-server-siri-shortcuts"], "env": { "GENERATE_SHORTCUT_TOOLS": "false", "INJECT_SHORTCUT_LIST": "true" } } } }Implementation Details
GENERATE_SHORTCUT_TOOLSdefaults totrueunless explicitly set to"false"INJECT_SHORTCUT_LISTdefaults tofalseunless explicitly set to"true"GENERATE_SHORTCUT_TOOLSrun_shortcutdescription conditionally includes the shortcut list based onINJECT_SHORTCUT_LISTGENERATE_SHORTCUT_TOOLSsetting when validating dynamic tool callsThe changes are minimal and maintain backward compatibility - existing installations will continue to work with the same behavior (all dynamic tools generated, no shortcut list injection).
Fixes #7.
💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.