proc-stats: A Task Manager for Claude Code Sessions

A Claude Code session can use around 450 MB of RAM before it runs any commands. Open a few sessions, and that starts to add up.

Claude Code draws its interface with Ink, React for the terminal, and ships as a Bun-compiled binary. That gives you a nice terminal UI, but it comes with a memory cost. Then the session starts working: subagents run in parallel, test runners start, dev servers and watchers keep running, and MCP servers load.

Have you noticed your laptop getting sluggish, or Claude Code taking longer on tasks it used to finish quickly? Memory pressure could be part of the problem.

When RAM runs short, the operating system may keep moving memory pages between RAM and swap. If that becomes constant, your machine spends more time shuffling memory than doing the work you asked it to do. That’s thrashing.

You can’t fix what you can’t see, so I built proc-stats, a Claude Code mod that works like a task manager for your session.

See what the session is running

The status line shows the session’s memory, CPU usage, and uptime, including the resources used by the processes it started. You can keep an eye on it without leaving the conversation.

Run /proc-stats to open a live process pane. It shows the session’s processes as a tree, with commands labeled by the tool or subagent that started them when that information is available. You can see what’s running, inspect a process, and sort by CPU, memory, or runtime.

It also tracks detached processes on Linux and macOS: the nohup server or tunnel that keeps running after the command ends. Those processes count toward the session’s totals too. Detached-process tracking isn’t available on Windows, and on supported platforms it depends on the process retaining the session’s environment marker.

Catch resource use before it gets out of hand

proc-stats shows warnings and alerts when the session’s memory or CPU usage climbs past configurable thresholds. It can also notify you when a process stays busy or grows large.

If you spot a runaway process, select it in the pane and press k to request a stop, then y to confirm. That stops the process and its children. If they don’t exit, the pane offers a force-stop option. Claude Code’s own process can’t be stopped from the pane.

There’s also /proc-stats report, which adds a resource summary to the conversation so Claude can read it too. It includes current usage, recent peaks, and the processes using the most memory.

Watching the work happen

It’s built on Claude Code Mods, which let a mod add live panes, status lines, slash commands, and hooks into tool calls. That’s what lets proc-stats connect commands to the work that started them and show a live pane inside the terminal.

I also like it for a reason I didn’t expect: you can watch how Claude Code does its agentic work. Commands start, fan out, and finish in real time. The process tree gives you another view of what’s happening beyond the conversation.

Try it

Install it from a Claude Code prompt:

/plugin install proc-stats --marketplace DragosMocrii/proc-stats

Confirm the marketplace prompt, then choose an installation scope. User scope loads it in every session.

You can find the source and full documentation on GitHub. I hope you find it useful. Feedback and issues are welcome!