# Stata Environment Diagnose

> Stata Environment Diagnose is an Agent Skill for testing & quality published in the brycewang-stanford/Auto-Empirical-Research-Skills repository on GitHub: a SKILL.md instruction file an AI agent can load to do this task.

Diagnose local Stata, MCP, package, startup, graph-export, and permissions issues. Use when setup is failing, Stata is not discovered, packages are missing, logs are truncated, or a managed machine behaves differently from a normal workstation.

- Skill name: `stata-environment-diagnose`
- Category: [Testing & Quality](https://www.openparable.com/skill/testing-quality/1)
- Source: https://github.com/brycewang-stanford/Auto-Empirical-Research-Skills/blob/HEAD/skills/64-tmonk-mcp-stata/skills/stata-environment-diagnose/SKILL.md
- Repository: brycewang-stanford/Auto-Empirical-Research-Skills (2,866 GitHub stars when collected)

## SKILL.md

# Environment Diagnose

Use this skill for setup and platform troubleshooting.

1. Verify detection with `stata_manage_session(action="detect")`.
2. Reproduce the smallest failing command.
3. Use logs, package checks, and environment reporting before suggesting a fix.
4. Separate root cause, evidence, remediation, and verification.

Read `references/troubleshooting.md` for the diagnosis flow and use `scripts/report_environment.py` for a deterministic environment summary.

---

Source: https://www.openparable.com/skill/testing-quality/stata-environment-diagnose (OpenParable). Cite the canonical URL above.
