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
Description: fmt.Sprintf("Fetch terminal scrollback from widget %s as plain text. Index 0 is the most recent line; indices increase going upward (older lines).", blockIdPrefix),
266
+
Strict: false,
267
+
InputSchema: map[string]any{
268
+
"type": "object",
269
+
"properties": map[string]any{
270
+
"linestart": map[string]any{
271
+
"type": "integer",
272
+
"minimum": 0,
273
+
"description": "Logical start index where 0 = most recent line (default: 0)",
274
+
},
275
+
"lineend": map[string]any{
276
+
"type": "integer",
277
+
"minimum": 0,
278
+
"description": "Exclusive end index. Returns lines [linestart, lineend)",
279
+
},
280
+
"count": map[string]any{
281
+
"type": "integer",
282
+
"minimum": 1,
283
+
"description": "Alternative to lineend: number of lines to return from linestart (default: 200)",
284
+
},
285
+
},
286
+
"required": []string{},
287
+
"additionalProperties": false,
288
+
},
289
+
ToolAnyCallback: func(inputany) (any, error) {
290
+
constDEFAULT_COUNT=200
291
+
constMAX_COUNT=1000
292
+
293
+
inputMap:=make(map[string]any)
294
+
ifinput!=nil {
295
+
varokbool
296
+
inputMap, ok=input.(map[string]any)
297
+
if!ok {
298
+
returnnil, fmt.Errorf("invalid input format")
299
+
}
300
+
}
301
+
302
+
lineStart:=0
303
+
ifval, ok:=inputMap["linestart"].(float64); ok {
304
+
lineStart=int(val)
305
+
}
306
+
307
+
count:=DEFAULT_COUNT
308
+
ifval, ok:=inputMap["count"].(float64); ok {
309
+
count=int(val)
310
+
} elseiflineEndVal, ok:=inputMap["lineend"].(float64); ok {
0 commit comments