Files
gw-triage/skills/map-repo/SKILL.md

2.7 KiB
Raw Blame History

name, description
name description
map-repo Use when generating or refreshing a codebase's triage profile for the gw-triage plugin — run from inside the repo to map. Triggers on /map-repo, "mappa questo repo", "aggiorna il profilo di triage".

Map-repo — profilo di triage del codebase

You generate a triage knowledge profile for the repo the user is in, and guide them to publish it to the gw-triage plugin repo.

All interaction with the user happens in Italian. The generated profile is written in English (it is read by the triage model, not by humans).

Step 1 — Identify the repo

  • git rev-parse --show-toplevel — if not a git repo, ask (Italian) to cd into the repo to map and stop.
  • Repo name = basename of the toplevel, lowercased.

Step 2 — Survey

Read ${CLAUDE_PLUGIN_ROOT}/knowledge/README.md (the profile format). Dispatch ONE exploration subagent with this prompt, filling :

Survey the codebase at to build a triage profile. Report back, with file evidence: (1) what the system does — main responsibility in one line; (2) user-visible surfaces: screens / pages / endpoints / dashboards a user might screenshot, with their on-screen titles and labels; (3) error presentation: how failures appear to users — banners, dialogs, toasts, their exact wording in every language present, HTTP/gRPC codes surfaced, what a crash looks like; (4) the domain vocabulary users see (menu labels, entity names, Italian terms); (5) integrations that fail visibly (payments, chat, auth, push notifications); (6) what this system does NOT do — adjacent systems it talks to and symptoms that belong to them. Return a structured report; do not write any file.

Step 3 — Write the profile

Write <repo-name>.md following the six headings of knowledge/README.md, all sections non-empty, 100200 lines, English. Write it to a temporary location first (the session scratchpad or /tmp). Present a short Italian summary to the user with the file path.

Step 4 — Publish

Ask (Italian) for the local path of the user's gw-triage checkout; offer to git clone <plugin-repo-url> if they don't have one (read the URL from git remote get-url origin run in ${CLAUDE_PLUGIN_ROOT} if available, otherwise ask).

With the user's confirmation, in the checkout:

  1. Copy the profile to knowledge/<repo-name>.md (overwrite if refreshing).
  2. Bump the patch version in .claude-plugin/plugin.json (e.g. 0.1.0 → 0.1.1).
  3. git add knowledge/<repo-name>.md .claude-plugin/plugin.json then git commit -m "knowledge: add/update <repo-name> profile" — ask before committing, and ask again before git push.
  4. Tell the user (Italian) that teammates receive the update with /plugin marketplace update gw-triage.