( mcpCommands: readonly Command[], )
| 547 | * separately. |
| 548 | */ |
| 549 | export function getMcpSkillCommands( |
| 550 | mcpCommands: readonly Command[], |
| 551 | ): readonly Command[] { |
| 552 | if (feature('MCP_SKILLS')) { |
| 553 | return mcpCommands.filter( |
| 554 | cmd => |
| 555 | cmd.type === 'prompt' && |
| 556 | cmd.loadedFrom === 'mcp' && |
| 557 | !cmd.disableModelInvocation, |
| 558 | ) |
| 559 | } |
| 560 | return [] |
| 561 | } |
| 562 | |
| 563 | // SkillTool shows ALL prompt-based commands that the model can invoke |
| 564 | // This includes both skills (from /skills/) and commands (from /commands/) |
no test coverage detected