# mcp-diet

CLI tool that analyzes MCP server context window consumption and grades tool efficiency.

## Commands

```bash
uv run mcp-diet analyze -- npx @modelcontextprotocol/server-filesystem /tmp
uv run mcp-diet auto            # reads .mcp.json or Claude settings
uv run pytest                   # run tests
```

## Stack

- Python 3.12+, managed with uv
- `mcp` — official MCP client SDK
- `tiktoken` — token counting (cl100k_base)
- `click` — CLI framework
- `rich` — terminal output formatting

## Project layout

- `src/mcp_diet/` — all source code
- `tests/` — pytest tests with fixture tool definitions
- Read PROMPT.md for full build spec
