list_models
Discover available AI models with descriptions and recommended use cases to select the right model for your specific task requirements.
Instructions
List all available AI models with their descriptions and best use cases
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- src/mcp/handlers/ToolHandler.ts:66-85 (handler)The primary handler function for the 'list_models' MCP tool. It retrieves the list of models from the ConsultationService and returns them formatted as a JSON string in a ToolResponse.private handleListModels(): ToolResponse { if (this.config.verboseLogging) { console.error("[MCP] Fetching available models list"); } const models = this.consultationService.listModels(); if (this.config.verboseLogging) { console.error(`[MCP] Found ${models.length} available models`); } return { content: [ { type: "text" as const, text: JSON.stringify(models, null, 2), }, ], }; }
- src/mcp/ToolDefinitions.ts:56-64 (registration)Registers the 'list_models' tool in the MCP server, including its name, description, and input schema (no required parameters).{ name: "list_models", description: "List all available AI models with their descriptions and best use cases", inputSchema: { type: "object", properties: {}, }, },
- src/mcp/ToolDefinitions.ts:60-63 (schema)Defines the input schema for the 'list_models' tool, which requires no parameters.inputSchema: { type: "object", properties: {}, },
- Helper method in ConsultationService that fetches and formats the list of available models from ModelSelector, invoked by the tool handler.public listModels() { const models = this.modelSelector.getAllModels(); return Object.entries(models).map(([key, model]) => ({ name: key, id: model.id, description: model.description, bestFor: model.bestFor, })); }
- src/mcp/handlers/ToolHandler.ts:37-39 (handler)Dispatch case in the main handleToolCall method that routes 'list_models' tool calls to the specific handler.case "list_models": result = this.handleListModels(); break;