Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I have a tool wrapper that captures the output of anything and allows the LLM to query it later, to save on tokens. It “smartly” truncates the output (basically like Node’s util.inspect) and allows the LLM to expand truncated content.

It basically is called like “capture some-cli” and it… captures the CLI output, outputting a subset of it + a handle to continue querying.

This for me solves the danger of a tool returning tons of content.



> captures the output of anything and allows the LLM to query it later

Otherwise known as a “file”. ;)


I’ve been trying headroom-ai for this reason. That project also reduces tokens in other clever ways. Have you looked into it?


Don't most harnesses already do that for bash commands?




Consider applying for YC's Winter 2027 batch! Applications are open till November 2.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: