inspect-runtime
Skill2 starsChanged 34 days agoApache-2.0View on GitHub
Triage a runtime issue in Mazarbul end-to-end. USE WHEN user reports an error, asks "why is X slow/failing", "investigate this incident", or pastes a panic trace. Walks logs -> traces -> pprof -> storage. NOT FOR code-quality issues (use /verify, /simplify) or version-mismatch checks (use /inspect-deploy).
In this repository41 other files it gives its agents.
- AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- 12-principles-of-animationSkill
- aip-namingSkill
- architectSkill
- babysit-abortSkill
- babysit-prSkill
- babysit-tickSkill
- baseline-uiSkill
- commit-pushSkill
- complex-refactorSkill
- critiqueSkill
- deadSkill
- devstackSkill
- go-backendSkill
- goSkill
- go-strictSkill
- greptileSkill
- impl-checkSkill
- inspect-dbSkill
- inspect-deploySkill
- interaction-designSkill
- issue-planSkill
- lessonsSkill
- mergeSkill
- new-resourceSkill
- plan-featureSkill
- preflightSkill
- pr-reviewSkill
- review-fixSkill
- reviewSkill
- shipSkill
- simplifySkill
- task-execution-protocolSkill
- teamSkill
- tui-component-browserSkill
- tui-design-labSkill
- tui-designSkill
- verifySkill
- wrap-upSkill
- write-docsSkill
The file
We split this skill into the rules it gives an agent
5 rules. About 0 are common, 3 are distinctive, and 2 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈3
Distinctive · estimate
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 15
When something is broken, you don't yet know which layer.
- Distinctive: line 34
When OTEL is wired (M2 work), traces go to the configured collector.
- Distinctive: line 38
If a code path is slow:
- Very specific: line 58
If the symptom looks like data corruption or stale data, drop down to /inspect-db.
- Very specific: line 73
pprof endpoint: must be enabled via --debug-addr.
≈ “Common” is an estimate: at least 1 in 5 of the 408,460 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Runtime triage
When something is broken, you don't yet know which layer. This skill walks the canonical layers in order so you don't skip a step.
Triage tree (run top to bottom; stop when you have a root cause)
1. Logs
Mazarbul uses zap structured logging to stderr by default:
./bin/maz mcp serve 2>&1 | tail -100 | jq -r 'select(.level == "error") | .msg + "\t" + .error'Watch for:
- Repeated error messages (a single bug, many invocations).
- Errors mentioning the kernel writer or scope enforcement (invariant violations).
- "context canceled" patterns (timeout cascades).
2. Traces (OpenTelemetry, when configured)
When OTEL is wired (M2 work), traces go to the configured collector. Stub for now.
3. Profile
If a code path is slow:
# Start the daemon with the pprof endpoint exposed
./bin/maz mcp serve --debug-addr=localhost:6060 &
# Capture
mise run pprof:cpu # 30s flame graph
mise run pprof:mem # heap profileFor a memory leak suspicion:
go tool pprof -http=:8080 http://localhost:6060/debug/pprof/heap
# Compare two captures 60 seconds apart.4. Storage
If the symptom looks like data corruption or stale data, drop down to /inspect-db.
Decision table
| Symptom | First check | If clean, then |
| MCP tool returns wrong shape | Logs at error level | Tool schema vs handler code |
| Recall is slow | Profile (mise run pprof:cpu) | Vector and FTS index counts |
| Daemon crashes | Logs around the crash | Run with -race to catch data races |
| Event log growing fast | Source-connector counts | Connector config (over-eager poll?) |
| Plugin won't load | Daemon stderr at startup | Plugin manifest validation |
Common gotchas
- Logs are JSON, not text, pipe through
jqfor usable output. - pprof endpoint must be enabled via
--debug-addr; not on by default in prod-mode. - Race detector has runtime overhead; only run with
-racewhen diagnosing concurrency bugs.
What this skill is NOT
- A replacement for actual telemetry. When OTEL is wired, traces give you more than logs alone.
- Storage-layer inspection, that's
/inspect-db.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

