fix: enable line range support for Grok models in read_file tool

- Remove grok-code-fast-1 from shouldUseSingleFileRead function
- This allows Grok models to use the full-featured read_file tool with args structure
- Fixes issue where Grok models could not read specific line ranges from files

Fixes #8146
This commit is contained in:
Roo Code 2025-09-18 14:10:48 +00:00
parent 87b45def18
commit 2584c713a1

View file

@ -6,9 +6,11 @@
/**
* Check if a model should use single file read format
* @param modelId The model ID to check
* @param _modelId The model ID to check (unused - all models now use full format)
* @returns true if the model should use single file reads
*/
export function shouldUseSingleFileRead(modelId: string): boolean {
return modelId.includes("grok-code-fast-1")
export function shouldUseSingleFileRead(_modelId: string): boolean {
// Currently no models require the simplified format
// Grok models now support the full args format with line ranges
return false
}