logoalt Hacker News

wren6991yesterday at 9:23 PM3 repliesview on HN

Given how poorly LLMs do with writing prompts for LLMs, I'm not sure I'd trust their judgement in designing a language for LLMs.

> and the runtime requires explicit permission to touch the filesystem, network, etc

This feels like more of an OS problem (or library problem) than a language problem.

> Run one program against many worlds. The same code can run against the real network, a scripted fake, a recording of last week's traffic, or a probability model of how servers usually behave

How is the "world" model different from plain dependency injection?


Replies

vineyardmikeyesterday at 10:15 PM

> How is the "world" model different from plain dependency injection?

In addition to what the other comment said, this "world" model is great for hermetic testing of complex code, LLM written or not. We've seen existing projects that intercept the OS level syscall for testing, replayability, etc. Building it into the language runtime, hopefully with better ergonomics from the start than a syscall, would be a welcome addition broadly.

embedding-shapeyesterday at 11:24 PM

> Given how poorly LLMs do with writing prompts for LLMs, I'm not sure I'd trust their judgement in designing a language for LLMs.

Yeah agree, what I really want to see now, is a programming language for LLMs, designed by a human (although code could still be LLM-made I suppose), and see how both of them fare in various scenarios.

inerteyesterday at 10:05 PM

I've done a version of "world" for Sigil, a programming language I was kinda doing but stopped, also for agents. LLM generated article here https://inerte.github.io/sigil/articles/worlds-not-mocks/

But basically world is a bit more narrow, that moment where your code touches the outside world (logging, http, etc), you can swap that. It's sorta like DI but deliberately narrower, only the moments where code touches the outside world are swappable.. With DI in theory you can replace anything, which has its benefits, but at least personally I am not a big fan of mocks, except when they touch the outside world. So that's what's replaceable.