Skip to content

Fast Edits

Default Setting

VJSP enables fast edits by default (via the "Enable editing through diffs" setting). You typically don’t need to change these settings unless you encounter specific issues or want to experiment with a different diff strategy.

VJSP provides an advanced setting that changes how it edits files—by using diffs (differences) instead of rewriting entire files. Enabling this feature offers significant advantages.

Enable editing through diffs

Click the gear icon ⚙️ → Providers → Advanced settings

When "Enable editing through diffs" is checked:

  1. Faster File Editing: VJSP modifies files more quickly by applying only the necessary changes.
  2. Prevents Truncated Writes: The system automatically detects and rejects AI attempts to write incomplete file content, which can occur with large files or complex instructions. This helps prevent file corruption.

Disabling Fast Edits

If you uncheck "Enable editing through diffs", VJSP will revert to using the write_to_file tool to write the entire file content on every edit, rather than using apply_diff to apply targeted changes. This full-write approach is generally slower and results in higher token usage when modifying existing files.

Match Precision

This slider controls how closely the code segment identified by the AI must match the actual code in the file before changes are applied.

VJSP settings showing the "Enable editing through diffs" checkbox and the Match Precision slider.

  • 100% (default): Requires an exact match. This is the safest option, minimizing the risk of incorrect modifications.
  • Lower values (80%–99%): Allows "fuzzy" matching. VJSP can apply changes even if the code segment differs slightly from what the AI expected. This can be useful when files have been slightly modified, but increases the risk of applying changes in the wrong location.

Use values below 100% with extreme caution. Lower precision may occasionally be necessary, but always carefully review the proposed changes.

Internally, this setting adjusts the fuzzyMatchThreshold (e.g., Levenshtein distance) algorithm used to compare code similarity.