Repository navigation
[Bug]: Skill discovery never scans repo-local .agents/skills (Agent Skills standard dir) #5487
Description
Before submitting
- I searched existing issues and did not find a duplicate.
- I included enough detail to reproduce or investigate the problem.
Area
apps/server
Steps to reproduce
- Create a repo-local skill following the Agent Skills standard directory that Claude Code loads:
with valid frontmatter (
<repo>/.agents/skills/my-skill/SKILL.mdname,description). - Verify Claude Code itself discovers it (open the repo in Claude Code — the skill is listed/invocable).
- Start T3 Code with a correct project cwd so this is not the cwd-scoping bug:
t3 servefrom the repo root. - Open a Claude thread for that project and type
$in the composer. - For comparison, add the same skill under
<repo>/.claude/skills/other-skill/SKILL.md— that one appears.
Expected behavior
Repo-local skills under .agents/skills should appear in the picker for Claude threads, the same way .claude/skills skills do. Claude Code loads both locations (.agents/skills is the cross-tool Agent Skills standard dir; .claude/skills wins on a same-name collision).
Actual behavior
.agents/skills skills never appear. Only <Claude config dir>/skills and <cwd>/.claude/skills are surfaced.
Root cause
This is not the server-process-cwd scoping bug (#3040, #4658, #4544). Even with a correct cwd, T3's own Claude skill discovery never scans .agents/skills — the scan root list in discoverClaudeSkills contains only two roots:
// apps/server/src/provider/Drivers/ClaudeSkills.ts (~L102)
const roots = [
{ directory: path.join(configDirPath, "skills"), scope: "user" },
...(cwd ? [{ directory: path.join(cwd, ".claude", "skills"), scope: "project" }] : []),
];So the $ picker (fed by providerStatus.skills) can never contain a .agents/skills skill, regardless of cwd. (The / picker for Claude is fed by SDK init.commands, whose project entries are the cwd bugs above — complementary, not a duplicate: once those land, .agents/skills would still be missing from T3's filesystem inventory.)
Relationship to the same symptom on other providers
The user-visible symptom — "repo-local .agents/skills don't show in the picker" — reproduces on Codex too, but that is a different root cause and is already tracked: T3 delegates Codex discovery to codex app-server (skills/list), which does scan .agents/skills; the failure there is the probe cwd (#3040, previously also reported as #3576 and closed as its duplicate, fix in flight in #5335). This issue covers only the Claude-specific gap: T3's own filesystem scanner is missing the .agents/skills root, so for Claude the symptom persists even after the cwd fixes land. Full Claude coverage needs both this fix and the cwd work (#4546 for the Claude probe).
Proposed fix (small, happy to PR)
Add <cwd>/.agents/skills as a project-scoped scan root between the user root and <cwd>/.claude/skills, keeping the existing last-write-wins map so precedence is user < .agents < .claude — matching Claude Code's own resolution (.claude/skills beats .agents/skills on a name collision, project beats user). Plus tests in ClaudeSkills.test.ts and a short skill-roots note in docs/user/providers-claude.md. ~10 lines of non-test code.
→ PR: #5488
Activity
[-][Bug]: Claude skill discovery never scans repo-local `.agents/skills` (Agent Skills standard dir)[/-][+][Bug]: Skill discovery never scans repo-local `.agents/skills` (Agent Skills standard dir)[/+]fix(claude): discover repo-local .agents/skills in skill discovery