[MODEL] Frequently uses Bash tools (sed/grep/etc) when use-case is well aligned to other builtin tools (Read/Grep/etc)
### Preflight Checklist - [x] I have searched [existing issues](https://github.com/anthropics/claude-code/issues?q=is%3Aissue%20state%3Aopen%20label%3Amodel) for similar behavior reports - [x] This report does NOT contain sensitive information (API keys, passwords, etc.) ### Type of Behavior Issue Other unexpected behavior ### What You Asked Claude to Do See attached (redacted, and line-wrapped for readability) for a full exchange analyzing occurrences based on claude/agent logs. The analysis ran afoul of some of the same issues being analyzed. [claude.cat-sed-grep.txt](https://github.com/user-attachments/files/24756859/claude.cat-sed-grep.txt) ### What Claude Actually Did I frequently see Bash tool permission requests invocations just like the following: ```sh # Output lines 147-162 from a given file. sed -n 147,162p /path/to/some/file # Search for a pattern in a directory. grep -r "^some pattern$" /path/to/some/dir # Write a file from content expressed via heredoc. cat > file.txt <<EOF ... EOF ``` Often these are just solitary commands (not as part of a pipeline). Sometimes, e.g. grep, might be piped to `head`. Sometimes these `&&`'d commands like: ```sh cat > file.py <<EOF ... EOF && chmod +x file.py && ./file.py ``` ### Expected Behavior All of the above examples are undesirable. These cases should broadly use the `Read`, `Grep` (builtin, **not** `Bash(grep)`), and `Write`/`Edit`. The `&&`'d example above ideally should use `Write` followed by `Bash` tool
Posted by extemporalgenome on Jan 21, 2026, 5:23 AM
Tags
Related issues
- [Meta] Feedback on granular control over Copilot changes
- unexpected status 401 Unauthorized issue
- [MODEL] Measurable quality regression in Claude generation 5 (Fable 5 / Opus 5 / Sonnet 5): worse nonsense detection, ~2x verbosity, under-disclosed model fallb
- [CRITICAL] Subagent spawning and subagent pattern bugs trigger infinite recursion, infinite token usage, grossly inefficient token usage, and lost accumulated s
- Video stops playing after some minutes
- [MODEL] Claude verbose code comments by default — ignores instructions to stop.
Raise real-world problems, find people facing the same issue, and discuss solutions.2,000 issues0 comments
github (Software)
[Meta] Feedback on granular control over Copilot changes
unexpected status 401 Unauthorized issue
[MODEL] Measurable quality regression in Claude generation 5 (Fable 5 / Opus 5 / Sonnet 5): worse nonsense detection, ~2x verbosity, under-disclosed model fallb
[CRITICAL] Subagent spawning and subagent pattern bugs trigger infinite recursion, infinite token usage, grossly inefficient token usage, and lost accumulated s
Video stops playing after some minutes
[MODEL] Claude verbose code comments by default — ignores instructions to stop.
Scope Codex VS Code chats to the current workspace/project
Update on "Co-authored-by: Copilot" in commit messages
[MODEL] Frequently uses Bash tools (sed/grep/etc) when use-case is well aligned to other builtin tools (Read/Grep/etc)
### Preflight Checklist - [x] I have searched [existing issues](https://github.com/anthropics/claude-code/issues?q=is%3Aissue%20state%3Aopen%20label%3Amodel) for similar behavior reports - [x] This report does NOT contain sensitive information (API keys, passwords, etc.) ### Type of Behavior Issue Other unexpected behavior ### What You Asked Claude to Do See attached (redacted, and line-wrapped for readability) for a full exchange analyzing occurrences based on claude/agent logs. The analysis ran afoul of some of the same issues being analyzed. [claude.cat-sed-grep.txt](https://github.com/user-attachments/files/24756859/claude.cat-sed-grep.txt) ### What Claude Actually Did I frequently see Bash tool permission requests invocations just like the following: ```sh # Output lines 147-162 from a given file. sed -n 147,162p /path/to/some/file # Search for a pattern in a directory. grep -r "^some pattern$" /path/to/some/dir # Write a file from content expressed via heredoc. cat > file.txt <<EOF ... EOF ``` Often these are just solitary commands (not as part of a pipeline). Sometimes, e.g. grep, might be piped to `head`. Sometimes these `&&`'d commands like: ```sh cat > file.py <<EOF ... EOF && chmod +x file.py && ./file.py ``` ### Expected Behavior All of the above examples are undesirable. These cases should broadly use the `Read`, `Grep` (builtin, **not** `Bash(grep)`), and `Write`/`Edit`. The `&&`'d example above ideally should use `Write` followed by `Bash` tool
Comments (0)
No comments yet. Start the discussion.