←back to thread

Tools: Code Is All You Need

(lucumr.pocoo.org)
313 points Bogdanp | 1 comments | | HN request time: 0.474s | source
1. CharlieDigital ◴[] No.44456665[source]

    > So maybe we need to look at ways to find a better abstraction for what MCP is great at, and code generation. For that that we might need to build better sandboxes and maybe start looking at how we can expose APIs in ways that allow an agent to do some sort of fan out / fan in for inference. Effectively we want to do as much in generated code as we can, but then use the magic of LLMs after bulk code execution to judge what we did.
Por que no los dos? I ended up writing an OSS MCP server that securely executes LLM generated JavaScript using a C# JS interpreter (Jint) and handing it a `fetch` analogue as well as `jsonpath-plus`. Also gave it a built-in secrets manager.

Give it an objective and the LLM writes its own code and uses the tool iteratively to accomplish the task (as long as you can interact with it via a REST API).

For well known APIs, it does a fine job generating REST API calls.

You can pretty much do anything with this.

https://github.com/CharlieDigital/runjs