Skip to content

Conversation

@bassamsdata
Copy link
Contributor

@bassamsdata bassamsdata commented Oct 22, 2025

Description

Prerequisite: PR #2219

3 new/refactored changes in this PR:

  1. New FS Monitor to track all chnages made by LLM to the files.
  2. New UI for SuperDiff.

Details:

This replaces the old snapshot-based edit_tracker with FSMonitor, an event-driven file system monitor.

FSMonitor uses OS-level file events (vim.uv.new_fs_event) and async I/O to reliably detect created, modified, deleted, and renamed files.

It keeps a content cache for efficient diffing, debounces rapid events, and exposes APIs to start/stop watches, tag changes by tool execution time ranges, and retrieve change lists or stats.

What this fixes and benefits:

  • Race conditions and unreliable diffs from snapshot comparisons.
  • Inability to detect file creation, deletion, and renames.
  • Blocking or slow I/O due to synchronous reads.
  • Easier to extend (e.g., restore checkpoints) and to integrate with ACP, HTTP, or future adapters and strategies or external tools.
  • Way more cleaner API suitable for broader plugin ecosystem/extensions

Note:
this is still work in progress.

Thank you

Related Issue(s)

Screenshots

Checklist

  • I've read the contributing guidelines and have adhered to them in this PR
  • I've added test coverage for this fix/feature
  • I've run make all to ensure docs are generated, tests pass and my formatting is applied
  • (optional) I've updated CodeCompanion.has in the init.lua file for my new feature
  • (optional) I've updated the README and/or relevant docs pages

@bassamsdata bassamsdata changed the title Replace snapshot-based edit_tracker with event-driven FSMonitor New File System Change Tracking, Enhanced Super Diff, and Diff Navigation Oct 27, 2025
@bassamsdata bassamsdata changed the title New File System Change Tracking, Enhanced Super Diff, and Diff Navigation New File System Change Tracking, Enhanced Super Diff Nov 6, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant