Detrix MCP Server

Local setup required. This server has to be cloned and prepared on your machine before you register it in Claude Code.
1

Set the server up locally

Run this once to clone and prepare the server before adding it to Claude Code.

Run in terminal
git clone https://github.com/flashus/detrix
cd detrix

Then follow the repository README for any remaining dependency or build steps before continuing.

2

Register it in Claude Code

After the local setup is done, run this command to point Claude Code at the built server.

Run in terminal
claude mcp add detrix -- node "<FULL_PATH_TO_DETRIX>/dist/index.js"

Replace <FULL_PATH_TO_DETRIX>/dist/index.js with the actual folder you prepared in step 1.

README.md

Give your AI agent eyes inside any running program.

Detrix

Give your AI agent eyes inside any running program.

  • Watch any variable at any line — agent sets an observation point in seconds, zero code changes during debugging
  • Local or cloud — same workflow for Docker containers and remote hosts
  • Python, Go, Rust — observation points capture values without pausing, without restarting
  • Built for agents — observe, query, manage observations via natural language; Claude Code, Cursor, Windsurf

See It in Action

1-minute demo: A Go service in Docker starts reporting wrong numbers. Nothing in the client code changed. Claude watches it live and finds the cause.

Here's what the session looks like:

You:    "The order-service in Docker is reporting wildly inflated revenue.
         Daily total is in the thousands when transactions should be $20-200."

Agent:  → reads the source, spots dead unit-conversion code
        → wakes the service via Detrix
        → observes txn.Amount, txn.Unit, total
          (no line number — find_variable locates it in the running container)

        "Found it. The pricing API changed what it's returning.

        txn.Amount = 8957, txn.Unit = "cents" → should be $89.57, summed as $8957

        In calculateRevenue, the unit field is fetched and discarded:

        unit := txn.Unit
        _ = unit          // ← conversion was intended, never implemented
        total += amount   // ← adds cents as if they were dollars

        This didn't matter before. It matters now."

        → fixed the client code
        → reported the API contract change upstream

No code was modified to instrument. No restarts. The old workflow — add a log line, rebuild, redeploy, wait for the bug to reproduce — replaced by watching it live.

You don't need to know the line number either — describe the behavior and the agent finds where to look.


Why Detrix?

You hit a bug. The old workflow: add a print, restart, reproduce, remove the print, repeat. If it's in production, redeploy. If it's in a Docker container, get into the container. If it's intermittent, wait.

With Detrix, you just ask the agent. It finds the right line, plants an observation point, and tells you what it sees — live, nothing restarting.

That bug that cost you hours last week — redeploy after redeploy, still can't reproduce — your agent can investigate it in minutes, while your app keeps running.

print() / logging Detrix
Iteration speed Hours (edit → rebuild → deploy) Minutes
Add new observation Edit code → restart Ask the agent — no code, no restart¹
Production-safe Output pollution, perf risk Non-breaking observation points
Events Ephemeral stream Stored, queryable by metric and time
Capture control Every hit, no filtering Throttle, sample, first-hit, interval
Cleanup Manual (easy to forget, ships to prod) One command — or automatic expiry
Sensitive data Secrets can leak via log output Sensitive-named vars blocked by default; configurable blacklist + whitelist in detrix.toml

¹ Embed detrix.init() once for zero restarts forever. Or restart once to attach the debugger (--debugpy, dlv, lldb-dap) — from that point on, the agent adds and removes observations without any further restarts.


Quick Start

Try it in 2 minutes. Your agent handles everything after step 3.

1. Install Detrix

macOS (Homebrew):

brew install flashus/tap/detrix

macOS / Linux (shell script):

curl --proto '=https' --tlsv1.2 -LsSf \
  https://github.com/flashus/detrix/releases/latest/download/detrix-installer.sh | sh

Windows (PowerShell):

irm https://github.com/flashus/detrix/releases/latest/

Tools (2)

find_variableLocates a variable in the running container or process to set an observation point.
observeCaptures values of variables at specific points without pausing or restarting the application.

Environment Variables

DETRIX_CONFIGPath to the detrix.toml configuration file for blacklist/whitelist settings.

Configuration

claude_desktop_config.json
{"mcpServers": {"detrix": {"command": "detrix", "args": ["mcp"]}}}

Try it

Find the variable responsible for the inflated revenue calculation in the order-service container.
Set an observation point on the user_id variable in the authentication module and report back when it changes.
Monitor the transaction amount in the payment processing function and alert me if it exceeds $1000.
List all active observation points currently set in the running Go service.

Frequently Asked Questions

What are the key features of Detrix?

Watch variables at any line without code changes. Zero-restart debugging for Python, Go, and Rust. Support for local, Docker, and remote host environments. Natural language query and management of observations. Configurable sensitive data blacklisting and whitelisting.

What can I use Detrix for?

Debugging intermittent production bugs without redeploying code. Investigating API contract changes by observing live variable values. Monitoring variable states in Docker containers without manual log injection. Analyzing performance bottlenecks by sampling variable values in real-time.

How do I install Detrix?

Install Detrix by running: brew install flashus/tap/detrix

What MCP clients work with Detrix?

Detrix works with any MCP-compatible client including Claude Desktop, Claude Code, Cursor, and other editors with MCP support.

Turn this server into reusable context

Keep Detrix docs, env vars, and workflow notes in Conare so your agent carries them across sessions.

Need the old visual installer? Open Conare IDE.
Open Conare