Metadata-Version: 2.4
Name: unclog
Version: 0.2.1
Summary: Audit your Claude Code installation and clear context-window bloat. Local-only.
Project-URL: Homepage, https://github.com/thomaschill/unclog
Project-URL: Repository, https://github.com/thomaschill/unclog
Project-URL: Issues, https://github.com/thomaschill/unclog/issues
Author: Tom Hill
License: MIT License
        
        Copyright (c) 2026 Tom Hill
        
        Permission is hereby granted, free of charge, to any person obtaining a copy
        of this software and associated documentation files (the "Software"), to deal
        in the Software without restriction, including without limitation the rights
        to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
        copies of the Software, and to permit persons to whom the Software is
        furnished to do so, subject to the following conditions:
        
        The above copyright notice and this permission notice shall be included in all
        copies or substantial portions of the Software.
        
        THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
        IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
        FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
        AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
        LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
        OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
        SOFTWARE.
License-File: LICENSE
Keywords: audit,claude,claude-code,cli,context,llm
Classifier: Development Status :: 3 - Alpha
Classifier: Environment :: Console
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: MacOS
Classifier: Operating System :: POSIX :: Linux
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Topic :: Software Development
Classifier: Topic :: Utilities
Classifier: Typing :: Typed
Requires-Python: >=3.11
Requires-Dist: readchar>=4.0
Requires-Dist: rich>=13.7
Requires-Dist: tiktoken>=0.7
Requires-Dist: typer>=0.12
Provides-Extra: dev
Requires-Dist: mypy>=1.11; extra == 'dev'
Requires-Dist: pytest-snapshot>=0.9; extra == 'dev'
Requires-Dist: pytest>=8.0; extra == 'dev'
Requires-Dist: ruff>=0.6; extra == 'dev'
Description-Content-Type: text/markdown

# unclog

[![PyPI](https://img.shields.io/pypi/v/unclog.svg)](https://pypi.org/project/unclog/)
[![GitHub stars](https://img.shields.io/github/stars/thomaschill/unclog?style=flat&logo=github)](https://github.com/thomaschill/unclog)

**Every agent, skill, and MCP server you've installed occupies your Claude Code context window on every turn.** `unclog` scans your install, shows you what's costing tokens, and lets you handpick what to delete — locally, with no telemetry, no accounts, and no network calls.

```
# install
uv tool install unclog

# run
unclog
```

![unclog scan output](https://raw.githubusercontent.com/thomaschill/unclog/main/screenshot.png)

## What it shows

- Every **agent** in `~/.claude/agents/`, with its token cost.
- Every **skill** in `~/.claude/skills/`, with its token cost.
- Every **slash command** in `~/.claude/commands/`, with its token cost.
- Every **MCP server** declared in `~/.claude.json` (global and per-project), with its measured session-token cost when available.
- A **baseline** — the total tokens loaded before you type a single message.

## Remove what's costing you

![unclog interactive curate flow](https://raw.githubusercontent.com/thomaschill/unclog/main/demo.gif)

After the scan, one sectioned picker opens. Tick the agents / skills / commands / MCPs you want to remove, hit `enter`, confirm once, done. A post-apply line shows how many tokens you saved and the new baseline.

Picker keys: `↑↓` move · `space` toggle · `a` / `A` check section / all · `n` / `N` clear section / all · `enter` apply · `q` quit.

**Actions are destructive.** Deleted files are removed from disk — there is no undo command. MCP servers are a softer case: they're renamed to `__unclog_disabled__<name>` in your config, so you can revive one by hand-editing `~/.claude.json` and removing the prefix.

## Requirements

Python 3.11+, Claude Code ≥ 2.1.90, macOS or Linux.

## Development

```
uv sync --all-extras --dev
uv run pytest
uv run ruff check src tests
uv run mypy src/unclog
```

## License

MIT. See [LICENSE](LICENSE).
