Back to Home
jackdark425 icon

aigroup-stata-mcp

Verified Safe

by jackdark425

Overview

A Stata integration server based on Model Context Protocol (MCP) that allows AI assistants to execute Stata scripts, fetch data information, and run statistical analysis.

Installation

Run Command
uvx aigroup-stata-mcp

Environment Variables

  • STATA_CLI
  • stata_cli
  • STATA-MCP-CLIENT
  • STATA_MCP_CWD
  • STATA-MCP-CWD

Security Notes

The server utilizes `subprocess.Popen` and `pexpect` with `shell=True` for executing Stata commands. While this is necessary for its core function, it introduces a potential risk of shell injection if LLM-generated Stata code or file paths contain malicious shell commands. File operations such as `read_file`, `write_dofile`, `append_dofile`, and `load_figure` allow the LLM to interact with arbitrary file paths. Although `mk_dir` employs `pathvalidate` for sanitization, other file-related tools do not show explicit path sanitization against traversal attacks, which could potentially allow access or modification of files outside the intended working directory if an LLM is compromised. No hardcoded secrets were identified.

Similar Servers

Stats

Interest Score31
Security Score6
Cost ClassMedium
Avg Tokens1000
Stars1
Forks1
Last Update2025-12-04

Tags

StataMCPData AnalysisAI AssistantPython