CommandCodeAI / CommandCodeAI/command-code
Feature: Just 3 Hooks are there Please expand the hooks system to match Claude Code / Codex parity
@vipulgupta2048 已經在處理了。
開始於 2026年6月30日。
- 主要語言
- 沒有語言資料
- 星號
- 4k
- 分支
- 350
- PR 合併指標
- 30 天內沒有已合併 PR
描述
Feature Description
Command Code currently supports only 3 hook events:
PreToolUsePostToolUseStop
This is severely limited compared to Codex and Claude Code, which both expose a much richer hook lifecycle. The gaps prevent meaningful observability, automation, and integration with orchestration tools like herdr, tmux, and cmux.
Missing events (present in Codex):
PermissionRequest— intercept before a permission dialogPostCompact/PreCompact— hook around context compactionSessionStart— fire on session begin/resumeSubagentStart/SubagentStop— detect when subagents spawn/finishUserPromptSubmit— intercept before Claude processes the prompt
Missing events (present in Claude Code, not even in Codex):
Setup— one-time prep on initUserPromptExpansion— before slash command expands to a promptPermissionDenied— when auto-mode classifier denies a tool callPostToolUseFailure— after a tool call fails (currently only success is hooked)PostToolBatch— after a full parallel tool batch resolvesNotification— when the assistant sends a notificationMessageDisplay— while assistant message text is being displayedTaskCreated— when a task is created viaTaskCreate
Missing tool matcher support:
Command Code's supported tools table (shell, read, write, edit) also lacks matcher support for MCP tools, which both Codex and Claude Code support via mcp__* patterns.
Use Case
Without these hooks, Command Code cannot be properly integrated into multi-agent orchestration setups.
Concrete pain points today:
- herdr cannot recognize
cmdagents in tmux/cmux sessions because there is noSessionStartorSubagentStartevent to listen on — the hooks to signal "an agent started" simply don't exist - No failure visibility —
PostToolUseFailureis missing, so failed tool calls are silent - No notification hooks — the
Notificationevent missing means tools like cmux cannot trigger alerts when Command Code finishes a task - No permission interception —
PermissionRequest/PermissionDeniedmissing means no way to auto-approve or audit permission dialogs programmatically - No subagent lifecycle —
SubagentStart/SubagentStopmissing breaks any workflow that needs to track spawned agents
Codex and Claude Code already solved these. Command Code needs hook parity to be usable in the same workflows.
Additional Context
Reference implementations for all listed events:
- Claude Code hooks reference: https://docs.claude.com (Reference > Hooks reference)
- Codex hooks reference: https://platform.openai.com/docs/codex (Configuration > Hooks)
Priority order for missing events (highest impact first):
SessionStart— needed for herdr/cmux agent detectionSubagentStart/SubagentStop— needed for multi-agent orchestrationNotification— needed for cmux notification triggersPostToolUseFailure— needed for error observabilityPermissionRequest/PermissionDenied— needed for auto-approval workflowsUserPromptSubmit— needed for prompt interceptionPostToolBatch,MessageDisplay,TaskCreated,UserPromptExpansion,Setup— parity completion
How important is this to you?
Very important
貢獻指南
這個儲存庫沒有索引到貢獻指南
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
評估
這個 Issue 還沒有評估資料。