Skip to main content
Glama
Cappybara12

OpenXAI MCP Server

by Cappybara12

list_explainers

Discover available AI explanation methods like LIME, SHAP, and Grad-CAM to understand model predictions. Filter by method type to find suitable interpretability tools.

Instructions

List available explanation methods in OpenXAI

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
method_typeNoFilter by explanation method type

Implementation Reference

  • The main execution function for the list_explainers tool. Filters and returns available explanation methods (LIME, SHAP, etc.) with their details based on the method_type parameter.
    async listExplainers(methodType) {
      const explainers = {
        lime: {
          name: 'LIME (Local Interpretable Model-agnostic Explanations)',
          description: 'Local explanations by approximating the model locally with an interpretable model',
          supported_data_types: ['tabular', 'image', 'text'],
          explanation_type: 'local',
          model_agnostic: true
        },
        shap: {
          name: 'SHAP (SHapley Additive exPlanations)',
          description: 'Feature attribution based on cooperative game theory',
          supported_data_types: ['tabular', 'image', 'text'],
          explanation_type: 'local',
          model_agnostic: true
        },
        integrated_gradients: {
          name: 'Integrated Gradients',
          description: 'Attribution method based on gradients integrated along a path',
          supported_data_types: ['tabular', 'image', 'text'],
          explanation_type: 'local',
          model_agnostic: false,
          requires: 'PyTorch or TensorFlow model'
        },
        gradcam: {
          name: 'Grad-CAM (Gradient-weighted Class Activation Mapping)',
          description: 'Visual explanations for CNN models using gradients',
          supported_data_types: ['image'],
          explanation_type: 'local',
          model_agnostic: false,
          requires: 'CNN model'
        },
        guided_backprop: {
          name: 'Guided Backpropagation',
          description: 'Modified backpropagation for generating visual explanations',
          supported_data_types: ['image'],
          explanation_type: 'local',
          model_agnostic: false,
          requires: 'Neural network model'
        }
      };
    
      let result = [];
      if (methodType === 'all') {
        result = Object.entries(explainers).map(([key, value]) => ({
          method: key,
          ...value
        }));
      } else {
        result = explainers[methodType] ? [{ method: methodType, ...explainers[methodType] }] : [];
      }
    
      return {
        content: [
          {
            type: 'text',
            text: `Available OpenXAI explanation methods:\n\n` +
                  JSON.stringify(result, null, 2)
          }
        ]
      };
    }
  • JSON schema defining the input parameters for the list_explainers tool, including the optional method_type filter.
    inputSchema: {
      type: 'object',
      properties: {
        method_type: {
          type: 'string',
          description: 'Filter by explanation method type',
          enum: ['lime', 'shap', 'integrated_gradients', 'gradcam', 'all']
        }
      },
      required: []
    }
  • index.js:115-129 (registration)
    Registration of the list_explainers tool in the ListToolsRequestHandler response, providing name, description, and schema.
    {
      name: 'list_explainers',
      description: 'List available explanation methods in OpenXAI',
      inputSchema: {
        type: 'object',
        properties: {
          method_type: {
            type: 'string',
            description: 'Filter by explanation method type',
            enum: ['lime', 'shap', 'integrated_gradients', 'gradcam', 'all']
          }
        },
        required: []
      }
    },
  • index.js:267-268 (registration)
    Dispatch registration in the CallToolRequestHandler switch statement, calling the listExplainers handler with parameters.
    case 'list_explainers':
      return await this.listExplainers(args.method_type || 'all');
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full burden of behavioral disclosure. It states what the tool does but lacks details on behavioral traits such as whether it's read-only, potential rate limits, authentication needs, output format, or pagination. For a tool with zero annotation coverage, this is a significant gap in transparency.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, efficient sentence that directly states the tool's purpose without unnecessary words. It is appropriately sized and front-loaded, with zero waste, making it highly concise and well-structured for its simplicity.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's low complexity (one optional parameter) but lack of annotations and output schema, the description is incomplete. It doesn't cover behavioral aspects, output details, or usage context, leaving gaps that could hinder an AI agent's ability to use the tool effectively without additional inference.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The description adds no parameter semantics beyond what the input schema provides. With 100% schema description coverage and an enum for 'method_type', the schema fully documents the parameter. The description doesn't explain the meaning of 'explanation methods' or the filter options, so it meets the baseline of 3 where the schema does the heavy lifting.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the verb ('List') and resource ('available explanation methods in OpenXAI'), making the purpose specific and understandable. It distinguishes from siblings like 'evaluate_explanation' or 'generate_explanation' by focusing on listing rather than evaluating or generating, but doesn't explicitly differentiate from 'list_datasets', 'list_models', or 'list_metrics' beyond the resource type.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus alternatives. It doesn't mention prerequisites, context for filtering, or relationships with sibling tools like 'get_framework_info' or 'get_deployment_guide' that might provide related information. Usage is implied only by the tool name and purpose.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Cappybara12/mcpopenxAI'

If you have feedback or need assistance with the MCP directory API, please join our Discord server