Does LM Return Entire File When Making a One-Line Change?

When I ask Cursor to update N lines in a file, or make a change that logically only affects N lines:

  1. Does the language model return the entire updated file content for Cursor to apply?
  2. Does Cursor replace the file content entirely?

My experience suggests some form of this is true.* My concern is software that charges or rate-limits based on tokens would recognize a 20-token change in a 200-token document as a 200-token change.

* If I ask Cursor to fix broken links in all files — files which happen to have curly quotes — it will perform the task I give it, but also replace all curly quotes with straight quotes. The quote replacement is an independent bug, but one I do not expect because the quotes are on lines of the file that are irrelevant to the task performed.

Hey, if you ask the Composer to update your code, it only returns snippets of the updates needed (so not every line of the file).

Then, our custom “apply” model has been trained to take these snippets and apply them to the whole file at record speeds.

This means, to summarise, the LLM you choose does not get fed/output your entire file, only the apply model does!

1 Like