gstack-investigate

gstack-investigate is a skill for Claude Code, Codex from garrytan/gstack. It costs 40 tokens per session (1,164 once invoked), scanned A, original, MIT.

A debugging procedure for finding the underlying cause of a failed test, code error, or incorrect result before changing code. It ends with a fix and a regression test, which is a test that prevents the same bug from returning.

In plain words
What is it for?
Use it to inspect recent repository changes, reproduce the failure, identify and prove its root cause, apply the smallest fix, and verify it with a regression test.
Why use it?
It reduces repeated symptom fixes and avoids making later debugging harder. Reproducing the problem first provides evidence instead of relying on an untested guess.

Skill for Claude CodeCodex

Which agent this was written for is unclear — built for gstack. Also seen: built for gstack.

Good fit Use it to inspect recent repository changes, reproduce the failure, identify and prove its root cause, apply the smallest fix, and verify it with a regression test.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/garrytan/gstack/gstack-investigate
About the project

gstack is a set of opinionated tools that gives a coding agent workflows associated with roles such as product leadership, design, engineering management, release management, documentation, and quality assurance. It is for developers who want one coding agent to support more parts of the software delivery process.

garrytan/gstack · 139,952 stars · on GitHub

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.

Any agent
npx skills add garrytan/gstack --skill gstack-investigate
Clone the repo
git clone --depth 1 https://github.com/garrytan/gstack

Made for: Claude Code, Codex.

Wrote 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.

agentmods badge for gstack-investigate

README.md
[![agentmods](https://agentmods.dev/badge/skills/garrytan/gstack/gstack-investigate/github.svg)](https://agentmods.dev/skills/garrytan/gstack/gstack-investigate)
Your own site
<a href="https://agentmods.dev/skills/garrytan/gstack/gstack-investigate"><img src="https://agentmods.dev/badge/skills/garrytan/gstack/gstack-investigate/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.

agentmods 80×15 button for gstack-investigate

Your own site · 80×15
<a href="https://agentmods.dev/skills/garrytan/gstack/gstack-investigate"><img src="https://agentmods.dev/badge/skills/garrytan/gstack/gstack-investigate.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 40 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,164 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
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.1 $0.00040 $0.01164
Opus 5.5 $0.00016 $0.00466
Sonnet 5.5 $0.00008 $0.00233
Haiku 4.5 $0.00004 $0.00116

Measured yesterday against content hash 5eb9030fe895, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

gstack-investigate 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 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.

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.

qm/sandbox/skills/gstack-investigate/SKILL.md · 94 lines

How it starts

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

Investigate: root cause before any fix

Start here, before reading code. In the repository (cd into it first: the shell starts in the workspace root), run with execute, adding the failing file or directory if you know it:

git status --short
git log --oneline -20 -- <path>

Then reproduce the symptom with the project's own test or run command, and write down what you saw, before you form a hypothesis.

Iron Law

NO FIXES WITHOUT ROOT CAUSE INVESTIGATION FIRST.

Fixing symptoms creates whack-a-mole debugging. Every fix that doesn't address root cause makes the next bug harder to find. Find the root cause, then fix it.

How to work

Find the root cause, fix it with the smallest change, prove the fix, and finish with the DEBUG REPORT below. The order, tools and depth are yours. Three lessons that cost real time before:

  • Before calling two queries, helpers or code paths duplicates, read their call sites: what looks identical usually differs in a caller's guard, transaction or scope, and the "duplicate" is the one that is right.
  • Before timing anything that spawns git in a benchmark or bisect worktree, run git update-index --refresh there: a stale index makes the first git status/git diff pay a full refresh and the measurement lies.
  • Two fixes that shared one premise failed the same gate — write the premise down in one sentence and test it before a third fix. The evidence already points away from it.

Three guards:

  • 3-strike rule: if 3 hypotheses fail, STOP and ask the user: A) continue with a new hypothesis (describe it), B) escalate for human review, C) add logging and wait.
  • Blast radius: if the fix touches more than 5 files, ask the user: A) proceed, the root cause spans these files, B) split, fixing the critical path now, C) rethink for a more targeted approach.
  • Web searches: search the generic error class, library and version, never the raw error text, hostnames, IPs, file paths, SQL, customer data or secrets.

Read the full file on GitHub · 94 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 · 94 lines · 40 tokens per session scan A 5eb9030fe895

Subscribe to this mod's changes

gstack-investigate is a skill published in the GitHub repository garrytan/gstack (139,952 stars, last pushed yesterday), licensed MIT. It adds 40 tokens to every session and 1,164 once invoked, about $0.0002 per session on Opus 5.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-11-06.

Related

gstack-investigate compared with skills from other repositories

gstack-investigate next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
gstack-investigategarrytan/gstackSkill140kyesterdayMITA40Claude Code, Codex
testinggarrytan/gbrainSkill32kyesterdayMITA63Claude Code
verifyYeachan-Heo/oh-my-claudecodeSkill41kyesterdayMITA12Claude Code
detect-static-dependenciesdotnet/skillsSkill5.8kyesterdayMITA135Claude Code
testing-blocksadobe/skillsSkill319yesterdayApache-2.0A61Claude Code
dart-downstream-fixdartsim/dartSkill1.2kyesterdayBSD-2-ClauseA25Claude Code
experiment-iterative-coderEvoScientist/EvoSkillsSkill48610d agoApache-2.0A145Claude Code