You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/09_tool_interface.md
+5-5Lines changed: 5 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -168,19 +168,19 @@ The pattern is relative to `path`. `*` stays within one path segment, `**` cross
168
168
path?:string; // default /workspace
169
169
query: string;
170
170
include?:string; // glob relative to path
171
-
fixedString?:boolean; // default false
172
-
caseSensitive?:boolean;// default false
173
-
contextLines?:number; // 0 through 10
171
+
regex?:boolean;// default false
172
+
ignoreCase?:boolean;// default false
173
+
context?:number;// 0 through 10
174
174
limit?:number; // default 200, maximum 1000
175
175
offset?:number;
176
176
}
177
177
```
178
178
179
-
The AI tool defaults to case-insensitive regular expressions to match Think's tool contract. Set `fixedString` when the query should be treated as plain text. Matches include path, line number, text, and optional numbered context. Invalid regular expressions return a structured error. A non-final page includes `nextOffset`.
179
+
The AI tool defaults to literal, case-sensitive matching. Set `regex: true` to interpret `query` as a regular expression and `ignoreCase: true` to ignore letter case. Matches include path, line number, text, and optional numbered context. Invalid regular expressions return a structured error. A non-final page includes `nextOffset`.
180
180
181
181
The tool passes `include`, `limit`, and `offset` through one `workspace.fs.grep` call. The storage search pages matching files and stops after the requested matches, so an included search does not build the full file or match list in the tool layer. Directory searches return matches in deterministic depth-first discovery order, then line order within each file. They are not globally sorted by full path.
182
182
183
-
The lower-level `workspace.fs.grep`keeps its existing defaults: literal and case-sensitive. Its options also accept `limit`, `offset`, `include`, `contextLines`, `fixedString`, and `caseSensitive`.
183
+
The lower-level `workspace.fs.grep`uses the same literal, case-sensitive defaults. Its options also accept `limit`, `offset`, `include`, `context`, `regex`, and `ignoreCase`.
0 commit comments