cpwrap runs whatever command you pass it, sending the transcript to copilot and giving you autocomplete suggestions along the way. It's like how rlwrap gives you readline input editing- cpwrap gives you copilot input editing.
In other words, copilot for ed: https://twitter.com/markdotdev/status/1616273277533446145
Or sh, python, any non-curses interactive shell program.
And it's a single public domain c file, though you need node and the copilot extension files to run the copilot agent. (And a copilot subscription.)