MCP Server for Propensity Score Inverse Probability Weighting (IPW) Skill. Fits a logistic regression model for treatment assignment probabilities and computes the stabilized Horvitz-Thompson / Hajek IPW estimator for Average Treatment Effect (ATE).
Single tool 'estimate_ate_ipw' has a detailed description (194 chars, within baseline 34-392 range) explaining the statistical method clearly. Input schema is present with three array parameters (covariate_x, treatment_t, outcome_y), each with type and description. However, critical gaps prevent higher scoring: (1) Tool name does not start with action verb, 'estimate_ate_ipw' is a noun phrase, not 'estimate_ate' or 'calculate_ate'. LLMs infer intent from verb-first names; this violates pattern:tool naming convention. (2) No output schema documented, the code returns a dict with 6 fields (ate_ipw, naive_ate, mu1, mu0, w0, w1) but the tool definition provides no schema for these outputs. LLMs need to know what fields to expect.' (3) No error handling guidance, the code has no validation of input array lengths, no checks for empty arrays, no recovery hints. If arrays are mismatched or empty, the tool will fail silently or crash. (4) Parameters lack constraints, arrays accept any numeric values with no bounds, no validation that arrays have matching lengths, no guidance on expected ranges (e.g., treatment_t should be 0 or 1 only). (5) No tool annotations (readOnlyHint, idempotentHint) despite being a stateless, read-only statistical computation.
Calculate Hajek-stabilized Inverse Probability Weighting ATE estimate. Fits a univariate logistic regression model for propensity scores P(T=1|X), computes inverse probability weights, and returns the IPW-adjusted Average Treatment Effect along with naive difference in means and model parameters.
Tool name does not start with action verb. 'estimate_ate_ipw' is a noun phrase; should be 'estimate_ate' or 'calculate_ate'. LLMs infer intent from verb-first names.
No output schema documented. Tool returns dict with 6 fields (ate_ipw, naive_ate, mu1, mu0, w0, w1) but MCP definition provides no schema. LLMs cannot plan downstream calls or extract fields reliably.
Input parameters lack validation constraints. Arrays accept any numeric values; no check that treatment_t contains only 0 or 1; no validation that all three arrays have matching length. Missing length bounds and type constraints.
No error handling or recovery guidance. Code has no input validation, no handling of edge cases (empty arrays, mismatched lengths, division by zero in mu1/mu0 calculation). Errors will be cryptic to LLM.
| Scored | Grade | Overall | Spec posture | Rubric |
|---|---|---|---|---|
| 2026-09-23 | F | 36 | 2026-07-28+ | v2 |
No tool annotations. Tool is stateless and read-only (no side effects) but lacks idempotentHint annotation. This metadata helps agents reason about retry safety.