debug

A troubleshooting command for Golden Armada agent services. It checks service health, containers, Kubernetes workloads, resource use, events, and application logs.

In plain words
What is it for?
Use it to inspect local health endpoints, Docker containers, Kubernetes pods and events, OOM-kill reports, resource usage, and recent error logs.
Why use it?
It brings common checks into one process when an agent service is not responding, crashes, runs out of memory, or behaves unexpectedly.

Command for Claude Code

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add commands/thelobbi/claude/debug
Clone the repo
git clone --depth 1 https://github.com/TheLobbi/claude

Made for: Claude Code.

Per session 0 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,173 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00000 $0.01173
Opus 5 $0.00000 $0.00587
Sonnet 5 $0.00000 $0.00235
Haiku 4.5 $0.00000 $0.00117

Measured yesterday against content hash 69c7c9ac2701, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

debug scanned grade A with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

curl -s http://localhost:8080/health | jq '.' 2>/dev/null || echo "Service not responding"
.claude/commands/debug.md · 168 lines

How it starts

The opening of the file, as written. The whole thing — 168 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Debug Agent Issues

Comprehensive debugging for Golden Armada agent services.

Instructions

1. Identify the Problem

```bash

Quick health check

curl -s http://localhost:8080/health | jq '.' 2>/dev/null || echo "Service not responding"

Check if container is running

docker ps | grep golden-armada || echo "No containers running"

Check Kubernetes pods

kubectl get pods -n agents 2>/dev/null || echo "K8s not available" ```

2. Kubernetes Debugging

```bash

Pod status

kubectl get pods -n agents -o wide

Recent events

kubectl get events -n agents --sort-by='.lastTimestamp' | tail -20

Describe problematic pod

kubectl describe pod -n agents -l app.kubernetes.io/name=golden-armada | tail -50

Check for OOMKilled

kubectl get pods -n agents -o json | jq '.items[] | select(.status.containerStatuses[]?.lastState.terminated.reason=="OOMKilled") | .metadata.name'

Resource usage

kubectl top pods -n agents 2>/dev/null || echo "Metrics server not available" ```

3. Log Analysis

```bash

Application logs (last 100 lines)

kubectl logs -n agents deployment/golden-armada-backend-developer --tail=100 2>/dev/null

Filter for errors

kubectl logs -n agents deployment/golden-armada-backend-developer --since=1h 2>/dev/null | grep -i "error|exception|traceback" | head -50

Previous container logs (after restart)

kubectl logs -n agents deployment/golden-armada-backend-developer --previous 2>/dev/null | tail -50 ```

4. Docker Debugging

```bash

Container logs

docker logs $(docker ps -q -f name=golden-armada) --tail=100 2>/dev/null

Interactive shell

docker exec -it $(docker ps -q -f name=golden-armada) /bin/sh 2>/dev/null

Container inspection

docker inspect $(docker ps -q -f name=golden-armada) 2>/dev/null | jq '.[0].State' ```

5. Network Debugging

```bash

Check service endpoints

kubectl get endpoints -n agents

DNS resolution test

kubectl run -it --rm debug --image=busybox --restart=Never -- nslookup golden-armada-backend-developer.agents.svc.cluster.local 2>/dev/null

Read the full file on GitHub · 168 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. yesterday First seen · 168 lines · 0 tokens per session scan A 69c7c9ac2701

Subscribe to this mod's changes

debug is a command published in the GitHub repository TheLobbi/claude (21 stars, last pushed 5d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 1,173 tokens. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.