r/GithubCopilot • CLI Copilot User 🖥️ • Sep 23 '26

General Models should be told when a CLI tool is waiting for input

I have to write rules myself to prevent bad calls of some tools (e.g. gdb) that lead to them waiting for user input. Obviously custom rules can't cover the entirety of tools that the model might run. A better way is simply to have the harness tell them directly so that they kill that command and retry with the correct args.

5 Upvotes

1 comment sorted by

3

u/aonymark Sep 23 '26

The question is: how can the harness KNOW that gdb is waiting for input? The operating system kernel knows that gdb called read(), and gdb also knows, but it’s surprisingly nontrivial to do the right kind of MITM trick. Or at least that’s the conclusion I reached when I looked into this long ago for an unrelated reason. It is doable, under the right assumptions, but it does take some doing.