For what reason are they encouraging it to use bash over the purpose-specific tools?
So the agent is going to put less into context when it uses sed to see 15 lines of a file than using read and putting the entire file into context.
That is my best charitable guess at what they are hoping to achieve.
Of course, there is an obvious set of solutions for this problem that don't involve pushing the agent to use bash.
Part of the reason i assume is that to extract 5 line ranges is a single line very small sed call that it has to output, but 5 separate full read calls it has to output correctly and quickly.
Who knows.