{"id":"tmonk-mcp-stata","name":"mcp-stata","homepage":"https://tdmonk.com","repo_url":"https://github.com/tmonk/mcp-stata","category":"ai-ml","subcategories":[],"tags":["mcp","stata","econometrics","local-integration","data-browser","agents","python"],"what_it_does":"mcp-stata is a Model Context Protocol (MCP) server that connects AI agents to a locally installed Stata (17+) installation. It runs Stata commands, can load/inspect datasets and variables, executes .do files, exports graphs, and retrieves stored r()/e() results. It also exposes an additional localhost-only HTTP API for a data-browser UI with bearer-token access.","use_cases":["Letting an LLM agent execute and iterate on Stata analysis interactively","Automating inspection of datasets (describe/codebook/variable lists) from an AI workflow","Exporting Stata graphs on-demand during agent conversations","Validating model results by reading stored r()/e() results","Providing a UI data browser (paging/filtering/sorting) via a local HTTP endpoint for IDE extensions"],"not_for":["Running untrusted Stata code from untrusted sources without user controls","Multi-tenant remote access or use where network exposure beyond localhost is required","Use cases needing a publicly accessible API with robust third-party auth/authorization and rate-limit enforcement details"],"best_when":"You have a licensed local Stata installation and want IDE/agent integration through MCP (stdio transport) plus optional localhost UI browsing.","avoid_when":"You need strict governance around what code can be executed, or you cannot isolate the process/session from untrusted prompts.","alternatives":["Run Stata manually and use LLMs only for interpretation/summarization","Use a different MCP tool that provides a narrower, safer interface to statistical software (if available)","Build a bespoke integration that exposes only specific Stata operations behind strict allowlists"],"af_score":71.0,"security_score":57.8,"reliability_score":43.8,"package_type":"mcp_server","discovery_source":["github"],"priority":"high","status":"evaluated","version_evaluated":null,"last_evaluated":"2026-03-30T15:24:20.260962+00:00","interface":{"has_rest_api":true,"has_graphql":false,"has_grpc":false,"has_mcp_server":true,"mcp_server_url":null,"has_sdk":false,"sdk_languages":[],"openapi_spec_url":null,"webhooks":false},"auth":{"methods":["MCP stdio transport (no network auth described for MCP tools)","Local HTTP UI API bearer token (Authorization: Bearer <token>) for localhost endpoints"],"oauth":false,"scopes":false,"notes":"The MCP interface is via stdio from the client/IDE. The separate local HTTP UI requires short-lived bearer tokens obtained through the MCP tool get_ui_channel(). No OAuth flows are described."},"pricing":{"model":null,"free_tier_exists":false,"free_tier_limits":null,"paid_tiers":[],"requires_credit_card":false,"estimated_workload_costs":null,"notes":"No pricing information is provided in the supplied content; this appears to be a self-hosted/local integration (plus your Stata license)."},"requirements":{"requires_signup":false,"requires_credit_card":false,"domain_verification":false,"data_residency":[],"compliance":[],"min_contract":null},"agent_readiness":{"af_score":71.0,"security_score":57.8,"reliability_score":43.8,"mcp_server_quality":86.0,"documentation_accuracy":78.0,"error_message_quality":null,"error_message_notes":"The README describes structured notifications (e.g., notifications/logMessage with log_path) and cancellation behavior. It does not show detailed error payload formats for typical failures.","auth_complexity":75.0,"rate_limit_clarity":25.0,"tls_enforcement":60.0,"auth_strength":70.0,"scope_granularity":35.0,"dependency_hygiene":55.0,"secret_handling":65.0,"security_notes":"MCP uses stdio (reducing network attack surface). The localhost HTTP UI is loopback-only with bearer tokens obtained per session/channel. However, MCP tools allow execution of arbitrary Stata commands/do-files, which is inherently high-risk if inputs/prompts are untrusted (command injection / data exfiltration via file/command effects is possible depending on Stata capabilities). No explicit scope granularity for MCP is described (effectively full access within the running process/session). Dependency hygiene is uncertain from the provided manifest (presence of pinned/compatible deps like httpx pin is noted, but no CVE status is provided).","uptime_documented":10.0,"version_stability":55.0,"breaking_changes_history":45.0,"error_recovery":65.0,"idempotency_support":"false","idempotency_notes":"Most operations execute code in a persistent Stata session (run_command/run_do_file/load_data) and are therefore not naturally idempotent.","pagination_style":"offset/limit for UI endpoints (/v1/page, /views/:viewId/page); no explicit pagination for MCP tools","retry_guidance_documented":false,"known_agent_gotchas":["Commands can mutate/alter the Stata session state; treat session as stateful and avoid re-running without understanding side effects","The server can reload startup do-files on certain clear commands unless MCP_STATA_NO_RELOAD_ON_CLEAR=1 is set","Large outputs are written to a temp log and emitted to the client via log tailing; agents should use read_log/find_in_log for context rather than expecting outputs inline","Cancellation is best-effort and depends on Stata surfacing BreakError; partial output may remain in the log"]}}