6 ms·
Has anyone ever tried giving LLMs a backspace? I have long wondered if their responses could be better if they had the ability to correct earlier parts of their
by StilesCrisis 2mo ago
Has anyone ever tried giving LLMs a backspace? I have long wondered if their responses could be better if they had the ability to correct earlier parts of their text. Imagine how much harder it would be for us to write coherently with no backspace!
- Chu4eeno 2mo agoYes, it was invented by an anonymous user on 4chan in the early 2020s, then sanitized by a Google paper some years later as CoT (chain of thought) or thinking tags, where the model iterates on its own before writing a final response. All models do it now.
- kangalioo 2mo agoThinking mode is exactly this. The LLM is allowed to dump thoughts, correcting itself along the way, and only surfaces the cleaned-up final answer to the user
- krautsauer 2mo agoIt's not exactly this. It's something like it. But it's not a token that erases a previous token. Not that I know how that would work or how you'd get training data (edit histories of internet comments seem too few). (You could have a token that hides previous tokens, but that'd be rather closer to CoT.)
- gspr 2mo agoBacktracking, of sorts. The LLM descends a seemingly fruitful path, and all of a sudden that path seems less so. So you backtrack a few tokens ("erasing"/"undoing") and resample the probability distribution a bit back in the stream.
- krautsauer 2mo agoWould it retain some memory of the fact that it backtracked? That path becoming less likely somehow?
- gspr 2mo agoYeah that's what I was imagining. No idea how though, so this is just rambling on my part :)
- dpkirchner 2mo agoYou could burn a few tokens by prompting the LLM to summarize the omit all of the "wrong" answers (where it overrode itself), after the user accepts the response. It'd probably reduce token use in the end, especially for long sessions.
- Aissen 2mo agoI'm not sure how that would work. You'd need to be able to reverse the operations in the KV cache, and I'm not sure if it's doable or not. And then you'd need to pick another path, or "rebalance" the probabilities or you'd go the same token path. CoT is probably easier to implement (but not necessarily better).
- StilesCrisis 2mo agoYou could set up checkpoints where you store off the current state, and roll back to those checkpoints?
- Aissen 2mo agoDefinitely, this is the easy "bruteforce" way, but it would require more memory, and would not resolve the second part of the problem (i.e "how to pick a better path").
- Aissen 2mo agoI'm not an LLM engineer, but I just got an idea of how it could work, combining CoT + checkpoints : - use checkpoints to save KV cache before trigger CoT - trigger CoT, save result as a summary - go back to previous checkpoint - instead of generating tokens, add result of CoT summary as input tokens - continue normally For the price of twice the KV cache memory, the context stays perpetually small, allowing smarter sessions. You can even apply that continually by summarizing tool calls, etc. This idea is free. I'm not sure it's that advantageous though: it consumes more memory, and the sessions are already quite long at 1M+ tokens. One would need to run the economics down, and just test if the shorter sessions are actually smarter with the continuous summarization.
- zarzavat 2mo agoChatGPT does this. It will present an initial response, then change its mind partway through the thinking process and present a different response.
- StilesCrisis 2mo agoOh wow, I'd like to see this. Any prompt which reliably triggers it? (Seahorse emoji comes to mind!)
- zarzavat 2mo agoIt does it quite consistently on higher reasoning. I believe they have made display answer a tool call so that it can keep updating its answer as it thinks, instead of doing all the reasoning up front, essentially inverting the usual flow. You can use this pattern with any model that supports tool calling.
- deaton 2mo agoCopilot does this too, kinda. It will give an initial response, realize that it might tangentially criticize Microsoft, then change that response to a refusal.
- StilesCrisis 2mo agoThat's not a backspace, that's just a nanny filter. I think all bigco LLMs have something similar. e.g. Claude obviously uses this to prevent Fable from doing security work.
- kevin_thibedeau 2mo agoChatgpt will erase text it wants to censor if you get near sensitive topics.
- StilesCrisis 2mo agoWhat sort of prompt would exercise this?
- kevin_thibedeau 2mo agoI inquired into a court case against a police officer who committed a sex crime. I only wanted to know the disposition of the case with no details. It briefly spit out a response involving the victim and wiped it away with a refusal to answer more questions. This was a year ago and the behavior may have changed by now.
- StilesCrisis 2mo agoThat's just a standard nanny filter. The filter realized it was in the process of saying "sexual assault" or the like, and just shut the conversation down.