Examples · learn/18-approval · 232 of 339
approved
run: --yes
tin run examples/learn/18-approval/approved.tin// run: --yes
/// Permanently delete a file.
guarded tool fn deleteFile(path: string): string => "deleted {path}"
agent Janitor {
model: "mock"
tools: [deleteFile]
on toolResult(name, output, ok) => print(" {name} -> {output}")
}
fn main() {
print(Janitor("deleteFile 'old-backup.zip'"))
}