Investigate a GitHub issue or reported bug the way a seasoned maintainer would — form an independent model before reading the thread's theories, trace the mechanism and history, verify the diagnosis, and return a concise briefing with a verdict and fix direction. Use for triage, root-cause analysis, or re-investigation.
91%
Does it follow best practices?
Run evals on this skill
Adds up to 20 points to the overall score
Low
Low-risk findings worth noting
Investigate the issue as a maintainer deciding what is actually wrong and what should happen next. Help the human understand it without turning the investigation into a walkthrough. Run uninterrupted to a concise front page, then stay available inside the goal until the human says the investigation is finished.
The issue follows ARGUMENTS: at the end of the objective. If absent, infer it from the conversation or the checked-out branch name (fix/1234, issue-567, gh-890). If no issue can be resolved and no bug is described, ask once.
Use one ignored file: .mastracode/scratch/issues/<owner>-<repo>-<n>.md. Never stage or commit it.
Start the record with a short Own model:
Append the investigation beneath it and leave it unchanged afterward. Capture decisive evidence as you work so it survives context compression—a ledger, not command transcripts. Use references/templates.md as an example, not a schema.
Resolve the issue with the minimal recipe in references/recipes.md. The metadata tells you whether the thread has anything to anchor you: comment count and cross-referenced PRs.
If the thread has comments or linked PRs, form your model before reading them. Use only the issue title, body, reproduction, error text, and the current code on the default branch; do not consult mastra_expert or another source that may already hold a diagnosis. Other people's theories are cheap to read later and expensive to un-read—a maintainer's "I think it's X" tends to become the investigation. Write the model, then open the thread.
If the thread is empty, there is nothing to seal. Investigate directly and write the model whenever you have one; it still records what you believed before verification.
Either way: start from the symptom, find the entry point, trace the mechanism to where the observed behavior is produced, and identify every area that could contribute—shared state, upstream data, configuration, callers, ordering. Stop when you can name a hypothesis and the evidence that would settle it.
If the report is too thin to trace (no symptom, no surface, no version), say so in the front page and draft the exact questions to ask—but still investigate whatever can be investigated.
Read every comment, linked PR, and related issue. Then:
Author context (first-time reporter vs. core contributor) informs where you look first, never whether you trust the report.
Use these questions where they apply. They shape judgment; they are not rows to fill.
Open deeper branches when the mechanism crosses them:
History answers whether the current behavior is an accident or a decision, and when a regression entered. Run a light pass when the code's rationale is unclear or the behavior is old and stable. Go deep on a regression, a revert, repeated churn, "because/workaround/don't/see #" comments, or a test named after a past bug.
Use blame, git log -S, originating PRs, and linked issues. End with the implication for this issue. "Nothing notable" is a valid result. Recipes live in references/recipes.md.
Once the thread is open, mastra_expert may help orient you on Mastra-specific history. Verify its leads yourself; it is not required.
Choose the smallest verification that could falsify it:
Never claim a reproduction you did not run. Never keep a diagnosis after contrary evidence resolves it.
Verdicts: bug / regression of <sha or #pr> / working as designed / configuration or usage / docs gap / duplicate of #N / cannot determine — needs <specific info>.
State the diagnosis as a claim with its mechanism and evidence. Do not present a candidate list when the evidence supports one cause; present candidates only when it genuinely does not, and then say which you favor and what would decide it. A question to the reporter is allowed only when the answer could change the verdict—and it must be a specific, answerable question, not a hedge.
State the fix direction as a request: the pointer, what should change, and why the obvious patch would or would not suffice. Note secondary work (docs, other affected sites, missing test) explicitly rather than folding it in.
Write the rest of the record for the human. Lead with the mechanism and diagnosis, then include only useful context: evidence, relevant history, related issues, hunks to read, and decisions that genuinely need the human. Omit empty sections. No self-audit or process narration.
Then post the front page in chat. It should make the result understandable quickly and leave nothing out that the human would have to ask for:
This is a content contract, not a template. There is no line budget. Cut narration, process, and self-audit—never conclusions. Omit what does not apply. Offers follow from the diagnosis—draft an issue comment, draft a request-for-info comment, or start a fix—and zero offers is fine.
After posting, go to waiting. Answer follow-up questions from the record without reposting the summary. The goal ends only when the user explicitly says the investigation is finished.
Read the existing record first. The own model already exists; do not recreate it. Inspect only what changed—new comments, new commits on the default branch, new linked PRs—and report whether the diagnosis stands, changes, or is resolved. If nothing changed, say so briefly and wait.
Apply this to the local briefing and to any drafted or posted GitHub comment. Before drafting or posting anything to GitHub, load the gh-review skill and follow it: the diagnosis is stated as a claim, the fix is a required change, and nothing is hedged or deferred.
Never post comments, push commits, open issues, or create other GitHub artifacts without the user explicitly saying to post. Show the draft; wait for the go.
Judge investigation quality, not ritual. Open the record, inspect the front page, and spot-check evidence where needed. Send the executor back only when a substantive invariant fails:
Do not bounce for section order, labels, exact fields, word counts, omitted empty sections, the executor's chosen commands, or formatting when the meaning is clear. Do not require a reproduction, history search, or offer merely because one could exist.
mastra-ai/mastra
31ddf86
If you maintain this skill, you can claim it as your own. Once claimed, you can manage eval scenarios, bundle related skills, attach documentation or rules, and ensure cross-agent compatibility.