<https://blog.cloudflare.com/code-mode/> saw this ...
# koog-agentic-framework
k
https://blog.cloudflare.com/code-mode/ saw this and I wondered how the approach might be applied to koog
👀 1
👍 1
🙌 1
v
That’s something requiring dynamic languages like python or javascript/typescript. You can do it with JS target of Koog + a few tweaks to glue everything together. But honestly it’s not the safest pattern for serious production — you are allowing LLM to execute any code in your system and providing essentially a code execution API. It would require lots of engineering to make it restrictive enough so that it wouldn’t crash your machine at some point.
Upd: just read this in the article, The code is then executed in a secure sandbox. The sandbox is totally isolated from the Internet. Its only access to the outside world is through the TypeScript APIs representing its connected MCP servers.
Quite interesting that it was performing better than normal tool calling. Probably because everyone is playing this SWE-bench game now , and models are highly optimised for coding
💯 1
k
I mean, kinda already allowing llms to execute code, the loop is just a lot faster this way
Definitely nice that it can be in a secure sandbox
g
Actually, I already did it with kotlin scripting. gpt-120-oss, running on low latency groq inference, and I had in some cases < 1s request to action, and frankly in this context the Kotlin compiler is SLOW. I generate kotlin DSL stubs that I provide to the llm. Initially it was a narrow scope, but I've been expanding the framework a little. I also care about things like preemptive execution and back driveability, so not pure kotlin in the future