Root-cause analysis for AI Agents, agentic workflows and Now Assist skills — from a Chrome side panel, using your own logged-in session.
When an AI Agent run fails in ServiceNow, the evidence is never in one place. The execution plan is in one table, its tasks in another, tool executions and LLM calls in two more, the Virtual Agent transcript somewhere else again — and the thing the user actually saw is three joins away from the thing that broke. I got tired of spelunking, so I built a Chrome side panel that does the spelunking for me. Here is what it looks like — the panel below is clickable:
look_up_order → 200 (312 ms)// ServiceNow AI Debugger: stop 1 stuck run(s) // Review it, keep DRY_RUN = true for a first run, read // the output, then set DRY_RUN = false. (function () { var DRY_RUN = true; // nothing changes until you flip it var EXPECTED_INSTANCE = "dev82613"; var MAX_RECORDS = 200; // safety cap ... })();
The extension never runs scripts. It opens Scripts ‑ Background with this filled in, in dry-run mode, and you click Run.
Read-only, your session, no server. The extension sends GET requests as you, to your instance, and nothing else. No service account, no backend, no telemetry. If you can't see a table, neither can it. This one decision removed almost every hard conversation about running it against a production instance.
Stop scripts that never run themselves. Sometimes the diagnosis is "this run will never finish" and you want it stopped. The extension generates a Scripts - Background snippet — dry-run by default, pinned to the instance it was generated for, capped at 200 records — opens it for you, and you click Run. The extension never writes to the instance; the admin does, with the script in front of them.
Claude analysis is optional and bring-your-own-key. With an Anthropic API key set, "Analyse with Claude" sends a redacted summary of the trace to the API under your key. Without one, "Copy prompt for claude.ai" gives you the same thing to paste into a chat. The default is neither — the rules engine works offline.
Before the first commit, an automated security review flagged something half-handled: the generated stop scripts embed record display names in // comments, and the code stripped \r and \n — but not U+2028 and U+2029, the Unicode line separators that the ES5 engine behind Scripts - Background treats as line breaks and JSON.stringify leaves raw. A hostile record name could have broken out of the comment and injected code into a script an admin runs with full rights. The fix sanitizes every value inside the header builder itself, and builds those characters with String.fromCharCode so no tooling can ever "helpfully" decode them again.
Manifest V3, no build step — the repo is the extension. Pure-logic modules in lib/ (collectors, rules, timeline, redaction, report) with 35 Node tests that run against a mock instance, so the rules engine is testable without a ServiceNow instance in the loop. GitHub Actions runs the suite on every push. MIT licensed — issues and PRs welcome.
git clone https://github.com/legato27/sn-ai-debugger.gitchrome://extensions, switch on Developer mode.Independent open-source project — not affiliated with, endorsed by or supported by ServiceNow or Anthropic. Privacy: the extension talks only to your instance (and, only if you add a key, api.anthropic.com). No telemetry, no third-party servers, PII redaction on by default for exports. Chrome 116+, works on *.service-now.com out of the box.