From 509b10ac577b7a57f76443b23a482426b8c0e3e0 Mon Sep 17 00:00:00 2001 From: Felix Faerber Date: Sat, 4 Jul 2026 11:56:27 +0300 Subject: [PATCH] fix(routing): expose agent skills in the roster so pm routes by capability MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The homelab health-check test mis-routed a node1 inspection to @junior (skills: []), which cannot reach node1 — only @senior/@lead hold node1-ssh. Root cause: the roster shown to agents listed desc + vision but not skills, so @pm had no way to route by capability (despite a comment claiming it could). Add each teammate's skill names to the roster line. Names only; the scoped how-to detail stays hidden via permission.skill. Co-Authored-By: Claude Opus 4.8 (1M context) --- .gitea/workflows/scripts/run-agent.sh | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.gitea/workflows/scripts/run-agent.sh b/.gitea/workflows/scripts/run-agent.sh index 45bd4e6..d913160 100755 --- a/.gitea/workflows/scripts/run-agent.sh +++ b/.gitea/workflows/scripts/run-agent.sh @@ -10,7 +10,10 @@ set -u [ -z "$CMT" ] && CMT="(a new issue was just opened — assess it)" THREAD=$(cat /tmp/thread.md 2>/dev/null); [ -z "$THREAD" ] && THREAD="(no prior comments)" DESC=$(jq -r --arg a "$NAME" '.[$a].desc' /tmp/agents.json) -ROSTER=$(jq -r 'to_entries | map("- @\(.key): \(.value.desc) (vision: \(.value.vision))") | join("\n")' /tmp/agents.json) +# Include each teammate's skills so an agent (esp. @pm) can route by capability — e.g. only +# @senior/@lead hold node1-ssh, so a node1 task must not go to @junior. Skill *names* only; the +# scoped how-to detail stays hidden per the permission.skill allow-list. +ROSTER=$(jq -r 'to_entries | map("- @\(.key): \(.value.desc) (vision: \(.value.vision); skills: \(.value.skills | if length>0 then join(", ") else "none" end))") | join("\n")' /tmp/agents.json) if [ "$VISION" = "true" ]; then CAP="You CAN read images attached to the issue."; else CAP="You CANNOT read images — you are a text-only model."; fi NOTE="" if [ "$VISION" != "true" ] && [ "${HAS_IMAGES:-0}" -gt 0 ]; then -- 2.54.0