get_sd_upscalers
Retrieve a list of available upscaler models for enhancing image resolution and quality, integrated with Stable Diffusion WebUI for efficient image generation workflows.
Instructions
Get list of available upscaler models
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- src/index.ts:316-320 (handler)The main handler function for the 'get_sd_upscalers' tool. It makes a GET request to the Stable Diffusion WebUI API endpoint '/sdapi/v1/upscalers' to retrieve the list of available upscalers, casts the response to UpscalerInfo[], extracts their names, and returns them as a JSON string in the tool response.
case 'get_sd_upscalers': { const response = await this.axiosInstance.get('/sdapi/v1/upscalers'); const upscalers = response.data as UpscalerInfo[]; return { content: [{ type: 'text', text: JSON.stringify(upscalers.map(u => u.name)) }] }; } - src/index.ts:77-83 (schema)TypeScript interface defining the structure of upscaler information returned by the Stable Diffusion API, used for typing the response data in the handler.
interface UpscalerInfo { name: string; model_name: string; model_path: string; model_url: string; scale: number; } - src/index.ts:192-200 (registration)Tool registration entry in the listTools response, defining the tool's name, description, and input schema (which is empty as no parameters are required).
{ name: 'get_sd_upscalers', description: 'Get list of available upscaler models', inputSchema: { type: 'object', properties: {}, required: [] } }, - src/index.ts:195-199 (schema)Input schema for the get_sd_upscalers tool, specifying no required properties.
inputSchema: { type: 'object', properties: {}, required: [] }