← Back to context

Comment by dexwiz

10 days ago

Does anyone actually do this? I've never considered this as a practical method, mostly due to context seeming like the worst version of global, unserializable, irreproducible state. How do you maintain a system that you cannot easily inspect, even in a test environment.

I think LLMs are powerful, but not for this.

What's 'this', do you mean the command pattern being described? If so, yes - I've used it to great effect, if the code around it is designed properly. It's even amenable to evals if you can write the LLM call as a function that operates on some state:

  (document, input) -> command  
  (document, command) -> document'  
  # assert something about document' relative to document

  • Chiming in, this is exactly how I use LLMs in my yet-to-be-released product. Document reading, parsing, organizing, distilling

    Synonym+context finding, rewriting text based on rules, etc.

    Works not terribly for that! Sometimes needs a couple passes to get it right; but let it run a few times, put it in the background, and you're off to the races!