[feedback] Agent guard hooks cannot see every agent definition, so a named-teammate spawn…

Open
#2,893 0 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 5 days

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
45/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Active
Tech stack
typescript

Research direction

Start by locating LifeOS's hook configuration and the existing Agent PreToolUse guard, then trace how session-level hooks receive the agent type. Check how definitions from extra directories and JSON are represented, and how messages wake existing teammates. Done means agent-scoped guards can run at session level keyed by agent type and cover those cases; the issue does not name specific files or tests.

Written by the indexing model from the issue text.

Description

What happened

A PreToolUse hook on the Agent tool now refuses a spawn that sets name when the requested type's file has a hooks: block. It cannot be complete from a hook: agent definitions loaded from --add-dir folders or --agents JSON are not visible in the hook input, and a teammate that already exists can be woken by a message with no new spawn.

Summary

Claude Code does not apply an agent file's frontmatter hooks when the Agent tool spawns it with a name (teammate). A LifeOS install can only compensate with a PreToolUse hook on the Agent tool, and that hook cannot be complete: it does not see agent definitions loaded from extra directories or JSON, and an existing teammate can be woken by a message with no new spawn. A LifeOS-side answer would be to move agent-scoped guards to a session-level hook that keys on the agent type.

Details

  • Kind: feedback
  • LifeOS version: 8.761.0

Filed with the LifeOS /feedback command. The reporter approved this exact text before it was sent; paths, secrets and personal details were stripped locally.

Dominant language
TypeScript
Stars
19.9k
Forks
2.5k
PR merge metrics
No merged PRs in 30d

Getting set up

This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from danielmiessler/LifeOS

All issues in danielmiessler/LifeOS

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.