Expand description
Sandboxed tools exposed to the model as OpenAI function calls. Target-crate
tools (read_file, list_dir, grep, optional rg, web_fetch, and gated
edit_file) resolve paths relative to the scheduler crate or public URLs;
comparison tools read other schedulers under scheds/rust but never write
them. Host-topology tools run fixed read-only commands or read fixed sysfs
CPU cache metadata paths.
Absolute paths and .. are rejected, and canonicalized targets must stay
inside their configured roots.
ConstantsΒ§
- DEFAULT_
WEB_ πFETCH_ BYTES - LOCAL_
TOOL_ πTIMEOUT - MAX_
GREP_ πMATCHES - MAX_
READ_ πBYTES - MAX_
RG_ πOUTPUT_ BYTES - MAX_
SCHED_ πREAD_ BYTES - MAX_
TOPOLOGY_ πOUTPUT_ BYTES - MAX_
WEB_ πFETCH_ BYTES
FunctionsΒ§
- collapse_
text π - count_
occurrences π - cpu_
cache_ πsizes - cpu_
cache_ πsizes_ from_ root - decode_
basic_ πentities - edit_
file π - execute_
tool - Dispatch a tool call.
allow_editgatesedit_file. - execute_
tool_ async - Async dispatch for tools that may perform network I/O.
- fuzzy_
line_ πmatch - Find a unique block of lines in
contentwhose whitespace-trimmed text equals the trimmed lines ofneedle(ignoring indentation and blank lines around the block). Returns the byte range [start, end) of that block, or None if there is not exactly one match. - grep π
- grep_
dir π - grep_
schedulers π - html_
to_ πtext - is_
disallowed_ πhost - is_
disallowed_ πip - is_
write_ tool - True for write-capable tools (used by the controller to count edits per round).
- list_
dir π - list_
schedulers π - lscpu_e π
- nearest_
lines π - Up to 5 file lines (with 1-based line numbers) that contain
anchor, for error feedback when old_string doesnβt match. - normalized_
crate_ πrelative_ path - numactl_
hardware π - openai_
tools_ json - The function-calling tool schema advertised to the model.
- parse_
prefixed_ πu32 - read_
file π - read_
path π - read_
scheduler_ πfile - read_
trimmed π - resolve π
- Resolve a crate-relative path inside
sandbox, rejecting../absolute and escapes. - resolve_
scheduler_ πpath - rg π
- rg_
available π - rg_
glob_ πarg - run_
fixed_ πtopology_ command - scheduler_
dir π - strip_
line_ πnumber_ prefixes - Strip a leading line-number+tab prefix (as emitted by read_fileβs
"{:>6}\t"format) from each line. Preserves a trailing newline. - truncate_
lossy π - validate_
public_ πurl - web_
fetch π - web_
fetch_ πcontent_ type_ allowed - web_
fetch_ πmax_ bytes