Skip to content

feat: register team-discover hooks + add Skill Check step to preset commands#103

Merged
kanfil merged 1 commit into
mainfrom
feat/team-discover-hooks
Jul 15, 2026
Merged

feat: register team-discover hooks + add Skill Check step to preset commands#103
kanfil merged 1 commit into
mainfrom
feat/team-discover-hooks

Conversation

@kanfil

@kanfil kanfil commented Jul 15, 2026

Copy link
Copy Markdown
Member

Summary

The team-ai-directives extension declared no hooks in its extension.yml, so register_hooks() wrote nothing for before_specify/before_plan. The team.discover.md command documented these hooks but the manifest never declared them — leaving personas, rules, examples, and team skills undiscovered during /spec.specify and /spec.plan.

This was found by reviewing a session trace of /spec.constitution and /spec.specify where team skills were never triggered despite the AGENTS.md injection being present.

Changes

Part 1: Register team-discover hooks (extensions/team-ai-directives/extension.yml)

  • Added hooks: block with mandatory before_specify + before_plan hooks (optional: false) pointing at adlc.team-ai-directives.discover.
  • On install/update, register_hooks(manifest) now writes these to .specify/extensions.yml, so the spec workflow's existing pre-execution hook checks auto-invoke /team.discover.
  • Bumped extension version to 4.2.0.

Part 2: Add generic Skill Check step to 11 preset command files

  • All preset commands in agentic-sdlc (9 adlc.spec.* + adlc.spec.specify) and agentic-quick (adlc.quick.implement) now include a generic "Skill Check" step before the extension hook checks.
  • This bridges the ambient AGENTS.md "Strict Compliance" directive into the command's procedural flow, preventing the "STOP. execute extension hooks" tunnel from overriding it.
  • Fully generic — does not name any specific skill.

Part 3: Strengthen AGENTS.md injection text

  • update-agent-context.sh / .ps1 / .py: strengthened "Strict Compliance" bullet with "This is not optional and applies to every interaction."

Part 4: Tests, CHANGELOGs, version bump

  • test_team_ai_directives_declares_hooks: verifies manifest declares both hooks with correct command and optional: false.
  • Root CHANGELOG: 0.12.15+adlc3 entry.
  • extensions/team-ai-directives/CHANGELOG.md: 4.2.0 entry.
  • pyproject.toml: version bump to 0.12.15+adlc3.

Test plan

  • test_team_ai_directives_declares_hooks passes
  • 425 tests pass (test_bundled_extension_hooks.py + test_extensions.py + test_extension_registration.py + test_agent_config_consistency.py)
  • Manual: run specify extension update team-ai-directives in a workspace with team-ai-directives installed, verify before_specify and before_plan hooks appear in .specify/extensions.yml

Migration

Existing workspaces: run specify extension update team-ai-directives to populate the new before_specify / before_plan hooks in .specify/extensions.yml.

Assisted-by: opencode (model: glm-5.2, supervised)

…ommands

The team-ai-directives extension declared no hooks in its extension.yml,
so register_hooks() wrote nothing for before_specify/before_plan. The
team.discover.md command documented these hooks but the manifest never
declared them — leaving personas, rules, examples, and team skills
undiscovered during /spec.specify and /spec.plan.

Changes:
- team-ai-directives/extension.yml: add hooks block with mandatory
  before_specify + before_plan hooks (optional: false) pointing at
  adlc.team-ai-directives.discover. Bump to v4.2.0.
- 11 preset command files (agentic-sdlc + agentic-quick): add generic
  Skill Check step before the extension hook checks. Bridges the ambient
  AGENTS.md Strict Compliance directive into the procedural flow so it
  is not overridden by the STOP-execute-hooks tunnel. Fully generic —
  no specific skill names referenced.
- update-agent-context.sh/.ps1/.py: strengthen Strict Compliance bullet
  with "This is not optional and applies to every interaction."
- test_team_ai_directives_declares_hooks: verify manifest declares both
  hooks with correct command and optional: false.
- Version bump to 0.12.15+adlc3.

Existing workspaces: run `specify extension update team-ai-directives`
to populate the new hooks in .specify/extensions.yml.

Assisted-by: opencode (model: glm-5.2, supervised)
@kanfil
kanfil merged commit 4e7fc4a into main Jul 15, 2026
12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant