Getting it into your agent
It runs from inside its repository, so the clone comes first — what it calls does not travel with the file alone.
git clone --depth 1 https://github.com/atretyak1985/swarmerynpx agentmods add commands/atretyak1985/swarmery/ci-diagnoseWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/commands/atretyak1985/swarmery/ci-diagnose)<a href="https://agentmods.dev/commands/atretyak1985/swarmery/ci-diagnose"><img src="https://agentmods.dev/badge/commands/atretyak1985/swarmery/ci-diagnose/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/commands/atretyak1985/swarmery/ci-diagnose"><img src="https://agentmods.dev/badge/commands/atretyak1985/swarmery/ci-diagnose.svg" alt="Reviewed on agentmods" width="80" height="20"></a>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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00025 | $0.01567 |
| Opus 5 | $0.00013 | $0.00783 |
| Sonnet 5 | $0.00005 | $0.00313 |
| Haiku 4.5 | $0.00003 | $0.00157 |
Grade A, and why
ci-diagnose scanned grade A with 0 findings 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 6d ago.
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.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 149 lines — stays where its author put it; the contents beside it link to each section on GitHub.
/ci-diagnose — GitLab pipeline failure forensics
Given a failed pipeline ID (or auto-detect the most recent failed pipeline on main), produce a diagnostic report: which jobs failed, the full trace of each, pattern-matched root-cause hypothesis, and specific recovery commands.
Usage
/ci-diagnose # auto-find most recent failed pipeline on main
/ci-diagnose <pipeline-id> # inspect a specific pipeline
/ci-diagnose -R <repo> # non-default repo
What it does
- Pipeline overview —
glab ci getto map job states. - Failed-job traces —
glab ci trace <job>for each job with statefailed. Tail of each (last ~100 lines is usually enough). - Pattern match against known failure modes (if the project keeps a curated failure-modes taxonomy in its docs, consult it first):
| Pattern in log | Root-cause hypothesis | Recovery |
|---|---|---|
[ERROR] Required secret '<app>-*' not found in namespace '<namespace>' |
Missing bootstrap secret | Run the project's bootstrap-secrets script/command |
Save error occurred: can't get a valid version for dependency |
Chart.yaml / Chart.lock drift | bash scripts/check-chart-sync.sh in the chart repo; helm dependency update . |
ERROR: remote payload exited 1 without other context |
Remote deploy wrapper swallowed stderr — look at stdout in the remote-output capture | SSH to the VM and re-run the failing script manually; check the preceding [ERROR] lines |
helm rollback failure or --atomic rollback triggered |
Pod readiness probe failing; likely env-var missing or config broken | Check deployment env block; check pod logs |
FAILED_PRECONDITION: Secret Version is in DESTROYED state |
GCP Secret Manager destroyed-version | Repopulate the secret version via the project's bootstrap-secrets flow |
Too many authentication failures |
SSH agent crowded with keys | Ensure IdentitiesOnly=yes -o IdentityAgent=none in the SSH call (the project's SSH wrapper should set this) |
yaml Errors: non-empty in pipeline metadata |
CI YAML parse error | Open .gitlab-ci.yml / ci/includes/*.yml; glab ci lint locally |
IMAGE_DIGEST missing or malformed |
publish-metadata artefact didn't propagate | Retry build+publish; check build.env artefact |
[ERROR] Drift check from rollback |
Cluster-vs-versions drift (live digest ≠ version-pinning repo) | Run helm rollback <release> -n <namespace> on the VM first, then retry the staging rollback job |
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.
- 6d ago First seen · 149 lines · 25 tokens per session scan A d60a9db8d31e
ci-diagnose is a command published in the GitHub repository atretyak1985/swarmery (5 stars, last pushed today), licensed Apache-2.0. It adds 25 tokens to every session and 1,567 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.
Other commands, from other repositories
ci-sentinel
Daily autonomous classifier for failing PRs across your repos. Runs /ci-debug headless against every open PR with red required checks, posts the verdict as a collapsed PR comment, and appends to a per-repo .sentinel/ledger.jsonl. v1 is propose-don't-apply — NEVER auto-pushes a fix. Use when you're tired of /status…
ci-debug
Diagnose a failing CI run against an 11-pattern playbook. Classifies the failure, cites the relevant memory entry, proposes the exact fix command — but NEVER applies without explicit user approval. Use when a specific PR check or GitHub Actions run failed and you want a diagnosis instead of speculation. Don't use for…
debug
Diagnose Ansible playbook issues from symptoms.
perf-profile.template
This prompt was authored for Claude-style slash workflows. In Codex runtime, adapt tool calls as follows.
gws-keep
List and read Google Keep notes.
bug
Reproduce then TDD-fix a ready-for-agent bug ticket in this checkout. Web bugs get a browser repro first.