Claude Code Bash searches bypass codebase-memory hook augmentation
Reproduction
With codebase-memory-mcp 0.9.0, invoke hook-augment with:
{"tool_name":"Grep","tool_input":{"pattern":"CreateStripeCheckout"}}
It returns four graph symbol matches.
Invoke it with the equivalent Claude Code Bash payload:
{"tool_name":"Bash","tool_input":{"command":"rg -n CreateStripeCheckout ."}}
It returns no graph context.
Claude Code commonly runs rg, grep, and find through the Bash tool, so code discovery silently bypasses graph augmentation when the PreToolUse matcher only covers Grep|Glob.
Expected behavior
Bash-based code searches should receive the same graph augmentation as native Grep searches, or the installer should provide a reliable Claude Code integration that detects these searches.
Workaround
A Bash PreToolUse adapter that extracts the search pattern, reshapes the payload as Grep, and forwards it to hook-augment restores the expected context.
This is an integration/installer issue: the MCP graph query itself works, but Claude Code's common Bash search path bypasses it.
Claude Code Bash searches bypass codebase-memory hook augmentation
Reproduction
With codebase-memory-mcp 0.9.0, invoke
hook-augmentwith:{"tool_name":"Grep","tool_input":{"pattern":"CreateStripeCheckout"}}It returns four graph symbol matches.
Invoke it with the equivalent Claude Code Bash payload:
{"tool_name":"Bash","tool_input":{"command":"rg -n CreateStripeCheckout ."}}It returns no graph context.
Claude Code commonly runs
rg,grep, andfindthrough theBashtool, so code discovery silently bypasses graph augmentation when the PreToolUse matcher only coversGrep|Glob.Expected behavior
Bash-based code searches should receive the same graph augmentation as native
Grepsearches, or the installer should provide a reliable Claude Code integration that detects these searches.Workaround
A Bash PreToolUse adapter that extracts the search pattern, reshapes the payload as
Grep, and forwards it tohook-augmentrestores the expected context.This is an integration/installer issue: the MCP graph query itself works, but Claude Code's common Bash search path bypasses it.