routing-fix-worker
БесплатноБез исполняемых скриптовНе проверенFixes bugs in the agent-studio routing system (hooks, lib, state management)
от oimiragieo★ 48 звёзд на GitHubОб этом скилле
Routing Fix Worker
NOTE: Startup and cleanup are handled by worker-base. This skill defines the WORK PROCEDURE.
When to Use This Skill
Use for features that fix bugs in the routing system: hooks in .claude/hooks/routing/, library modules in .claude/lib/routing/, and state management in .claude/context/runtime/. These are surgical fixes to specific identified bugs.
Work Procedure
Read the feature description — it identifies the specific bug, affected files, and expected behavior.
Trace the bug — Use Grep to find the exact code locations. Read only the specific functions mentioned in the feature. Do NOT read entire 2000+ line files. For example, if fixing
resetToRouterMode(), grep for that function name and read only that function.Read existing tests — Check if tests already exist for this area:
tests/lib/routing/for routing lib teststests/hooks/for hook tests.claude/hooks/routing/*.test.cjsfor co-located hook tests
Write failing tests FIRST (red) — Create regression tests that demonstrate the bug. Tests use
node:testbuilt-in:const { describe, it } = require('node:test'); const assert = require('node:assert');Place tests in
tests/lib/routing/ortests/hooks/matching existing conventions.Implement the fix (green) — Make the minimal change to fix the bug. Do NOT refactor unrelated code.
CRITICAL: Windows file locking — If fixing race conditions or concurrent writes, use
proper-lockfile(already a dependency). See.claude/lib/heartbeat/heartbeat-sentinel.cjsfor the pattern. Never use naivefs.openSynclocks.Run tests — Execute
node --test tests/lib/routing/andnode --test tests/hooks/to verify your fix passes and no regressions.Run validation — Execute
pnpm validate:routingto ensure routing consistency.Manual verification — Grep for the specific pattern you fixed to confirm no other instances remain.
Example Handoff
{
"salientSummary": "Fixed resetToRouterMode() in router-state.cjs to preserve session-scoped fields (plannerSpawned, complexity) across prompt boundaries while still resetting transient fields. Added 3 regression tests covering spawn history preservation, complexity persistence, and transient field reset.",
"whatWasImplemented": "Modified resetToRouterMode() to check sessionId before resetting session-scoped fields. Added TRANSIENT_FIELDS and SESSION_SCOPED_FIELDS constants to separate concerns. Updated saveStateWithRetry() to use proper-lockfile for atomic writes.",
"whatWasLeftUndone": "",
"verification": {
"commandsRun": [
{
"command": "node --test tests/lib/routing/router-state-reset.test.cjs",
"exitCode": 0,
"observation": "3 tests passing, covers spawn preservation, complexity persistence, and transient reset"
},
{
"command": "node --test tests/lib/routing/",
"exitCode": 0,
"observation": "All 12 routing tests pass, no regressions"
},
{
"command": "pnpm validate:routing",
"exitCode": 0,
"observation": "Routing consistency validated"
}
],
"interactiveChecks": [
{
"action": "Grepped for resetToRouterMode calls across codebase",
"observed": "Called in user-prompt-unified.core.cjs line 47 and router-state.cjs line 347. Both now use the updated function."
}
]
},
"tests": {
"added": [
{
"file": "tests/lib/routing/router-state-reset.test.cjs",
"cases": [
{
"name": "preserves plannerSpawned across prompt reset",
"verifies": "VAL-RTR-001 spawn history"
},
{
"name": "preserves complexity within same session",
"verifies": "VAL-RTR-001 complexity persistence"
},
{
"name": "resets transient fields to defaults",
"verifies": "VAL-RTR-001 transient field reset"
}
]
}
]
},
"discoveredIssues": []
}
When to Return to Orchestrator
- The bug requires changes to CLAUDE.md (the router's system prompt) — that's an orchestrator decision
- The fix would change the behavior of hooks that other features depend on
- Multiple conflicting fixes are needed for the same function
- The bug is actually in a different subsystem (memory, creation, etc.)
Установить routing-fix-worker в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
FAQ
Что делает скилл routing-fix-worker?
Fixes bugs in the agent-studio routing system (hooks, lib, state management)
Как установить скилл routing-fix-worker?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл routing-fix-worker запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
theme-factory
Toolkit for styling artifacts with a theme. These artifacts can be slides, docs, reportings, HTML landing pages, etc. There are 10 pre-set themes with…
от Anthropicaccess
Manage Discord channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
от Anthropicconfigure
Set up the Discord channel — save the bot token and review access policy. Use when the user pastes a Discord bot token, asks to configure Discord, asks "how…
от Anthropicaccess
Manage iMessage channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
от Anthropic