Skip to main content
Glama
petrmasa
by petrmasa

find_drivers

Analyze a dataset to find key drivers influencing a specified target class, returning a nested hierarchy of drivers and sub-drivers with lift and strength metrics.

Instructions

Find the key drivers and influencers of a target outcome in a loaded dataset. Call this ONCE — it returns a complete, multi-level nested JSON in a single response. Do NOT call it multiple times to "refine" results; use the parameters below to get it right on the first call.

The response contains a "drivers" list. Every top-level single-variable driver is guaranteed to have a "sub_drivers" list — if araxai did not produce one naturally, the server automatically runs a sub-analysis by filtering to that segment. Sub_drivers may themselves contain further "sub_drivers" up to max_depth levels. Always read the full nested structure before deciding whether more analysis is needed. Only call again with filters when the user asks about a specific sub-segment (e.g. "within women in 3rd class") that is not already covered by sub_drivers.

IMPORTANT — avoid trivial drivers: Before calling, check load_dataset output for columns that are direct encodings or recodings of the target (e.g. a numeric "survived=1" column when target is "alive=yes", or redundant label columns like "who"/"adult_male" that restate "sex"). Exclude these via the attributes parameter, otherwise they will dominate the results trivially.

Lift > 1 means the feature increases the probability of the target class. Lift < 1 means it decreases it. Strength shows +/- signs: more signs = stronger.

Args: dataset_name: Name of a dataset loaded with load_dataset target: Column name of the outcome variable to explain (e.g. "Severity") target_class: The specific outcome value to find drivers for (e.g. "Fatal") attributes: Explicit list of candidate driver columns. Use this to EXCLUDE columns that are redundant with or direct encodings of the target. If omitted, all non-target columns are used. filters: Optional dict of column→value pairs to restrict analysis to a specific segment before running (e.g. {"sex": "female", "pclass": "3"}). Use this when the user asks about a specific sub-group. Filtered columns are automatically excluded from driver candidates (they are constant). Values must match the raw dataset values before encoding. min_base: Minimum number of records a rule must cover (default 20) max_depth: Levels of nested sub-driver drill-down, 1–3 (default 2). Use 2 for standard analysis. Only increase to 3 when the user explicitly asks to drill deeper into a specific segment (e.g. "tell me more about women in 1st class"). The response already contains all levels nested under "sub_drivers" keys — do NOT call find_drivers again just to get deeper results. Only call again if a specific segment is entirely absent. auto_boundaries: If True, automatically tunes the lift threshold to return 2–10 drivers regardless of their absolute lift value

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
dataset_nameYes
targetYes
target_classYes
attributesNo
filtersNo
min_baseNo
max_depthNo
auto_boundariesNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior5/5

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

Despite no annotations, the description fully discloses behavioral traits: it returns a complete nested JSON, automatically runs sub-analysis if needed, explains lift values (Lift > 1 / < 1, strength signs), and details how parameters like max_depth and auto_boundaries affect results. No contradictions with annotations as none exist.

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

Conciseness4/5

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

The description is well-structured with clear sections (purpose, usage admonition, response explanation, important note, lift interpretation, Args) and is front-loaded with critical usage guidance. However, it is somewhat verbose; some details could be condensed without losing value, earning a 4 instead of 5.

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

Completeness5/5

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

The description fully covers the tool's behavior given its complexity (8 parameters, nested response). It explains the return structure (drivers list with sub_drivers), lift interpretation, and parameter effects. An output schema exists, so omitting return field details is acceptable. The description is sufficient for correct usage.

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 adds extensive meaning: each parameter (dataset_name, target, target_class, attributes, filters, min_base, max_depth, auto_boundaries) is explained with purpose, defaults, and usage examples. For instance, attributes is described as a way to exclude redundant columns, and filters includes instructions on value matching.

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: 'Find the key drivers and influencers of a target outcome in a loaded dataset.' It specifies the verb ('find'), resource ('drivers and influencers'), and distinguishes from siblings by emphasizing that it returns complete nested JSON in one call, contrasting with potential iterative approaches.

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

Usage Guidelines5/5

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

The description provides explicit guidance: 'Call this ONCE' and 'Do NOT call it multiple times to refine results.' It instructs when to call again with filters (only for specific sub-segments not already covered) and warns about avoiding trivial drivers by checking load_dataset output. This clearly differentiates usage from alternatives.

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/petrmasa/key_drivers_mcp'

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