Hook routing worker

From oimiragieo/agent-studio · View interactive version

Hook routing worker is an AI agent skill from the GitHub repository oimiragieo/agent-studio. Hook enhancements — updatedInput for bash safety prefixes, suppressOutput for verbose blocks, denial-based routing feedback

How to use this skill

Skill file

Hook Routing Worker

NOTE: Startup and cleanup are handled by worker-base. This skill defines the WORK PROCEDURE.

When to Use This Skill

Features that add hook input/output capabilities (updatedInput, suppressOutput), enhance denial-based routing feedback, or integrate hooks with the routing system.

Work Procedure

  1. Read the feature description carefully. Understand the hook protocol fields being added and how they integrate with the routing system.
  1. Read source files. Before modifying:
  1. Write tests first (red). Create test file at tests/hooks/<descriptive-name>.test.cjs. Tests must cover:

Run tests — they should FAIL (red).

  1. Implement changes.
  1. Run tests (green). All tests pass.
  1. Run lint.

```

pnpm lint

npx prettier --check <modified-files>

```

Example Handoff

{
  "salientSummary": "bash-command-validator now returns updatedInput.command with safety prefix for multi-line scripts. suppressOutput:true on blocks. 22 tests.",
  "whatWasImplemented": "updatedInput logic: detect multi-line commands missing set -e, prepend set -euo pipefail. suppressOutput:true on exit-2 blocks only. Denial feedback integration tested with seeded logs.",
  "whatWasLeftUndone": "",
  "verification": {
    "commandsRun": [
      { "command": "node --test tests/hooks/bash-updated-input.test.cjs", "exitCode": 0, "observation": "22 tests passing" },
      { "command": "pnpm lint", "exitCode": 0, "observation": "0 errors" }
    ]
  }
}

When to Return to Orchestrator

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.