Which tool family a tool_use belongs to.
(name)
| 65 | |
| 66 | /** Which tool family a tool_use belongs to. */ |
| 67 | function familyOf(name) { |
| 68 | if (/codegraph/.test(name)) return 'codegraph'; |
| 69 | if (name === 'Read' || name === 'NotebookRead') return 'read'; |
| 70 | if (name === 'Grep' || name === 'Glob') return 'search'; |
| 71 | if (name === 'Bash' || name === 'BashOutput') return 'bash'; |
| 72 | return 'other'; |
| 73 | } |
| 74 | const FAMILIES = ['codegraph', 'read', 'search', 'bash', 'other']; |
| 75 | // The without-arm's way of getting the same bytes: reading and searching files. |
| 76 | const FILE_ACCESS = ['read', 'search', 'bash']; |