Skip to main content
Glama
florenciakabas

xai-toolkit

get_partial_dependence

Analyze how a single feature influences model predictions across its range, revealing average and individual effects through partial dependence plots and ICE visualizations.

Instructions

Show how a single feature affects predictions across its range.

Returns a narrative describing the relationship between the feature
and the model's predicted probability. Optionally includes a PDP + ICE
plot (model-agnostic visualization, not SHAP-based).

PDP (bold line) shows the average effect. ICE (gray lines) show individual
sample effects, revealing heterogeneity the average hides.

Args:
    model_id: ID of a registered model (e.g., "gbc_lubricant_quality").
    feature_name: Name of the feature to analyze (e.g., "mean radius").
    include_plot: If True, include a PDP+ICE plot as base64 PNG (default: True).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
model_idYes
feature_nameYes
include_plotNo
Behavior4/5

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

With no annotations provided, the description carries full burden and does well by explaining key behavioral aspects: it returns a narrative description, optionally includes a visualization (PDP+ICE plot as base64 PNG), explains what PDP and ICE represent (average effect vs individual sample effects), and clarifies the visualization is model-agnostic. It doesn't mention rate limits, authentication needs, or data size constraints, but provides substantial operational context.

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 efficiently structured with zero wasted sentences. It starts with the core purpose, then describes the return value, then explains optional visualization, then clarifies the visualization components (PDP vs ICE), and finally documents all parameters clearly. Every sentence adds essential information.

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

Completeness4/5

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

For a 3-parameter tool with no annotations and no output schema, the description provides excellent coverage of inputs, behavior, and output format. It explains what the tool returns (narrative + optional plot), how the visualization works, and all parameter meanings. The only minor gap is not explicitly describing the narrative format or potential error conditions, but overall it's highly complete given the context.

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

Parameters5/5

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

With 0% schema description coverage, the description fully compensates by providing clear semantic explanations for all 3 parameters: 'model_id' is described as 'ID of a registered model' with an example, 'feature_name' as 'Name of the feature to analyze' with an example, and 'include_plot' as controlling whether to include a PDP+ICE plot as base64 PNG with default value. Each parameter's purpose and format is clearly explained beyond the bare schema.

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

Purpose5/5

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

The description clearly states the tool's purpose with specific verbs ('Show how a single feature affects predictions', 'Returns a narrative describing the relationship') and distinguishes it from siblings by specifying it's about partial dependence analysis (not SHAP-based, not feature comparison). It explicitly names the resource (model feature) and output type (narrative + optional plot).

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

Usage Guidelines3/5

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

The description implies usage context through phrases like 'model-agnostic visualization, not SHAP-based' which differentiates it from SHAP-based explanation tools, but doesn't explicitly state when to use this versus alternatives like 'explain_prediction' or 'compare_features'. No explicit when-not-to-use guidance or prerequisites are provided.

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/florenciakabas/xai-mcp'

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