Stata-MCP

by SepineTam
Verified

local-only server

The server can only run on the client’s local machine because it depends on local resources.

Integrations

  • Supports running Stata statistical analysis on macOS systems, with Windows support planned for future releases.

Let LLM help you achieve your regression analysis with Stata.

Windows is supported now!


Looking for other Stata integrations or others?

  • A VScode or Cursor integrated here. Confused it? 💡 Difference
  • Jupyter Lab Usage (Important: Stata 17+) here
  • NBER-MCP 🔧 under construction

💡 Quick Start

For more detailed usage information, visit the Usage guide. If you are using Windows, follow Usage

Prerequisites

  • uv - Package installer and virtual environment manager
  • Claude, Cline, ChatWise, or other LLM service
  • Stata License
  • Your API-KEY from LLM

Installation

# Clone the repository git clone https://github.com/sepinetam/stata-mcp.git cd stata-mcp # Copy example config cp example.config.py config.py # Using uv (recommended) uv run stata_mcp.py 17 se # Test run with Stata 17 SE # Alternative setup with pip # python3.11 -m venv .venv # source .venv/bin/activate # pip install -r requirements.txt

Note: Windows support is not currently available. If you have a Stata license for Windows and would like to contribute, please submit a PR.

🔧 MCP Server Configuration

Claude

{ "stata-mcp": { "command":"uv", "args":[ "--directory", "/Users/yourname/path/to/repo/", "run", "stata_mcp.py", "17", "se" ] } }

ChatWise

Open ChatWise app and navigate to the tools tab (subscription required):

type: stdio ID: stata-mcp command: uv --directory /Users/yourname/path/to/repo/ run stata_mcp.py 17 se

Cline

{ "mcpServers": { "stata-mcp": { "command":"uv", "args":[ "--directory", "/Users/yourname/path/to/repo/", "run", "stata_mcp.py", "17", "se" ] } } }

📝 Documentation

For more detailed usage information, visit the Usage guide.

💡 Questions

🚀 Roadmap

  • macOS support
  • Windows support
  • Additional LLM integrations
  • Performance optimizations

⚠️ Disclaimer

This project is for research purposes only. I am not responsible for any damage caused by this project. Please ensure you have proper licensing to use Stata.

For more information, refer to the Statement.

🐛 Report Issues

If you encounter any bugs or have feature requests, please open an issue.

📄 License

MIT License and Extensions

📚 Citation

If you use Stata-MCP in your research, please cite this repository using one of the following formats:

BibTeX

@software{sepinetam2025stata, author = {Song Tan}, title = {Stata-MCP: Let LLM help you achieve your regression analysis with Stata}, year = {2025}, url = {https://github.com/sepinetam/stata-mcp}, version = {1.0.3} }

APA

Song Tan. (2025). Stata-MCP: Let LLM help you achieve your regression analysis with Stata (Version 1.0.3) [Computer software]. https://github.com/sepinetam/stata-mcp

Chicago

Song Tan. 2025. "Stata-MCP: Let LLM help you achieve your regression analysis with Stata." Version 1.0.3. https://github.com/sepinetam/stata-mcp.

📬 Contact

Email: sepinetam@gmail.com

Or contribute directly by submitting a Pull Request! We welcome contributions of all kinds, from bug fixes to new features.

✨ Star History

-
security - not tested
F
license - not found
-
quality - not tested

An MCP server that lets Large Language Models interact with Stata software to perform regression analysis and other statistical operations.

  1. Prerequisites
    1. Installation
      1. 🔧 MCP Server Configuration
        1. Claude
        2. ChatWise
        3. Cline
      2. 📝 Documentation
        1. 💡 Questions
          1. 🚀 Roadmap
            1. ⚠️ Disclaimer
              1. 🐛 Report Issues
                1. 📄 License
                  1. 📚 Citation
                    1. BibTeX
                    2. APA
                    3. Chicago
                  2. 📬 Contact
                    1. ✨ Star History
                      ID: wwch657j12