I get what you're saying but to be slightly pedantic etc.
Why can't an llm tool call `delete(index: int)` or `replace(from_index: int, to_index: int, string: str)` and then it can go back and edit just the way we can?
We also first made the mistake and only afterwards noticed we actually want to change something
It can, that's why things like planning and reasoning are so effective. Planning effectively gives them a scratchpad they can keep modifying till they're satisfied without being constrained into the "only go forward" output they usually produce. Reasoning is also the same idea. Although I have on rare occasions seen in plans models saying "blabla above is wrong, I should instead do …" instead of actually fixing the plan, but that's another problem
Why can't an llm tool call `delete(index: int)` or `replace(from_index: int, to_index: int, string: str)` and then it can go back and edit just the way we can?
We also first made the mistake and only afterwards noticed we actually want to change something