twg-engineering-work
Use together with the root twg skill. Exact command grammar must come from
live twg help, twg help <terms>, or twg help describe <path>.
CLI launcher fallback
Run twg <command>. On shell command not found, use $HOME/.local/bin/twg
(macOS/Linux) / $env:LOCALAPPDATA\Programs\twg\bin\twg.exe (PowerShell), then
tell user to add that directory to PATH. Do not treat auth or command errors as
PATH failures.
Use When
- "Which PRs are waiting for my review?"
- "Where is this API implemented or used?"
- "Which repositories directly depend on this package?"
- "Latest PRs for this issue"
- "Who contributed most to this repo/topic?"
- "Repos I created PRs in"
- "Stale reviews"
- "Review flow or bottlenecks"
- "PR-only status for a user, team, or repo"
- "PR status for Alice" or "this person's PRs"
- "My PRs this week"
- "Summarize my pull requests for a time window"
- "Open bugs/tasks with PRs in flight"
First Move
Resolve the engineering anchor:
- Repo prompt: identify workspace and repo from URL, local checkout, or repo query.
- PR prompt: resolve exact PR URL, ID, workspace, and repo.
- Workitem prompt: fetch/context the Jira workitem to discover linked PRs,
commits, branches, and repos.
- Topic prompt: resolve/search once, then find linked repos, PRs, and workitems.
- Code prompt: search the concrete package, API, symbol, or behavior, then
inspect only the source locations needed to verify the requested relationship.
Use matching typed pull-request, Bitbucket, Jira, context, and search commands.
Provider-native PR commands apply only to their host; Bitbucket
activity/comment/task commands never apply to GitHub PRs. Use focused help for
uncertain routes/contracts.
Route Selection
- For queues, query candidate PRs first, then hydrate selected PRs needing action.
- For stale reviews, group by repo, author, reviewer, and stage before fetching
detailed comments or diffs.
- For issue-to-PR lookup, use workitem context before broad PR text search.
- For repo contributors and hot areas, combine PR/commit/file-area signals with
ownership and review evidence.
- For PR leadership/team/org rollups, use
twg-status-rollups; this skill
supplements PR details.
- For person/repo status, collect merged/open PRs for relevant people, repos,
and window.
- Code: load
references/code-search.md.
- For person-scoped summaries with Jira, docs, meetings, planning, or
notifications, use
twg-status-rollups plus
../twg-status-rollups/references/personal-work-summary.md; this skill owns
PR-only work.
Evidence Policy
- Hydrate PR details, comments, tasks, pipeline status, and diff only for stale,
blocked, central, or high-impact PRs.
- For PR rollups, stop after the evidence set identifies the main themes,
repos/services, owners, and recency. Do not keep searching for more PRs when
the next batch would only add more examples of the same theme.
- For review status, include age, requested reviewers, comments/tasks, approval
state, CI/check or pipeline state, and last activity when the provider surface
exposes them.
- For repo/team reports, group by repo, service, or workstream rather than only
person counts.
- Inspect PR titles/descriptions and linked issues to infer themes; do not rank
solely by PR count.
- Keep Bitbucket, GitHub connector/tool, and Atlassian auth failures separate.
- If PR graph or repo-wide query calls repeatedly fail, make one narrower
fallback using known repos, people, workitems, or search anchors. If that also
fails, answer from the successful evidence and call out the PR coverage gap.
Recipe Cards
Review Queue
Query reviewer-scoped open PRs. Sort by waiting time, requested action,
unresolved tasks/comments, failing CI, and project relevance. Hydrate only PRs
that need action.
Stale Reviews / Review Bottlenecks
Find PRs open or waiting beyond the threshold. Group by repo, author, reviewer,
and stage. Identify bottleneck patterns such as missing reviewer, unresolved
tasks, failing CI, repeated request-changes, or owner unavailable.
Issue PRs
Use workitem context to find linked PRs, commits, branches, and repos. Fetch PRs
only if the user asks for details, status, or next action.
Repo Contributors / Hot Areas
Query PRs/commits for the repo and time window. Group by files/areas, authors,
reviewers, and themes. For hot areas, prioritize changed area plus frequency and
ownership signals.
PR-Based Status Rollup
Resolve org/team first, then collect PRs for members or repos in the time window.
Group into themes and repos/services. Call out gaps where PR-only evidence omits
Jira, docs, planning, or customer context.
For a single person where the prompt is broader than PRs, switch to
twg-status-rollups and load
../twg-status-rollups/references/personal-work-summary.md.
Output Shape
For queues, include PR, repo, owner, state, reason, next action, and evidence.
For engineering reports, summarize workstreams, contributors, bottlenecks,
risks, and gaps. Include stable URLs or IDs for key artifacts.
Anti-Patterns
- Do not guess Bitbucket workspace or repo.
- Do not fetch every PR body, diff, or comment in a large queue.
- Do not treat PR counts as impact.
- Do not mix Bitbucket, GitHub connector/tool, and Atlassian auth failures.
1---2name: twg-engineering-work3description: Use with root `twg` for code search, repositories using an API/package, implementation and reverse-dependency discovery, PR status and reviews, repo contributors, hot areas, and issue-to-PR lookups.4---56# twg-engineering-work78Use together with the root `twg` skill. Exact command grammar must come from9live `twg help`, `twg help <terms>`, or `twg help describe <path>`.1011## CLI launcher fallback1213Run `twg <command>`. On shell `command not found`, use `$HOME/.local/bin/twg`14(macOS/Linux) / `$env:LOCALAPPDATA\Programs\twg\bin\twg.exe` (PowerShell), then15tell user to add that directory to PATH. Do not treat auth or command errors as16PATH failures.1718## Use When1920- "Which PRs are waiting for my review?"21- "Where is this API implemented or used?"22- "Which repositories directly depend on this package?"23- "Latest PRs for this issue"24- "Who contributed most to this repo/topic?"25- "Repos I created PRs in"26- "Stale reviews"27- "Review flow or bottlenecks"28- "PR-only status for a user, team, or repo"29- "PR status for Alice" or "this person's PRs"30- "My PRs this week"31- "Summarize my pull requests for a time window"32- "Open bugs/tasks with PRs in flight"3334## First Move3536Resolve the engineering anchor:3738- Repo prompt: identify workspace and repo from URL, local checkout, or repo query.39- PR prompt: resolve exact PR URL, ID, workspace, and repo.40- Workitem prompt: fetch/context the Jira workitem to discover linked PRs,41 commits, branches, and repos.42- Topic prompt: resolve/search once, then find linked repos, PRs, and workitems.43- Code prompt: search the concrete package, API, symbol, or behavior, then44 inspect only the source locations needed to verify the requested relationship.4546Use matching typed pull-request, Bitbucket, Jira, context, and search commands.47Provider-native PR commands apply only to their host; Bitbucket48activity/comment/task commands never apply to GitHub PRs. Use focused help for49uncertain routes/contracts.5051## Route Selection5253- For queues, query candidate PRs first, then hydrate selected PRs needing action.54- For stale reviews, group by repo, author, reviewer, and stage before fetching55 detailed comments or diffs.56- For issue-to-PR lookup, use workitem context before broad PR text search.57- For repo contributors and hot areas, combine PR/commit/file-area signals with58 ownership and review evidence.59- For PR leadership/team/org rollups, use `twg-status-rollups`; this skill60 supplements PR details.61- For person/repo status, collect merged/open PRs for relevant people, repos,62 and window.63- Code: load `references/code-search.md`.64- For person-scoped summaries with Jira, docs, meetings, planning, or65 notifications, use `twg-status-rollups` plus66 `../twg-status-rollups/references/personal-work-summary.md`; this skill owns67 PR-only work.6869## Evidence Policy7071- Hydrate PR details, comments, tasks, pipeline status, and diff only for stale,72 blocked, central, or high-impact PRs.73- For PR rollups, stop after the evidence set identifies the main themes,74 repos/services, owners, and recency. Do not keep searching for more PRs when75 the next batch would only add more examples of the same theme.76- For review status, include age, requested reviewers, comments/tasks, approval77 state, CI/check or pipeline state, and last activity when the provider surface78 exposes them.79- For repo/team reports, group by repo, service, or workstream rather than only80 person counts.81- Inspect PR titles/descriptions and linked issues to infer themes; do not rank82 solely by PR count.83- Keep Bitbucket, GitHub connector/tool, and Atlassian auth failures separate.84- If PR graph or repo-wide query calls repeatedly fail, make one narrower85 fallback using known repos, people, workitems, or search anchors. If that also86 fails, answer from the successful evidence and call out the PR coverage gap.8788## Recipe Cards8990### Review Queue9192Query reviewer-scoped open PRs. Sort by waiting time, requested action,93unresolved tasks/comments, failing CI, and project relevance. Hydrate only PRs94that need action.9596### Stale Reviews / Review Bottlenecks9798Find PRs open or waiting beyond the threshold. Group by repo, author, reviewer,99and stage. Identify bottleneck patterns such as missing reviewer, unresolved100tasks, failing CI, repeated request-changes, or owner unavailable.101102### Issue PRs103104Use workitem context to find linked PRs, commits, branches, and repos. Fetch PRs105only if the user asks for details, status, or next action.106107### Repo Contributors / Hot Areas108109Query PRs/commits for the repo and time window. Group by files/areas, authors,110reviewers, and themes. For hot areas, prioritize changed area plus frequency and111ownership signals.112113### PR-Based Status Rollup114115Resolve org/team first, then collect PRs for members or repos in the time window.116Group into themes and repos/services. Call out gaps where PR-only evidence omits117Jira, docs, planning, or customer context.118For a single person where the prompt is broader than PRs, switch to119`twg-status-rollups` and load120`../twg-status-rollups/references/personal-work-summary.md`.121122## Output Shape123124For queues, include PR, repo, owner, state, reason, next action, and evidence.125For engineering reports, summarize workstreams, contributors, bottlenecks,126risks, and gaps. Include stable URLs or IDs for key artifacts.127128## Anti-Patterns129130- Do not guess Bitbucket workspace or repo.131- Do not fetch every PR body, diff, or comment in a large queue.132- Do not treat PR counts as impact.133- Do not mix Bitbucket, GitHub connector/tool, and Atlassian auth failures.